nsf

Clone Tools
  • last updated 19 hours ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
- changed name "/obj|cls/ slot info definition" to "/obj|cls/ slot info definition" since result is a set - dropped parameter method "properties" - dropped "/obj/ info properties" (since "properties" or "variables" are returned")

nx.tcl: - change parameter name in "/cls/ inif paramameter ... ?pattern?" from "name" to "pattern"

- added functiality for "cget" to call parameter-methods (e.g. "... cget -class"). The method cget calls either "/slot/ get ..." (when slot=... is provided in the parameter spec) or it assumes that the method without argument returns the value - added "::nsf::object::property /obj/ volatile" to query whether a object is volatile or not - "/obj/ cget -volatile" returns now the volatial state of the object - factored out ParameterMethodDispatch() from OConfigureMethod() - extended regression test

- invalidation of per-object parameter cache * on mixin changes and * on deletion/adding of per-object slots - decactivate PER_OBJECT_PARAMETER_CACHING per default (flipping this parameter makes regression test more than 20 faster). - extended regression test

- NsfObjInfoObjectparameterMethod(): return not only the first matching parameter, but the list of all matching ones. The last optional argument was renamed from "name" to "pattern" accordingly

- rename invalidateobjectparameter -> parameter:invalidate::classcache - rename invalidateobjobjectparameter -> parameter:invalidate::objectcache - bring cmds into alphabetical order

- first draft of per-object parameter caching (for per-object-mixins and per-object properties).

nsf.c: - fix potential bad interaction between per-object mixins and per-class caching of object-parameters

- don't blindly register all object/class methods for XOTcl

    • -13
    • +30
    /library/xotcl/library/xotcl2.tcl
Property Reform Part 2: better handling of per-object properties nsf.c: - changed "/class/ __objectconfigure" to "/obj/ __objectconfigure" to be able to handle per-object properties on classes properly. - renamed "info method parametersyntax" -> "info method syntax" - renamed "/obj|cls/ info method parametersyntax" into "/obj|cls/ info method syntax" - replaced "::nsf::methods::class::info::objectparameter" by "::nsf::methods::object::info::objectparameter" - new command "::nsf::parameter::specs ?-configure? ?-noposargs? slotobjs": convert provided slotobjs into a list of parameter specs - new command "::nsf::parameter::get list|name|syntax parameterspec": convert parameter spec into syntax form, or retrieve pieces of information from it (can be extended in the future) - added more or less generic list handling functions TclObjListFreeList(), TclObjListNewElement() and TclObjListAdd() used by "::nsf::parameter::specs" - replaced "::nsf::method::property /obj/ -per-object /name/ slotcontainer ?value?" by "::nsf::object::property /obj/ slotcontainer ?value?" - added "::nsf::object::property /obj/ hasperobjectslots ?value?"

nx.tcl:

- new info methods

* "/obj/ info lookup parameter definitions"

* "/obj/ info lookup parameter names"

* "/obj/ info lookup parameter list"

* "/obj/ info lookup parameter syntax"

- changed "/cls/ info parameter definition ?name?"

into "/cls/ info parameter definitions ?name?"

since ir returns a list. Still, "list" or "syntax" won't

be plural

    • -28
    • +15
    /library/xotcl/library/xotcl2.tcl
  1. … 4 more files in changeset.
- renamed timing variable from "time" to "ms"

- added timing statistics

- generalize handling for per-object-properties

- added addtional file for regression test

    • -0
    • +321
    /tests/properties.test
updated todo

Property reform part 1:

- disallow protection modifiers for "properties" and

add new flag "-accessor" to "property" and "variable"

This changes definitions like

Class create C {

:property {a a1}

:public property {b b1}

:protected property {c c1}

:private property {d d1}

}

to

Class create C {

:property {a a1}

:property -accessor public {b b1}

:property -accessor protected {c c1}

:property -accessor private {d d1}

}

since "properties" are always public accessible

over the "configure" and "cget" interface, but the

accessors methods might not be public. The value of

the accessor might be also "none" (specifying explicitely

that no accessor is wanted) or "", which means: use the default.

Same holds for "variable"

- disallow parameter option "incremental" and change it to a flag

of the property or variable. The motivation for this is due to

the fact, that "incremental" is a property of the accessor, and

not of the value.

old:

Class create C {

:property foo:int,incremental

:variable bar:int,incremental

}

new:

Class create C {

:property -incremental foo:int

:variable -incremental bar:int

}

- disallow "public class property" and friends since these are not needed

- removed parameter property "noaccessor"

- removed "nx::configure defaultPropertyCallProtection" and

method hook "__default_property_call_protection"

- introduced "nx::configure defaultAccessor" and

method hook "__default_accessor"

- for the time being, "defaultAccessor" is "public" for NX and XOTcl,

will be changed to "none" in NX

- extended regression test (new file properties.test)

nsf.c: - fixed parmeter syntax for required nonpos args - deactivate deletion of methods via nsf::object::delete during shutdown to avoid missing slot forwarders called from destructors

nx.tcl: - remove debugging output

- renamed testlog file, remove it on "make clean"

nsf.c: - made argument of cget required

nx.tcl:

- added Tk-style methods "configure" and "cget"

- added additional regression test set for cget and configure

nsf.c: - implememted cget as a configure-like method, dropped ensemble method variant

nx.tcl:

- simplified "/obj|cls/ delete method" due to resolving capabilities in

nsf::delete::method

- fixed regression test to run all test again correctly

xotcl2.tcl: - made destructor of Connection more robust such it does not depend on accessor methods.

    • -2
    • +2
    /library/xotcl/library/comm/Access.xotcl
    • -1
    • +1
    /library/xotcl/library/comm/Httpd.xotcl
    • -2
    • +2
    /library/xotcl/library/comm/pkgIndex.tcl
nsf.c: - extended nsf::method::delete to handle ensemble names

nx.tcl:

- added tk/incr-tcl style cget methods on class/object levels.

- improve copy handling with other child-types of the slot container working

- make sure to ignore non-slot-type objects in slot introspection

- worked on regression test until "methods.test". others are missing,

but maybe reconsideration

    • -3
    • +6
    /library/mongodb/example-nsf-mongo.tcl
- updated 34 copyright notices

  1. … 19 more files in changeset.
nx.tcl: - rename the following internally called methods (not for XOTcl). alloc -> __alloc dealloc -> __dealloc objectparameter -> __objectparameter recrate -> __recreate - from these methods, only __objectparameter is defined per default, the others are defined on demand

changes to allow efficient tk/incr tcl compatible configure/cget - refactored code to allow to parameterize handling of required flag for parameters - don't flag an error when configure is called on an initialized object (logic: if the object is initialized, configure must have been called before, and the required action must have been already taken).

- rename nx::Object.configure to nx::Object.__configure to free method name "configure" for an e.g. tk-like configure

- finalize transition from old code

- fix frame scoping for myvar/myproc