%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 ::xo::ical::VCALITEM ::xo::ical::VCALITEM add_recurrence as_ical creation_date description dtstamp dtstart edit_recurrence geo get ical_body is_day_item last-modified last_modified location parse RRULE priority start_end status summary tag uid url ::xo::ical::VCALITEM->::nx::Object ::xo::MessageRelay ::xo::MessageRelay can_be_used encode_message send_to_subscriber start_of_page subscribe sweep ::xo::MessageRelay->::nx::Object ::xowf::test_item::grading::Grading ::xowf::test_item::grading::Grading calc_grade grading_dict init print ::xowf::test_item::grading::Grading->::nx::Object ::xowf::test_item::AssessmentInterface ::xowf::test_item::AssessmentInterface add_to_fc assert_answer_instance assert_assessment assert_assessment_container export_links list_equal render_feedback_files replace_in_fc ::xowf::test_item::AssessmentInterface->::nx::Object ::xowf::IpRange ::xowf::IpRange allow_access match ::xowf::IpRange->::nx::Object ::rrd::Plugin ::rrd::Plugin → update baseResolution datasource datasources init updateDataSource ::rrd::Plugin->::nx::Object ::acs::Container ::acs::Container active_p init mapping ::acs::Container->::nx::Object ::acs::SiteNodesCache ::acs::SiteNodesCache flush_cache flush_pattern flush_per_request_cache get_children get_node_id get_package_url get_url get_urls_from_object_id has_children properties ::acs::SiteNodesCache->::nx::Object ::acs::Cache ::acs::Cache cache_create cache_name eval flush flush_all flush_cache flush_pattern get get_size init set show_all ::acs::Cache->::nx::Object ::ftpd::Infrastructure ::ftpd::Infrastructure log ::ftpd::Infrastructure->::nx::Object ::acs::DocHelper ::acs::DocHelper method protected public register_filename ::acs::DocHelper->::nx::Object ::crypto::HashFunctions ::crypto::HashFunctions readfile ::crypto::HashFunctions->::nx::Object ::ws::snapshot::Snapshot ::ws::snapshot::Snapshot collect all collect nx-objects collect procs collect vars collect xotcl-objects diff get_delta init listDiff save nx-objects save procs save vars save xotcl-objects ::ws::snapshot::Snapshot->::nx::Object ::nsbeat::Beat ::nsbeat::Beat beat data ms_to_utc nspost ::nsbeat::Beat->::nx::Object ::acs::SiteNodeUrlspaceCache ::acs::SiteNodeUrlspaceCache flush_cache get_node_id ::acs::SiteNodeUrlspaceCache->::nx::Object ::xo::lti::LTI ::xo::lti::LTI form_render get_context get_params_from_section init ::xo::lti::LTI->::nx::Object ::rrd::VolatileObject ::rrd::VolatileObject init ::rrd::VolatileObject->::nx::Object ::letsencrypt::Client ::letsencrypt::Client URL abortMsg authorizeDomain backup certificateInstall certificateRequest decnum_to_bytes domainForm getAPIurls getCertificate getNonce init log parseAccountKey printHeaders readFile registerNewAccount requireKeyFile send_signed_request signAgreement startOfReport updateConfiguration writeFile ::letsencrypt::Client->::nx::Object ::nsshell::THREAD ::nsshell::THREAD do init ::nsshell::THREAD->::nx::Object ::acs::LockfreeCache ::acs::LockfreeCache eval flush get ::acs::LockfreeCache->::nx::Object ::acs::db::Driver ::acs::db::Driver 0or1row 1row dml ds foreach get_sql get_value list list_of_lists map_default_dbn prepare qn row_lock sets transaction ::acs::db::Driver->::nx::Object ::xowiki::Mode ::xowiki::Mode get mode_name set toggle ::xowiki::Mode->::nx::Object ::xowiki::Upload ::xowiki::Upload store_file ::xowiki::Upload->::nx::Object ::rrd::DataSource ::rrd::DataSource createRRDfile deleteRRD init lastupdate requireRRD update ::rrd::DataSource->::nx::Object ::nsshell::Handler ::nsshell::Handler ::nsshell::Handler->::nx::Object ::nntp::Session ::nntp::Session → refresh decodeHeader destroy group init log login readArticle readLine writeLine ::nntp::Session->::nx::Object ::nx::serializer::Serializer ::nx::serializer::Serializer → addPattern → all → allChildren → application_namespaces → deepSerialize → exportMethods → exportObjects → export_nsfprocs → exportedMethods → exportedObjects → finalize_application_classes → methodSerialize → resetPattern addPostCmd deepSerialize getTargetName ignore ignoreVarsRE init isExportedObject needsOneOf objmap serialize-objects setObjectSystemSerializer topoSort warn ::nx::serializer::Serializer->::nx::Object ::acs::db::SQL ::acs::db::SQL build_function_argument_list build_stub_body create_db_function_interface dbfunction_argument_value dbfunction_to_tcl dbproc_arg ::acs::db::SQL->::nx::Object ::cookieconsent::CookieConsent ::cookieconsent::CookieConsent render_js ::cookieconsent::CookieConsent->::nx::Object ::ns_crypto::HashFunctions ::ns_crypto::HashFunctions readfile ::ns_crypto::HashFunctions->::nx::Object ::xo::REST ::xo::REST body expect_status_code init json_to_dict pp request typed_list_to_json typed_value_to_json with_json_result ::xo::REST->::nx::Object ::acs::SiteNode ::acs::SiteNode flush_cache get get_children get_node_id get_package_url get_url get_urls_from_object_id get_urls_from_package_key has_children properties ::acs::SiteNode->::nx::Object ::acs::Cluster ::acs::Cluster allowed_command broadcast check_state current_server_is_canonical_server current_server_is_dynamic_cluster_peer current_server_locations disconnect_request dynamic_cluster_nodes dynamic_cluster_reconfigure execute external_location incoming_request init is_canonical_server is_configured_server is_current_server join_request last_contact last_request log map_inaddr_any message decode message encode message sign message verify ns_http_send peer_nodes preauth preferred_location qualified_location reachable register_nodes secret secret_configured send send_disconnect_request_to_canonical_server send_dynamic_cluster_reconfigure_request send_join_request_to_canonical_server setup update_node_info ::acs::Cluster->::nx::Object ::nx::CopyHandler ::nx::CopyHandler copy copyTargets dest getDest makeTargetList objLength targetList ::nx::CopyHandler->::nx::Object ::nx::NsScopedNew ::nx::NsScopedNew new ::nx::NsScopedNew->::nx::Object ::nx::Slot ::nx::Slot exists getParameterOptionSubstdefault istype type=any type=cr_item_of_package type=dbtext type=html type=localurl type=naturalnum type=nohtml type=object_id type=oneof type=range type=signed type=token ::nx::Slot->::nx::Object ::nx::EnsembleObject ::nx::EnsembleObject defaultmethod init unknown ::nx::EnsembleObject->::nx::Object ::nx::Class ::nx::Class __class_configureparameter alias delete method delete property delete variable filters forward info info info method args info method body info method callprotection info method debug info method definition info method definitionhandle info method deprecated info method exists info method handle info method origin info method parameters info method registrationhandle info method returns info method submethods info method syntax info method type info slots info variables method mixins property require method require private method require protected method require public method unknown variable ::nx::Class->::nx::Object ::xo::ical::VEVENT ::xo::ical::VEVENT dtend finish formatted_recurrences sequence transp ::xo::ical::VEVENT->::xo::ical::VCALITEM ::xo::ical::VTODO ::xo::ical::VTODO completed due percent-complete ::xo::ical::VTODO->::xo::ical::VCALITEM ::xowf::test_item::grading::GradingNone ::xowf::test_item::grading::GradingNone grade ::xowf::test_item::grading::GradingNone->::xowf::test_item::grading::Grading ::xowf::test_item::grading::GradingRoundNone ::xowf::test_item::grading::GradingRoundNone grade ::xowf::test_item::grading::GradingRoundNone->::xowf::test_item::grading::Grading ::xowf::test_item::grading::GradingRoundPoints ::xowf::test_item::grading::GradingRoundPoints grade ::xowf::test_item::grading::GradingRoundPoints->::xowf::test_item::grading::Grading ::xowf::test_item::grading::GradingRoundPercentage ::xowf::test_item::grading::GradingRoundPercentage grade ::xowf::test_item::grading::GradingRoundPercentage->::xowf::test_item::grading::Grading ::xowf::test_item::Answer_manager ::xowf::test_item::Answer_manager achieved_points allow_answering answer_form_field_objs answers_panel countdown_timer create_workflow delete_all_answer_data delete_scheduled_atjobs dom class add dom class remove dom node appendXML dom node delete dom node replace dom node replaceXML exam_results export_answer export_file_submission get_IPs get_answer_attributes get_answer_wf get_duration get_exam_results get_label_from_options get_non_empty_file_formfields get_wf_instances grading_dialog_setup grading_scheme grading_table last_time_in_state last_time_switched_to_state marked_results participant_result participants_table postprocess_question_html pretty_formfield_name pretty_period prevent_multiple_tabs recutil_create render_answers render_answers_with_edit_history render_filter_bar render_full_submission_form render_print_button render_proctor_images render_submission=edit_history render_submission=exam_protocol render_submissions=edit_history result_table per_participant result_table per_question results_table revisions_up_to runtime_panel set_exam_results state_periods student_submissions_exist submissions time_window_setup waiting_room_message ::xowf::test_item::Answer_manager->::xowf::test_item::AssessmentInterface ::xowf::test_item::Question_manager ::xowf::test_item::Question_manager add_seeds aggregated_form combined_question_form current_question_form current_question_name current_question_number current_question_obj current_question_title describe_form disable_text_field_feature disallow_paste disallow_spellcheck disallow_translation exam_base_time exam_configuration_block exam_configuration_modifiable_field_names exam_configuration_popup exam_configuration_render_fields exam_info_block exam_target_time get_pool_questions get_pool_replacement_candidates goto_page hint_box hint_boxes initialize item_substitute_markup load_question_objs max_items minutes_string more_ahead nth_question_form nth_question_obj pagination_actions pagination_button_css_class percent_substitute percent_substitute_in_form points_string pretty_ncorrect pretty_nr_alternatives pretty_shuffle qualified_question_names question_count question_info question_info_block question_is_autograded question_names question_objs question_overview_block question_property question_randomization_ok question_statistics_block question_summary questions_without_minutes render_describe_infos replace_pool_question replace_pool_questions shuffled_index title_infos total total_minutes total_minutes_for_exam total_points ::xowf::test_item::Question_manager->::xowf::test_item::AssessmentInterface ::xowf::test_item::Renaming_form_loader ::xowf::test_item::Renaming_form_loader answer_attributes answer_for_form answers_for_form form_name_based_attribute_stem map_form_constraints name_to_question_obj_dict rename_attributes ::xowf::test_item::Renaming_form_loader->::xowf::test_item::AssessmentInterface ::acs::PartitionedCache ::acs::PartitionedCache cache_name flush_all flush_pattern_in_all_partitions init show_all ::acs::PartitionedCache->::acs::Cache ::ftpd::Session ::ftpd::Session AUTH CDUP CWD EPRT EPSV FEAT LIST MDTM MLSD NLST OPTS PASS PASV PWD QUIT RETR SIZE SYST TYPE USER close_data destroy file dir file exists file format date file format list file format mlst file format name file format permissions file glob file lastmodified file open file size init listen_data read_handler reply require_data write_data ::ftpd::Session->::ftpd::Infrastructure ::ftpd::Server ::ftpd::Server destroy listen listen_handler ::ftpd::Server->::ftpd::Infrastructure ::xo::lti::Jupyter ::xo::lti::Jupyter ::xo::lti::Jupyter->::xo::lti::LTI ::xo::lti::BBB ::xo::lti::BBB ::xo::lti::BBB->::xo::lti::LTI ::xo::lti::Zoom ::xo::lti::Zoom ::xo::lti::Zoom->::xo::lti::LTI ::rrd::Element ::rrd::Element ::rrd::Element->::rrd::VolatileObject ::rrd::Graph ::rrd::Graph elements imgName init render ::rrd::Graph->::rrd::VolatileObject ::acs::db::nsdbi ::acs::db::nsdbi list list_of_lists ::acs::db::nsdbi->::acs::db::Driver ::acs::db::nsdb ::acs::db::nsdb list list_of_lists ::acs::db::nsdb->::acs::db::Driver ::xowiki::UploadPhotoForm ::xowiki::UploadPhotoForm store_file ::xowiki::UploadPhotoForm->::xowiki::Upload ::xowiki::UploadFile ::xowiki::UploadFile store_file ::xowiki::UploadFile->::xowiki::Upload ::nsshell::CurrentThreadHandler ::nsshell::CurrentThreadHandler _eval autocomplete completion_elements context require eval heartbeat info_complete init ::nsshell::CurrentThreadHandler->::nsshell::Handler ::nsshell::KernelThreadHandler ::nsshell::KernelThreadHandler dropKernel eval init useKernel ::nsshell::KernelThreadHandler->::nsshell::Handler ::acs::db::oracle ::acs::db::oracle db_proc_opt_arg_spec expected_result_types get_all_package_functions map_function_name sql_function_argument_list sql_function_name typemap ::acs::db::oracle->::acs::db::SQL ::acs::db::postgresql ::acs::db::postgresql argument_name_match db_proc_opt_arg_spec expected_result_types get_all_package_functions map_function_name psql_statement_suffix sql_function_argument_list sql_function_name typemap ::acs::db::postgresql->::acs::db::SQL ::ns_hmac ::ns_hmac → file → string add destroy get init ::ns_hmac->::ns_crypto::HashFunctions ::ns_md ::ns_md → file → string add destroy get init ::ns_md->::ns_crypto::HashFunctions ::xo::Authorize ::xo::Authorize decoded_state encoded_state get_required_fields login_url logout lookup_user_id name perform_login qualified record_oauth_registration redeem_code register_new_user required_fields ::xo::Authorize->::xo::REST ::canvas::API ::canvas::API account admins account courses account get account list account permissions account settings course activities course todo course users paginated_result_list params parse_link_params parse_link_value request token ::canvas::API->::xo::REST ::ms::Graph ::ms::Graph → run_donecallback application get application list async_operation_status chat get chat messages check_async_operation encode_query group deleted group get group list group member add group member list group member remove group memberof group owner add group owner list group owner remove paginated_result_list params request run_donecallback schedule_donecallback team archive team channel list team clone team create team delete team get team member add team member list team member remove team unarchive token user get user list user me user memberof ::ms::Graph->::xo::REST ::nx::MethodParameterSlot ::nx::MethodParameterSlot ::nx::MethodParameterSlot->::nx::Slot ::nx::ObjectParameterSlot ::nx::ObjectParameterSlot createForwarder definition destroy getParameterOptions getParameterSpec getPropertyDefinitionOptions init makeForwarder namedParameterSpec onError unknown ::nx::ObjectParameterSlot->::nx::Slot ::xotcl::package ::xotcl::package → contains → create → extend → import → present → require → unknown → verbose ::xotcl::package->::nx::Class ::nx::MetaSlot ::nx::MetaSlot → createFromParameterSpec → optionsToValueCheckingSpec → parseParameterSpec → requireClass → substDefaultOptions ::nx::MetaSlot->::nx::Class

