Top | ![]() |
![]() |
![]() |
![]() |
gpointer | context | Read |
GalagoOrigin | origin | Read / Write / Construct Only |
gboolean | supports-attrs | Read |
GObject ╰── GalagoObject ├── GalagoAccount ├── GalagoContext ├── GalagoCore ├── GalagoImage ├── GalagoPerson ├── GalagoPresence ├── GalagoService ╰── GalagoStatus
GalagoObject is the base class for all Galago objects. Most GalagoObject
subclasses can be passed around in D-BUS messages through
galago_dbus_message_iter_append_object()
and
galago_dbus_message_iter_get_object()
.
GalagoObjects may also support remote attributes. Examples of such objects are GalagoPerson and GalagoAccount.
Most GalagoObjects are managed by the libgalago, and are created
by factories. In most cases, you should not call g_object_unref()
unless you've
already called g_object_ref()
. If you wish to destroy an object, call
galago_object_destroy()
.
#define GALAGO_OBJECT_HAS_FLAG(obj, flag)
Returns whether or not the object has the specified flag set.
#define GALAGO_OBJECT_FLAGS(obj) (GALAGO_OBJECT(obj)->flags)
Returns the flags belonging to an object.
#define GALAGO_OBJECT_SET_FLAGS(obj, flag)
Sets one or more flags on an object.
#define GALAGO_OBJECT_UNSET_FLAGS(obj, flag)
Unsets one or more flags on an object.
#define GALAGO_ORIGIN_IS_VALID(origin)
Returns whether or not a numeric value is a valid GalagoOrigin value.
#define GALAGO_OBJECT_IS_LOCAL(obj)
Returns TRUE
if an object is local. This is the same as comparing
the result of galago_object_get_origin()
to GALAGO_LOCAL
.
#define GALAGO_OBJECT_IS_REMOTE(obj)
Returns TRUE
if an object is remote. This is the same as comparing
the result of galago_object_get_origin()
to GALAGO_REMOTE
.
void
galago_object_destroy (GalagoObject *object
);
Emits the "destroy" signal for an object, and attempts to dispose of it. The memory for the object won't actually be deleted until the reference count drops to 0.
const gchar *
galago_object_type_get_dbus_signature (GType type
);
Returns the D-BUS signature of the object type.
void galago_object_set_dbus_path (GalagoObject *object
,const gchar *obj_path
);
Sets the D-BUS object path of an object.
const gchar *
galago_object_get_dbus_path (const GalagoObject *object
);
Returns the D-BUS object path of an object.
void galago_object_set_watch (GalagoObject *object
,gboolean watch
);
Sets whether or not this object is watched for events.
gboolean
galago_object_is_watched (const GalagoObject *object
);
Returns whether or not an object is watched for events.
GalagoOrigin
galago_object_get_origin (const GalagoObject *object
);
Returns the object's origin.
GalagoContext *
galago_object_get_context (const GalagoObject *object
);
Returns the object's context.
void galago_object_set_attr_string (GalagoObject *object
,const char *name
,const char *value
);
Sets a string attribute on an object.
void galago_object_set_attr_bool (GalagoObject *object
,const char *name
,gboolean value
);
Sets a boolean attribute on an object.
void galago_object_set_attr_int (GalagoObject *object
,const char *name
,gint32 value
);
Sets an integer attribute on an object.
void galago_object_set_attr_double (GalagoObject *object
,const char *name
,gdouble value
);
Sets a double attribute on an object.
void galago_object_set_attribute (GalagoObject *object
,const char *name
,GValue *value
);
Sets an attribute on an object.
This is limited to string, boolean, and integer value types.
gboolean galago_object_remove_attribute (GalagoObject *object
,const char *name
);
Removes an attribute on an object.
const char * galago_object_get_attr_string (const GalagoObject *object
,const char *name
);
Returns the value of a string attribute on an object.
gboolean galago_object_get_attr_bool (const GalagoObject *object
,const char *name
);
Returns the value of a boolean attribute on an object.
gint32 galago_object_get_attr_int (const GalagoObject *object
,const char *name
);
Returns the value of an integer attribute on an object.
gdouble galago_object_get_attr_double (const GalagoObject *object
,const char *name
);
Returns the value of a double attribute on an object.
const GValue * galago_object_get_attribute (const GalagoObject *object
,const char *name
);
Returns the value of an attribute on an object.
gboolean galago_object_get_has_attribute (const GalagoObject *object
,const char *name
);
Returns whether or not an object has a specific attribute set.
GList *
galago_object_get_attributes (const GalagoObject *object
);
Returns the list of attributes in an object, represented by GalagoKeyValue structs.
struct GalagoObject;
The object itself. You should never access the members of this directly. Always use the public API methods and macros.
“origin”
property“origin” GalagoOrigin
The object's origin.
Flags: Read / Write / Construct Only
Default value: GALAGO_LOCAL
“destroy”
signalvoid user_function (GalagoObject *object, gpointer user_data)
Emitted when the object is undergoing a dispose. Signals that anything holding a reference to this object should release the reference. This may or may not end with the object being finalized, depending on whether there are any references left after this is emitted.
object |
The object which received the signal. |
|
user_data |
user data set when the signal handler was connected. |
Flags: No Hooks