acs_object_type::supertypes (private)

 acs_object_type::supertypes -subtype subtype [ -no_cache ]

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

Returns a list of the supertypes of subtypes.

Switches:
-subtype (required)
-no_cache (optional, boolean)
Author:
Lee Denison <lee@thaum.net>

Partial Call Graph (max 5 caller/called nodes):
%3 test_is_object_type_p is_object_type_p (test acs-tcl) acs_object_type::supertypes acs_object_type::supertypes test_is_object_type_p->acs_object_type::supertypes test_object_type_hierarchy object_type_hierarchy (test acs-tcl) test_object_type_hierarchy->acs_object_type::supertypes db_list db_list (public) acs_object_type::supertypes->db_list acs_object::is_type_p acs_object::is_type_p (private) acs_object::is_type_p->acs_object_type::supertypes acs_object_type::supertype acs_object_type::supertype (private) acs_object_type::supertype->acs_object_type::supertypes callback::get_object_type_impl callback::get_object_type_impl (public) callback::get_object_type_impl->acs_object_type::supertypes

Testcases:
is_object_type_p, object_type_hierarchy
Source code:
    if {$no_cache_p} {
        return [db_list supertypes {}]
    } else {
        return [acs::per_thread_cache eval  -key acs-tcl.acs_object_type.supertypes($subtype) {
                        acs_object_type::supertypes  -subtype $subtype  -no_cache
                    }]
    }
XQL Not present:
Generic
PostgreSQL XQL file:
<fullquery name="acs_object_type::supertypes.supertypes">
    <querytext>
      WITH RECURSIVE supertypes AS (
          select supertype as object_type from acs_object_types
          where object_type = :subtype
      UNION
          select ot.supertype as object_type
          from supertypes s, acs_object_types ot
          where ot.object_type = s.object_type and ot.supertype is not NULL
      ) SELECT object_type from supertypes;
      </querytext>
</fullquery>
packages/acs-tcl/tcl/object-type-procs-postgresql.xql

Oracle XQL file:
<fullquery name="acs_object_type::supertypes.supertypes">
    <querytext>
          select object_type
            from acs_object_types
           start with object_type = :subtype
      connect by prior supertype = object_type
           where object_type != :substype
        order by level desc
      </querytext>
</fullquery>
packages/acs-tcl/tcl/object-type-procs-oracle.xql

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