Class ::nx::Object

::nx::Object[i] create ...

Class Relations

  • class: ::nx::Class[i]
  • subclass: ::nx::serializer::ObjectSystemSerializer[i], ::xo::ical::VCALITEM[i], ::xo::MessageRelay[i], ::xowf::test_item::grading::Grading[i], ::xowf::test_item::AssessmentInterface[i], ::xowf::IpRange[i], ::rrd::Plugin[i], ::acs::Container[i], ::acs::SiteNodesCache[i], ::acs::Cache[i], ::ftpd::Infrastructure[i], ::acs::DocHelper[i], ::crypto::HashFunctions[i], ::ws::snapshot::Snapshot[i], ::nsbeat::Beat[i], ::acs::SiteNodeUrlspaceCache[i], ::xo::lti::LTI[i], ::rrd::VolatileObject[i], ::letsencrypt::Client[i], ::nsshell::THREAD[i], ::acs::LockfreeCache[i], ::acs::db::Driver[i], ::xowiki::Mode[i], ::xowiki::Upload[i], ::rrd::DataSource[i], ::nsshell::Handler[i], ::nntp::Session[i], ::nx::serializer::Serializer[i], ::acs::db::SQL[i], ::cookieconsent::CookieConsent[i], ::ns_crypto::HashFunctions[i], ::xo::REST[i], ::acs::SiteNode[i], ::acs::Cluster[i], ::nx::CopyHandler[i], ::nx::NsScopedNew[i], ::nx::Slot[i], ::nx::EnsembleObject[i], ::nx::Class[i]
