gi-glib-2.0.30: GLib bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellSafe-Inferred
LanguageHaskell2010

GI.GLib.Structs.Tuples

Description

The Tuples struct is used to return records (or tuples) from the Relation by g_relation_select(). It only contains one public member - the number of records that matched. To access the matched records, you must use tuplesIndex.

Synopsis

Exported types

newtype Tuples Source #

Memory-managed wrapper type.

Constructors

Tuples (ManagedPtr Tuples) 

Instances

Instances details
Eq Tuples Source # 
Instance details

Defined in GI.GLib.Structs.Tuples

Methods

(==) :: Tuples -> Tuples -> Bool #

(/=) :: Tuples -> Tuples -> Bool #

BoxedPtr Tuples Source # 
Instance details

Defined in GI.GLib.Structs.Tuples

CallocPtr Tuples Source # 
Instance details

Defined in GI.GLib.Structs.Tuples

ManagedPtrNewtype Tuples Source # 
Instance details

Defined in GI.GLib.Structs.Tuples

Methods

toManagedPtr :: Tuples -> ManagedPtr Tuples

tag ~ 'AttrSet => Constructible Tuples tag Source # 
Instance details

Defined in GI.GLib.Structs.Tuples

Methods

new :: MonadIO m => (ManagedPtr Tuples -> Tuples) -> [AttrOp Tuples tag] -> m Tuples

newZeroTuples :: MonadIO m => m Tuples Source #

Construct a Tuples struct initialized to zero.

Methods

Click to display all available methods, including inherited ones

Expand

Methods

destroy, index.

Getters

None.

Setters

None.

destroy

tuplesDestroy Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Tuples

tuples: the tuple data to free.

-> m () 

Deprecated: (Since version 2.26)Rarely used API

Frees the records which were returned by g_relation_select(). This should always be called after g_relation_select() when you are finished with the records. The records are not removed from the Relation.

index

tuplesIndex Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Tuples

tuples: the tuple data, returned by g_relation_select().

-> Int32

index_: the index of the record.

-> Int32

field: the field to return.

-> m (Ptr ())

Returns: the field of the record.

Deprecated: (Since version 2.26)Rarely used API

Gets a field from the records returned by g_relation_select(). It returns the given field of the record at the given index. The returned value should not be changed.

Properties

len

the number of records that matched.

getTuplesLen :: MonadIO m => Tuples -> m Word32 Source #

Get the value of the “len” field. When overloading is enabled, this is equivalent to

get tuples #len

setTuplesLen :: MonadIO m => Tuples -> Word32 -> m () Source #

Set the value of the “len” field. When overloading is enabled, this is equivalent to

set tuples [ #len := value ]