gda.holder

Module for [Holder] class

Types 4

Methods
GType _gType() @property
Holder self()Returns `this`, for use in `with` statements.
HolderGidBuilder builder()Get builder for [gda.holder.Holder] Returns: New builder object
string description() @property
void description(string propval) @property
void fullBind(gda.holder.Holder propval) @property
void gType(gobject.types.GType propval) @property
string id() @property
void id(string propval) @property
string name() @property
void name(string propval) @property
bool notNull() @property
void notNull(bool propval) @property
void simpleBind(gda.holder.Holder propval) @property
int sourceColumn() @property
void sourceColumn(int propval) @property
void sourceModel(gda.data_model.DataModel propval) @property
bool validateChanges() @propertyGet `validateChanges` property. Returns: Defines if the "validate-change" signal gets emitted when the holder's value changes.
void validateChanges(bool propval) @propertySet `validateChanges` property. Params: propval = Defines if the "validate-change" signal gets emitted when the holder's value changes.
gda.holder.Holder copy()Copy constructor.
void forceInvalid()Forces a holder to be invalid; to set it valid again, a new value must be assigned to it using [gda.holder.Holder.setValue] or [gda.holder.Holder.takeValue].
void forceInvalidE(glib.error.ErrorWrap error = null)Forces a holder to be invalid; to set it valid again, a new value must be assigned to it using [gda.holder.Holder.setValue] or [gda.holder.Holder.takeValue].
string getAlphanumId()Get an "encoded" version of holder's name. The "encoding" consists in replacing non alphanumeric character with the string "__gdaXX" where XX is the hex. representation of the non alphanumeric char.
gobject.value.Value getAttribute(string attribute)Get the value associated to a named attribute.
gda.holder.Holder getBind()Get the holder which makes holder change its value when the holder's value is changed. Returns: the #GdaHolder or null
gobject.value.Value getDefaultValue()Get the default value held into the holder. WARNING: the default value does not need to be of the same type as the one required by holder. Returns: the default value
string getId()Get the ID of holder. The ID can be set using holder's "id" property Returns: the ID (don't modify the string).
bool getNotNull()Get wether the holder can be NULL or not Returns: TRUE if the holder cannot be NULL
gobject.value.Value getValue()Get the value held into the holder. If holder is set to use its default value and that default value is not of the same type as holder, then null is returned.
string getValueStr(gda.data_handler.DataHandler dh = null)Same functionality as [gda.holder.Holder.getValue] except that it returns the value as a string (the conversion is done using dh if not null, or the default data handler otherwise).
bool isValid()Get the validity of holder (that is, of the value held by holder) Returns: TRUE if holder's value can safely be used
bool isValidE()Get the validity of holder (that is, of the value held by holder) Returns: TRUE if holder's value can safely be used Throws: [HolderException]
void setAttribute(string attribute, gobject.value.Value value, glib.types.DestroyNotify destroy)Set the value associated to a named attribute. The attribute string is 'stolen' by this method, and the memory it uses will be freed using the destroy function when no longer needed (if destroy is ...
bool setBind(gda.holder.Holder bindTo)Sets holder to change when bindto changes (and does not make bindto change when holder changes). For the operation to succeed, the GType of holder and bindto must be the same, with the exception th...
void setDefaultValue(gobject.value.Value value)Sets the default value within the holder. If value is null then holder won't have a default value anymore. To set a default value to null, then pass a #GValue created using [gda.global.valueNewNull].
void setNotNull(bool notNull)Sets if the holder can have a NULL value. If not_null is TRUE, then that won't be allowed
bool setSourceModel(gda.data_model.DataModel model, int col)Sets an hint that holder's values should be restricted among the values contained in the col column of the model data model. Note that this is just a hint, meaning this policy is not enforced by ho...
bool setValue(gobject.value.Value value = null)Sets the value within the holder. If holder is an alias for another holder, then the value is also set for that other holder.
bool setValueStr(gda.data_handler.DataHandler dh, string value)Same functionality as [gda.holder.Holder.setValue] except that it uses a string representation of the value to set, which will be converted into a GValue first (using default data handler if dh is ...
bool setValueToDefault()Set holder's value to its default value. Returns: TRUE if holder has got a default value
bool takeValue(gobject.value.Value value)Sets the value within the holder. If holder is an alias for another holder, then the value is also set for that other holder.
bool valueIsDefault()Tells if holder's current value is the default one. Returns: TRUE if holder holder's current value is the default one
gulong connectAttributeChanged(T)(T callback, Flag!"After" after = No.After) if (isCallable!T && is(ReturnType!T == void) && (Parameters!T.length < 1 || (ParameterStorageClassTuple!T[0] == ParameterStorageClass.none && is(Parameters!T[0] == string))) && (Parameters!T.length < 2 || (ParameterStorageClassTuple!T[1] == ParameterStorageClass.none && is(Parameters!T[1] == gobject.value.Value))) && (Parameters!T.length < 3 || (ParameterStorageClassTuple!T[2] == ParameterStorageClass.none && is(Parameters!T[2] : gda.holder.Holder))) && Parameters!T.length < 4)Connect to `AttributeChanged` signal.
gulong connectChanged(T)(T callback, Flag!"After" after = No.After) if (isCallable!T && is(ReturnType!T == void) && (Parameters!T.length < 1 || (ParameterStorageClassTuple!T[0] == ParameterStorageClass.none && is(Parameters!T[0] : gda.holder.Holder))) && Parameters!T.length < 2)Connect to `Changed` signal.
gulong connectSourceChanged(T)(T callback, Flag!"After" after = No.After) if (isCallable!T && is(ReturnType!T == void) && (Parameters!T.length < 1 || (ParameterStorageClassTuple!T[0] == ParameterStorageClass.none && is(Parameters!T[0] : gda.holder.Holder))) && Parameters!T.length < 2)Connect to `SourceChanged` signal.
gulong connectValidateChange(T)(T callback, Flag!"After" after = No.After) if (isCallable!T && is(ReturnType!T == glib.error.ErrorWrap) && (Parameters!T.length < 1 || (ParameterStorageClassTuple!T[0] == ParameterStorageClass.none && is(Parameters!T[0] == gobject.value.Value))) && (Parameters!T.length < 2 || (ParameterStorageClassTuple!T[1] == ParameterStorageClass.none && is(Parameters!T[1] : gda.holder.Holder))) && Parameters!T.length < 3)Connect to `ValidateChange` signal.
Constructors
this(void * ptr, Flag!"Take" take)
this(gobject.types.GType type)Creates a new holder of type type
Methods
T description(string propval)
T id(string propval)
T name(string propval)
T notNull(bool propval)
T sourceColumn(int propval)
T validateChanges(bool propval)Set `validateChanges` property. Params: propval = Defines if the "validate-change" signal gets emitted when the holder's value changes. Returns: Builder instance for fluent chaining

Fluent builder for [gda.holder.Holder]

Methods
Constructors
this(GError * err)
this(Code code, string msg)