::nx::Class create ::nx::Object

Methods (to be applied on instances)

  • cget (alias)

  • configure (alias)

  • contains (scripted)

    if {![info exists object]} {set object [::nsf::self]}
    if {![::nsf::object::exists $object]} {$class create $object}
    # This method is reused in XOTcl which has e.g. no "require";
    # therefore use nsf primitiva.
    ::nsf::directdispatch $object ::nsf::methods::object::requirenamespace
    
    if {$withnew} {
      #
      # When $withnew is requested we replace the default new method
      # with a version using the current namespace as root. Earlier
      # implementations used a mixin on nx::Class and xotcl::Class,
      # but frequent mixin operations on the most general meta-class
      # are expensive when there are many classes defined
      # (e.g. several ten thousands), since the mixin operation
      # invalidates the mixins for all instances of the meta-class
      # (i.e. for all classes)
      #
      set infoMethod "::nsf::methods::class::info::method"
      set plainNew   "::nsf::methods::class::new"
      set mappedNew  [::nx::NsScopedNew $infoMethod definitionhandle new]
    
      set nxMapNew [expr {[::nx::Class $infoMethod origin new] eq $plainNew}]
      if {$nxMapNew} {::nsf::method::alias ::nx::Class new $mappedNew}
    
      if {[::nsf::is class ::xotcl::Class]} {
        set xotclMapNew [expr {[::xotcl::Class $infoMethod origin new] eq $plainNew}]
        if {$xotclMapNew} {::nsf::method::alias ::xotcl::Class new $mappedNew }
      }
      #
      # Evaluate the command under catch to ensure reverse mapping
      # of "new"
      #
      set errorOccurred [catch  [list ::apply [list {} $cmds $object]]  result errorOptions]
    
      #
      # Remove the mapped "new" method, if it was added above
      #
      if {$nxMapNew} {::nsf::method::alias ::nx::Class new $plainNew}
      if {[::nsf::is class ::xotcl::Class]} {
        if {$xotclMapNew} {::nsf::method::alias ::xotcl::Class new $plainNew}
      }
      #
      # Report the error with message and code when necessary
      #
      if {$errorOccurred} {
        dict incr errorOptions -level
        dict unset errorOptions -errorinfo
      }
      return -options $errorOptions $result
    
    } else {
      ::apply [list {} $cmds $object]
    }
  • copy (scripted)

    if {[string trimleft $newName :] ne [string trimleft [::nsf::self] :]} {
      set h [CopyHandler new]
      set r [$h copy [::nsf::self$newName]
      $h destroy
      return $r
    }
  • delete object method (scripted)

    ::nsf::method::delete [self] -per-object $name
  • delete object property (scripted)

    set slot [: ::nsf::methods::object::info::slotobjects -type ::nx::Slot $name]
    if {$slot eq ""} {
          return -code error  "[self]: cannot delete object-specific property '$name'"
    }
    $slot destroy
    nsf::var::unset -nocomplain [self$name
  • delete object variable (scripted)

    if {[nsf::var::exists [self$name]} {
        nsf::var::unset [self$name
    } else {
        return -code error  "[self]: object does not have an instance variable '$name'"
    }
    # call explicitly the per-object variant of "info::slotobjects"
    set slot [: ::nsf::methods::object::info::slotobjects -type ::nx::Slot $name]
    
    if {$slot ne ""} {
        # it is not a slot-less variable
        $slot destroy
    }
  • destroy (alias)

  • destroy_on_cleanup (scripted)

    set ::xo::cleanup([self]) [list [self] destroy]
  • eval (alias)

  • info baseclass (alias)

  • info children (alias)

  • info class (alias)

  • info has mixin (alias)

  • info has namespace (alias)

  • info has type (alias)

  • info info (scripted)

    ::nx::internal::infoOptions -asList=$asList ::nx::Object::slot::__info
  • info lookup filter (alias)

  • info lookup filters (alias)

  • info lookup method (alias)

  • info lookup methods (alias)

  • info lookup mixins (alias)

  • info lookup parameters (scripted)

    return [::nsf::cmd::info  parameter  -context [self]  [:info lookup method $methodName]  {*}[expr {[info exists pattern] ? $pattern : ""}] ]
  • info lookup slots (scripted)

    set cmd [list ::nsf::methods::object::info::lookupslots -type $type]
    if {[info exists source]} {lappend cmd -source $source}
    if {[info exists pattern]} {lappend cmd $pattern}
    return [: {*}$cmd]
  • info lookup syntax (scripted)

    return [::nsf::cmd::info  syntax  -context [self]  [:info lookup method $methodName]  {*}[expr {[info exists pattern] ? $pattern : ""}] ]
  • info lookup variables (scripted)

    return [: info lookup slots -type ::nx::VariableSlot {*}[current args]]
  • info name (alias)

  • info object filters (alias)

  • info object method args (scripted)

    : ::nsf::methods::object::info::method args $name
  • info object method body (scripted)

    : ::nsf::methods::object::info::method body $name
  • info object method callprotection (scripted)

    if {[::nsf::method::property [self] -per-object $name call-protected]} {
      return protected
    } elseif {[::nsf::method::property [self] -per-object $name call-private]} {
      return private
    } else {
      return public
    }
  • info object method debug (scripted)

    ::nsf::method::property [self] -per-object $name debug
  • info object method definition (scripted)

    : ::nsf::methods::object::info::method definition $name
  • info object method definitionhandle (scripted)

    : ::nsf::methods::object::info::method definitionhandle $name
  • info object method deprecated (scripted)

    ::nsf::method::property [self] -per-object $name deprecated
  • info object method exists (scripted)

    : ::nsf::methods::object::info::method exists $name
  • info object method handle (scripted)

    : ::nsf::methods::object::info::method definitionhandle $name
  • info object method origin (scripted)

    : ::nsf::methods::object::info::method origin $name
  • info object method parameters (scripted)

    set defs [: ::nsf::methods::object::info::method parameter $name]
    if {[info exists pattern]} {return [::nsf::parameter::filter $defs $pattern]}
    return $defs
  • info object method registrationhandle (scripted)

    : ::nsf::methods::object::info::method registrationhandle $name
  • info object method returns (scripted)

    : ::nsf::methods::object::info::method returns $name
  • info object method submethods (scripted)

    : ::nsf::methods::object::info::method submethods $name
  • info object method syntax (scripted)

    return [string trimright "/obj/ [namespace tail $name] [: ::nsf::methods::object::info::method syntax $name]" { }]
  • info object method type (scripted)

    : ::nsf::methods::object::info::method type $name
  • info object methods (alias)

  • info object mixins (alias)

  • info object slots (scripted)

    set method [list ::nsf::methods::object::info::slotobjects -type $type]
    if {[info exists pattern]} {lappend method $pattern}
    return [: {*}$method]
  • info object variables (scripted)

    return [: info object slots -type ::nx::VariableSlot {*}[current args]]
  • info parent (alias)

  • info precedence (alias)

  • info variable definition (scripted)

    return [$handle definition]
  • info variable name (scripted)

    return [$handle cget -name]
  • info variable parameter (scripted)

    return [$handle parameter]
  • info vars (alias)

  • move (scripted)

    if {[string trimleft $newName :] ne [string trimleft [::nsf::self] :]} {
      if {$newName ne ""} {
        :copy $newName
      }
      ### let all subclasses get the copied class as superclass
      if {[::nsf::is class [::nsf::self]] && $newName ne ""} {
        foreach subclass [: ::nsf::methods::class::info::subclass] {
          set scl [$subclass ::nsf::methods::class::info::superclass]
          if {[set index [lsearch -exact $scl [::nsf::self]]] != -1} {
            set scl [lreplace $scl $index $index $newName]
            ::nsf::relation::set $subclass superclass $scl
          }
        }    
      }
      :destroy
    }
  • object alias (scripted)

    set pathData  [:__resolve_method_path -per-object  $methodName]
    set object    [dict get $pathData object]
    
    #puts "object alias $object.[dict get $pathData methodName] $cmd"
    set r [::nsf::method::alias $object -per-object [dict get $pathData methodName]  -frame $frame $cmd]
    ::nsf::method::property $object -per-object $r call-protected  [::nsf::dispatch $object __default_method_call_protection]
    if {[info exists returns]} {::nsf::method::property $object $r returns $returns}
    if {$debug} {::nsf::method::property $object $r debug true}
    if {$deprecated} {::nsf::method::property $object $r deprecated true}
    return $r
  • object filters (forward)

  • object forward (scripted)

    set arguments [lrange [::nsf::current args] 1 end]
    set pathData  [:__resolve_method_path -per-object  $methodName]
    set object    [dict get $pathData object]
    
    if {[info exists target] && [string index $target 0] eq "-"} {
      error "target '$target' must not start with a dash"
    }
    if {[info exists frame] && $frame ni {object default}} {
      error "value of parameter '-frame' must be 'object' or 'default'"
    }
    if {[info exists returns]} {
      set nrPreArgs [expr {[llength $arguments]-[llength $args]}]
        # search for "-returns" in the arguments before $args ...
        set p [lsearch -exact [lrange $arguments 0 $nrPreArgs] -returns]
        # ... and remove it if found
        if {$p > -1} {set arguments [lreplace $arguments $p $p+1]}
    }
    set r [::nsf::method::forward $object -per-object  [dict get $pathData methodName] {*}$arguments]
    ::nsf::method::property $object -per-object $r call-protected  [::nsf::dispatch $object __default_method_call_protection]
    if {[info exists returns]} {::nsf::method::property $object $r returns $returns}
    if {$debug} {::nsf::method::property $object $r debug true}
    if {$deprecated} {::nsf::method::property $object $r deprecated true}
    return $r
  • object method (scripted)

    set pathData  [:__resolve_method_path -per-object $methodName]
    set object    [dict get $pathData object]
    set regObject [dict get $pathData regObject]
    
    # puts "object method $object.[dict get $pathData methodName] [list $arguments] {...}"
    set r [::nsf::method::create $object  -checkalways=$checkalways  {*}[expr {$regObject ne "" ? "-reg-object [list $regObject]" : ""}]  -per-object  [dict get $pathData methodName] $arguments $body]
    if {$r ne ""} {
        # the method was not deleted
        ::nsf::method::property $object $r call-protected  [::nsf::dispatch $object __default_method_call_protection]
        if {[info exists returns]} {::nsf::method::property $object $r returns $returns}
      if {$debug} {::nsf::method::property $object $r debug true}
      if {$deprecated} {::nsf::method::property $object $r deprecated true}
    }
    return $r
  • object mixins (forward)

  • object property (scripted)

    if {$accessor eq ""} {
      set accessor [::nsf::dispatch [self] __default_accessor]
      #puts stderr "OBJECT [self] got default accessor ${accessor}"
    }
    set traceSpec [expr {[info exists trace] ? [list -trace $trace] : ""}]
    
    set r [[self] object variable  -accessor $accessor  -incremental=$incremental  -class $class  -initblock $initblock  -configurable $configurable  -nocomplain=$nocomplain  {*}$traceSpec  {*}$spec]
    return $r
  • object variable (scripted)

    #puts stderr "Object variable $spec accessor $accessor nocomplain $nocomplain incremental $incremental"
    
    # get name and list of parameter options
    lassign [::nx::MetaSlot parseParameterSpec -class $class -target [self$spec]  name parameterOptions class options
    
    #puts "[self] object variable $spec name <$name> parameterOptions <$parameterOptions> class <$class> options <$options>"
    
    
    if {[dict exists $options -configurable]} {
      set configurable [dict get $options -configurable]
    }
    
    if {![info exists trace] && [info exists :trace] && ${:trace} ne "none"} {
      set trace ${:trace}
    }
    
    #puts "[self] object variable $spec haveDefault? [info exists defaultValue] opts <$parameterOptions> options <$options>"
    
    if {[info exists defaultValue]
        && [dict exists $options -substdefault]
        && [string match {*\[*\]*} $defaultValue]
      } {
      if {![info complete $defaultValue]} {
        return -code error "substdefault: default '$defaultValue' is not a complete script"
      }
      set substDefaultOptions [::nx::MetaSlot substDefaultOptions [dict get $options -substdefault]]
      set defaultValue [subst {*}$substDefaultOptions $defaultValue]
    }
    
    #
    # Check for slot-less variables
    #
    if {$initblock eq ""
        && !$configurable
        && !$incremental
        && $accessor eq "none"
        && ![info exists trace]
      } {
      #
      # The variable is slot-less.
      #
      #puts "[self]... slotless variable $spec"
    
      # The following tasks have to be still performed:
      # - If there is an explicit default value, the value has to
      #   be checked.
      # - if the type is a switch, we have to set the implicit
      #   default value, when there is not explicit default
      #
      set isSwitch [expr {[dict exists $options -type] && [dict get $options -type] eq "switch"}]
    
      if {[info exists defaultValue]} {
        if {[info exists :$name] && !$nocomplain} {
          return -code error  "object [self] has already an instance variable named '$name'"
        }
        if {$parameterOptions ne ""} {
          #puts stderr "*** ::nsf::is $parameterOptions $defaultValue // opts=$options"
          #
          # Extract from the options a spec for value checking, and
          # let "nsf::is" perform the actual checking. In case, the
          # check fails, "nsf::is" will raise an error with and error
          # message communicating the failure.
          #
          set nspec [::nx::MetaSlot optionsToValueCheckingSpec $options]
          ::nsf::is -complain $nspec $defaultValue
        } else {
          set name $spec
        }
        set :$name $defaultValue
      } elseif {$isSwitch} {
        set :$name 0
      } else {
        return -code error  "variable definition for '$name' (without value and accessor) is useless"
      }
      return
    }
    
    #puts "[self]... slot variable $spec"
    #
    # create variable via a slot object
    #
    set defaultopts [list -accessor $accessor]
    if {[info exists trace]} {lappend defaultopts -trace $trace}
    
    set slot [::nx::MetaSlot createFromParameterSpec [self]  -per-object  -class $class  -initblock $initblock  -incremental=$incremental  -private=[expr {$accessor eq "private"}]  -defaultopts $defaultopts  $spec  {*}[expr {[info exists defaultValue] ? [list $defaultValue] : ""}]]
    
    if {$nocomplain} {$slot eval {set :nocomplain 1}}
    if {!$configurable} {$slot eval {set :configurable false}}
    if {[info exists defaultValue]} {
      #
      # We could consider calling "configure" instead, but that would
      # not work for true "variable" handlers.
      #
      # In case a "get" trace is activated, don't complain about
      # pre-existing variables, which might be set via traces.
      #
      set allowpreset [expr {"get" in [$slot cget -trace] && [nsf::var::exists [self$name]}]
      $slot setCheckedInstVar -allowpreset=$allowpreset -nocomplain=$nocomplain [self$defaultValue
      #set :__initblock($name) 1
    }
    
    if {[$slot eval {info exists :settername}]} {
      set name [$slot cget -settername]
    } else {
      set name [$slot cget -name]
    }
    #puts "[self]... $slot cget DONE"
    return [::nsf::directdispatch [self] ::nsf::methods::object::info::method registrationhandle $name]
  • private (scripted)

    if {![info exists ::nsf::methodDefiningMethod([lindex $args 0])]} {
        return -code error "'[lindex $args 0]' is not a method defining method"
    } elseif {[lindex $args 0] eq "object" && ![info exists ::nsf::methodDefiningMethod([lindex $args 1])]} {
        return -code error "'[lindex $args 1]' is not a method defining method"
    }
    set r [: -system {*}$args]
    if {$r ne ""} {::nsf::method::property [self$r call-private true}
    return $r
  • protected (scripted)

    if {![info exists ::nsf::methodDefiningMethod([lindex $args 0])]} {
        return -code error "'[lindex $args 0]' is not a method defining method"
    } elseif {[lindex $args 0] eq "object" && ![info exists ::nsf::methodDefiningMethod([lindex $args 1])]} {
        return -code error "'[lindex $args 1]' is not a method defining method"
    }
    set r [: -system {*}$args]
    if {$r ne ""} {::nsf::method::property [self$r call-protected true}
    return $r
  • public (scripted)

    if {![info exists ::nsf::methodDefiningMethod([lindex $args 0])]} {
        return -code error "'[lindex $args 0]' is not a method defining method"
    } elseif {[lindex $args 0] eq "object" && ![info exists ::nsf::methodDefiningMethod([lindex $args 1])]} {
        return -code error "'[lindex $args 1]' is not a method defining method"
    }
    set r [: -system {*}$args]
    if {$r ne ""} {::nsf::method::property [self$r call-protected false}
    return $r
  • require namespace (scripted)

    ::nsf::directdispatch [::nsf::self] ::nsf::methods::object::requirenamespace
  • require object method (scripted)

    ::nsf::method::require [::nsf::self$methodName 1
    return [:info lookup method $methodName]
  • require private object method (scripted)

    set result [:require object method $methodName]
    ::nsf::method::property [self$result call-private true
    return $result
  • require protected object method (scripted)

    set result [:require object method $methodName]
    ::nsf::method::property [self$result call-protected true
    return $result
  • require public object method (scripted)

    set result [:require object method $methodName]
    ::nsf::method::property [self$result call-protected false
    return $result
  • serialize (scripted)

    ::Serializer deepSerialize [self]