%3 ::nx::Object ::nx::Object __default_accessor __default_method_call_protection __object_configureparameter __resolve_method_path contains copy delete object method delete object property delete object variable destroy_on_cleanup info info info lookup parameters info lookup slots info lookup syntax info lookup variables info object method args info object method body info object method callprotection info object method debug info object method definition info object method definitionhandle info object method deprecated info object method exists info object method handle info object method origin info object method parameters info object method registrationhandle info object method returns info object method submethods info object method syntax info object method type info object slots info object variables info variable definition info variable name info variable parameter move object alias object forward object method object property object variable private protected public qn require namespace require object method require private object method require protected object method require public object method serialize ::nx::serializer::ObjectSystemSerializer ::nx::serializer::ObjectSystemSerializer Class-needsNothing Object-needsNothing alias-dependency classify collect-var-traces collectVars extraMethodProperties forward-serialize frameWorkCmd getExported init instances list_instances matchesIgnorePattern needsNothing registerSerializer responsibleSerializer serialize serialize-all-end serialize-all-start serializeExportedMethods ::nx::serializer::ObjectSystemSerializer->::nx::Object

Class ::nx::serializer::ObjectSystemSerializer

::nx::serializer::ObjectSystemSerializer[i] create ...

Class Relations

  • class: ::nx::Class[i]
  • superclass: ::nx::Object[i]
::nx::Class create ::nx::serializer::ObjectSystemSerializer \
     -superclass ::nx::Object

Methods (to be applied on instances)

  • getExported (scripted)

    foreach k [Serializer exportedMethods] {
      lassign $k o p m
      if {![::nsf::object::exists $o]} {
        :warn "$o is not an object"
      } elseif {[::nsf::dispatch $o ::nsf::methods::object::info::hastype ${:rootClass}]} {
        set :exportMethods($k) 1
      }
    }
    foreach o [Serializer exportedObjects] {
      if {![::nsf::object::exists $o]} {
        :warn "$o is not an object"
      } elseif {[nsf::dispatch $o ::nsf::methods::object::info::hastype ${:rootClass}]} {
        set :exportObjects($o) 1
      }
    }
    foreach p [array names :ignorePattern] {Serializer addPattern $p}
  • instances (scripted)

    set instances [list]
    foreach i [${:rootClass} info instances -closure] {
      if {[:matchesIgnorePattern $i] && ![$s isExportedObject $i]} {
        continue
      }
      $s setObjectSystemSerializer $i [::nsf::current object]
      lappend instances $i
    }
    #:warn "[::nsf::current object] handles instances: $instances"
    return $instances
  • list_instances (scripted)

    set instances [list]
    foreach i [${:rootClass} info instances -closure] {
      if {[:matchesIgnorePattern $i]} {
        continue
      }
      lappend instances $i
    }
    #:warn "[::nsf::current object] handles instances: $instances"
    return $instances
  • needsNothing (scripted)

    return [:[:classify $x]-needsNothing $x $s]
  • registerSerializer (scripted)

    foreach i $instances {
      if {![::nsf::dispatch $i ::nsf::methods::object::info::hastype ${:rootClass}]} continue
      $s setObjectSystemSerializer $i [::nsf::current object]
    }
  • responsibleSerializer (scripted)

    return [::nsf::dispatch $object ::nsf::methods::object::info::hastype ${:rootClass}]
  • serialize (scripted)

    set :targetName [$s getTargetName $objectOrClass]
    :[:classify $objectOrClass]-serialize $objectOrClass $s
  • serialize-all-end (scripted)

    set cmd ""
    foreach o [list ${:rootClass} ${:rootMetaClass}] {
      append cmd  [:frameWorkCmd ::nsf::relation::get $o object-mixin]  [:frameWorkCmd ::nsf::relation::get $o class-mixin]  [:frameWorkCmd ::nsf::method::assertion $o object-invar]  [:frameWorkCmd ::nsf::method::assertion $o class-invar]
    }
    #puts stderr "*** array unset [nsf::current object] alias_dependency // size [array size :alias_dependency]"
    array unset :alias_dependency
    return $cmd
  • serialize-all-start (scripted)

    :getExported
    return [:serializeExportedMethods $s]