GObject.Object
Midgard.DBObject
Midgard.Object
Import line: | Midgard = imports.gi.Midgard; |
GIR File: | Midgard-10.05.gir |
C documentation: | MidgardObject |
Class : | Object |
Extends: | Midgard.DBObject |
Show / Hide Inherited methods, properties and signals |
Properties | Defined By | |
---|---|---|
action : String
|
Midgard.Object | |
dbpriv : Midgard.DBObjectPrivate
read only
|
Midgard.DBObject | |
guid : String
read only
|
Midgard.Object | |
metadata : Midgard.Metadata
|
Midgard.Object | |
parent : Midgard.DBObject
read only
|
Midgard.Object | |
priv : Midgard.ObjectPrivate
read only
|
Midgard.Object |
Method / Constructor | Defined By | |
---|---|---|
new Midgard.Object
(Object properties)
Create a new Midgard.Object
Create a new Midgard.Object
|
||
Create a new Midgard.Object
Create a new Midgard.Object
|
||
approve
()
:
Boolean
Approve object.
Approve object. Approval functionality is not used by midgard core itself. Instead, it supports higher level's applications. It means, that there are no core methods ( like update or delete ) which do real check if object is approved. You should create own approval midgard_object_unapprove() and this one. This method updates metadata properties: revisor, revised, revision, approver and approved. Cases to return FALSE:
|
Midgard.Object | |
build_path
()
:
String
|
Midgard.Object | |
create
()
:
Boolean
Creates new database record(s) for object.
Creates new database record(s) for object. Internally such properties are set (overwritten):
|
Midgard.Object | |
Creates object's attachment using given properties.
Creates object's attachment using given properties. Any property may be explicitly set to NULL.
|
Midgard.Object | |
Delete object's record(s) from database, but object's record is not fully deleted from database.
Delete object's record(s) from database, but object's record is not fully deleted from database. Instead, it is marked as deleted , thus it is possible to undelete object later with midgard_schema_object_factory_object_undelete(). If check_dependents toggle is TRUE, parameters and attachments storage will be queried, if any of such exist and depend on deleted object. If given object's class has no metadata defined, object will be purged. Use midgard_object_purge() if you need to purge object's data from database. Cases to return FALSE:
|
Midgard.Object | |
Delete object's attachments(s) which match given properties' values.
Delete object's attachments(s) which match given properties' values. Properties list in parameters is optional. All object's attachments are deleted ( if exist ) if parameters is explicitly set to NULL.
|
Midgard.Object | |
Delete object's parameter(s) which match given properties' values.
Delete object's parameter(s) which match given properties' values. Properties list in parameters is optional. All object's parameters are deleted ( if exist ) if parameters is explicitly set to NULL.
|
Midgard.Object | |
Find object's attachment(s) with matching given properties.
Find object's attachment(s) with matching given properties. returned ( if exist ) if parameters is explicitly set to NULL.
|
Midgard.Object | |
Find object's parameter(s) with matching given properties.
Find object's parameter(s) with matching given properties. returned ( if exist ) if parameters is explicitly set to NULL.
|
Midgard.Object | |
Fetch object's record(s) from database using 'guid' property constraint.
Fetch object's record(s) from database using 'guid' property constraint. MidgardObject object instance must be created with midgard_object_new function. When midgard connection handler is not associated with object instance, application is terminated with 'assertion fails' error message being logged. Object instance created with this function should be freed using g_object_unref. Cases to return FALSE:
|
Midgard.Object | |
Fetch object's record(s) from database using 'id' property.
Fetch object's record(s) from database using 'id' property. This is common practice to use 'id' property with integer type when table's id column stores unique, primary key value which identifies object and its record(s). However primary property with integer type is freely defined by user. MidgardObject object instance must be created with midgard_object_new function. When midgard connection handler is not associated with object instance, application is terminated with 'assertion fails' error message being logged. Object instance created with this function should be freed using g_object_unref. Cases to return FALSE:
|
Midgard.Object | |
Midgard.Object | ||
get_connection
()
:
Midgard.Connection
Returned MidgardConnection is owned by core, and should not be freed.
Returned MidgardConnection is owned by core, and should not be freed.
|
Midgard.Object | |
|
Midgard.Object | |
get_schema_property
(String property)
:
GObject.Value
|
Midgard.Object | |
has_attachments
()
:
Boolean
|
Midgard.Object | |
has_dependents
()
:
Boolean
Checks whether object has dependent objects.
Checks whether object has dependent objects. Check is done with such particular order:
|
Midgard.Object | |
has_parameters
()
:
Boolean
|
Midgard.Object | |
is_approved
()
:
Boolean
Check whether object is approved.
Check whether object is approved.
|
Midgard.Object | |
is_locked
()
:
Boolean
Check whether object is locked Cases to return FALSE:
Check whether object is locked Cases to return FALSE:
|
Midgard.Object | |
list_attachments
()
:
Midgard.Object
Returned objects are midgard_attachment class.
Returned objects are midgard_attachment class. Attachments objects are fetched from database unconditionally. That is, only those which parent guid property matches object's guid. Returned array should be freed when no longer needed.
|
Midgard.Object | |
list_parameters
(String domain)
:
Midgard.Object
Returned objects are midgard_parameter class.
Returned objects are midgard_parameter class. Parameter objects are fetched from database unconditionally if domain i sexplicitly set to NULL. That is, only those which parent guid property matches object's guid. Returned array should be freed when no longer needed.
|
Midgard.Object | |
lock
()
:
Boolean
Lock object.
Lock object. This method doesn't affect any core's functionality like midgard_object_approve. You should create own locking workflow and logic with methods: midgard_object_is_locked(), midgard_object_unlock() and this one. Updates metadata properties: locker, locked, revisor, revised and revision Cases to return FALSE:
|
Midgard.Object | |
Purge object's record(s) from database.
Purge object's record(s) from database. If check_dependents toggle is TRUE, parameters and attachments storage will be queried, if any of such exist and depend on deleted object. Object's record(s) are purged from database without any possibility to recover. After successfull call, only repligard table holds information about object's state. Use midgard_object_delete(), if undelete facility is needed. Cases to return FALSE:
|
Midgard.Object | |
Purge object's attachments(s) which match given properties' values.
Purge object's attachments(s) which match given properties' values. Properties list in parameters is optional. All object's attachments are purged ( if exist ) if parameters is explicitly set to NULL. to blob located on filesystem ( it should be set to TRUE by default ). However, if midgard_attachment is created for blobs sharing and file should not be deleted, delete_blob should be set to FALSE. There's no way to determine if midgard_attachment is sharing blob, so aplication itelf is responsible to create such own logic.
|
Midgard.Object | |
Purge object's parameter(s) which match given properties' values.
Purge object's parameter(s) which match given properties' values. Properties list in parameters is optional. All object's parameters are purged ( if exist ) if parameters is explicitly set to NULL.
|
Midgard.Object | |
set_connection
(Connection mgd)
:
none
|
Midgard.Object | |
Sets object's guid Cases to return FALSE:
|
Midgard.Object | |
Creates object's parameter object if it doesn't exists, updates otherwise.
Creates object's parameter object if it doesn't exists, updates otherwise.
|
Midgard.Object | |
|
Midgard.Object | |
unapprove
()
:
Boolean
Simply unapprove object.
Simply unapprove object. It doesn't affect any core functionality, like midgard_object_approve(). This method updates metadata properties: revisor, revised, revision, approver and approved Cases to return FALSE:
|
Midgard.Object | |
unlock
()
:
Boolean
Unlock object.
Unlock object. Cases to return FALSE:
|
Midgard.Object | |
update
()
:
Boolean
Update object's record(s).
Update object's record(s). Internally such metadata properties are set (overwritten):
|
Midgard.Object |
Event | Defined By | |
---|---|---|
action_approve (Object self)
:
none
|
Midgard.Object | |
action_approve_hook (Object self)
:
none
|
Midgard.Object | |
action_approved (Object self)
:
none
|
Midgard.Object | |
action_create (Object self)
:
none
|
Midgard.Object | |
action_create_hook (Object self)
:
none
|
Midgard.Object | |
action_created (Object self)
:
none
|
Midgard.Object | |
action_delete (Object self)
:
none
|
Midgard.Object | |
action_delete_hook (Object self)
:
none
|
Midgard.Object | |
action_deleted (Object self)
:
none
|
Midgard.Object | |
action_export (Object self)
:
none
|
Midgard.Object | |
action_export_hook (Object self)
:
none
|
Midgard.Object | |
action_exported (Object self)
:
none
|
Midgard.Object | |
action_import (Object self)
:
none
|
Midgard.Object | |
action_import_hook (Object self)
:
none
|
Midgard.Object | |
action_imported (Object self)
:
none
|
Midgard.Object | |
action_loaded (Object self)
:
none
|
Midgard.Object | |
action_loaded_hook (Object self)
:
none
|
Midgard.Object | |
action_lock (Object self)
:
none
|
Midgard.Object | |
action_lock_hook (Object self)
:
none
|
Midgard.Object | |
action_locked (Object self)
:
none
|
Midgard.Object | |
action_purge (Object self)
:
none
|
Midgard.Object | |
action_purge_hook (Object self)
:
none
|
Midgard.Object | |
action_purged (Object self)
:
none
|
Midgard.Object | |
action_unapprove (Object self)
:
none
|
Midgard.Object | |
action_unapprove_hook (Object self)
:
none
|
Midgard.Object | |
action_unapproved (Object self)
:
none
|
Midgard.Object | |
action_unlock (Object self)
:
none
|
Midgard.Object | |
action_unlock_hook (Object self)
:
none
|
Midgard.Object | |
action_unlocked (Object self)
:
none
|
Midgard.Object | |
action_update (Object self)
:
none
|
Midgard.Object | |
action_update_hook (Object self)
:
none
|
Midgard.Object | |
action_updated (Object self)
:
none
|
Midgard.Object |
Class / Namespace | Method / Signal / Properties |
---|---|
Midgard
Method |
|
Midgard
Method |
|
Midgard
Method |
|
Midgard
Method |
|
Midgard
Method |
|
Midgard.Blob
Method |
Create a new Midgard.Blob
|
Midgard.Replicator
Method |
Serialize midgard_blob binary data.
|
Midgard.Replicator
Method |
Alias for midgard_replicator_serialize_blob().
|
Midgard.Replicator
Method |
|
Midgard.SchemaObjectFactory
Method |
Creates new instance of the class defined in Midgard Schema.
|
Midgard.SchemaObjectFactory
Method |
Midgard.SchemaObjectFactory.get_object_by_path
(Connection mgd, String classname, String path)
:
Midgard.Object
Get object by path.
|
Midgard.SchemaObjectTree
Method |
|
Midgard.SchemaObjectTree
Method |
|
Midgard.SchemaObjectTree
Method |
Get tree parent object, of the given object.
|
Midgard.SchemaObjectTree
Method |
List tree children objects, of given object type.
|
Midgard.SchemaObjectTree
Method |
Midgard.SchemaObjectTree.list_children_objects
(Object object, String classname, Object out_values)
:
Midgard.Object
List all classname objects, if exist and are tree children of given object.
|
Midgard.User
Method |
get_person
()
:
Midgard.Object
Returned object should not be unref.
|
Midgard.User
Method |
Associates given MidgardObject person with self MidgardUser.
|