... multiple object systems ....
::xotcl::use xotcl1
::xotcl::use xotcl2
describe, what ::xotcl::use
does
XOTcl 1 | XOTcl 2 |
---|---|
Class ClassName |
Class create ClassName |
Object ObjectName |
Object create ObjectName |
::xotcl::Class ClassName |
::xotcl2::Class create ClassName |
::xotcl::Object ObjectName |
::xotcl2::Object create ObjectName |
XOTcl 1 | XOTcl 2 |
---|---|
Class C |
Class create C { Class create C |
Object o |
Object create o { Object create o |
XOTcl 1 | XOTcl 2 |
---|---|
Class C |
Class create C { |
XOTcl 1 | XOTcl 2 |
---|---|
my set varname value |
set .varname value |
set newVar [my set otherVar] |
set newVar [set .otherVar] set newVar ${.otherVar} |
my instvar newVar
|
set .newVar value |
my exists varname |
info .varname |
XOTcl 1 | XOTcl 2 |
---|---|
obj set varname value |
obj eval [list set .varname value] |
set newVar [obj set otherVar] |
set newVar [obj eval {set .otherVar}] |
obj instvar newVar
|
::xotcl::importvar obj newVar |
obj exists varname |
obj eval {info exists .varname} |
XOTcl 1 | XOTcl 2 |
---|---|
obj info commands ?pattern? |
obj info methods ?pattern? |
obj info parametercmd ?pattern? |
obj info methods -methodtype setter ?pattern? |
obj info procs ?pattern? |
obj info methods -methodtype scripted ?pattern? |
n.a. | obj info methods -methodtype alias ?pattern? |
n.a. | obj info methods -methodtype forwarder ?pattern? |
n.a. | obj info methods -methodtype object ?pattern? |
n.a. | obj info methods -callprotection public|protected ... |
cls info instcommands ?pattern? |
cls info methods ?pattern? |
cls info instparametercmd ?pattern? |
cls info methods -methodtype setter ?pattern? |
cls info instprocs ?pattern? |
cls info methods -methodtype scripted ?pattern? |
n.a. | cls info methods -methodtype alias ?pattern? |
n.a. | cls info methods -methodtype forwarder ?pattern? |
n.a. | cls info methods -methodtype object ?pattern? |
n.a. | cls info methods -callprotection public|protected ... |
cls info commands ?pattern? |
cls object info methods ?pattern? |
cls info parametercmd ?pattern? |
cls object info methods -methodtype setter ?pattern? |
cls info procs ?pattern? |
cls object info methods -methodtype scripted ?pattern? |
n.a. | cls object info methods -methodtype alias ?pattern? |
n.a. | cls object info methods -methodtype forwarder ?pattern? |
n.a. | cls object info methods -methodtype object ?pattern? |
n.a. | cls object info methods -callprotection public|protected ... |
XOTcl 1 | XOTcl 2 |
---|---|
obj info methods ?pattern? |
obj info callable ?pattern? |
n.a. | # list only application specific methods obj info callable -application |
XOTcl 1 | XOTcl 2 |
---|---|
obj procsearch methodName |
obj info callable -which methodName |
XOTcl 1 | XOTcl 2 |
---|---|
cls info instbody methodName |
cls info method body methodName |
cls info instargs methodName |
cls info method args methodName |
cls info instnonposargs methodName |
cls info method parameter methodName |
cls info instdefault methodName |
cls info method parameter methodName |
cls info instpre methodName |
cls info method precondition methodName |
cls info instpost methodName |
cls info method postcondition methodName |
n.a. | cls info method definition methodName |
XOTcl 1 | XOTcl 2 |
---|---|
obj info body methodName |
obj info method body methodName |
obj info args methodName |
obj info method args methodName |
obj info nonposargs methodName |
obj info method parameter methodName |
obj info default methodName |
obj info method parameter methodName |
obj info pre methodName |
obj info method precondition methodName |
obj info post methodName |
obj info method postcondition methodName |
n.a. | obj info method definition methodName |
For definition of class object specific methods, use modifier
object
as shown in examples above.
XOTcl 1 | XOTcl 2 |
---|---|
n.a. | obj info method definition methodName |
n.a. | cls info method definition methodName |
XOTcl 1 | XOTcl 2 |
---|---|
n.a. | obj info method name methodName |
n.a. | cls info method name methodName |
XOTcl 1 | XOTcl 2 |
---|---|
n.a. | obj info method type methodName |
n.a. | cls info method type methodName |
XOTcl 1 | XOTcl 2 |
---|---|
obj check checkptions |
::xotcl::assertion obj check checkptions |
obj info check |
::xotcl::assertion obj check |
obj invar conditions |
::xotcl::assertion obj object-invar conditions |
obj info invar |
::xotcl::assertion obj object-invar |
cls instinvar conditions |
::xotcl::assertion cls class-invar conditions |
cls info instinvar |
::xotcl::assertion cls class-invar |
cls invar conditions |
::xotcl::assertion cls object-invar conditions |
cls info invar |
::xotcl::assertion cls object-invar |