node-opcua-address-space 2.183.0 → 2.184.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/api/helpers/adjust_browse_direction.ts +1 -1
- package/api/helpers/argument_list.ts +9 -9
- package/api/helpers/coerce_enum_value.ts +1 -0
- package/api/helpers/dump_tools.ts +1 -1
- package/api/index.ts +2 -1
- package/api/interfaces/alarms_and_conditions/deviation_stuff.ts +30 -0
- package/api/interfaces/data_access/ua_multistate_discrete_ex.ts +1 -1
- package/api/interfaces/nodeset_loader_options.ts +17 -0
- package/api/loader/decode_xml_extension_object.ts +1 -1
- package/api/loader/ensure_datatype_extracted.ts +73 -37
- package/api/loader/generateAddressSpaceRaw.ts +32 -22
- package/api/loader/load_nodeset2.ts +2 -2
- package/api/loader/namespace_post_step.ts +1 -1
- package/api/loader/narrow_instance_datatypes.ts +22 -9
- package/api/loader/nodeset_image_codec.ts +26 -12
- package/api/loader/nodeset_record_applier.ts +1 -1
- package/api/loader/nodeset_xml_producer.ts +8 -6
- package/api/loader/parsers/extension_object_parser.ts +3 -3
- package/api/loader/register_node_promoter.ts +10 -2
- package/api/pseudo_session.ts +1 -1
- package/bin/{nodeset_equivalence.js → nodeset_equivalence.cjs} +1 -1
- package/bin/{opcua-nodeset-image.js → opcua-nodeset-image.cjs} +1 -1
- package/bin/{opcua-nodeset-live.js → opcua-nodeset-live.cjs} +2 -2
- package/dist/api/address_space_public.d.ts +1 -0
- package/dist/api/address_space_public.d.ts.map +1 -0
- package/dist/api/address_space_public.js +2 -5
- package/dist/api/address_space_public.js.map +1 -1
- package/dist/api/address_space_ts.d.ts +1 -0
- package/dist/api/address_space_ts.d.ts.map +1 -0
- package/dist/api/address_space_ts.js +2 -5
- package/dist/api/address_space_ts.js.map +1 -1
- package/dist/api/continuation_points/continuation_point_manager.d.ts +1 -0
- package/dist/api/continuation_points/continuation_point_manager.d.ts.map +1 -0
- package/dist/api/continuation_points/continuation_point_manager.js +13 -17
- package/dist/api/continuation_points/continuation_point_manager.js.map +1 -1
- package/dist/api/helpers/adjust_browse_direction.d.ts +1 -0
- package/dist/api/helpers/adjust_browse_direction.d.ts.map +1 -0
- package/dist/api/helpers/adjust_browse_direction.js +2 -5
- package/dist/api/helpers/adjust_browse_direction.js.map +1 -1
- package/dist/api/helpers/argument_list.d.ts +1 -0
- package/dist/api/helpers/argument_list.d.ts.map +1 -0
- package/dist/api/helpers/argument_list.js +61 -69
- package/dist/api/helpers/argument_list.js.map +1 -1
- package/dist/api/helpers/call_helpers.d.ts +1 -0
- package/dist/api/helpers/call_helpers.d.ts.map +1 -0
- package/dist/api/helpers/call_helpers.js +25 -28
- package/dist/api/helpers/call_helpers.js.map +1 -1
- package/dist/api/helpers/coerce_enum_value.d.ts +1 -0
- package/dist/api/helpers/coerce_enum_value.d.ts.map +1 -0
- package/dist/api/helpers/coerce_enum_value.js +15 -17
- package/dist/api/helpers/coerce_enum_value.js.map +1 -1
- package/dist/api/helpers/dump_tools.d.ts +1 -0
- package/dist/api/helpers/dump_tools.d.ts.map +1 -0
- package/dist/api/helpers/dump_tools.js +19 -29
- package/dist/api/helpers/dump_tools.js.map +1 -1
- package/dist/api/helpers/ensure_secure_access.d.ts +1 -0
- package/dist/api/helpers/ensure_secure_access.d.ts.map +1 -0
- package/dist/api/helpers/ensure_secure_access.js +24 -28
- package/dist/api/helpers/ensure_secure_access.js.map +1 -1
- package/dist/api/helpers/make_optionals_map.d.ts +1 -0
- package/dist/api/helpers/make_optionals_map.d.ts.map +1 -0
- package/dist/api/helpers/make_optionals_map.js +1 -4
- package/dist/api/helpers/make_optionals_map.js.map +1 -1
- package/dist/api/helpers/multiform_func.d.ts +1 -0
- package/dist/api/helpers/multiform_func.d.ts.map +1 -0
- package/dist/api/helpers/multiform_func.js +4 -8
- package/dist/api/helpers/multiform_func.js.map +1 -1
- package/dist/api/helpers/resolve_opaque_on_address_space.d.ts +1 -0
- package/dist/api/helpers/resolve_opaque_on_address_space.d.ts.map +1 -0
- package/dist/api/helpers/resolve_opaque_on_address_space.js +10 -13
- package/dist/api/helpers/resolve_opaque_on_address_space.js.map +1 -1
- package/dist/api/index.d.ts +3 -1
- package/dist/api/index.d.ts.map +1 -0
- package/dist/api/index.js +93 -218
- package/dist/api/index.js.map +1 -1
- package/dist/api/interfaces/alarms_and_conditions/condition_info_i.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/condition_info_i.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/condition_info_i.js +2 -5
- package/dist/api/interfaces/alarms_and_conditions/condition_info_i.js.map +1 -1
- package/dist/api/interfaces/alarms_and_conditions/condition_snapshot.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/condition_snapshot.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/condition_snapshot.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/deviation_stuff.d.ts +29 -0
- package/dist/api/interfaces/alarms_and_conditions/deviation_stuff.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/deviation_stuff.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/install_setpoint_options.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/install_setpoint_options.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/install_setpoint_options.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/instantiate_alarm_condition_options.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_alarm_condition_options.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_alarm_condition_options.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/instantiate_condition_options.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_condition_options.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_condition_options.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/instantiate_exclusive_deviation_alarm_options.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_exclusive_deviation_alarm_options.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_exclusive_deviation_alarm_options.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/instantiate_exclusive_limit_alarm_options.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_exclusive_limit_alarm_options.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_exclusive_limit_alarm_options.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/instantiate_limit_alarm_options.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_limit_alarm_options.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_limit_alarm_options.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/instantiate_non_exclusive_deviation_alarm_options.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_non_exclusive_deviation_alarm_options.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_non_exclusive_deviation_alarm_options.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/instantiate_non_exclusive_limit_alarm_options.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_non_exclusive_limit_alarm_options.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_non_exclusive_limit_alarm_options.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/instantiate_off_normal_alarm_options.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_off_normal_alarm_options.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/instantiate_off_normal_alarm_options.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/promote_to_alarm_options.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/promote_to_alarm_options.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/promote_to_alarm_options.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/ua_acknowledgeable_condition_ex.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_acknowledgeable_condition_ex.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_acknowledgeable_condition_ex.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/ua_alarm_condition_ex.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_alarm_condition_ex.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_alarm_condition_ex.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/ua_base_event_ex.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_base_event_ex.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_base_event_ex.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/ua_certificate_expiration_alarm_ex.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_certificate_expiration_alarm_ex.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_certificate_expiration_alarm_ex.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/ua_condition_ex.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_condition_ex.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_condition_ex.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/ua_discrete_alarm_ex.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_discrete_alarm_ex.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_discrete_alarm_ex.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/ua_exclusive_deviation_alarm_ex.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_exclusive_deviation_alarm_ex.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_exclusive_deviation_alarm_ex.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/ua_exclusive_limit_alarm_ex.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_exclusive_limit_alarm_ex.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_exclusive_limit_alarm_ex.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/ua_limit_alarm_ex.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_limit_alarm_ex.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_limit_alarm_ex.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/ua_non_exclusive_deviation_alarm_ex.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_non_exclusive_deviation_alarm_ex.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_non_exclusive_deviation_alarm_ex.js +1 -2
- package/dist/api/interfaces/alarms_and_conditions/ua_non_exclusive_limit_alarm_ex.d.ts +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_non_exclusive_limit_alarm_ex.d.ts.map +1 -0
- package/dist/api/interfaces/alarms_and_conditions/ua_non_exclusive_limit_alarm_ex.js +1 -2
- package/dist/api/interfaces/data_access/ua_multistate_discrete_ex.d.ts +2 -1
- package/dist/api/interfaces/data_access/ua_multistate_discrete_ex.d.ts.map +1 -0
- package/dist/api/interfaces/data_access/ua_multistate_discrete_ex.js +1 -2
- package/dist/api/interfaces/data_access/ua_multistate_value_discrete_ex.d.ts +1 -0
- package/dist/api/interfaces/data_access/ua_multistate_value_discrete_ex.d.ts.map +1 -0
- package/dist/api/interfaces/data_access/ua_multistate_value_discrete_ex.js +1 -2
- package/dist/api/interfaces/data_access/ua_two_state_discrete_ex.d.ts +1 -0
- package/dist/api/interfaces/data_access/ua_two_state_discrete_ex.d.ts.map +1 -0
- package/dist/api/interfaces/data_access/ua_two_state_discrete_ex.js +1 -2
- package/dist/api/interfaces/data_access/ua_y_array_item_ex.d.ts +1 -0
- package/dist/api/interfaces/data_access/ua_y_array_item_ex.d.ts.map +1 -0
- package/dist/api/interfaces/data_access/ua_y_array_item_ex.js +1 -2
- package/dist/api/interfaces/extension_object_constructor.d.ts +1 -0
- package/dist/api/interfaces/extension_object_constructor.d.ts.map +1 -0
- package/dist/api/interfaces/extension_object_constructor.js +1 -2
- package/dist/api/interfaces/i_condition_variable_type_setter_options.d.ts +1 -0
- package/dist/api/interfaces/i_condition_variable_type_setter_options.d.ts.map +1 -0
- package/dist/api/interfaces/i_condition_variable_type_setter_options.js +1 -2
- package/dist/api/interfaces/i_set_state_options.d.ts +1 -0
- package/dist/api/interfaces/i_set_state_options.d.ts.map +1 -0
- package/dist/api/interfaces/i_set_state_options.js +1 -2
- package/dist/api/interfaces/nodeset_loader_options.d.ts +18 -0
- package/dist/api/interfaces/nodeset_loader_options.d.ts.map +1 -0
- package/dist/api/interfaces/nodeset_loader_options.js +1 -2
- package/dist/api/interfaces/state_machine/ua_exclusive_limit_state_machine_type_ex.d.ts +1 -0
- package/dist/api/interfaces/state_machine/ua_exclusive_limit_state_machine_type_ex.d.ts.map +1 -0
- package/dist/api/interfaces/state_machine/ua_exclusive_limit_state_machine_type_ex.js +1 -2
- package/dist/api/interfaces/state_machine/ua_finite_state_machine_type.d.ts +1 -0
- package/dist/api/interfaces/state_machine/ua_finite_state_machine_type.d.ts.map +1 -0
- package/dist/api/interfaces/state_machine/ua_finite_state_machine_type.js +1 -2
- package/dist/api/interfaces/state_machine/ua_program_state_machine_type.d.ts +1 -0
- package/dist/api/interfaces/state_machine/ua_program_state_machine_type.d.ts.map +1 -0
- package/dist/api/interfaces/state_machine/ua_program_state_machine_type.js +1 -2
- package/dist/api/interfaces/state_machine/ua_shelved_state_machine_ex.d.ts +1 -0
- package/dist/api/interfaces/state_machine/ua_shelved_state_machine_ex.d.ts.map +1 -0
- package/dist/api/interfaces/state_machine/ua_shelved_state_machine_ex.js +1 -2
- package/dist/api/interfaces/state_machine/ua_state_machine_type.d.ts +1 -0
- package/dist/api/interfaces/state_machine/ua_state_machine_type.d.ts.map +1 -0
- package/dist/api/interfaces/state_machine/ua_state_machine_type.js +1 -2
- package/dist/api/interfaces/state_machine/ua_state_machine_type.js.map +1 -1
- package/dist/api/interfaces/state_machine/ua_transition_ex.d.ts +1 -0
- package/dist/api/interfaces/state_machine/ua_transition_ex.d.ts.map +1 -0
- package/dist/api/interfaces/state_machine/ua_transition_ex.js +1 -2
- package/dist/api/interfaces/ua_subscription_diagnostics_variable_ex.d.ts +1 -0
- package/dist/api/interfaces/ua_subscription_diagnostics_variable_ex.d.ts.map +1 -0
- package/dist/api/interfaces/ua_subscription_diagnostics_variable_ex.js +1 -2
- package/dist/api/interfaces/ua_subscription_diagnostics_variable_ex.js.map +1 -1
- package/dist/api/loader/decode_xml_extension_object.d.ts +1 -0
- package/dist/api/loader/decode_xml_extension_object.d.ts.map +1 -0
- package/dist/api/loader/decode_xml_extension_object.js +13 -17
- package/dist/api/loader/decode_xml_extension_object.js.map +1 -1
- package/dist/api/loader/ensure_datatype_extracted.d.ts +1 -0
- package/dist/api/loader/ensure_datatype_extracted.d.ts.map +1 -0
- package/dist/api/loader/ensure_datatype_extracted.js +83 -52
- package/dist/api/loader/ensure_datatype_extracted.js.map +1 -1
- package/dist/api/loader/generateAddressSpaceRaw.d.ts +1 -0
- package/dist/api/loader/generateAddressSpaceRaw.d.ts.map +1 -0
- package/dist/api/loader/generateAddressSpaceRaw.js +76 -74
- package/dist/api/loader/generateAddressSpaceRaw.js.map +1 -1
- package/dist/api/loader/load_nodeset2.d.ts +1 -0
- package/dist/api/loader/load_nodeset2.d.ts.map +1 -0
- package/dist/api/loader/load_nodeset2.js +44 -51
- package/dist/api/loader/load_nodeset2.js.map +1 -1
- package/dist/api/loader/make_semver_compatible.d.ts +1 -0
- package/dist/api/loader/make_semver_compatible.d.ts.map +1 -0
- package/dist/api/loader/make_semver_compatible.js +1 -4
- package/dist/api/loader/make_semver_compatible.js.map +1 -1
- package/dist/api/loader/make_xml_extension_object_parser.d.ts +1 -0
- package/dist/api/loader/make_xml_extension_object_parser.d.ts.map +1 -0
- package/dist/api/loader/make_xml_extension_object_parser.js +37 -40
- package/dist/api/loader/make_xml_extension_object_parser.js.map +1 -1
- package/dist/api/loader/namespace_post_step.d.ts +1 -0
- package/dist/api/loader/namespace_post_step.d.ts.map +1 -0
- package/dist/api/loader/namespace_post_step.js +12 -17
- package/dist/api/loader/namespace_post_step.js.map +1 -1
- package/dist/api/loader/narrow_instance_datatypes.d.ts +1 -0
- package/dist/api/loader/narrow_instance_datatypes.d.ts.map +1 -0
- package/dist/api/loader/narrow_instance_datatypes.js +38 -28
- package/dist/api/loader/narrow_instance_datatypes.js.map +1 -1
- package/dist/api/loader/nodeset_builtin_formats.d.ts +1 -0
- package/dist/api/loader/nodeset_builtin_formats.d.ts.map +1 -0
- package/dist/api/loader/nodeset_builtin_formats.js +20 -25
- package/dist/api/loader/nodeset_builtin_formats.js.map +1 -1
- package/dist/api/loader/nodeset_format.d.ts +1 -0
- package/dist/api/loader/nodeset_format.d.ts.map +1 -0
- package/dist/api/loader/nodeset_format.js +4 -10
- package/dist/api/loader/nodeset_format.js.map +1 -1
- package/dist/api/loader/nodeset_image.d.ts +1 -0
- package/dist/api/loader/nodeset_image.d.ts.map +1 -0
- package/dist/api/loader/nodeset_image.js +38 -54
- package/dist/api/loader/nodeset_image.js.map +1 -1
- package/dist/api/loader/nodeset_image_codec.d.ts +1 -0
- package/dist/api/loader/nodeset_image_codec.d.ts.map +1 -0
- package/dist/api/loader/nodeset_image_codec.js +118 -116
- package/dist/api/loader/nodeset_image_codec.js.map +1 -1
- package/dist/api/loader/nodeset_image_store.d.ts +1 -0
- package/dist/api/loader/nodeset_image_store.d.ts.map +1 -0
- package/dist/api/loader/nodeset_image_store.js +5 -11
- package/dist/api/loader/nodeset_image_store.js.map +1 -1
- package/dist/api/loader/nodeset_record.d.ts +1 -0
- package/dist/api/loader/nodeset_record.d.ts.map +1 -0
- package/dist/api/loader/nodeset_record.js +3 -7
- package/dist/api/loader/nodeset_record.js.map +1 -1
- package/dist/api/loader/nodeset_record_applier.d.ts +1 -0
- package/dist/api/loader/nodeset_record_applier.d.ts.map +1 -0
- package/dist/api/loader/nodeset_record_applier.js +89 -97
- package/dist/api/loader/nodeset_record_applier.js.map +1 -1
- package/dist/api/loader/nodeset_records_to_xml.d.ts +1 -0
- package/dist/api/loader/nodeset_records_to_xml.d.ts.map +1 -0
- package/dist/api/loader/nodeset_records_to_xml.js +82 -88
- package/dist/api/loader/nodeset_records_to_xml.js.map +1 -1
- package/dist/api/loader/nodeset_source.d.ts +1 -0
- package/dist/api/loader/nodeset_source.d.ts.map +1 -0
- package/dist/api/loader/nodeset_source.js +14 -21
- package/dist/api/loader/nodeset_source.js.map +1 -1
- package/dist/api/loader/nodeset_source_helpers.d.ts +1 -0
- package/dist/api/loader/nodeset_source_helpers.d.ts.map +1 -0
- package/dist/api/loader/nodeset_source_helpers.js +2 -6
- package/dist/api/loader/nodeset_source_helpers.js.map +1 -1
- package/dist/api/loader/nodeset_to_image.d.ts +1 -0
- package/dist/api/loader/nodeset_to_image.d.ts.map +1 -0
- package/dist/api/loader/nodeset_to_image.js +12 -15
- package/dist/api/loader/nodeset_to_image.js.map +1 -1
- package/dist/api/loader/nodeset_xml_header.d.ts +1 -0
- package/dist/api/loader/nodeset_xml_header.d.ts.map +1 -0
- package/dist/api/loader/nodeset_xml_header.js +9 -14
- package/dist/api/loader/nodeset_xml_header.js.map +1 -1
- package/dist/api/loader/nodeset_xml_primitives.d.ts +1 -0
- package/dist/api/loader/nodeset_xml_primitives.d.ts.map +1 -0
- package/dist/api/loader/nodeset_xml_primitives.js +32 -53
- package/dist/api/loader/nodeset_xml_primitives.js.map +1 -1
- package/dist/api/loader/nodeset_xml_producer.d.ts +1 -0
- package/dist/api/loader/nodeset_xml_producer.d.ts.map +1 -0
- package/dist/api/loader/nodeset_xml_producer.js +49 -51
- package/dist/api/loader/nodeset_xml_producer.js.map +1 -1
- package/dist/api/loader/parsers/extension_object_parser.d.ts +1 -0
- package/dist/api/loader/parsers/extension_object_parser.d.ts.map +1 -0
- package/dist/api/loader/parsers/extension_object_parser.js +49 -57
- package/dist/api/loader/parsers/extension_object_parser.js.map +1 -1
- package/dist/api/loader/parsers/localized_text_parser.d.ts +1 -0
- package/dist/api/loader/parsers/localized_text_parser.d.ts.map +1 -0
- package/dist/api/loader/parsers/localized_text_parser.js +3 -6
- package/dist/api/loader/parsers/localized_text_parser.js.map +1 -1
- package/dist/api/loader/parsers/nodeid_parser.d.ts +1 -0
- package/dist/api/loader/parsers/nodeid_parser.d.ts.map +1 -0
- package/dist/api/loader/parsers/nodeid_parser.js +3 -7
- package/dist/api/loader/parsers/nodeid_parser.js.map +1 -1
- package/dist/api/loader/parsers/qualified_name_parser.d.ts +1 -0
- package/dist/api/loader/parsers/qualified_name_parser.d.ts.map +1 -0
- package/dist/api/loader/parsers/qualified_name_parser.js +5 -9
- package/dist/api/loader/parsers/qualified_name_parser.js.map +1 -1
- package/dist/api/loader/parsers/variant_parser.d.ts +1 -0
- package/dist/api/loader/parsers/variant_parser.d.ts.map +1 -0
- package/dist/api/loader/parsers/variant_parser.js +59 -63
- package/dist/api/loader/parsers/variant_parser.js.map +1 -1
- package/dist/api/loader/register_node_promoter.d.ts +10 -1
- package/dist/api/loader/register_node_promoter.d.ts.map +1 -0
- package/dist/api/loader/register_node_promoter.js +11 -7
- package/dist/api/loader/register_node_promoter.js.map +1 -1
- package/dist/api/namespace.d.ts +1 -0
- package/dist/api/namespace.d.ts.map +1 -0
- package/dist/api/namespace.js +1 -2
- package/dist/api/namespace_alarm_and_condition.d.ts +1 -0
- package/dist/api/namespace_alarm_and_condition.d.ts.map +1 -0
- package/dist/api/namespace_alarm_and_condition.js +1 -2
- package/dist/api/namespace_data_access.d.ts +1 -0
- package/dist/api/namespace_data_access.d.ts.map +1 -0
- package/dist/api/namespace_data_access.js +1 -2
- package/dist/api/namespace_machine_state.d.ts +1 -0
- package/dist/api/namespace_machine_state.d.ts.map +1 -0
- package/dist/api/namespace_machine_state.js +1 -2
- package/dist/api/namespace_of.d.ts +1 -0
- package/dist/api/namespace_of.d.ts.map +1 -0
- package/dist/api/namespace_of.js +1 -4
- package/dist/api/namespace_of.js.map +1 -1
- package/dist/api/pseudo_session.d.ts +1 -0
- package/dist/api/pseudo_session.d.ts.map +1 -0
- package/dist/api/pseudo_session.js +56 -62
- package/dist/api/pseudo_session.js.map +1 -1
- package/dist/api/session_context.d.ts +1 -0
- package/dist/api/session_context.d.ts.map +1 -0
- package/dist/api/session_context.js +60 -68
- package/dist/api/session_context.js.map +1 -1
- package/dist/api/set_namespace_meta_data.d.ts +1 -0
- package/dist/api/set_namespace_meta_data.d.ts.map +1 -0
- package/dist/api/set_namespace_meta_data.js +10 -13
- package/dist/api/set_namespace_meta_data.js.map +1 -1
- package/dist/api/ua_addin.d.ts +1 -0
- package/dist/api/ua_addin.d.ts.map +1 -0
- package/dist/api/ua_addin.js +9 -13
- package/dist/api/ua_addin.js.map +1 -1
- package/dist/api/ua_interface.d.ts +1 -0
- package/dist/api/ua_interface.d.ts.map +1 -0
- package/dist/api/ua_interface.js +5 -8
- package/dist/api/ua_interface.js.map +1 -1
- package/dist/api/ua_root_folder.d.ts +1 -0
- package/dist/api/ua_root_folder.d.ts.map +1 -0
- package/dist/api/ua_root_folder.js +1 -2
- package/dist/api/ua_two_state_variable_ex.d.ts +1 -0
- package/dist/api/ua_two_state_variable_ex.d.ts.map +1 -0
- package/dist/api/ua_two_state_variable_ex.js +1 -2
- package/dist/api/xml_writer.d.ts +1 -0
- package/dist/api/xml_writer.d.ts.map +1 -0
- package/dist/api/xml_writer.js +1 -2
- package/dist/impl/_instantiate_helpers.d.ts +1 -0
- package/dist/impl/_instantiate_helpers.d.ts.map +1 -0
- package/dist/impl/_instantiate_helpers.js +25 -31
- package/dist/impl/_instantiate_helpers.js.map +1 -1
- package/dist/impl/_mandatory_child_or_requested_optional_filter.d.ts +1 -0
- package/dist/impl/_mandatory_child_or_requested_optional_filter.d.ts.map +1 -0
- package/dist/impl/_mandatory_child_or_requested_optional_filter.js +16 -20
- package/dist/impl/_mandatory_child_or_requested_optional_filter.js.map +1 -1
- package/dist/impl/address_space.d.ts +40 -0
- package/dist/impl/address_space.d.ts.map +1 -0
- package/dist/impl/address_space.js +246 -189
- package/dist/impl/address_space.js.map +1 -1
- package/dist/impl/address_space_change_event_tools.d.ts +1 -0
- package/dist/impl/address_space_change_event_tools.d.ts.map +1 -0
- package/dist/impl/address_space_change_event_tools.js +31 -29
- package/dist/impl/address_space_change_event_tools.js.map +1 -1
- package/dist/impl/address_space_private.d.ts +2 -0
- package/dist/impl/address_space_private.d.ts.map +1 -0
- package/dist/impl/address_space_private.js +1 -2
- package/dist/impl/address_space_private.js.map +1 -1
- package/dist/impl/alarms_and_conditions/condition.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/condition.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/condition.js +1 -2
- package/dist/impl/alarms_and_conditions/condition.js.map +1 -1
- package/dist/impl/alarms_and_conditions/condition_info_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/condition_info_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/condition_info_impl.js +3 -7
- package/dist/impl/alarms_and_conditions/condition_info_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/condition_snapshot_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/condition_snapshot_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/condition_snapshot_impl.js +77 -81
- package/dist/impl/alarms_and_conditions/condition_snapshot_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/deviation_alarm_helper.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/deviation_alarm_helper.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/deviation_alarm_helper.js +17 -20
- package/dist/impl/alarms_and_conditions/deviation_alarm_helper.js.map +1 -1
- package/dist/impl/alarms_and_conditions/index.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/index.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/index.js +13 -29
- package/dist/impl/alarms_and_conditions/index.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_acknowledgeable_condition_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_acknowledgeable_condition_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_acknowledgeable_condition_impl.js +60 -65
- package/dist/impl/alarms_and_conditions/ua_acknowledgeable_condition_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_alarm_condition_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_alarm_condition_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_alarm_condition_impl.js +53 -59
- package/dist/impl/alarms_and_conditions/ua_alarm_condition_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_base_event_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_base_event_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_base_event_impl.js +12 -16
- package/dist/impl/alarms_and_conditions/ua_base_event_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_certificate_expiration_alarm_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_certificate_expiration_alarm_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_certificate_expiration_alarm_impl.js +34 -39
- package/dist/impl/alarms_and_conditions/ua_certificate_expiration_alarm_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_condition_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_condition_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_condition_impl.js +140 -148
- package/dist/impl/alarms_and_conditions/ua_condition_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_discrete_alarm_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_discrete_alarm_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_discrete_alarm_impl.js +6 -10
- package/dist/impl/alarms_and_conditions/ua_discrete_alarm_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_exclusive_deviation_alarm_impl.d.ts +9 -0
- package/dist/impl/alarms_and_conditions/ua_exclusive_deviation_alarm_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_exclusive_deviation_alarm_impl.js +28 -22
- package/dist/impl/alarms_and_conditions/ua_exclusive_deviation_alarm_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_exclusive_level_alarm_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_exclusive_level_alarm_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_exclusive_level_alarm_impl.js +3 -7
- package/dist/impl/alarms_and_conditions/ua_exclusive_level_alarm_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_exclusive_limit_alarm_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_exclusive_limit_alarm_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_exclusive_limit_alarm_impl.js +14 -18
- package/dist/impl/alarms_and_conditions/ua_exclusive_limit_alarm_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_exclusive_rate_of_change_alarm_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_exclusive_rate_of_change_alarm_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_exclusive_rate_of_change_alarm_impl.js +2 -6
- package/dist/impl/alarms_and_conditions/ua_exclusive_rate_of_change_alarm_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_limit_alarm_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_limit_alarm_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_limit_alarm_impl.js +35 -39
- package/dist/impl/alarms_and_conditions/ua_limit_alarm_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_non_exclusive_deviation_alarm_impl.d.ts +9 -0
- package/dist/impl/alarms_and_conditions/ua_non_exclusive_deviation_alarm_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_non_exclusive_deviation_alarm_impl.js +27 -21
- package/dist/impl/alarms_and_conditions/ua_non_exclusive_deviation_alarm_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_non_exclusive_limit_alarm_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_non_exclusive_limit_alarm_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_non_exclusive_limit_alarm_impl.js +27 -31
- package/dist/impl/alarms_and_conditions/ua_non_exclusive_limit_alarm_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_off_normal_alarm_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_off_normal_alarm_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_off_normal_alarm_impl.js +18 -22
- package/dist/impl/alarms_and_conditions/ua_off_normal_alarm_impl.js.map +1 -1
- package/dist/impl/alarms_and_conditions/ua_system_off_normal_alarm_impl.d.ts +1 -0
- package/dist/impl/alarms_and_conditions/ua_system_off_normal_alarm_impl.d.ts.map +1 -0
- package/dist/impl/alarms_and_conditions/ua_system_off_normal_alarm_impl.js +3 -7
- package/dist/impl/alarms_and_conditions/ua_system_off_normal_alarm_impl.js.map +1 -1
- package/dist/impl/apply_condition_refresh.d.ts +1 -0
- package/dist/impl/apply_condition_refresh.d.ts.map +1 -0
- package/dist/impl/apply_condition_refresh.js +1 -4
- package/dist/impl/apply_condition_refresh.js.map +1 -1
- package/dist/impl/base_node_impl.d.ts +1 -0
- package/dist/impl/base_node_impl.d.ts.map +1 -0
- package/dist/impl/base_node_impl.js +279 -292
- package/dist/impl/base_node_impl.js.map +1 -1
- package/dist/impl/base_node_private.d.ts +1 -0
- package/dist/impl/base_node_private.d.ts.map +1 -0
- package/dist/impl/base_node_private.js +168 -199
- package/dist/impl/base_node_private.js.map +1 -1
- package/dist/impl/bulk_load_clock.d.ts +35 -0
- package/dist/impl/bulk_load_clock.d.ts.map +1 -0
- package/dist/impl/bulk_load_clock.js +58 -0
- package/dist/impl/bulk_load_clock.js.map +1 -0
- package/dist/impl/check_value_rank_compatibility.d.ts +1 -0
- package/dist/impl/check_value_rank_compatibility.d.ts.map +1 -0
- package/dist/impl/check_value_rank_compatibility.js +1 -4
- package/dist/impl/check_value_rank_compatibility.js.map +1 -1
- package/dist/impl/child_accessors.d.ts +1 -0
- package/dist/impl/child_accessors.d.ts.map +1 -0
- package/dist/impl/child_accessors.js +10 -20
- package/dist/impl/child_accessors.js.map +1 -1
- package/dist/impl/data_access/add_dataItem_stuff.d.ts +1 -0
- package/dist/impl/data_access/add_dataItem_stuff.d.ts.map +1 -0
- package/dist/impl/data_access/add_dataItem_stuff.js +6 -9
- package/dist/impl/data_access/add_dataItem_stuff.js.map +1 -1
- package/dist/impl/data_access/adjust_datavalue_status_code.d.ts +1 -0
- package/dist/impl/data_access/adjust_datavalue_status_code.d.ts.map +1 -0
- package/dist/impl/data_access/adjust_datavalue_status_code.js +9 -12
- package/dist/impl/data_access/adjust_datavalue_status_code.js.map +1 -1
- package/dist/impl/data_access/semantics_changed.d.ts +12 -0
- package/dist/impl/data_access/semantics_changed.d.ts.map +1 -0
- package/dist/impl/data_access/semantics_changed.js +44 -10
- package/dist/impl/data_access/semantics_changed.js.map +1 -1
- package/dist/impl/data_access/ua_multistate_discrete_impl.d.ts +2 -1
- package/dist/impl/data_access/ua_multistate_discrete_impl.d.ts.map +1 -0
- package/dist/impl/data_access/ua_multistate_discrete_impl.js +35 -41
- package/dist/impl/data_access/ua_multistate_discrete_impl.js.map +1 -1
- package/dist/impl/data_access/ua_multistate_value_discrete_impl.d.ts +1 -0
- package/dist/impl/data_access/ua_multistate_value_discrete_impl.d.ts.map +1 -0
- package/dist/impl/data_access/ua_multistate_value_discrete_impl.js +71 -78
- package/dist/impl/data_access/ua_multistate_value_discrete_impl.js.map +1 -1
- package/dist/impl/data_access/ua_two_state_discrete_impl.d.ts +1 -0
- package/dist/impl/data_access/ua_two_state_discrete_impl.d.ts.map +1 -0
- package/dist/impl/data_access/ua_two_state_discrete_impl.js +27 -36
- package/dist/impl/data_access/ua_two_state_discrete_impl.js.map +1 -1
- package/dist/impl/event_data.d.ts +1 -0
- package/dist/impl/event_data.d.ts.map +1 -0
- package/dist/impl/event_data.js +15 -19
- package/dist/impl/event_data.js.map +1 -1
- package/dist/impl/event_layout.d.ts +1 -0
- package/dist/impl/event_layout.d.ts.map +1 -0
- package/dist/impl/event_layout.js +12 -16
- package/dist/impl/event_layout.js.map +1 -1
- package/dist/impl/extension_object_array_node.d.ts +1 -0
- package/dist/impl/extension_object_array_node.d.ts.map +1 -0
- package/dist/impl/extension_object_array_node.js +47 -53
- package/dist/impl/extension_object_array_node.js.map +1 -1
- package/dist/impl/get_basic_datatype.d.ts +1 -0
- package/dist/impl/get_basic_datatype.d.ts.map +1 -0
- package/dist/impl/get_basic_datatype.js +6 -10
- package/dist/impl/get_basic_datatype.js.map +1 -1
- package/dist/impl/handle_hierarchy_parent.d.ts +1 -0
- package/dist/impl/handle_hierarchy_parent.d.ts.map +1 -0
- package/dist/impl/handle_hierarchy_parent.js +26 -30
- package/dist/impl/handle_hierarchy_parent.js.map +1 -1
- package/dist/impl/historical_access/address_space_historical_data_node.d.ts +1 -0
- package/dist/impl/historical_access/address_space_historical_data_node.d.ts.map +1 -0
- package/dist/impl/historical_access/address_space_historical_data_node.js +76 -84
- package/dist/impl/historical_access/address_space_historical_data_node.js.map +1 -1
- package/dist/impl/historical_access/read_processed_details_hook.d.ts +1 -0
- package/dist/impl/historical_access/read_processed_details_hook.d.ts.map +1 -0
- package/dist/impl/historical_access/read_processed_details_hook.js +1 -4
- package/dist/impl/historical_access/read_processed_details_hook.js.map +1 -1
- package/dist/impl/historizer_factory.d.ts +1 -0
- package/dist/impl/historizer_factory.d.ts.map +1 -0
- package/dist/impl/historizer_factory.js +1 -4
- package/dist/impl/historizer_factory.js.map +1 -1
- package/dist/impl/idx_iterator.d.ts +1 -0
- package/dist/impl/idx_iterator.d.ts.map +1 -0
- package/dist/impl/idx_iterator.js +1 -5
- package/dist/impl/idx_iterator.js.map +1 -1
- package/dist/impl/namespace_impl.d.ts +32 -0
- package/dist/impl/namespace_impl.d.ts.map +1 -0
- package/dist/impl/namespace_impl.js +418 -318
- package/dist/impl/namespace_impl.js.map +1 -1
- package/dist/impl/namespace_private.d.ts +3 -0
- package/dist/impl/namespace_private.d.ts.map +1 -0
- package/dist/impl/namespace_private.js +3 -6
- package/dist/impl/namespace_private.js.map +1 -1
- package/dist/impl/nodeid_manager.d.ts +16 -0
- package/dist/impl/nodeid_manager.d.ts.map +1 -0
- package/dist/impl/nodeid_manager.js +70 -46
- package/dist/impl/nodeid_manager.js.map +1 -1
- package/dist/impl/nodeset_tools/adjust_namespace_array.d.ts +1 -0
- package/dist/impl/nodeset_tools/adjust_namespace_array.d.ts.map +1 -0
- package/dist/impl/nodeset_tools/adjust_namespace_array.js +1 -4
- package/dist/impl/nodeset_tools/adjust_namespace_array.js.map +1 -1
- package/dist/impl/nodeset_tools/construct_namespace_dependency.d.ts +1 -0
- package/dist/impl/nodeset_tools/construct_namespace_dependency.d.ts.map +1 -0
- package/dist/impl/nodeset_tools/construct_namespace_dependency.js +28 -39
- package/dist/impl/nodeset_tools/construct_namespace_dependency.js.map +1 -1
- package/dist/impl/nodeset_tools/dump_to_bsd.d.ts +1 -0
- package/dist/impl/nodeset_tools/dump_to_bsd.d.ts.map +1 -0
- package/dist/impl/nodeset_tools/dump_to_bsd.js +14 -20
- package/dist/impl/nodeset_tools/dump_to_bsd.js.map +1 -1
- package/dist/impl/nodeset_tools/nodeset_to_records.d.ts +1 -0
- package/dist/impl/nodeset_tools/nodeset_to_records.d.ts.map +1 -0
- package/dist/impl/nodeset_tools/nodeset_to_records.js +125 -139
- package/dist/impl/nodeset_tools/nodeset_to_records.js.map +1 -1
- package/dist/impl/nodeset_tools/nodeset_to_xml.d.ts +1 -0
- package/dist/impl/nodeset_tools/nodeset_to_xml.d.ts.map +1 -0
- package/dist/impl/nodeset_tools/nodeset_to_xml.js +190 -202
- package/dist/impl/nodeset_tools/nodeset_to_xml.js.map +1 -1
- package/dist/impl/private_namespace.d.ts +1 -0
- package/dist/impl/private_namespace.d.ts.map +1 -0
- package/dist/impl/private_namespace.js +3 -8
- package/dist/impl/private_namespace.js.map +1 -1
- package/dist/impl/reference_impl.d.ts +1 -0
- package/dist/impl/reference_impl.d.ts.map +1 -0
- package/dist/impl/reference_impl.js +24 -37
- package/dist/impl/reference_impl.js.map +1 -1
- package/dist/impl/reference_type_version.d.ts +1 -0
- package/dist/impl/reference_type_version.d.ts.map +1 -0
- package/dist/impl/reference_type_version.js +2 -5
- package/dist/impl/reference_type_version.js.map +1 -1
- package/dist/impl/role_permissions.d.ts +1 -0
- package/dist/impl/role_permissions.d.ts.map +1 -0
- package/dist/impl/role_permissions.js +3 -6
- package/dist/impl/role_permissions.js.map +1 -1
- package/dist/impl/state_machine/finite_state_machine.d.ts +1 -0
- package/dist/impl/state_machine/finite_state_machine.d.ts.map +1 -0
- package/dist/impl/state_machine/finite_state_machine.js +123 -97
- package/dist/impl/state_machine/finite_state_machine.js.map +1 -1
- package/dist/impl/state_machine/ua_shelving_state_machine_ex.d.ts +1 -0
- package/dist/impl/state_machine/ua_shelving_state_machine_ex.d.ts.map +1 -0
- package/dist/impl/state_machine/ua_shelving_state_machine_ex.js +57 -62
- package/dist/impl/state_machine/ua_shelving_state_machine_ex.js.map +1 -1
- package/dist/impl/state_machine/ua_two_state_variable.d.ts +1 -0
- package/dist/impl/state_machine/ua_two_state_variable.d.ts.map +1 -0
- package/dist/impl/state_machine/ua_two_state_variable.js +56 -63
- package/dist/impl/state_machine/ua_two_state_variable.js.map +1 -1
- package/dist/impl/tool_isSubtypeOf.d.ts +1 -0
- package/dist/impl/tool_isSubtypeOf.d.ts.map +1 -0
- package/dist/impl/tool_isSubtypeOf.js +27 -34
- package/dist/impl/tool_isSubtypeOf.js.map +1 -1
- package/dist/impl/ua_condition_type.d.ts +1 -0
- package/dist/impl/ua_condition_type.d.ts.map +1 -0
- package/dist/impl/ua_condition_type.js +1 -2
- package/dist/impl/ua_data_type_impl.d.ts +1 -0
- package/dist/impl/ua_data_type_impl.d.ts.map +1 -0
- package/dist/impl/ua_data_type_impl.js +99 -83
- package/dist/impl/ua_data_type_impl.js.map +1 -1
- package/dist/impl/ua_method_impl.d.ts +3 -2
- package/dist/impl/ua_method_impl.d.ts.map +1 -0
- package/dist/impl/ua_method_impl.js +74 -78
- package/dist/impl/ua_method_impl.js.map +1 -1
- package/dist/impl/ua_object_impl.d.ts +1 -0
- package/dist/impl/ua_object_impl.d.ts.map +1 -0
- package/dist/impl/ua_object_impl.js +48 -51
- package/dist/impl/ua_object_impl.js.map +1 -1
- package/dist/impl/ua_object_type_impl.d.ts +1 -0
- package/dist/impl/ua_object_type_impl.d.ts.map +1 -0
- package/dist/impl/ua_object_type_impl.js +36 -39
- package/dist/impl/ua_object_type_impl.js.map +1 -1
- package/dist/impl/ua_reference_type_impl.d.ts +2 -1
- package/dist/impl/ua_reference_type_impl.d.ts.map +1 -0
- package/dist/impl/ua_reference_type_impl.js +41 -45
- package/dist/impl/ua_reference_type_impl.js.map +1 -1
- package/dist/impl/ua_variable_impl.d.ts +1 -0
- package/dist/impl/ua_variable_impl.d.ts.map +1 -0
- package/dist/impl/ua_variable_impl.js +373 -376
- package/dist/impl/ua_variable_impl.js.map +1 -1
- package/dist/impl/ua_variable_impl_ext_obj.d.ts +1 -0
- package/dist/impl/ua_variable_impl_ext_obj.d.ts.map +1 -0
- package/dist/impl/ua_variable_impl_ext_obj.js +79 -97
- package/dist/impl/ua_variable_impl_ext_obj.js.map +1 -1
- package/dist/impl/ua_variable_type_impl.d.ts +1 -0
- package/dist/impl/ua_variable_type_impl.d.ts.map +1 -0
- package/dist/impl/ua_variable_type_impl.js +78 -84
- package/dist/impl/ua_variable_type_impl.js.map +1 -1
- package/dist/impl/ua_view_impl.d.ts +1 -0
- package/dist/impl/ua_view_impl.d.ts.map +1 -0
- package/dist/impl/ua_view_impl.js +18 -22
- package/dist/impl/ua_view_impl.js.map +1 -1
- package/dist/impl/validate_data_type_correctness.d.ts +1 -0
- package/dist/impl/validate_data_type_correctness.d.ts.map +1 -0
- package/dist/impl/validate_data_type_correctness.js +24 -30
- package/dist/impl/validate_data_type_correctness.js.map +1 -1
- package/dist/tsconfig_base.tsbuildinfo +1 -1
- package/distHelpers/add_event_generator_object.d.ts +1 -0
- package/distHelpers/add_event_generator_object.d.ts.map +1 -0
- package/distHelpers/add_event_generator_object.js +8 -11
- package/distHelpers/add_event_generator_object.js.map +1 -1
- package/distHelpers/address_space_digest.d.ts +1 -0
- package/distHelpers/address_space_digest.d.ts.map +1 -0
- package/distHelpers/address_space_digest.js +1 -5
- package/distHelpers/address_space_digest.js.map +1 -1
- package/distHelpers/alarms_and_conditions_demo.d.ts +1 -0
- package/distHelpers/alarms_and_conditions_demo.d.ts.map +1 -0
- package/distHelpers/alarms_and_conditions_demo.js +8 -11
- package/distHelpers/alarms_and_conditions_demo.js.map +1 -1
- package/distHelpers/assertHasMatchingReference.d.ts +1 -0
- package/distHelpers/assertHasMatchingReference.d.ts.map +1 -0
- package/distHelpers/assertHasMatchingReference.js +6 -9
- package/distHelpers/assertHasMatchingReference.js.map +1 -1
- package/distHelpers/boiler_system.d.ts +1 -0
- package/distHelpers/boiler_system.d.ts.map +1 -0
- package/distHelpers/boiler_system.js +36 -40
- package/distHelpers/boiler_system.js.map +1 -1
- package/distHelpers/create_minimalist_address_space_nodeset.d.ts +1 -0
- package/distHelpers/create_minimalist_address_space_nodeset.d.ts.map +1 -0
- package/distHelpers/create_minimalist_address_space_nodeset.js +29 -35
- package/distHelpers/create_minimalist_address_space_nodeset.js.map +1 -1
- package/distHelpers/date_utils.d.ts +1 -0
- package/distHelpers/date_utils.d.ts.map +1 -0
- package/distHelpers/date_utils.js +1 -4
- package/distHelpers/date_utils.js.map +1 -1
- package/distHelpers/dump_statemachine.d.ts +1 -0
- package/distHelpers/dump_statemachine.d.ts.map +1 -0
- package/distHelpers/dump_statemachine.js +1 -2
- package/distHelpers/dump_statemachine.js.map +1 -1
- package/distHelpers/get_address_space_fixture.d.ts +1 -0
- package/distHelpers/get_address_space_fixture.d.ts.map +1 -0
- package/distHelpers/get_address_space_fixture.js +12 -18
- package/distHelpers/get_address_space_fixture.js.map +1 -1
- package/distHelpers/get_mini_address_space.d.ts +1 -0
- package/distHelpers/get_mini_address_space.d.ts.map +1 -0
- package/distHelpers/get_mini_address_space.js +12 -18
- package/distHelpers/get_mini_address_space.js.map +1 -1
- package/distHelpers/index.d.ts +1 -0
- package/distHelpers/index.d.ts.map +1 -0
- package/distHelpers/index.js +10 -26
- package/distHelpers/index.js.map +1 -1
- package/distHelpers/mock_session.d.ts +1 -0
- package/distHelpers/mock_session.d.ts.map +1 -0
- package/distHelpers/mock_session.js +11 -16
- package/distHelpers/mock_session.js.map +1 -1
- package/distNodeJS/address_space_digest.d.ts +1 -0
- package/distNodeJS/address_space_digest.d.ts.map +1 -0
- package/distNodeJS/address_space_digest.js +3 -6
- package/distNodeJS/address_space_digest.js.map +1 -1
- package/distNodeJS/generate_address_space.d.ts +1 -0
- package/distNodeJS/generate_address_space.d.ts.map +1 -0
- package/distNodeJS/generate_address_space.js +67 -97
- package/distNodeJS/generate_address_space.js.map +1 -1
- package/distNodeJS/index.d.ts +1 -0
- package/distNodeJS/index.d.ts.map +1 -0
- package/distNodeJS/index.js +3 -19
- package/distNodeJS/index.js.map +1 -1
- package/distNodeJS/nodeset_image_file_store.d.ts +1 -0
- package/distNodeJS/nodeset_image_file_store.d.ts.map +1 -0
- package/distNodeJS/nodeset_image_file_store.js +20 -28
- package/distNodeJS/nodeset_image_file_store.js.map +1 -1
- package/impl/_mandatory_child_or_requested_optional_filter.ts +3 -3
- package/impl/address_space.ts +75 -6
- package/impl/address_space_change_event_tools.ts +7 -0
- package/impl/address_space_private.ts +1 -0
- package/impl/alarms_and_conditions/condition_snapshot_impl.ts +1 -1
- package/impl/alarms_and_conditions/deviation_alarm_helper.ts +3 -0
- package/impl/alarms_and_conditions/ua_acknowledgeable_condition_impl.ts +1 -1
- package/impl/alarms_and_conditions/ua_alarm_condition_impl.ts +1 -1
- package/impl/alarms_and_conditions/ua_condition_impl.ts +1 -1
- package/impl/alarms_and_conditions/ua_exclusive_deviation_alarm_impl.ts +12 -1
- package/impl/alarms_and_conditions/ua_non_exclusive_deviation_alarm_impl.ts +12 -1
- package/impl/bulk_load_clock.ts +65 -0
- package/impl/data_access/semantics_changed.ts +39 -1
- package/impl/data_access/ua_multistate_discrete_impl.ts +1 -1
- package/impl/extension_object_array_node.ts +5 -5
- package/impl/historical_access/address_space_historical_data_node.ts +2 -2
- package/impl/namespace_impl.ts +119 -2
- package/impl/namespace_private.ts +3 -0
- package/impl/nodeid_manager.ts +40 -5
- package/impl/nodeset_tools/construct_namespace_dependency.ts +4 -4
- package/impl/nodeset_tools/dump_to_bsd.ts +1 -1
- package/impl/nodeset_tools/nodeset_to_xml.ts +1 -1
- package/impl/state_machine/finite_state_machine.ts +56 -10
- package/impl/state_machine/ua_shelving_state_machine_ex.ts +1 -1
- package/impl/state_machine/ua_two_state_variable.ts +1 -1
- package/impl/tool_isSubtypeOf.ts +1 -1
- package/impl/ua_data_type_impl.ts +26 -5
- package/impl/ua_method_impl.ts +10 -6
- package/impl/ua_object_impl.ts +6 -2
- package/impl/ua_object_type_impl.ts +1 -0
- package/impl/ua_variable_impl.ts +15 -8
- package/impl/ua_variable_type_impl.ts +4 -3
- package/nodeJS.d.ts +1 -1
- package/nodeJS.js +1 -1
- package/package.json +42 -41
- package/source_nodejs/generate_address_space.ts +31 -14
- package/testHelpers.d.ts +1 -1
- package/testHelpers.js +1 -1
- /package/bin/{nodeset_tool_common.js → nodeset_tool_common.cjs} +0 -0
|
@@ -1,47 +1,35 @@
|
|
|
1
|
-
"use strict";
|
|
2
1
|
/**
|
|
3
2
|
* @module node-opcua-address-space
|
|
4
3
|
*/
|
|
5
4
|
// produce nodeset xml files
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
};
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
const
|
|
32
|
-
const
|
|
33
|
-
const
|
|
34
|
-
const ua_object_type_impl_js_1 = require("../ua_object_type_impl.js");
|
|
35
|
-
const ua_variable_impl_js_1 = require("../ua_variable_impl.js");
|
|
36
|
-
const construct_namespace_dependency_js_1 = require("./construct_namespace_dependency.js");
|
|
37
|
-
const nodeset_to_records_js_1 = require("./nodeset_to_records.js");
|
|
38
|
-
var nodeset_xml_primitives_js_2 = require("../../api/loader/nodeset_xml_primitives.js");
|
|
39
|
-
Object.defineProperty(exports, "coerceInt64ToInt32", { enumerable: true, get: function () { return nodeset_xml_primitives_js_2.coerceInt64ToInt32; } });
|
|
40
|
-
Object.defineProperty(exports, "initXmlWriterEx", { enumerable: true, get: function () { return nodeset_xml_primitives_js_2.initXmlWriterEx; } });
|
|
41
|
-
Object.defineProperty(exports, "makeTypeXsd", { enumerable: true, get: function () { return nodeset_xml_primitives_js_2.makeTypeXsd; } });
|
|
42
|
-
const debugLog = (0, node_opcua_debug_1.make_debugLog)("nodeset_to_xml");
|
|
43
|
-
const warningLog = (0, node_opcua_debug_1.make_warningLog)("nodeset_to_xml");
|
|
44
|
-
const errorLog = (0, node_opcua_debug_1.make_errorLog)("nodeset_to_xml");
|
|
5
|
+
import { types } from "node:util";
|
|
6
|
+
import { assert } from "node-opcua-assert";
|
|
7
|
+
import { AttributeIds, isMinDate } from "node-opcua-basic-types";
|
|
8
|
+
import { VariableIds } from "node-opcua-constants";
|
|
9
|
+
import { makeAccessLevelFlag, NodeClass, QualifiedName } from "node-opcua-data-model";
|
|
10
|
+
import { make_debugLog, make_errorLog, make_warningLog } from "node-opcua-debug";
|
|
11
|
+
import { NodeId, NodeIdType } from "node-opcua-nodeid";
|
|
12
|
+
import { StatusCodes } from "node-opcua-status-code";
|
|
13
|
+
import { EnumDefinition, StructureDefinition, StructureType } from "node-opcua-types";
|
|
14
|
+
import { isNullOrUndefined, lowerFirstLetter } from "node-opcua-utils";
|
|
15
|
+
import { DataType, Variant, VariantArrayType } from "node-opcua-variant";
|
|
16
|
+
import XMLWriter from "xml-writer";
|
|
17
|
+
import { makeDefinitionMap } from "../../api/loader/decode_xml_extension_object.js";
|
|
18
|
+
import { _dumpLocalizedText, _dumpNodeId, _dumpQualifiedName, _dumpXmlElement, b, coerceInt64ToInt32, findXsdNamespaceUri, getPrefix, initXmlWriterEx, int64ToDecimalString, makeTypeXsd, n, restoreDefaultNamespace, startElementEx } from "../../api/loader/nodeset_xml_primitives.js";
|
|
19
|
+
import { SessionContext } from "../../api/session_context.js";
|
|
20
|
+
import { BaseNodeImpl, getReferenceType } from "../base_node_impl.js";
|
|
21
|
+
import { NamespaceImpl } from "../namespace_impl.js";
|
|
22
|
+
import { ReferenceImpl } from "../reference_impl.js";
|
|
23
|
+
import { UAMethodImpl } from "../ua_method_impl.js";
|
|
24
|
+
import { UAObjectImpl } from "../ua_object_impl.js";
|
|
25
|
+
import { UAObjectTypeImpl } from "../ua_object_type_impl.js";
|
|
26
|
+
import { UAVariableImpl } from "../ua_variable_impl.js";
|
|
27
|
+
import { _constructNamespaceTranslationTable, constructNamespaceDependency, constructNamespacePriorityTable } from "./construct_namespace_dependency.js";
|
|
28
|
+
import { namespaceToWalkEvents, nodeToWalkEvents, sortByNodeId } from "./nodeset_to_records.js";
|
|
29
|
+
export { coerceInt64ToInt32, initXmlWriterEx, makeTypeXsd } from "../../api/loader/nodeset_xml_primitives.js";
|
|
30
|
+
const debugLog = make_debugLog("nodeset_to_xml");
|
|
31
|
+
const warningLog = make_warningLog("nodeset_to_xml");
|
|
32
|
+
const errorLog = make_errorLog("nodeset_to_xml");
|
|
45
33
|
const doDebug = false;
|
|
46
34
|
function _hash(node) {
|
|
47
35
|
return node.nodeId.toString();
|
|
@@ -66,14 +54,14 @@ function hasHigherPriorityThan(namespaceIndex1, namespaceIndex2, priorityTable)
|
|
|
66
54
|
return order1 > order2;
|
|
67
55
|
}
|
|
68
56
|
function _hasHigherPriorityThan(xw, namespaceIndex1, namespaceIndex2) {
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
57
|
+
assert(xw.priorityTable, "expecting a priorityTable");
|
|
58
|
+
assert(namespaceIndex1 < xw.priorityTable.length);
|
|
59
|
+
assert(namespaceIndex2 < xw.priorityTable.length);
|
|
72
60
|
return hasHigherPriorityThan(namespaceIndex1, namespaceIndex2, xw.priorityTable);
|
|
73
61
|
}
|
|
74
62
|
function _mustFindReferenceType(addressSpace, name) {
|
|
75
63
|
const referenceType = addressSpace.findReferenceType(name);
|
|
76
|
-
|
|
64
|
+
/* c8 ignore next */
|
|
77
65
|
if (!referenceType) {
|
|
78
66
|
throw new Error(`Cannot find standard reference type ${name}: please check your nodeset file`);
|
|
79
67
|
}
|
|
@@ -95,7 +83,7 @@ function _dumpReferences(xw, node) {
|
|
|
95
83
|
const hierarchicalReferencesType = _mustFindReferenceType(addressSpace, "HierarchicalReferences");
|
|
96
84
|
function referenceToKeep(reference) {
|
|
97
85
|
// resolved here: a reference nobody has looked at since the load carries only the NodeId of its type
|
|
98
|
-
const referenceType =
|
|
86
|
+
const referenceType = ReferenceImpl.resolveReferenceType(addressSpace, reference);
|
|
99
87
|
if (!referenceType) {
|
|
100
88
|
return false;
|
|
101
89
|
}
|
|
@@ -160,16 +148,16 @@ function _dumpReferences(xw, node) {
|
|
|
160
148
|
}
|
|
161
149
|
const allReferences = node.allReferences();
|
|
162
150
|
const references = allReferences.filter(referenceToKeep);
|
|
163
|
-
for (const reference of references.sort(
|
|
164
|
-
if (
|
|
151
|
+
for (const reference of references.sort(sortByNodeId)) {
|
|
152
|
+
if (getReferenceType(reference).browseName.toString() === "HasSubtype" && reference.isForward) {
|
|
165
153
|
continue;
|
|
166
154
|
}
|
|
167
155
|
xw.startElement("Reference");
|
|
168
|
-
xw.writeAttribute("ReferenceType",
|
|
156
|
+
xw.writeAttribute("ReferenceType", b(xw, getReferenceType(reference).browseName));
|
|
169
157
|
if (!reference.isForward) {
|
|
170
158
|
xw.writeAttribute("IsForward", reference.isForward ? "true" : "false");
|
|
171
159
|
}
|
|
172
|
-
xw.text(
|
|
160
|
+
xw.text(n(xw, reference.nodeId));
|
|
173
161
|
xw.endElement();
|
|
174
162
|
}
|
|
175
163
|
xw.endElement();
|
|
@@ -195,44 +183,44 @@ function _dumpVariantValue(xw, dataTypeNodeId, dataType, addressSpace, value) {
|
|
|
195
183
|
if (value === undefined || value === null) {
|
|
196
184
|
return;
|
|
197
185
|
}
|
|
198
|
-
if (dataType ===
|
|
186
|
+
if (dataType === DataType.Null) {
|
|
199
187
|
return;
|
|
200
188
|
}
|
|
201
|
-
const uax =
|
|
202
|
-
xw.startElement(`${uax}${
|
|
203
|
-
const definitionMap =
|
|
189
|
+
const uax = getPrefix(xw, "http://opcfoundation.org/UA/2008/02/Types.xsd");
|
|
190
|
+
xw.startElement(`${uax}${DataType[dataType]}`);
|
|
191
|
+
const definitionMap = makeDefinitionMap(addressSpace);
|
|
204
192
|
_dumpVariantInnerValue(xw, dataType, dataTypeNodeId, definitionMap, addressSpace, value);
|
|
205
193
|
xw.endElement();
|
|
206
194
|
}
|
|
207
195
|
function _dumpVariantInnerExtensionObject(xw, definitionMap, definition, addressSpace, value) {
|
|
208
|
-
const namespaceUri =
|
|
209
|
-
const ns =
|
|
210
|
-
const isUnion = definition.structureType ===
|
|
196
|
+
const namespaceUri = findXsdNamespaceUri(xw, definition.defaultEncodingId);
|
|
197
|
+
const ns = getPrefix(xw, namespaceUri);
|
|
198
|
+
const isUnion = definition.structureType === StructureType.Union || definition.structureType === StructureType.UnionWithSubtypedValues;
|
|
211
199
|
for (const field of definition.fields || []) {
|
|
212
200
|
const dataTypeNodeId = field.dataType;
|
|
213
201
|
const fieldName = field.name || "";
|
|
214
|
-
const lowerFieldName =
|
|
202
|
+
const lowerFieldName = lowerFirstLetter(fieldName);
|
|
215
203
|
const v = value[lowerFieldName];
|
|
216
204
|
if (v !== null && v !== undefined) {
|
|
217
205
|
if (dataTypeNodeId.namespace === 0 &&
|
|
218
206
|
dataTypeNodeId.value === 0 &&
|
|
219
|
-
dataTypeNodeId.identifierType ===
|
|
207
|
+
dataTypeNodeId.identifierType === NodeIdType.NUMERIC) {
|
|
220
208
|
// to do ?? shall we do a extension Object here ?
|
|
221
209
|
continue; // ns=0;i=0 is reserved
|
|
222
210
|
}
|
|
223
211
|
const { name, definition } = definitionMap.findDefinition(dataTypeNodeId);
|
|
224
|
-
|
|
212
|
+
startElementEx(xw, ns, fieldName, namespaceUri);
|
|
225
213
|
// xw.startElement(fieldName);
|
|
226
214
|
let fun = (_value) => {
|
|
227
215
|
/** */
|
|
228
216
|
};
|
|
229
|
-
if (definition instanceof
|
|
217
|
+
if (definition instanceof StructureDefinition) {
|
|
230
218
|
fun = _dumpVariantInnerExtensionObject.bind(null, xw, definitionMap, definition, addressSpace);
|
|
231
219
|
}
|
|
232
|
-
else if (definition instanceof
|
|
220
|
+
else if (definition instanceof EnumDefinition) {
|
|
233
221
|
fun = _dumpVariantInnerValueEnum.bind(null, xw, definition);
|
|
234
222
|
}
|
|
235
|
-
else if (definition?.dataType ===
|
|
223
|
+
else if (definition?.dataType === DataType.Variant) {
|
|
236
224
|
fun = (value) => {
|
|
237
225
|
const variantValue = value;
|
|
238
226
|
xw.startElement("Value");
|
|
@@ -258,7 +246,7 @@ function _dumpVariantInnerExtensionObject(xw, definitionMap, definition, address
|
|
|
258
246
|
}
|
|
259
247
|
}
|
|
260
248
|
catch (err) {
|
|
261
|
-
if (
|
|
249
|
+
if (types.isNativeError(err)) {
|
|
262
250
|
errorLog("Error in _dumpVariantExtensionObjectValue_Body !!!", err.message);
|
|
263
251
|
}
|
|
264
252
|
// c8 ignore next
|
|
@@ -268,14 +256,14 @@ function _dumpVariantInnerExtensionObject(xw, definitionMap, definition, address
|
|
|
268
256
|
}
|
|
269
257
|
// throw err;
|
|
270
258
|
}
|
|
271
|
-
|
|
259
|
+
restoreDefaultNamespace(xw);
|
|
272
260
|
xw.endElement();
|
|
273
261
|
}
|
|
274
262
|
else {
|
|
275
263
|
if (!isUnion && !field.isOptional) {
|
|
276
264
|
// field is mandatory but is null=> provide an empty array
|
|
277
|
-
|
|
278
|
-
|
|
265
|
+
startElementEx(xw, ns, fieldName, namespaceUri);
|
|
266
|
+
restoreDefaultNamespace(xw);
|
|
279
267
|
xw.endElement();
|
|
280
268
|
}
|
|
281
269
|
}
|
|
@@ -289,47 +277,47 @@ function _dumpVariantInnerValueEnum(xw, definition, value) {
|
|
|
289
277
|
xw.text(`${field?.name}_${field?.value[1]}`);
|
|
290
278
|
}
|
|
291
279
|
function _dumpVariantInnerValue(xw, dataType, dataTypeNodeId, definitionMap, addressSpace, value) {
|
|
292
|
-
const uax =
|
|
280
|
+
const uax = getPrefix(xw, "http://opcfoundation.org/UA/2008/02/Types.xsd");
|
|
293
281
|
switch (dataType) {
|
|
294
282
|
case null:
|
|
295
|
-
case
|
|
283
|
+
case DataType.Null:
|
|
296
284
|
break;
|
|
297
|
-
case
|
|
298
|
-
|
|
285
|
+
case DataType.LocalizedText:
|
|
286
|
+
_dumpLocalizedText(xw, value);
|
|
299
287
|
break;
|
|
300
|
-
case
|
|
301
|
-
|
|
288
|
+
case DataType.QualifiedName:
|
|
289
|
+
_dumpQualifiedName(xw, value);
|
|
302
290
|
break;
|
|
303
|
-
case
|
|
304
|
-
|
|
291
|
+
case DataType.NodeId:
|
|
292
|
+
_dumpNodeId(xw, value);
|
|
305
293
|
break;
|
|
306
|
-
case
|
|
294
|
+
case DataType.DateTime:
|
|
307
295
|
xw.text(value.toISOString());
|
|
308
296
|
break;
|
|
309
|
-
case
|
|
310
|
-
case
|
|
311
|
-
xw.text(
|
|
297
|
+
case DataType.Int64:
|
|
298
|
+
case DataType.UInt64:
|
|
299
|
+
xw.text(int64ToDecimalString(value, dataType === DataType.Int64));
|
|
312
300
|
break;
|
|
313
|
-
case
|
|
314
|
-
case
|
|
315
|
-
case
|
|
316
|
-
case
|
|
317
|
-
case
|
|
318
|
-
case
|
|
319
|
-
case
|
|
320
|
-
case
|
|
321
|
-
case
|
|
322
|
-
case
|
|
301
|
+
case DataType.Boolean:
|
|
302
|
+
case DataType.SByte:
|
|
303
|
+
case DataType.Byte:
|
|
304
|
+
case DataType.Float:
|
|
305
|
+
case DataType.Double:
|
|
306
|
+
case DataType.Int16:
|
|
307
|
+
case DataType.Int32:
|
|
308
|
+
case DataType.UInt16:
|
|
309
|
+
case DataType.UInt32:
|
|
310
|
+
case DataType.String:
|
|
323
311
|
xw.text(value.toString());
|
|
324
312
|
break;
|
|
325
|
-
case
|
|
313
|
+
case DataType.ByteString:
|
|
326
314
|
{
|
|
327
315
|
const base64 = value.toString("base64");
|
|
328
316
|
const chunks = base64.match(/.{0,80}/g);
|
|
329
317
|
xw.text(base64.length > 80 && chunks ? chunks.join("\n") : base64);
|
|
330
318
|
}
|
|
331
319
|
break;
|
|
332
|
-
case
|
|
320
|
+
case DataType.Guid:
|
|
333
321
|
/*
|
|
334
322
|
<uax:Guid>
|
|
335
323
|
<uax:String>947c29a7-490d-4dc9-adda-1109e3e8fcb7</uax:String>
|
|
@@ -342,22 +330,22 @@ function _dumpVariantInnerValue(xw, dataType, dataTypeNodeId, definitionMap, add
|
|
|
342
330
|
xw.endElement();
|
|
343
331
|
}
|
|
344
332
|
break;
|
|
345
|
-
case
|
|
333
|
+
case DataType.ExtensionObject:
|
|
346
334
|
_dumpVariantExtensionObjectValue(xw, dataTypeNodeId, definitionMap, addressSpace, value);
|
|
347
335
|
break;
|
|
348
|
-
case
|
|
349
|
-
|
|
336
|
+
case DataType.XmlElement:
|
|
337
|
+
_dumpXmlElement(xw, value);
|
|
350
338
|
break;
|
|
351
|
-
case
|
|
339
|
+
case DataType.StatusCode:
|
|
352
340
|
xw.text(value.value.toString());
|
|
353
341
|
break;
|
|
354
|
-
case
|
|
342
|
+
case DataType.Variant: {
|
|
355
343
|
const variantValue = value;
|
|
356
344
|
_dumpVariantInnerValue(xw, variantValue.dataType, dataTypeNodeId, definitionMap, addressSpace, variantValue.value);
|
|
357
345
|
break;
|
|
358
346
|
}
|
|
359
347
|
default:
|
|
360
|
-
errorLog(`_dumpVariantInnerValue incomplete ${value} DataType=${dataType}=${
|
|
348
|
+
errorLog(`_dumpVariantInnerValue incomplete ${value} DataType=${dataType}=${DataType[dataType]}`);
|
|
361
349
|
// throw new Error("_dumpVariantInnerValue incomplete " + value + " " + "DataType=" + dataType + "=" + DataType[dataType]);
|
|
362
350
|
}
|
|
363
351
|
}
|
|
@@ -368,15 +356,15 @@ function _dumpVariantInnerValue(xw, dataType, dataTypeNodeId, definitionMap, add
|
|
|
368
356
|
* @param value
|
|
369
357
|
* @private
|
|
370
358
|
*/
|
|
371
|
-
function _dumpVariantExtensionObjectValue_Body(xw, definitionMap, name, definition, addressSpace, value) {
|
|
359
|
+
export function _dumpVariantExtensionObjectValue_Body(xw, definitionMap, name, definition, addressSpace, value) {
|
|
372
360
|
if (value) {
|
|
373
|
-
const namespaceUri =
|
|
374
|
-
const ns =
|
|
375
|
-
|
|
361
|
+
const namespaceUri = findXsdNamespaceUri(xw, definition.defaultEncodingId);
|
|
362
|
+
const ns = getPrefix(xw, namespaceUri);
|
|
363
|
+
startElementEx(xw, ns, `${name}`, namespaceUri);
|
|
376
364
|
if (value) {
|
|
377
365
|
_dumpVariantInnerExtensionObject(xw, definitionMap, definition, addressSpace, value);
|
|
378
366
|
}
|
|
379
|
-
|
|
367
|
+
restoreDefaultNamespace(xw);
|
|
380
368
|
xw.endElement();
|
|
381
369
|
}
|
|
382
370
|
}
|
|
@@ -389,28 +377,28 @@ function _dumpVariantExtensionObjectValue(xw, dataTypeNodeId, definitionMap, add
|
|
|
389
377
|
// throw new Error("Extension Object doesn't provide a XML ");
|
|
390
378
|
return;
|
|
391
379
|
}
|
|
392
|
-
const uax =
|
|
393
|
-
|
|
380
|
+
const uax = getPrefix(xw, "http://opcfoundation.org/UA/2008/02/Types.xsd");
|
|
381
|
+
startElementEx(xw, uax, `ExtensionObject`, "http://opcfoundation.org/UA/2008/02/Types.xsd");
|
|
394
382
|
{
|
|
395
|
-
const uax =
|
|
383
|
+
const uax = getPrefix(xw, "http://opcfoundation.org/UA/2008/02/Types.xsd");
|
|
396
384
|
xw.startElement(`${uax}TypeId`);
|
|
397
385
|
// find HasEncoding node
|
|
398
386
|
// xx var encodingDefaultXml = schema.encodingDefaultXml;
|
|
399
387
|
xw.startElement(`${uax}Identifier`);
|
|
400
|
-
xw.text(
|
|
388
|
+
xw.text(n(xw, encodingDefaultXml));
|
|
401
389
|
xw.endElement();
|
|
402
390
|
xw.endElement();
|
|
403
|
-
|
|
391
|
+
startElementEx(xw, uax, "Body", "http://opcfoundation.org/UA/2008/02/Types.xsd");
|
|
404
392
|
_dumpVariantExtensionObjectValue_Body(xw, definitionMap, name, definition, addressSpace, value);
|
|
405
|
-
|
|
393
|
+
restoreDefaultNamespace(xw);
|
|
406
394
|
xw.endElement();
|
|
407
395
|
}
|
|
408
|
-
|
|
396
|
+
restoreDefaultNamespace(xw);
|
|
409
397
|
xw.endElement();
|
|
410
398
|
}
|
|
411
399
|
function _dumpVariantExtensionObjectValue2(xw, addressSpace, value) {
|
|
412
400
|
const dataTypeNodeId = value.schema.dataTypeNodeId;
|
|
413
|
-
const definitionMap =
|
|
401
|
+
const definitionMap = makeDefinitionMap(addressSpace);
|
|
414
402
|
const dataTypeNode = addressSpace.findDataType(dataTypeNodeId);
|
|
415
403
|
if (!dataTypeNode) {
|
|
416
404
|
warningLog("_dumpVariantExtensionObjectValue2: Cannot find dataType for ", dataTypeNodeId.toString());
|
|
@@ -418,51 +406,51 @@ function _dumpVariantExtensionObjectValue2(xw, addressSpace, value) {
|
|
|
418
406
|
}
|
|
419
407
|
_dumpVariantExtensionObjectValue(xw, dataTypeNode.nodeId, definitionMap, addressSpace, value);
|
|
420
408
|
}
|
|
421
|
-
function _isDefaultValue(value) {
|
|
409
|
+
export function _isDefaultValue(value) {
|
|
422
410
|
// detect default value
|
|
423
|
-
if (value.arrayType ===
|
|
411
|
+
if (value.arrayType === VariantArrayType.Scalar) {
|
|
424
412
|
switch (value.dataType) {
|
|
425
|
-
case
|
|
413
|
+
case DataType.ExtensionObject:
|
|
426
414
|
if (!value.value) {
|
|
427
415
|
return true;
|
|
428
416
|
}
|
|
429
417
|
break;
|
|
430
|
-
case
|
|
431
|
-
if (!value.value ||
|
|
418
|
+
case DataType.DateTime:
|
|
419
|
+
if (!value.value || isMinDate(value.value)) {
|
|
432
420
|
return true;
|
|
433
421
|
}
|
|
434
422
|
break;
|
|
435
|
-
case
|
|
423
|
+
case DataType.ByteString:
|
|
436
424
|
if (!value.value || value.value.length === 0) {
|
|
437
425
|
return true;
|
|
438
426
|
}
|
|
439
427
|
break;
|
|
440
|
-
case
|
|
428
|
+
case DataType.Boolean:
|
|
441
429
|
return false; // we want it all the time !
|
|
442
|
-
case
|
|
443
|
-
case
|
|
444
|
-
case
|
|
445
|
-
case
|
|
446
|
-
case
|
|
447
|
-
case
|
|
448
|
-
case
|
|
449
|
-
case
|
|
430
|
+
case DataType.SByte:
|
|
431
|
+
case DataType.Byte:
|
|
432
|
+
case DataType.UInt16:
|
|
433
|
+
case DataType.UInt32:
|
|
434
|
+
case DataType.Int16:
|
|
435
|
+
case DataType.Int32:
|
|
436
|
+
case DataType.Double:
|
|
437
|
+
case DataType.Float:
|
|
450
438
|
if (value.value === 0 || value.value === null) {
|
|
451
439
|
return true;
|
|
452
440
|
}
|
|
453
441
|
break;
|
|
454
|
-
case
|
|
442
|
+
case DataType.String:
|
|
455
443
|
if (value.value === null || value.value === "") {
|
|
456
444
|
return true;
|
|
457
445
|
}
|
|
458
446
|
break;
|
|
459
|
-
case
|
|
460
|
-
case
|
|
461
|
-
if (0 ===
|
|
447
|
+
case DataType.Int64:
|
|
448
|
+
case DataType.UInt64:
|
|
449
|
+
if (0 === coerceInt64ToInt32(value.value)) {
|
|
462
450
|
return true;
|
|
463
451
|
}
|
|
464
452
|
break;
|
|
465
|
-
case
|
|
453
|
+
case DataType.LocalizedText:
|
|
466
454
|
if (!value.value) {
|
|
467
455
|
return true;
|
|
468
456
|
}
|
|
@@ -489,7 +477,7 @@ function _dumpValue(xw, node, variant) {
|
|
|
489
477
|
if (variant === null || variant === undefined) {
|
|
490
478
|
return;
|
|
491
479
|
}
|
|
492
|
-
|
|
480
|
+
assert(variant instanceof Variant);
|
|
493
481
|
const dataTypeNode = addressSpace.findDataType(node.dataType);
|
|
494
482
|
// c8 ignore next
|
|
495
483
|
if (!dataTypeNode) {
|
|
@@ -497,13 +485,13 @@ function _dumpValue(xw, node, variant) {
|
|
|
497
485
|
doDebug && debugLog("Cannot find dataType:", node.dataType.toString());
|
|
498
486
|
return;
|
|
499
487
|
}
|
|
500
|
-
const baseDataTypeName =
|
|
488
|
+
const baseDataTypeName = DataType[variant.dataType];
|
|
501
489
|
if (baseDataTypeName === "Null") {
|
|
502
490
|
return;
|
|
503
491
|
}
|
|
504
|
-
|
|
492
|
+
assert(typeof baseDataTypeName === "string");
|
|
505
493
|
// determine if dataTypeName is a ExtensionObject
|
|
506
|
-
const isExtensionObject = variant.dataType ===
|
|
494
|
+
const isExtensionObject = variant.dataType === DataType.ExtensionObject;
|
|
507
495
|
// nothing to serialize: a scalar with no value, or an array that is null rather than empty.
|
|
508
496
|
// This is the one thing _isDefaultValue used to catch here that still needs catching -- it is
|
|
509
497
|
// a test for the absence of a value, not for a value that happens to equal a type's default
|
|
@@ -511,18 +499,18 @@ function _dumpValue(xw, node, variant) {
|
|
|
511
499
|
return;
|
|
512
500
|
}
|
|
513
501
|
xw.startElement("Value");
|
|
514
|
-
const uax =
|
|
502
|
+
const uax = getPrefix(xw, "http://opcfoundation.org/UA/2008/02/Types.xsd");
|
|
515
503
|
if (isExtensionObject) {
|
|
516
504
|
const encodeXml = _dumpVariantExtensionObjectValue2.bind(null, xw, node.addressSpace);
|
|
517
505
|
switch (variant.arrayType) {
|
|
518
|
-
case
|
|
519
|
-
case
|
|
520
|
-
|
|
506
|
+
case VariantArrayType.Matrix:
|
|
507
|
+
case VariantArrayType.Array:
|
|
508
|
+
startElementEx(xw, uax, `ListOf${baseDataTypeName}`, "http://opcfoundation.org/UA/2008/02/Types.xsd");
|
|
521
509
|
variant.value.forEach(encodeXml);
|
|
522
|
-
|
|
510
|
+
restoreDefaultNamespace(xw);
|
|
523
511
|
xw.endElement();
|
|
524
512
|
break;
|
|
525
|
-
case
|
|
513
|
+
case VariantArrayType.Scalar:
|
|
526
514
|
encodeXml(variant.value);
|
|
527
515
|
break;
|
|
528
516
|
default:
|
|
@@ -533,18 +521,18 @@ function _dumpValue(xw, node, variant) {
|
|
|
533
521
|
else {
|
|
534
522
|
const encodeXml = _dumpVariantValue.bind(null, xw, node.dataType, variant.dataType, node.addressSpace);
|
|
535
523
|
switch (variant.arrayType) {
|
|
536
|
-
case
|
|
537
|
-
case
|
|
524
|
+
case VariantArrayType.Matrix:
|
|
525
|
+
case VariantArrayType.Array:
|
|
538
526
|
// the built-in type, not the DataType's browse name: the uax schema defines
|
|
539
527
|
// ListOfInt32 and ListOfString, and nothing named after a nodeset's own DataType.
|
|
540
528
|
// A `ListOfIdType` is not an element any reader knows, so the reader that meets it
|
|
541
529
|
// walks straight past into the first child and takes the array for a scalar
|
|
542
|
-
|
|
530
|
+
startElementEx(xw, uax, `ListOf${baseDataTypeName}`, "http://opcfoundation.org/UA/2008/02/Types.xsd");
|
|
543
531
|
variant.value.forEach(encodeXml);
|
|
544
|
-
|
|
532
|
+
restoreDefaultNamespace(xw);
|
|
545
533
|
xw.endElement();
|
|
546
534
|
break;
|
|
547
|
-
case
|
|
535
|
+
case VariantArrayType.Scalar:
|
|
548
536
|
encodeXml(variant.value);
|
|
549
537
|
break;
|
|
550
538
|
default:
|
|
@@ -568,19 +556,19 @@ function _dumpArrayDimensionsAttribute(xw, node) {
|
|
|
568
556
|
xw.writeAttribute("ArrayDimensions", node.arrayDimensions.join(","));
|
|
569
557
|
}
|
|
570
558
|
function getParent(node) {
|
|
571
|
-
if (node instanceof
|
|
559
|
+
if (node instanceof UAVariableImpl || node instanceof UAMethodImpl || node instanceof UAObjectImpl) {
|
|
572
560
|
return node.parent;
|
|
573
561
|
}
|
|
574
562
|
return null;
|
|
575
563
|
}
|
|
576
|
-
const currentReadFlag =
|
|
564
|
+
const currentReadFlag = makeAccessLevelFlag("CurrentRead");
|
|
577
565
|
function dumpCommonAttributes(xw, node) {
|
|
578
|
-
xw.writeAttribute("NodeId",
|
|
579
|
-
xw.writeAttribute("BrowseName",
|
|
566
|
+
xw.writeAttribute("NodeId", n(xw, node.nodeId));
|
|
567
|
+
xw.writeAttribute("BrowseName", b(xw, node.browseName));
|
|
580
568
|
const parentNode = getParent(node);
|
|
581
569
|
if (parentNode) {
|
|
582
570
|
if (parentNode.nodeId.namespace <= node.nodeId.namespace) {
|
|
583
|
-
xw.writeAttribute("ParentNodeId",
|
|
571
|
+
xw.writeAttribute("ParentNodeId", n(xw, parentNode.nodeId));
|
|
584
572
|
}
|
|
585
573
|
}
|
|
586
574
|
if (Object.hasOwn(node, "symbolicName")) {
|
|
@@ -600,7 +588,7 @@ function dumpCommonAttributes(xw, node) {
|
|
|
600
588
|
// class rather than on the presence of the property: UAVariableTypeImpl happens not to own
|
|
601
589
|
// an accessLevel today, but it does own a `historizing` (see #1550), so a property-presence
|
|
602
590
|
// guard is one refactor away from emitting an attribute the schema rejects.
|
|
603
|
-
if (node.nodeClass ===
|
|
591
|
+
if (node.nodeClass === NodeClass.Variable) {
|
|
604
592
|
const variable = node;
|
|
605
593
|
// CurrentRead is by default
|
|
606
594
|
if (variable.accessLevel !== currentReadFlag) {
|
|
@@ -632,7 +620,7 @@ function dumpCommonAttributes(xw, node) {
|
|
|
632
620
|
// EventNotifier lives on UAObject, UAObjectType and UAView in the XSD. 0 is the default and is
|
|
633
621
|
// left unwritten; anything else the document declared. It was written nowhere at all until now,
|
|
634
622
|
// so every node that declared one lost it on the way out
|
|
635
|
-
if (node.nodeClass ===
|
|
623
|
+
if (node.nodeClass === NodeClass.Object || node.nodeClass === NodeClass.ObjectType || node.nodeClass === NodeClass.View) {
|
|
636
624
|
// typeof, not truthiness: a node with a child called "EventNotifier" resolves the name to
|
|
637
625
|
// that child through the shared child accessors, so `node.eventNotifier` is a BaseNode
|
|
638
626
|
// there and not the attribute. PublishedEventsType is one, and stringifying it wrote a
|
|
@@ -646,7 +634,7 @@ function dumpCommonAttributes(xw, node) {
|
|
|
646
634
|
// DataType/ValueRank/ArrayDimensions. UAVariableTypeImpl nevertheless owns a `historizing`
|
|
647
635
|
// property, so the node class must be tested here rather than the presence of the property.
|
|
648
636
|
// false being the default, the attribute is only emitted when it is set.
|
|
649
|
-
if (node.nodeClass ===
|
|
637
|
+
if (node.nodeClass === NodeClass.Variable && node.historizing) {
|
|
650
638
|
xw.writeAttribute("Historizing", "true");
|
|
651
639
|
}
|
|
652
640
|
}
|
|
@@ -662,7 +650,7 @@ function _dumpRolePermissions(xw, node) {
|
|
|
662
650
|
for (const rolePermission of rolePermissions) {
|
|
663
651
|
xw.startElement("RolePermission");
|
|
664
652
|
xw.writeAttribute("Permissions", rolePermission.permissions.toString());
|
|
665
|
-
xw.text(
|
|
653
|
+
xw.text(n(xw, rolePermission.roleId));
|
|
666
654
|
xw.endElement();
|
|
667
655
|
}
|
|
668
656
|
xw.endElement();
|
|
@@ -678,8 +666,8 @@ function _dumpEnumDefinition(xw, enumDefinition) {
|
|
|
678
666
|
for (const defItem of enumDefinition.fields) {
|
|
679
667
|
xw.startElement("Field");
|
|
680
668
|
xw.writeAttribute("Name", defItem.name);
|
|
681
|
-
if (!
|
|
682
|
-
xw.writeAttribute("Value",
|
|
669
|
+
if (!isNullOrUndefined(defItem.value)) {
|
|
670
|
+
xw.writeAttribute("Value", coerceInt64ToInt32(defItem.value));
|
|
683
671
|
}
|
|
684
672
|
_dumpDescription(xw, defItem);
|
|
685
673
|
xw.endElement();
|
|
@@ -698,8 +686,8 @@ function _dumpStructureDefinition(xw, structureDefinition, baseStructureDefiniti
|
|
|
698
686
|
// Part 3 8.51: in a *WithSubtypedValues structure, isOptional is where "subtyping allowed" is
|
|
699
687
|
// held, and the document spells that AllowSubTypes. Written as IsOptional it said the opposite
|
|
700
688
|
// of what it meant, and the AllowSubTypes the document had was simply gone
|
|
701
|
-
const subtypedValues = structureDefinition.structureType ===
|
|
702
|
-
structureDefinition.structureType ===
|
|
689
|
+
const subtypedValues = structureDefinition.structureType === StructureType.StructureWithSubtypedValues ||
|
|
690
|
+
structureDefinition.structureType === StructureType.UnionWithSubtypedValues;
|
|
703
691
|
for (let index = nbFieldsInBase; index < fields.length; index++) {
|
|
704
692
|
const defItem = fields[index];
|
|
705
693
|
xw.startElement("Field");
|
|
@@ -719,7 +707,7 @@ function _dumpStructureDefinition(xw, structureDefinition, baseStructureDefiniti
|
|
|
719
707
|
// todo : SymbolicName ( see AutoId )
|
|
720
708
|
if (defItem.dataType) {
|
|
721
709
|
// todo : namespace translation !
|
|
722
|
-
xw.writeAttribute("DataType",
|
|
710
|
+
xw.writeAttribute("DataType", n(xw, defItem.dataType));
|
|
723
711
|
}
|
|
724
712
|
_dumpDescription(xw, defItem);
|
|
725
713
|
xw.endElement();
|
|
@@ -733,7 +721,7 @@ function _dumpUADataTypeDefinition(xw, uaDataType) {
|
|
|
733
721
|
const asImpl = uaDataType;
|
|
734
722
|
// what the document called this definition, or -- for a DataType built here, which never had a
|
|
735
723
|
// declaration -- the browse name, which is the only name available
|
|
736
|
-
const definitionName = asImpl.declaredDefinitionName ??
|
|
724
|
+
const definitionName = asImpl.declaredDefinitionName ?? b(xw, uaDataType.browseName);
|
|
737
725
|
if (asImpl.isOptionSetDataType && asImpl.declaredDefinitionFields) {
|
|
738
726
|
xw.startElement("Definition");
|
|
739
727
|
xw.writeAttribute("Name", definitionName);
|
|
@@ -760,7 +748,7 @@ function _dumpUADataTypeDefinition(xw, uaDataType) {
|
|
|
760
748
|
if (uaDataType.isStructure()) {
|
|
761
749
|
// in case the namespace is conforming to 1.03 specification the DataTypeDefinition attribute
|
|
762
750
|
// will be not be readable....
|
|
763
|
-
const dataValue = uaDataType.readAttribute(
|
|
751
|
+
const dataValue = uaDataType.readAttribute(SessionContext.defaultContext, AttributeIds.DataTypeDefinition);
|
|
764
752
|
const t = true;
|
|
765
753
|
if (t || dataValue.statusCode.isGood()) {
|
|
766
754
|
const definition = uaDataType.getStructureDefinition();
|
|
@@ -769,7 +757,7 @@ function _dumpUADataTypeDefinition(xw, uaDataType) {
|
|
|
769
757
|
const baseDefinition = uaDataTypeBase?.isStructure() ? uaDataTypeBase.getStructureDefinition() : null;
|
|
770
758
|
xw.startElement("Definition");
|
|
771
759
|
xw.writeAttribute("Name", definitionName);
|
|
772
|
-
if (definition.structureType ===
|
|
760
|
+
if (definition.structureType === StructureType.Union) {
|
|
773
761
|
xw.writeAttribute("IsUnion", "true");
|
|
774
762
|
}
|
|
775
763
|
_dumpStructureDefinition(xw, definition, baseDefinition);
|
|
@@ -781,16 +769,16 @@ function _dumpUADataTypeDefinition(xw, uaDataType) {
|
|
|
781
769
|
function dumpUAView(xw, node) {
|
|
782
770
|
_markAsVisited(xw, node);
|
|
783
771
|
xw.startElement("UAView");
|
|
784
|
-
xw.writeAttribute("NodeId",
|
|
785
|
-
xw.writeAttribute("BrowseName",
|
|
772
|
+
xw.writeAttribute("NodeId", n(xw, node.nodeId));
|
|
773
|
+
xw.writeAttribute("BrowseName", b(xw, node.browseName));
|
|
786
774
|
dumpCommonElements(xw, node);
|
|
787
775
|
xw.endElement();
|
|
788
776
|
}
|
|
789
777
|
function dumpUADataType(xw, node) {
|
|
790
778
|
_markAsVisited(xw, node);
|
|
791
779
|
xw.startElement("UADataType");
|
|
792
|
-
xw.writeAttribute("NodeId",
|
|
793
|
-
xw.writeAttribute("BrowseName",
|
|
780
|
+
xw.writeAttribute("NodeId", n(xw, node.nodeId));
|
|
781
|
+
xw.writeAttribute("BrowseName", b(xw, node.browseName));
|
|
794
782
|
if (node.symbolicName !== node.browseName.name) {
|
|
795
783
|
xw.writeAttribute("SymbolicName", node.symbolicName);
|
|
796
784
|
}
|
|
@@ -803,11 +791,11 @@ function dumpUADataType(xw, node) {
|
|
|
803
791
|
}
|
|
804
792
|
function _markAsVisited(xw, node) {
|
|
805
793
|
xw.visitedNode = xw.visitedNode || new Set();
|
|
806
|
-
|
|
794
|
+
assert(!xw.visitedNode.has(_hash(node)));
|
|
807
795
|
xw.visitedNode.add(_hash(node));
|
|
808
796
|
}
|
|
809
797
|
function dumpUAVariable(xw, node) {
|
|
810
|
-
|
|
798
|
+
assert(node.nodeClass === NodeClass.Variable);
|
|
811
799
|
if (xw.visitedNode.has(_hash(node))) {
|
|
812
800
|
return;
|
|
813
801
|
}
|
|
@@ -826,7 +814,7 @@ function dumpUAVariable(xw, node) {
|
|
|
826
814
|
if (dataTypeNode) {
|
|
827
815
|
// verify that data Type is in alias
|
|
828
816
|
// xx const dataTypeName = dataTypeNode.browseName.toString();
|
|
829
|
-
const dataTypeName =
|
|
817
|
+
const dataTypeName = b(xw, resolveDataTypeName(addressSpace, dataTypeNode.nodeId));
|
|
830
818
|
xw.writeAttribute("DataType", dataTypeName);
|
|
831
819
|
}
|
|
832
820
|
}
|
|
@@ -840,16 +828,16 @@ function dumpUAVariable(xw, node) {
|
|
|
840
828
|
const synthesized = node.valueWasSynthesized;
|
|
841
829
|
const dataValue = node.$dataValue;
|
|
842
830
|
const value = dataValue.value;
|
|
843
|
-
if (value && !synthesized && !dataValue.statusCode.equals(
|
|
831
|
+
if (value && !synthesized && !dataValue.statusCode.equals(StatusCodes.BadWaitingForInitialData)) {
|
|
844
832
|
_dumpValue(xw, node, value);
|
|
845
833
|
}
|
|
846
834
|
}
|
|
847
835
|
xw.endElement();
|
|
848
836
|
}
|
|
849
837
|
function dumpUAVariableType(xw, node) {
|
|
850
|
-
|
|
838
|
+
assert(node.nodeClass === NodeClass.VariableType);
|
|
851
839
|
xw.visitedNode = xw.visitedNode || new Set();
|
|
852
|
-
|
|
840
|
+
assert(!xw.visitedNode.has(_hash(node)));
|
|
853
841
|
xw.visitedNode.add(_hash(node));
|
|
854
842
|
const addressSpace = node.addressSpace;
|
|
855
843
|
xw.startElement("UAVariableType");
|
|
@@ -872,7 +860,7 @@ function dumpUAVariableType(xw, node) {
|
|
|
872
860
|
node.nodeId.toString());
|
|
873
861
|
}
|
|
874
862
|
else {
|
|
875
|
-
const dataTypeName =
|
|
863
|
+
const dataTypeName = b(xw, resolveDataTypeName(addressSpace, dataTypeNode.nodeId));
|
|
876
864
|
xw.writeAttribute("DataType", dataTypeName);
|
|
877
865
|
}
|
|
878
866
|
}
|
|
@@ -888,9 +876,9 @@ function dumpUAVariableType(xw, node) {
|
|
|
888
876
|
xw.endElement();
|
|
889
877
|
}
|
|
890
878
|
function _dumpUAObject(xw, node) {
|
|
891
|
-
|
|
879
|
+
assert(node.nodeClass === NodeClass.Object);
|
|
892
880
|
xw.visitedNode = xw.visitedNode || new Set();
|
|
893
|
-
|
|
881
|
+
assert(!xw.visitedNode.has(_hash(node)));
|
|
894
882
|
xw.visitedNode.add(_hash(node));
|
|
895
883
|
// dump SubTypeOf and HasTypeDefinition
|
|
896
884
|
xw.startElement("UAObject");
|
|
@@ -900,8 +888,8 @@ function _dumpUAObject(xw, node) {
|
|
|
900
888
|
// dump aggregates nodes ( Properties / components )
|
|
901
889
|
}
|
|
902
890
|
function dumpUAObjectType(xw, node) {
|
|
903
|
-
|
|
904
|
-
|
|
891
|
+
assert(node.nodeClass === NodeClass.ObjectType);
|
|
892
|
+
assert(node instanceof UAObjectTypeImpl);
|
|
905
893
|
_markAsVisited(xw, node);
|
|
906
894
|
// dump SubtypeOf and HasTypeDefinition node if part of the same namespace
|
|
907
895
|
xw.startElement("UAObjectType");
|
|
@@ -910,12 +898,12 @@ function dumpUAObjectType(xw, node) {
|
|
|
910
898
|
xw.endElement();
|
|
911
899
|
}
|
|
912
900
|
function dumpUAMethod(xw, node) {
|
|
913
|
-
|
|
901
|
+
assert(node.nodeClass === NodeClass.Method);
|
|
914
902
|
_markAsVisited(xw, node);
|
|
915
903
|
xw.startElement("UAMethod");
|
|
916
904
|
dumpCommonAttributes(xw, node);
|
|
917
905
|
if (node.methodDeclarationId) {
|
|
918
|
-
xw.writeAttribute("MethodDeclarationId",
|
|
906
|
+
xw.writeAttribute("MethodDeclarationId", n(xw, node.methodDeclarationId));
|
|
919
907
|
}
|
|
920
908
|
dumpCommonElements(xw, node);
|
|
921
909
|
xw.endElement();
|
|
@@ -927,13 +915,13 @@ function resolveDataTypeName(addressSpace, dataType) {
|
|
|
927
915
|
dataTypeNode = addressSpace.findDataType(dataType);
|
|
928
916
|
}
|
|
929
917
|
else {
|
|
930
|
-
|
|
918
|
+
assert(dataType instanceof NodeId);
|
|
931
919
|
const o = addressSpace.findNode(dataType.toString());
|
|
932
920
|
dataTypeNode = o ? o : null;
|
|
933
921
|
}
|
|
934
922
|
if (!dataTypeNode) {
|
|
935
923
|
errorLog(`resolveDataTypeName: warning cannot find DataType ${dataType.toString()}`);
|
|
936
|
-
return new
|
|
924
|
+
return new QualifiedName({ name: "", namespaceIndex: 0 });
|
|
937
925
|
}
|
|
938
926
|
return dataTypeNode.browseName;
|
|
939
927
|
}
|
|
@@ -966,7 +954,7 @@ function dumpReferenceType(xw, referenceType) {
|
|
|
966
954
|
}
|
|
967
955
|
xw.endElement();
|
|
968
956
|
}
|
|
969
|
-
function sortByBrowseName(x, y) {
|
|
957
|
+
export function sortByBrowseName(x, y) {
|
|
970
958
|
const x_str = x.browseName.toString();
|
|
971
959
|
const y_str = y.browseName.toString();
|
|
972
960
|
if (x_str > y_str) {
|
|
@@ -980,28 +968,28 @@ function sortByBrowseName(x, y) {
|
|
|
980
968
|
/** the element of one node, and nothing else: the walk decides what comes before and after it */
|
|
981
969
|
function dumpElement(xw, node) {
|
|
982
970
|
switch (node.nodeClass) {
|
|
983
|
-
case
|
|
971
|
+
case NodeClass.Method:
|
|
984
972
|
dumpUAMethod(xw, node);
|
|
985
973
|
break;
|
|
986
|
-
case
|
|
974
|
+
case NodeClass.Object:
|
|
987
975
|
_dumpUAObject(xw, node);
|
|
988
976
|
break;
|
|
989
|
-
case
|
|
977
|
+
case NodeClass.Variable:
|
|
990
978
|
dumpUAVariable(xw, node);
|
|
991
979
|
break;
|
|
992
|
-
case
|
|
980
|
+
case NodeClass.VariableType:
|
|
993
981
|
dumpUAVariableType(xw, node);
|
|
994
982
|
break;
|
|
995
|
-
case
|
|
983
|
+
case NodeClass.ReferenceType:
|
|
996
984
|
dumpReferenceType(xw, node);
|
|
997
985
|
break;
|
|
998
|
-
case
|
|
986
|
+
case NodeClass.ObjectType:
|
|
999
987
|
dumpUAObjectType(xw, node);
|
|
1000
988
|
break;
|
|
1001
|
-
case
|
|
989
|
+
case NodeClass.DataType:
|
|
1002
990
|
dumpUADataType(xw, node);
|
|
1003
991
|
break;
|
|
1004
|
-
case
|
|
992
|
+
case NodeClass.View:
|
|
1005
993
|
dumpUAView(xw, node);
|
|
1006
994
|
break;
|
|
1007
995
|
default:
|
|
@@ -1027,7 +1015,7 @@ function writeWalkEvents(xw, addressSpace, translationTable, events) {
|
|
|
1027
1015
|
if (namespace === undefined) {
|
|
1028
1016
|
throw new Error(`toNodeset2XML: no namespace for ${event.nodeId.toString()}`);
|
|
1029
1017
|
}
|
|
1030
|
-
const node = addressSpace.findNode(new
|
|
1018
|
+
const node = addressSpace.findNode(new NodeId(event.nodeId.identifierType, event.nodeId.value, namespace));
|
|
1031
1019
|
if (!node) {
|
|
1032
1020
|
throw new Error(`toNodeset2XML: cannot find ${event.nodeId.toString()} (namespace ${namespace})`);
|
|
1033
1021
|
}
|
|
@@ -1038,23 +1026,23 @@ function writeWalkEvents(xw, addressSpace, translationTable, events) {
|
|
|
1038
1026
|
* one node as XML, with what the export brings with it: its type definition and supertype when they
|
|
1039
1027
|
* belong to the same namespace, its aggregates after it. The same walk toNodeset2XML runs, from this node.
|
|
1040
1028
|
*/
|
|
1041
|
-
|
|
1042
|
-
const { events, translationTable } =
|
|
1029
|
+
BaseNodeImpl.prototype.dumpXML = function (xw) {
|
|
1030
|
+
const { events, translationTable } = nodeToWalkEvents(this);
|
|
1043
1031
|
xw.translationTable = xw.translationTable || translationTable;
|
|
1044
1032
|
writeWalkEvents(xw, this.addressSpace, translationTable, events);
|
|
1045
1033
|
};
|
|
1046
|
-
|
|
1047
|
-
const namespaceArrayNode = this.addressSpace.findNode(
|
|
1034
|
+
NamespaceImpl.prototype.toNodeset2XML = function () {
|
|
1035
|
+
const namespaceArrayNode = this.addressSpace.findNode(VariableIds.Server_NamespaceArray);
|
|
1048
1036
|
const namespaceArray = namespaceArrayNode
|
|
1049
|
-
? namespaceArrayNode.readAttribute(null,
|
|
1037
|
+
? namespaceArrayNode.readAttribute(null, AttributeIds.Value).value.value
|
|
1050
1038
|
: [];
|
|
1051
|
-
const xw = new
|
|
1052
|
-
xw.priorityTable =
|
|
1053
|
-
const dependency =
|
|
1054
|
-
const translationTable =
|
|
1039
|
+
const xw = new XMLWriter(true);
|
|
1040
|
+
xw.priorityTable = constructNamespacePriorityTable(this.addressSpace).priorityTable;
|
|
1041
|
+
const dependency = constructNamespaceDependency(this, xw.priorityTable);
|
|
1042
|
+
const translationTable = _constructNamespaceTranslationTable(dependency, this);
|
|
1055
1043
|
xw.translationTable = translationTable;
|
|
1056
1044
|
// the walk: the same records the image writer and the loader consume, plus the comments
|
|
1057
|
-
const events =
|
|
1045
|
+
const events = namespaceToWalkEvents(this);
|
|
1058
1046
|
const header = events[0];
|
|
1059
1047
|
if (header?.kind !== "header") {
|
|
1060
1048
|
throw new Error("toNodeset2XML: the walk must start with the header record");
|
|
@@ -1075,10 +1063,10 @@ namespace_impl_js_1.NamespaceImpl.prototype.toNodeset2XML = function () {
|
|
|
1075
1063
|
}
|
|
1076
1064
|
const translatedIndex = translationTable.get(namespace.index);
|
|
1077
1065
|
const smallName = `ns${translatedIndex}`;
|
|
1078
|
-
xw.writeAttribute(`xmlns:${smallName}`,
|
|
1066
|
+
xw.writeAttribute(`xmlns:${smallName}`, makeTypeXsd(namespace.namespaceUri));
|
|
1079
1067
|
namespacesMap[namespace.namespaceUri] = smallName;
|
|
1080
1068
|
}
|
|
1081
|
-
|
|
1069
|
+
initXmlWriterEx(xw, namespacesMap, namespaceArray);
|
|
1082
1070
|
xw.startElement("NamespaceUris");
|
|
1083
1071
|
for (const namespaceUri of header.namespaceUris) {
|
|
1084
1072
|
xw.startElement("Uri");
|