MidgardQueryConstraint

MidgardQueryConstraint

Synopsis

struct              MidgardQueryConstraint;
struct              MidgardQueryConstraintClass;
MidgardQueryConstraint * midgard_query_constraint_new   (MidgardQueryProperty *property,
                                                         const gchar *op,
                                                         MidgardQueryHolder *holder,
                                                         MidgardQueryStorage *storage);
MidgardQueryStorage * midgard_query_constraint_get_storage
                                                        (MidgardQueryConstraint *self);
gboolean            midgard_query_constraint_set_storage
                                                        (MidgardQueryConstraint *self,
                                                         MidgardQueryStorage *storage);
MidgardQueryProperty * midgard_query_constraint_get_property
                                                        (MidgardQueryConstraint *self);
gboolean            midgard_query_constraint_set_property
                                                        (MidgardQueryConstraint *self,
                                                         MidgardQueryProperty *property);
const gchar *       midgard_query_constraint_get_operator
                                                        (MidgardQueryConstraint *self);
gboolean            midgard_query_constraint_set_operator
                                                        (MidgardQueryConstraint *self,
                                                         const gchar *op);

Object Hierarchy

  GObject
   +----MidgardQueryConstraint

Implemented Interfaces

MidgardQueryConstraint implements MidgardQueryConstraintSimple and MidgardValidable.

Properties

  "holder"                   MidgardQueryHolder*   : Read / Write
  "operator"                 gchar*                : Read / Write
  "property"                 MidgardQueryProperty*  : Read / Write
  "storage"                  MidgardQueryStorage*  : Read / Write

Description

Details

struct MidgardQueryConstraint

struct MidgardQueryConstraint;


struct MidgardQueryConstraintClass

struct MidgardQueryConstraintClass {
	GObjectClass parent;
	MidgardQueryConstraintSimple **(*list_constraints) (MidgardQueryConstraint *self, guint *n_objects);
};


midgard_query_constraint_new ()

MidgardQueryConstraint * midgard_query_constraint_new   (MidgardQueryProperty *property,
                                                         const gchar *op,
                                                         MidgardQueryHolder *holder,
                                                         MidgardQueryStorage *storage);

Valid op operators are: '=', '<', '>', '!=', '<>', '<=', '>=', 'LIKE', 'NOT LIKE', 'IN', 'NOT IN'

property :

MidgardQueryProperty instance

op :

constraint operator

holder :

MidgardQueryHolder instance

storage :

optional MidgardQueryStorage to use with constraint. [allow-none]

Returns :

new MidgardQueryConstraint instance, or NULL on failure

Since 10.05


midgard_query_constraint_get_storage ()

MidgardQueryStorage * midgard_query_constraint_get_storage
                                                        (MidgardQueryConstraint *self);

self :

MidgardQueryStorage instance

Returns :

MidgardQueryStorage associated with constraint or NULL. [transfer none]

Since 10.05


midgard_query_constraint_set_storage ()

gboolean            midgard_query_constraint_set_storage
                                                        (MidgardQueryConstraint *self,
                                                         MidgardQueryStorage *storage);

self :

MidgardQueryConstraint instance

storage :

MidgardQueryStorage to associate with self constraint. [allow-none]

Returns :

TRUE on success, FALSE otherwise

Since 10.05


midgard_query_constraint_get_property ()

MidgardQueryProperty * midgard_query_constraint_get_property
                                                        (MidgardQueryConstraint *self);

self :

MidgardQueryConstraint instance

Returns :

MidgardQueryProperty associated with self constraint, or NULL. [transfer none]

Since 10.05


midgard_query_constraint_set_property ()

gboolean            midgard_query_constraint_set_property
                                                        (MidgardQueryConstraint *self,
                                                         MidgardQueryProperty *property);

self :

MidgardQueryConstraint instance

property :

MidgardQueryProperty to associate with self constraint

Returns :

TRUE on success, FALSE otherwise

Since 10.05


midgard_query_constraint_get_operator ()

const gchar *       midgard_query_constraint_get_operator
                                                        (MidgardQueryConstraint *self);

self :

MidgardQueryConstraint instance

Returns :

operator type associated with self constraint, or NULL

Since 10.05


midgard_query_constraint_set_operator ()

gboolean            midgard_query_constraint_set_operator
                                                        (MidgardQueryConstraint *self,
                                                         const gchar *op);

Check midgard_query_constraint_new() for valid operator types.

self :

MidgardQueryConstraint instance

op :

operator to associate with constraint

Returns :

TRUE on success, FALSE otherwise

Since 10.05

Property Details

The "holder" property

  "holder"                   MidgardQueryHolder*   : Read / Write


The "operator" property

  "operator"                 gchar*                : Read / Write

Default value: ""


The "property" property

  "property"                 MidgardQueryProperty*  : Read / Write


The "storage" property

  "storage"                  MidgardQueryStorage*  : Read / Write