Defined in
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
-
No testcase defined.
Source code:
switch -- $what {
"mixin" {
return [$o ::nsf::methods::object::info::mixins]
}
"instmixin" {
return [$o ::nsf::methods::class::info::mixins]
}
"mixinof" {
return [$o ::nsf::methods::class::info::mixinof -scope object]
}
"instmixinof" {
return [$o ::nsf::methods::class::info::mixinof -scope class]
}
"instproc" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o info instprocs {*}$args]}
return [$o info methods -path -type scripted -callprotection all {*}$args]
}
"instcommand" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o info instcommands {*}$args]}
return [$o info methods -path {*}$args]
}
"instforward" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o info instforward {*}$args]}
return [$o info methods -type forwarder {*}$args]
}
"instmethodtype" {
return [$o ::nsf::methods::class::info::method type {*}$args]
}
"methodtype" {
return [$o ::nsf::methods::object::info::method type {*}$args]
}
"proc" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o info procs {*}$args]}
return [$o info object methods -path -type scripted {*}$args]
}
"command" {
return [$o ::nsf::methods::object::info::methods {*}$args]
}
"forward" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o info forward {*}$args]}
return [$o info object methods -type forwarder {*}$args]
}
"slots" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o info slots]}
return [$o info object methods -type forwarder]
}
"class" {
return [$o ::nsf::methods::object::info::class]
}
"superclass" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o info superclass]}
return [$o info superclasses]
}
"heritage" {
return [$o info heritage]
}
"subclass" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o info subclass]}
return [$o info subclasses]
}
"parameter" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o info parameter]}
return [lmap p [$o info variables -closure] {$o info variable parameter $p}]
}
"isclass" {
return [nsf::is class $o]
}
"isobject" {
return [nsf::is object $o]
}
"isbaseclass" {
if {![nsf::is class $o]} {return 0}
if {[catch {set p [$o info precedence]}]} {return 0}
return [expr {[lindex $p end] eq $o}]
}
"instmethodparameter" {
return [$o ::nsf::methods::class::info::method parameter {*}$args]
}
"methodparameter" {
return [$o ::nsf::methods::object::info::method parameter {*}$args]
}
"instargs" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o info instargs {*}$args]}
set posargs {}
foreach m [$o info method args {*}$args] p [$o info method parameters {*}$args] {
if {[string index [lindex $p 0] 0] eq "-"} continue
lappend posargs $m
}
return $posargs
}
"args" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o info args {*}$args]}
set posargs {}
foreach m [$o info object method args {*}$args] p [$o info object method parameters {*}$args] {
if {[lindex [string index $p 0] 0] eq "-"} continue
lappend posargs $m
}
return $posargs
}
"instargdefault" {
if {"::xotcl::Object" in [$o info precedence]} {
return [uplevel [list $o info instdefault {*}$args]]
}
lassign $args method arg varName
foreach p [$o info method parameters $method] {
lassign $p name default
if {$name eq $arg} {
uplevel [list set $varName $default]
return [expr {[llength $p] == 2}]
}
}
return 0
}
"argdefault" {
if {"::xotcl::Object" in [$o info precedence]} {
return [uplevel [list $o info default {*}$args]]
}
lassign $args method arg varName
foreach p [$o info object method parameters $method] {
lassign $p name default
if {$name eq $arg} {
uplevel [list set $varName $default]
return [expr {[llength $p] == 2}]
}
}
return 0
}
"array-exists" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o array exists {*}$args]}
return [$o eval [list array exists :{*}$args]]
}
"array-get" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o array get {*}$args]}
return [$o eval [list array get :{*}$args]]
}
"array-set" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o array set {*}$args]}
return [$o eval [list array set :{*}$args]]
}
"set" {
if {"::xotcl::Object" in [$o info precedence]} {return [$o set {*}$args]}
return [$o eval [list set :[lindex $args 0]]]
}
"vars" {
return [$o ::nsf::methods::object::info::vars]
}
"isnxobject" {
if {[info commands ::nsf::dispatch] ne "" && [info commands $o] ne ""} {
return [::nsf::dispatch $o ::nsf::methods::object::info::hastype ::nx::Object]
} {
return 0
}
}
default {
error "no idea how to return $what"
}
}
XQL Not present:Generic, PostgreSQL, Oracle