acs_object::get (public)

 acs_object::get -object_id object_id [ -array array ] \
    [ -element element ]

Defined in packages/acs-tcl/tcl/object-procs.tcl

Gets information about an acs_object. If called without "-element", it returns a dict containing object_id, package_id, object_type, context_id, security_inherit_p, creation_user, creation_date_ansi, creation_ip, last_modified_ansi, modifying_user, modifying_ip, tree_sortkey, object_name. If called with "-element" it returns the denoted element (similar to e.g. "party::get").

Switches:
-object_id (required)
for which the information should be retrieved
-array (optional)
An array in the caller's namespace into which the info should be delivered (upvared)
-element (optional)
to be returned
Error:
when object_id does not exist

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_object_procs_test acs_object_procs_test (test acs-tcl) acs_object::get acs_object::get test_acs_object_procs_test->acs_object::get db_1row db_1row (public) acs_object::get->db_1row acs_object::get_element acs_object::get_element (public) acs_object::get_element->acs_object::get chat_room_get_not_cached chat_room_get_not_cached (private, deprecated) chat_room_get_not_cached->acs_object::get packages/acs-subsite/www/admin/parties/one.tcl packages/acs-subsite/ www/admin/parties/one.tcl packages/acs-subsite/www/admin/parties/one.tcl->acs_object::get packages/acs-subsite/www/permissions/one.tcl packages/acs-subsite/ www/permissions/one.tcl packages/acs-subsite/www/permissions/one.tcl->acs_object::get packages/acs-subsite/www/permissions/perm-include.tcl packages/acs-subsite/ www/permissions/perm-include.tcl packages/acs-subsite/www/permissions/perm-include.tcl->acs_object::get

Testcases:
acs_object_procs_test
Source code:
    if {[info exists array]} {
        upvar 1 $array row
    }
    db_1row select_object {
        select o.object_id,
               o.title,
               o.package_id,
               o.object_type,
               o.context_id,
               o.security_inherit_p,
               o.creation_user,
               to_char(o.creation_date, 'YYYY-MM-DD HH24:MI:SS') as creation_date_ansi,
               o.creation_ip,
               to_char(o.last_modified, 'YYYY-MM-DD HH24:MI:SS') as last_modified_ansi,
               o.modifying_user,
               o.modifying_ip,
               acs_object.name(o.object_id) as object_name
        from   acs_objects o
        where  o.object_id = :object_id
    } -column_array row

    if {[info exists element]} {
        return [dict get [array get row] $element]
    } else {
        return [array get row]
    }
XQL Not present:
PostgreSQL, Oracle
Generic XQL file:
packages/acs-tcl/tcl/object-procs.xql

[ hide source ] | [ make this the default ]
Show another procedure: