Index: doc/Class.man =================================================================== diff -u --- doc/Class.man (revision 0) +++ doc/Class.man (revision e5ad7edaed3418723ed31bda80c8639df6b44a7e) @@ -0,0 +1,266 @@ +[comment {-*- tcl -*- nx::Class manpage}] +[manpage_begin nx::Class n 2.0b6] + +[keywords base-metaclass] +[keywords NX] +[keywords "mixin class"] +[keywords "re-classification"] +[keywords "submethod"] +[keywords "method ensemble"] +[keywords "linearisation"] +[term "filter specification"] + +[vset SCOPE "class"] +[vset CMD "cls"] +[vset MODIFIER ""] + +[copyright {2014 Stefan Sobernig , Gustaf Neumann }] +[titledesc {nx::Class API Reference}] + +[description] +[para] + +[cmd nx::Class] is the [term base-metaclass] of the [term NX] object +system. All application classes defined in [term NX] are (direct or indirect) +instances of this [cmd nx::Class]. The methods provided by [cmd nx::Class] are +available to all application classes. A custom metaclass instantiates [cmd nx::Class] and +subclasses [cmd nx::Class] at the same time. + +[list_begin definitions] + +[call [cmd nx::Class] [method create] [arg className] [opt "[option -superclass] [arg superClassNames]"] [opt "[option -mixin] [arg mixinSpec]"] [opt "[option -filter] [arg filterSpec]"] [opt [arg initBlock]]] + +[para] + +To create an application class having an explicit [arg className], use [method create]. + +[call [cmd nx::Class] [method new] [opt "[option -superclass] [arg superClassNames]"] [opt "[option -mixin] [arg mixinSpec]"] [opt "[option -filter] [arg filterSpec]"] [opt [arg initBlock]]] + +To create an application class having an automatically assigned, implicit object name, use [method new]. + +[list_end] + +The configuration options for direct instances of [cmd nx::Class], +which can be passed when calling [method create] and [method new], are +documented in the subsequent section. + +[section {Configuration Options for Instances of nx::Class}] + +[para] Configuration options can be used for configuring objects during +their creation by passing the options as non-positional arguments into calls +of [method new] and [method create] (see [cmd nx::Class]). An +existing object can be queried for its current configuration using +[method cget] and it can be re-configured using [method configure]. + +[list_begin options] + +[opt_def -superclass [opt [arg superClassNames]]] + +If [arg superClassNames] is not specified, returns the superclasses of +the class. If provided, the class becomes the subclass of [arg superClassNames]. + +[opt_def -filter [opt [arg filterSpecs]]] + +Retrieves the list of filter methods currently active on instances of +the class, if [arg filterSpecs] is not set. Otherwise, activates a +list of filter methods for the instances of the class. Filters are +returned or set in terms of a list of [term "filter specification"]s. + +[opt_def -mixin [opt [arg mixinSpecs]]] + +Returns the list of [term "mixin class"]es currently active on +instances of the class, if [arg mixinSpecs] is not specified. Otherwise, the class +is extended by the list of [term "mixin class"]es provided by [arg mixinSpecs]. +[term "mixin class"]es are returned or set in terms of a list of [term "mixin specification"]s. + +[list_end] + +The configuration options provided by [cmd nx::Object] are equally +available because an application class [arg className] are indirect +instances of [cmd nx::Object]. + +[section {Methods for Instances of nx::Class}] + +[list_begin commands] + +[cmd_def alias] +[list_begin definitions] + +[include alias.man.inc] + +[list_end] + +[cmd_def create] + +[list_begin definitions] + +[call [arg cls] [method create] [arg className] [opt "[arg arg] ..."]] + +[list_end] + +[cmd_def delete] + +[list_begin definitions] + +[include delete.man.inc] + +[list_end] + +[cmd_def filter] + +[list_begin definitions] + +[include filter.man.inc] + +[list_end] + +[cmd_def forward] + +[list_begin definitions] + +[include forward.man.inc] + +[list_end] + +[cmd_def info] + +[list_begin definitions] + +[call [arg cls] [method info] [method configure]] + +Lists all configuration options available for [arg obj]. These include +the [sectref {Configuration Options for Instances of nx::Class} "configuration options"] provided +by [cmd nx::Object]. The available configuration options can be +modified using [method configure], their current value can be queried +using [method cget]. + +[call [arg cls] [method info] [method heritage]] + +... + +[call [arg cls] [method info] [method instances]] + +... + +[call [arg cls] [method info] [method mixinof]] + +... + +[call [arg cls] [method info] [method subclass]] + +... + +[call [arg cls] [method info] [method superclass]] + +... + +[include info.man.inc] + +[list_end] + + +[cmd_def method] + +[list_begin definitions] + +[include method.man.inc] + +[list_end] + +[cmd_def mixin] +[list_begin definitions] + +[include mixin.man.inc] + +[list_end] + +[cmd_def require] + +[list_begin definitions] + +[include require.man.inc] + +[list_end] + +[cmd_def property] + +[list_begin definitions] + +[call [arg cls] [method property] [opt "[option -accessor] public | protected | private"] [opt "[option -configurable] [arg trueFalse]"] [opt [option -incremental]] [opt "[option -class] [arg className]"] [opt [option -nocomplain]] [arg spec] [opt [arg initBlock]]] + +[include property.man.inc] + +[para] + +By default, the [term property] will ascertain that no (potentially) +pre-existing and equally named object variable will be overwritten +when defining the property. In case of a conflict, an error exception +is thrown: + +[example { +% Object create obj { set :x 1 } +::obj +% ::obj object property {x 2} +object ::obj has already an instance variable named 'x' +}] + +If the [term switch] [option -nocomplain] is on, this check is omitted (continuing the above example): + +[example { +% ::obj object property -nocomplain {x 2} +% ::obj eval {set :x} +2 +}] + +[list_end] + +[cmd_def variable] + +[list_begin definitions] + +[comment {::nx::Object variable ?-accessor /value/? ?-incremental? ?-class /value/? ?-configurable /boolean/? ?-initblock /value/? ?-nocomplain? /spec/ ?/defaultValue/?}] + +[call [arg cls] [method variable] [opt "[option -accessor] public | protected | private"] [opt [option -incremental]] [opt "[option -class] [arg className]"] [opt "[option -configurable] [arg trueFalse]"] [opt "[option -initblock] [arg script]"] [opt [option -nocomplain]] [arg spec] [opt [arg defaultValue]]] + +[include variable.man.inc] + +[para] + +By default, the [term variable] will ascertain that a +pre-existing and equally named object variable will not be overwritten +when defining the [term variable]. In case of a conflict, an error exception +is thrown: + +[example { +% Object create obj { set :x 1 } +::obj +% ::obj object variable x 2 +object ::obj has already an instance variable named 'x' +}] + +If the [term switch] [option -nocomplain] is on, this check is omitted (continuing the above example): + +[example { +% ::obj object variable -nocomplain x 2 +% ::obj eval {set :x} +2 +}] + +[list_end] + +[list_end] + +[comment { COMMANDS list }] + +[comment { + [cmd nx::Object] provides a set of default implementations for + internally called methods, which are called primarily during the + creation or destruction of NX objects. + + Application developers can provide custom implementations of these + methods by providing tailored implementations for these methods in application + classes (i.e., subclasses of [cmd nx::Object]). An adequate method + implementation must comply with the method signature interfaces described below. +}] + +[manpage_end] Index: doc/Object.man =================================================================== diff -u -r75f2f668aa42591075dc628edb3d020c9a499b89 -re5ad7edaed3418723ed31bda80c8639df6b44a7e --- doc/Object.man (.../Object.man) (revision 75f2f668aa42591075dc628edb3d020c9a499b89) +++ doc/Object.man (.../Object.man) (revision e5ad7edaed3418723ed31bda80c8639df6b44a7e) @@ -10,8 +10,8 @@ [keywords "linearisation"] [vset SCOPE "object"] -[vset CMD "::obj"] -[vset SCOPEMODIFIER "object"] +[vset CMD "obj"] +[vset MODIFIER "object"] [copyright {2014 Stefan Sobernig , Gustaf Neumann }] [titledesc {nx::Object API Reference}] @@ -105,8 +105,6 @@ [cmd_def alias] [list_begin definitions] -[call [arg obj] [opt "public | private | protected"] [const object] [cmd alias] [arg methodName] [opt "[option -returns] [arg valueChecker]"] [opt "[option -frame] object | method"] [arg cmdName]] - [include alias.man.inc] [list_end] Index: doc/alias.man.inc =================================================================== diff -u -ref17499c6911ca6b6712384f6793acc1d7cb856e -re5ad7edaed3418723ed31bda80c8639df6b44a7e --- doc/alias.man.inc (.../alias.man.inc) (revision ef17499c6911ca6b6712384f6793acc1d7cb856e) +++ doc/alias.man.inc (.../alias.man.inc) (revision e5ad7edaed3418723ed31bda80c8639df6b44a7e) @@ -4,6 +4,8 @@ [keywords "value checker"] [keywords "method handle"] +[call [arg [vset CMD]] [opt "public | private | protected"] [const [vset MODIFIER]] [cmd alias] [arg methodName] [opt "[option -returns] [arg valueChecker]"] [opt "[option -frame] object | method"] [arg cmdName]] + Define an [term "alias method"] for the given [vset SCOPE]. The resulting method registers a pre-existing Tcl command [arg cmdName] under the (alias) name [arg methodName] with the [vset SCOPE]. If [arg cmdName] refers Index: doc/delete.man.inc =================================================================== diff -u -r28458dc55de6b9134e16623722f3fd5f2c109caf -re5ad7edaed3418723ed31bda80c8639df6b44a7e --- doc/delete.man.inc (.../delete.man.inc) (revision 28458dc55de6b9134e16623722f3fd5f2c109caf) +++ doc/delete.man.inc (.../delete.man.inc) (revision e5ad7edaed3418723ed31bda80c8639df6b44a7e) @@ -3,18 +3,18 @@ [keywords "alias method"] [keywords "forwarder method"] -[call [arg obj] [method delete] [const [vset SCOPE]] [method property]|[method variable]|[method method] [arg arg]] +[call [arg [vset CMD]] [method delete] [const [vset MODIFIER]] [method property]|[method variable]|[method method] [arg arg]] This method serves as the equivalent to Tcl's [cmd rename] for removing structural (properties, variables) and behavioral features (methods) of the [vset SCOPE]: -[def "[arg obj] [method delete] [const [vset SCOPE]] [const property] [arg propertyName]"] -[def "[arg obj] [method delete] [const [vset SCOPE]] [const variable] [arg variableName]"] -[def "[arg obj] [method delete] [const [vset SCOPE]] [const method] [arg methodName]"] +[def "[arg [vset CMD]] [method delete] [const [vset MODIFIER]] [const property] [arg propertyName]"] +[def "[arg [vset CMD]] [method delete] [const [vset MODIFIER]] [const variable] [arg variableName]"] +[def "[arg [vset CMD]] [method delete] [const [vset MODIFIER]] [const method] [arg methodName]"] Removes a property [arg propertyName], variable [arg variableName], and method [arg methodNome], respectively, previously defined for the scope of the [vset SCOPE]. [para] -[method "delete [const [vset SCOPE]] [const method]"] can be equally used for removing regular methods (see [method "[vset SCOPE] method"]), an [term "alias method"] (see [method "[vset SCOPE] alias"]), and a [term "forwarder method"] (see [method "[vset SCOPE] forward"]). +[method "delete [const [vset MODIFIER]] [const method]"] can be equally used for removing regular methods (see [method "[vset MODIFIER] method"]), an [term "alias method"] (see [method "[vset MODIFIER] alias"]), and a [term "forwarder method"] (see [method "[vset MODIFIER] forward"]). Index: doc/filter.man.inc =================================================================== diff -u -rb7cf7b45ced98536a4267b45e772607282dd43b6 -re5ad7edaed3418723ed31bda80c8639df6b44a7e --- doc/filter.man.inc (.../filter.man.inc) (revision b7cf7b45ced98536a4267b45e772607282dd43b6) +++ doc/filter.man.inc (.../filter.man.inc) (revision e5ad7edaed3418723ed31bda80c8639df6b44a7e) @@ -2,54 +2,54 @@ [keywords "method filter"] -[call [arg obj] [const [vset SCOPE]] [method filter] [arg submethod] [opt "[arg arg] ..."]] +[call [arg [vset CMD]] [const [vset MODIFIER]] [method filter] [arg submethod] [opt "[arg arg] ..."]] Accesses and modifies the list of methods which are registered as [term "filter"]s with [arg obj] using a specific setter or getter [arg submethod]: [list_begin definitions] -[def "[arg obj] [const [vset SCOPE]] [method {filter set}] [arg filterSpecList]"] +[def "[arg [vset CMD]] [const [vset MODIFIER]] [method {filter set}] [arg filterSpecList]"] [arg filterSpecList] takes a list of [term "filter"] specs, with each spec being itself either a one-element or a two-element list: [arg methodName] ?-guard [arg guardExpr]?. [arg methodName] identifies -an existing method of [arg obj] which becomes +an existing method of [arg [vset CMD]] which becomes registered as a filter. If having three elements, the third element [arg guardExpr] will be stored as a guard expression of the [term "filter"]. This guard expression must be a valid Tcl expression -(see [cmd expr]). [arg expr] is evaluated when [arg obj] receives a message to determine whether the +(see [cmd expr]). [arg expr] is evaluated when [arg [vset CMD]] receives a message to determine whether the filter should intercept the message. Guard expressions allow for realizing context-dependent or conditional filter composition. -[def "[arg obj] [const [vset SCOPE]] [method {filter get}]"] +[def "[arg [vset CMD]] [const [vset MODIFIER]] [method {filter get}]"] Returns the current list of methods registered as [term "filter"]s. -[def "[arg obj] [const [vset SCOPE]] [method {filter add}] [arg spec] [opt [arg index]]"] -Inserts a single [term "filter"] into the current list of [term "filter"]s of [arg obj]. Using [arg index], a position in the existing list of [term "filter"]s for inserting the new [term "filter"] can be set. If +[def "[arg [vset CMD]] [const [vset MODIFIER]] [method {filter add}] [arg spec] [opt [arg index]]"] +Inserts a single [term "filter"] into the current list of [term "filter"]s of [arg [vset CMD]]. Using [arg index], a position in the existing list of [term "filter"]s for inserting the new [term "filter"] can be set. If omitted, [arg index] defaults to the list head (0). -[def "[arg obj] [const [vset SCOPE]] [method {filter delete}] [option -nocomplain] [arg specPattern]"] +[def "[arg [vset CMD]] [const [vset MODIFIER]] [method {filter delete}] [option -nocomplain] [arg specPattern]"] Removes a single [term "filter"] from the current list of [term "filter"]s of -[arg obj] whose spec matches [arg specPattern]. [arg specPattern] can +[arg [vset CMD]] whose spec matches [arg specPattern]. [arg specPattern] can contain special matching chars (see [cmd "string match"]). [const [vset SCOPE]] [method "filter delete"] will throw an error if there is no matching [term "filter"], unless [option -nocomplain] is set. -[def "[arg obj] [const [vset SCOPE]] [method {filter clear}]"] -Removes all [term "filter"]s from [arg obj] and returns the list of removed [term "filter"]s. Clearing is equivalent +[def "[arg [vset CMD]] [const [vset MODIFIER]] [method {filter clear}]"] +Removes all [term "filter"]s from [arg [vset CMD]] and returns the list of removed [term "filter"]s. Clearing is equivalent to passing an empty list for [arg filterSpecList] to [const [vset SCOPE]] [method {filter set}]. -[def "[arg obj] [const [vset SCOPE]] [method {filter guard}] [arg methodName] [arg expr]"] +[def "[arg [vset CMD]] [const [vset MODIFIER]] [method {filter guard}] [arg methodName] [arg expr]"] Registers a guard expression [arg expr] with a filter [arg methodName] -in a separate step, once the filter was set or added using [const [vset SCOPE]] [method {filter set}] or -[const [vset SCOPE]] [method {filter add}]. [arg expr] must be a valid Tcl expression (see +in a separate step, once the filter was set or added using [const [vset MODIFIER]] [method {filter set}] or +[const [vset MODIFIER]] [method {filter add}]. [arg expr] must be a valid Tcl expression (see [cmd expr]). An empty string for [arg expr] will clear the currently registered guard expression for filter [arg methodName]. [list_end] Every [arg methodName] in a [arg spec] must resolve to an existing method in the scope of the [vset SCOPE]. To -access and to manipulate the list of [term "filter"]s of [arg obj], -[method cget]|[method configure] [option -[vset SCOPE]-filter] can also be used. +access and to manipulate the list of [term "filter"]s of [arg [vset CMD]], +[method cget]|[method configure] [option -[vset MODIFIER]-filter] can also be used. Index: doc/forward.man.inc =================================================================== diff -u -rf8e79022a6358a42c082e1637a14bddaa3798e73 -re5ad7edaed3418723ed31bda80c8639df6b44a7e --- doc/forward.man.inc (.../forward.man.inc) (revision f8e79022a6358a42c082e1637a14bddaa3798e73) +++ doc/forward.man.inc (.../forward.man.inc) (revision e5ad7edaed3418723ed31bda80c8639df6b44a7e) @@ -4,7 +4,7 @@ [keywords "forward method"] [keywords "debugging level"] -[call [arg [vset CMD]] [opt "public | protected | private"] [const [vset SCOPE]] [method forward] [arg methodName] [opt "[option -prefix] [arg prefixName]"] [opt "[option -frame] [arg object]"] [opt "[option -returns] [arg valueChecker]"] [opt [option -verbose]] [arg target] [opt "[arg arg] ..."]] +[call [arg [vset CMD]] [opt "public | protected | private"] [const [vset MODIFIER]] [method forward] [arg methodName] [opt "[option -prefix] [arg prefixName]"] [opt "[option -frame] [arg object]"] [opt "[option -returns] [arg valueChecker]"] [opt [option -verbose]] [arg target] [opt "[arg arg] ..."]] Define a [term "forward method"] for the given [vset SCOPE]. The definition of a [term "forward method"] registers a predefined, but @@ -19,7 +19,7 @@ [para] -As for a regular [method "[vset SCOPE] method"], [option "-returns"] allows +As for a regular [method "[vset MODIFIER] method"], [option "-returns"] allows for setting a [term "value checker"] on the values returned by the resulting Tcl command call. When passing to [option "-frame"] [const object], the resulting Tcl command is evaluated in the context of the object Index: doc/info.man.inc =================================================================== diff -u -rdb089c577e57dea28edf1c0f6bec37a15419e39f -re5ad7edaed3418723ed31bda80c8639df6b44a7e --- doc/info.man.inc (.../info.man.inc) (revision db089c577e57dea28edf1c0f6bec37a15419e39f) +++ doc/info.man.inc (.../info.man.inc) (revision e5ad7edaed3418723ed31bda80c8639df6b44a7e) @@ -9,11 +9,11 @@ [keywords "method handle"] [keywords "method path"] -[call [arg obj] [method "info [vset SCOPE] filter"] [arg option] [opt "[arg arg] ..."]] +[call [arg [vset CMD]] [method "info [vset MODIFIER] filter"] [arg option] [opt "[arg arg] ..."]] [list_begin definitions] -[def "[arg obj] [method "info [vset SCOPE] filter methods"] [opt [option -guards]] [opt [arg pattern]]"] +[def "[arg [vset CMD]] [method "info [vset MODIFIER] filter methods"] [opt [option -guards]] [opt [arg pattern]]"] If [arg pattern] is omitted, returns all filter names which are @@ -23,15 +23,15 @@ -guard [arg guardExpr]. The returned filters can be limited to those whose names match [arg patterns] (see [cmd "string match"]). -[def "[arg obj] [method "info [vset SCOPE] filter guard"] [arg name]"] +[def "[arg [vset CMD]] [method "info [vset MODIFIER] filter guard"] [arg name]"] Returns the guard expression set on the [term "filter"] [arg name] defined for [arg obj]. If none is available, an empty string will be returned. [list_end] -[call [arg obj] [method "info [vset SCOPE] method"] [arg option] [arg methodName]] +[call [arg [vset CMD]] [method "info [vset MODIFIER] method"] [arg option] [arg methodName]] This introspection [term "submethod"] provides access to the details of [arg methodName] provided by [arg obj]. Permitted values for @@ -80,7 +80,7 @@ [list_end] -[call [arg obj] [method "info [vset SCOPE] methods"] [opt "[option -callprotection] [arg level]"] [opt "[option -type] [arg methodType]"] [opt [option -path]] [opt [arg namePattern]]] +[call [arg [vset CMD]] [method "info [vset MODIFIER] methods"] [opt "[option -callprotection] [arg level]"] [opt "[option -type] [arg methodType]"] [opt [option -path]] [opt [arg namePattern]]] Returns the names of all methods defined by [arg obj]. Methods covered include those defined using , @@ -105,11 +105,11 @@ }] [list_end] -[call [arg obj] [method "info [vset SCOPE] mixin"] [arg option] [opt "[arg arg] ..."]] +[call [arg [vset CMD]] [method "info [vset MODIFIER] mixin"] [arg option] [opt "[arg arg] ..."]] [list_begin definitions] -[def "[arg obj] [method {info object mixin classes}] [opt [option -guards]] [opt [arg pattern]]"] +[def "[arg [vset CMD]] [method "info [vset MODIFIER] mixin classes"] [opt [option -guards]] [opt [arg pattern]]"] If [arg pattern] is omitted, returns the object names of the [term "mixin class"]es which extend [arg obj] directly. By turning on the [term switch] [option -guards], @@ -118,7 +118,7 @@ -guard [arg guardExpr]. The returned [term "mixin class"]es can be limited to those whose names match [arg patterns] (see [cmd "string match"]). -[def "[arg obj] [method {info object mixin guard}] [arg name]"] +[def "[arg [vset CMD]] [method "info [vset MODIFIER] mixin guard"] [arg name]"] For the [term "mixin class"] [arg name] which extends [arg obj] directly, returns the corresponding guard expression, if @@ -127,15 +127,15 @@ [list_end] -[call [arg obj] [method "info [vset SCOPE] slots"] [opt "[option -type] [arg className]"] [arg pattern]] +[call [arg [vset CMD]] [method "info [vset MODIFIER] slots"] [opt "[option -type] [arg className]"] [arg pattern]] If [arg pattern] is not specified, returns the object names of all [term "slot object"]s defined by [arg obj]. The returned [term "slot object"]s can be limited according to any or a combination of the following criteria: First, [term "slot object"]s can be filtered based on their command names matching [arg namePattern] (see [cmd "string match"]). Second, [option "-type"] allows to select [term "slot object"]s which are instantiated from a subclass [arg className] of [cmd nx::Slot] (default: [cmd nx::Slot]). -[call [arg obj] [method "info [vset SCOPE] variables"] [arg pattern]] +[call [arg [vset CMD]] [method "info [vset MODIFIER] variables"] [arg pattern]] If [arg pattern] is omitted, returns the object names of all [term "slot object"]s provided by [arg obj] which are responsible for managing properties and variables of [arg obj]. Otherwise, @@ -144,7 +144,7 @@ [para] -This is equivalent to calling: [arg obj] [method "info [vset SCOPE] slots"] -type ::nx::VariableSlot [opt [arg namePattern]]. +This is equivalent to calling: [arg obj] [method "info [vset MODIFIER] slots"] -type ::nx::VariableSlot [opt [arg namePattern]]. [para] Index: doc/method.man.inc =================================================================== diff -u -rf8e79022a6358a42c082e1637a14bddaa3798e73 -re5ad7edaed3418723ed31bda80c8639df6b44a7e --- doc/method.man.inc (.../method.man.inc) (revision f8e79022a6358a42c082e1637a14bddaa3798e73) +++ doc/method.man.inc (.../method.man.inc) (revision e5ad7edaed3418723ed31bda80c8639df6b44a7e) @@ -1,6 +1,6 @@ [comment {-*- tcl -*- manpage fragment for method method, shared by nx::Object and nx::Class}] -[call [arg [vset CMD]] [opt "public | protected | private"] [const [vset SCOPE]] [method method] [arg name] [arg parameters] [opt [option "-checkalways"]] [opt "[option -returns] [arg valueChecker]"] [arg body]] +[call [arg [vset CMD]] [opt "public | protected | private"] [const [vset MODIFIER]] [method method] [arg name] [arg parameters] [opt [option "-checkalways"]] [opt "[option -returns] [arg valueChecker]"] [arg body]] [keywords "value checker"] [keywords "colon-prefix notation"] @@ -43,6 +43,6 @@ implementing the method body can contain object-specific notation and commands (see above). Third, method calls [emph cannot] be intercepted using Tcl [cmd trace]. Note that an existing Tcl [cmd proc] can be registered as -an [term "alias method"] with the [vset SCOPE] (see [method "[vset SCOPE] alias"]). +an [term "alias method"] with the [vset SCOPE] (see [method "[vset MODIFIER] alias"]). [comment {TODO: refer to nsf::proc?}] Index: doc/mixin.man.inc =================================================================== diff -u -rb7cf7b45ced98536a4267b45e772607282dd43b6 -re5ad7edaed3418723ed31bda80c8639df6b44a7e --- doc/mixin.man.inc (.../mixin.man.inc) (revision b7cf7b45ced98536a4267b45e772607282dd43b6) +++ doc/mixin.man.inc (.../mixin.man.inc) (revision e5ad7edaed3418723ed31bda80c8639df6b44a7e) @@ -3,13 +3,13 @@ [keywords "mixin class"] [keywords linearisation] -[call [arg obj] [const [vset SCOPE]] [method mixin] [arg submethod] [opt "[arg arg] ..."]] +[call [arg [vset CMD]] [const [vset MODIFIER]] [method mixin] [arg submethod] [opt "[arg arg] ..."]] Accesses and modifies the list of [term "mixin class"]es of [arg obj] using a specific setter or getter [arg submethod]: [list_begin definitions] -[def "[arg obj] [const [vset SCOPE]] [method {mixin set}] [arg mixinSpecList]"] +[def "[arg [vset CMD]] [const [vset MODIFIER]] [method {mixin set}] [arg mixinSpecList]"] [arg mixinSpecList] takes a list of [term "mixin class"] specs, with each spec being itself either a one-element or a three-element list: [arg className] ?-guard [arg guardExpr]?. If having one element, the element will be considered the [arg className] @@ -21,24 +21,24 @@ allow for realizing context-dependent or conditional mixin composition. -[def "[arg obj] [const [vset SCOPE]] [method {mixin get}]"] +[def "[arg [vset CMD]] [const [vset MODIFIER]] [method {mixin get}]"] Returns the current list of [term "mixin class"]es. -[def "[arg obj] [const [vset SCOPE]] [method {mixin add}] [arg spec] [opt [arg index]]"] +[def "[arg [vset CMD]] [const [vset MODIFIER]] [method {mixin add}] [arg spec] [opt [arg index]]"] Inserts a single [term "mixin class"] into the current list of [term "mixin class"]es of [arg obj]. Using [arg index], a position in the existing list of [term "mixin class"]es for inserting the new [term "mixin class"] can be set. If omitted, [arg index] defaults to the list head (0). [comment {Therefore, by default, any added [term "mixin class"] takes precedence over previously added classes in the overall linearisation of [arg obj].}] -[def "[arg obj] [const [vset SCOPE]] [method {mixin delete}] [option -nocomplain] [arg specPattern]"] +[def "[arg [vset CMD]] [const [vset MODIFIER]] [method {mixin delete}] [option -nocomplain] [arg specPattern]"] Removes a [term "mixin class"] from a current list of [term "mixin class"]es of [arg obj] whose spec matches [arg specPattern]. [arg specPattern] can contain special matching chars (see [cmd "string match"]). [const [vset SCOPE]] [method "mixin delete"] will throw an error if there is no matching [term "mixin class"], unless [option -nocomplain] is set. -[def "[arg obj] [const [vset SCOPE]] [method {mixin clear}]"] +[def "[arg [vset CMD]] [const [vset MODIFIER]] [method {mixin clear}]"] Removes all [term "mixin class"]es from [arg obj] and returns the list of removed [term "mixin class"]es. Clearing is equivalent to passing an empty list for [arg mixinSpecList] to [const [vset SCOPE]] [method {mixin set}]. -[def "[arg obj] [const [vset SCOPE]] [method {mixin guard}] [arg className] [arg expr]"] +[def "[arg [vset CMD]] [const [vset MODIFIER]] [method {mixin guard}] [arg className] [arg expr]"] Registers a guard expression [arg expr] with the [term "mixin class"] [arg className] in a separate step, once the [term "mixin class"] was set or added using [const [vset SCOPE]] [method {mixin set}] or -[const [vset SCOPE]] [method {mixin add}]. [arg expr] must be a valid Tcl expression (see +[const [vset MODIFIER]] [method {mixin add}]. [arg expr] must be a valid Tcl expression (see [cmd expr]). An empty string for [arg expr] will clear the currently registered guard expression for the registered [term "mixin class"] [arg className]. [list_end] @@ -49,8 +49,7 @@ overall [term linearisation] of [arg obj] guarantees to maintain this local order of [term "mixin class"]es. }] -At the time of setting the mixin relation, that is, calling [const [vset SCOPE]] [method mixin], every +At the time of setting the mixin relation, that is, calling [const [vset MODIFIER]] [method mixin], every [arg className] as part of a spec must be an existing instance of [cmd nx::Class]. To access and to manipulate the list of [term "mixin class"]es of [arg obj], -[method cget]|[method configure] [option -[vset SCOPE]-mixin] can also be used. - +[method cget]|[method configure] [option -[vset MODIFIER]-mixin] can also be used. Index: doc/require.man.inc =================================================================== diff -u -rf0f4c4be4d21ba578d3be3e9559710bde3f17ac2 -re5ad7edaed3418723ed31bda80c8639df6b44a7e --- doc/require.man.inc (.../require.man.inc) (revision f0f4c4be4d21ba578d3be3e9559710bde3f17ac2) +++ doc/require.man.inc (.../require.man.inc) (revision e5ad7edaed3418723ed31bda80c8639df6b44a7e) @@ -2,7 +2,7 @@ [keywords "call protection"] -[call [arg [vset CMD]] [opt "public | protected | private"] [method require] [const [vset SCOPE]] [method method] [arg methodName]] +[call [arg [vset CMD]] [opt "public | protected | private"] [method require] [const [vset MODIFIER]] [method method] [arg methodName]] Attempts to register a method definition made available using [cmd ::nsf::method::provide] under the name [arg methodName] with the object [arg obj] . The registered