Functions¶
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Details¶
- Dee.filter_new(map_func, map_notify, *userdata)¶
- Parameters:
map_func (
Dee.FilterMapFunc) – TheDee.FilterMapFuncto use for the filtermap_notify (
Dee.FilterMapNotify) – TheDee.FilterMapNotifyto use for the filteruserdata (
objectorNone) – The user data to pass to map_func and map_notify
- Returns:
A pointer to an uninitialized
Dee.Filterstruct. This struct will zeroed and configured with the filter parameters- Return type:
out_filter:
Dee.Filter
Create a new
Dee.Filterwith the given parameters. This call will zero the out_filter struct.
- Dee.filter_new_collator(column)¶
- Parameters:
column (
int) – The index of a column containing the strings to sort after- Returns:
A pointer to an uninitialized
Dee.Filterstruct. This struct will zeroed and configured with the filter parameters- Return type:
out_filter:
Dee.Filter
Create a
Dee.Filterthat takes string values from a column in the model and builds aDee.FilterModelwith the rows sorted according to the collation rules of the current locale.
- Dee.filter_new_collator_desc(column)¶
- Parameters:
column (
int) – The index of a column containing the strings to sort after- Returns:
A pointer to an uninitialized
Dee.Filterstruct. This struct will zeroed and configured with the filter parameters- Return type:
out_filter:
Dee.Filter
Create a
Dee.Filterthat takes string values from a column in the model and builds aDee.FilterModelwith the rows sorted descending according to the collation rules of the current locale.
- Dee.filter_new_for_any_column(column, value)¶
- Parameters:
column (
int) – The index of a column containing the string to matchvalue (
GLib.Variant) – AGLib.Variantvalue columns must match exactly. The matching semantics are those ofGLib.Variant.equal(). If value is floating the ownership will be transfered to the filter
- Returns:
A pointer to an uninitialized
Dee.Filterstruct. This struct will zeroed and configured with the filter parameters- Return type:
out_filter:
Dee.Filter
Create a
Dee.Filterthat only includes rows from the original model which match a variant value in a given column. ADee.FilterModelcreated with this filter will be ordered in accordance with its parent model.This method will work on any column, disregarding its schema, since the value comparison is done using
GLib.Variant.equal(). This means you can use this filter as a convenient fallback when there is no predefined filter for your column type if raw performance is not paramount.
- Dee.filter_new_for_key_column(column, key)¶
- Parameters:
- Returns:
A pointer to an uninitialized
Dee.Filterstruct. This struct will zeroed and configured with the filter parameters- Return type:
out_filter:
Dee.Filter
Create a
Dee.Filterthat only includes rows from the original model which has an exact match on some string column. ADee.FilterModelcreated with this filter will be ordered in accordance with its parent model.
- Dee.filter_new_regex(column, regex)¶
- Parameters:
column (
int) – The index of a column containing the string to matchregex (
GLib.Regex) – The regular expression column must match
- Returns:
A pointer to an uninitialized
Dee.Filterstruct. This struct will zeroed and configured with the filter parameters- Return type:
out_filter:
Dee.Filter
Create a
Dee.Filterthat only includes rows from the original model which match a regular expression on some string column. ADee.FilterModelcreated with this filter will be ordered in accordance with its parent model.
- Dee.filter_new_sort(cmp_row, *cmp_user_data)¶
- Parameters:
cmp_row (
Dee.CompareRowFunc) – ADee.CompareRowFuncto use for sortingcmp_user_data (
objectorNone) – User data passed to cmp_row
- Returns:
A pointer to an uninitialized
Dee.Filterstruct. This struct will zeroed and configured with the filter parameters- Return type:
out_filter:
Dee.Filter
Create a new
Dee.Filtersorting a model according to aDee.CompareRowFunc.
- Dee.model_reader_new(reader_func, *userdata)¶
- Parameters:
reader_func (
Dee.ModelReaderFunc) – TheDee.ModelReaderFuncto use for the readeruserdata (
objectorNone) – The user data to pass to reader_func
- Returns:
A pointer to an uninitialized
Dee.ModelReaderstruct- Return type:
out_reader:
Dee.ModelReader
Create a new
Dee.ModelReaderwith the given parameters. This call will zero the out_reader struct.
- Dee.model_reader_new_for_int32_column(column)¶
- Parameters:
column (
int) – The column index to read a %gint32 from- Returns:
A pointer to a
Dee.ModelReaderinstance which will have all fields initialized appropriately- Return type:
out_reader:
Dee.ModelReader
A
Dee.ModelReaderreading a %gint32 from aDee.Modelat a given column
- Dee.model_reader_new_for_string_column(column)¶
- Parameters:
column (
int) – The column index to read a string from- Returns:
A pointer to a
Dee.ModelReaderinstance which will have all fields initialized appropriately- Return type:
out_reader:
Dee.ModelReader
A
Dee.ModelReaderreading a string from aDee.Modelat a given column
- Dee.model_reader_new_for_uint32_column(column)¶
- Parameters:
column (
int) – The column index to read a %guint32 from- Returns:
A pointer to a
Dee.ModelReaderinstance which will have all fields initialized appropriately- Return type:
out_reader:
Dee.ModelReader
A
Dee.ModelReaderreading a %guint32 from aDee.Modelat a given column
- Dee.resource_manager_get_default()¶
- Returns:
The default resource manager for the platform. Do not unreference. If you need to keep the instance around you must manually reference it.
- Return type:
Get a pointer to the platform default
Dee.ResourceManager.
- Dee.serializable_parse(data, type)¶
- Parameters:
data (
GLib.Variant) – TheGLib.Variantdata to parse. If this is a floating reference it will be consumedtype (
GObject.GType) – TheGObject.GTypeof the class to instantiate from data
- Returns:
A newly constructed
GObject.Objectbuild from data orNonein case no parser has been registered for the givenGObject.GTypeor variant signature. Free withGObject.Object.unref().- Return type:
Reconstruct a
Dee.SerializablefromGLib.Variantdata. For this function to work you need to register a parser with dee_serializable_register_parser(). Any native Dee class will do so automatically.This method only works on data created with
Dee.Serializable.serialize() and not with data fromDee.Serializable.externalize().Since a
Dee.SerializableParseFuncis not allowed to fail - by contract - it can be guaranteed that this function only returnsNonein case there is no known parser for type andGLib.Variantsignature of data.
- Dee.serializable_parse_external(data)¶
- Parameters:
data (
GLib.Variant) – TheGLib.Variantdata to parse- Returns:
A newly constructed
GObject.Objectbuild from data orNonein case no parser has been registered for the givenGObject.GTypeor variant signature. Free withGObject.Object.unref().- Return type:
Reconstruct a
Dee.SerializablefromGLib.Variantdata. For this function to work you need to register a parser with dee_serializable_register_parser(). Any native Dee class will do so automatically.This method only works on data created with
Dee.Serializable.externalize() and not with data fromDee.Serializable.serialize().Since a
Dee.SerializableParseFuncis not allowed to fail - by contract - it can be guaranteed that this function only returnsNonein case there is no known parser for theGObject.GTypeorGLib.Variantsignature of data.