From 233e64c0c5f8d09ea184c5cba3597d06022dc66a Mon Sep 17 00:00:00 2001 From: Will Sobel Date: Fri, 5 Apr 2024 21:41:43 -0400 Subject: [PATCH 1/3] updated copyright and added validations --- agent/cppagent.cpp | 2 +- agent_lib/CMakeLists.txt | 7 ++++ src/mtconnect/agent.cpp | 19 +++++++-- src/mtconnect/agent.hpp | 5 ++- src/mtconnect/asset/asset.cpp | 2 +- src/mtconnect/asset/asset.hpp | 2 +- src/mtconnect/asset/asset_buffer.hpp | 2 +- src/mtconnect/asset/asset_storage.hpp | 2 +- .../component_configuration_parameters.cpp | 2 +- .../component_configuration_parameters.hpp | 2 +- src/mtconnect/asset/cutting_tool.cpp | 2 +- src/mtconnect/asset/cutting_tool.hpp | 2 +- src/mtconnect/asset/file_asset.cpp | 2 +- src/mtconnect/asset/file_asset.hpp | 2 +- src/mtconnect/asset/qif_document.cpp | 2 +- src/mtconnect/asset/qif_document.hpp | 2 +- src/mtconnect/asset/raw_material.cpp | 2 +- src/mtconnect/asset/raw_material.hpp | 2 +- src/mtconnect/buffer/checkpoint.cpp | 2 +- src/mtconnect/buffer/checkpoint.hpp | 2 +- src/mtconnect/buffer/circular_buffer.hpp | 2 +- src/mtconnect/config.hpp | 2 +- src/mtconnect/configuration/agent_config.cpp | 5 ++- src/mtconnect/configuration/agent_config.hpp | 2 +- src/mtconnect/configuration/async_context.hpp | 2 +- .../configuration/config_options.hpp | 3 +- src/mtconnect/configuration/hook_manager.hpp | 2 +- src/mtconnect/configuration/parser.cpp | 2 +- src/mtconnect/configuration/parser.hpp | 2 +- src/mtconnect/configuration/service.cpp | 2 +- src/mtconnect/configuration/service.hpp | 2 +- src/mtconnect/device_model/agent_device.cpp | 2 +- src/mtconnect/device_model/agent_device.hpp | 2 +- src/mtconnect/device_model/component.cpp | 2 +- src/mtconnect/device_model/component.hpp | 2 +- src/mtconnect/device_model/composition.cpp | 2 +- src/mtconnect/device_model/composition.hpp | 2 +- .../configuration/configuration.cpp | 2 +- .../configuration/configuration.hpp | 2 +- .../configuration/coordinate_systems.cpp | 2 +- .../configuration/coordinate_systems.hpp | 2 +- .../device_model/configuration/image_file.cpp | 2 +- .../device_model/configuration/image_file.hpp | 2 +- .../device_model/configuration/motion.cpp | 2 +- .../device_model/configuration/motion.hpp | 2 +- .../configuration/relationships.cpp | 2 +- .../configuration/relationships.hpp | 2 +- .../configuration/sensor_configuration.cpp | 2 +- .../configuration/sensor_configuration.hpp | 2 +- .../configuration/solid_model.cpp | 2 +- .../configuration/solid_model.hpp | 2 +- .../configuration/specifications.cpp | 2 +- .../configuration/specifications.hpp | 2 +- .../device_model/data_item/constraints.hpp | 2 +- .../device_model/data_item/data_item.cpp | 2 +- .../device_model/data_item/data_item.hpp | 2 +- .../device_model/data_item/definition.hpp | 2 +- .../device_model/data_item/filter.hpp | 2 +- .../device_model/data_item/relationships.hpp | 2 +- .../device_model/data_item/source.hpp | 2 +- .../data_item/unit_conversion.cpp | 2 +- .../data_item/unit_conversion.hpp | 2 +- src/mtconnect/device_model/description.cpp | 2 +- src/mtconnect/device_model/description.hpp | 2 +- src/mtconnect/device_model/device.cpp | 2 +- src/mtconnect/device_model/device.hpp | 2 +- src/mtconnect/device_model/reference.cpp | 2 +- src/mtconnect/device_model/reference.hpp | 2 +- src/mtconnect/entity/data_set.cpp | 2 +- src/mtconnect/entity/data_set.hpp | 2 +- src/mtconnect/entity/entity.cpp | 2 +- src/mtconnect/entity/entity.hpp | 2 +- src/mtconnect/entity/factory.cpp | 2 +- src/mtconnect/entity/factory.hpp | 2 +- src/mtconnect/entity/json_parser.cpp | 2 +- src/mtconnect/entity/json_parser.hpp | 2 +- src/mtconnect/entity/json_printer.hpp | 2 +- src/mtconnect/entity/qname.hpp | 2 +- src/mtconnect/entity/requirement.cpp | 2 +- src/mtconnect/entity/requirement.hpp | 2 +- src/mtconnect/entity/xml_parser.cpp | 2 +- src/mtconnect/entity/xml_parser.hpp | 2 +- src/mtconnect/entity/xml_printer.cpp | 2 +- src/mtconnect/entity/xml_printer.hpp | 2 +- src/mtconnect/logging.hpp | 2 +- src/mtconnect/mqtt/mqtt_authorization.hpp | 2 +- src/mtconnect/mqtt/mqtt_client.hpp | 2 +- src/mtconnect/mqtt/mqtt_client_impl.hpp | 2 +- src/mtconnect/mqtt/mqtt_server.hpp | 2 +- src/mtconnect/mqtt/mqtt_server_impl.hpp | 2 +- src/mtconnect/observation/change_observer.cpp | 2 +- src/mtconnect/observation/change_observer.hpp | 2 +- src/mtconnect/observation/observation.cpp | 23 ++++++----- src/mtconnect/observation/observation.hpp | 2 +- src/mtconnect/parser/xml_parser.cpp | 2 +- src/mtconnect/parser/xml_parser.hpp | 2 +- src/mtconnect/pipeline/convert_sample.hpp | 2 +- src/mtconnect/pipeline/deliver.cpp | 2 +- src/mtconnect/pipeline/deliver.hpp | 2 +- src/mtconnect/pipeline/delta_filter.hpp | 2 +- src/mtconnect/pipeline/duplicate_filter.hpp | 2 +- src/mtconnect/pipeline/guard.hpp | 2 +- src/mtconnect/pipeline/json_mapper.cpp | 2 +- src/mtconnect/pipeline/json_mapper.hpp | 2 +- src/mtconnect/pipeline/message_mapper.hpp | 2 +- .../pipeline/mtconnect_xml_transform.hpp | 2 +- src/mtconnect/pipeline/period_filter.hpp | 2 +- src/mtconnect/pipeline/pipeline.hpp | 2 +- src/mtconnect/pipeline/pipeline_context.hpp | 2 +- src/mtconnect/pipeline/pipeline_contract.hpp | 2 +- src/mtconnect/pipeline/response_document.cpp | 2 +- src/mtconnect/pipeline/response_document.hpp | 2 +- src/mtconnect/pipeline/shdr_token_mapper.cpp | 2 +- src/mtconnect/pipeline/shdr_token_mapper.hpp | 2 +- src/mtconnect/pipeline/shdr_tokenizer.hpp | 2 +- .../pipeline/timestamp_extractor.hpp | 2 +- src/mtconnect/pipeline/topic_mapper.hpp | 2 +- src/mtconnect/pipeline/transform.hpp | 2 +- src/mtconnect/pipeline/upcase_value.hpp | 2 +- src/mtconnect/printer/json_printer.cpp | 32 +++++++++------ src/mtconnect/printer/json_printer.hpp | 4 +- src/mtconnect/printer/json_printer_helper.hpp | 2 +- src/mtconnect/printer/printer.hpp | 16 ++++++-- src/mtconnect/printer/xml_helper.hpp | 2 +- src/mtconnect/printer/xml_printer.cpp | 7 +++- src/mtconnect/printer/xml_printer.hpp | 4 +- src/mtconnect/printer/xml_printer_helper.hpp | 2 +- src/mtconnect/ruby/embedded.cpp | 2 +- src/mtconnect/ruby/embedded.hpp | 2 +- src/mtconnect/ruby/ruby_agent.hpp | 2 +- src/mtconnect/ruby/ruby_entity.hpp | 2 +- src/mtconnect/ruby/ruby_observation.hpp | 2 +- src/mtconnect/ruby/ruby_pipeline.hpp | 2 +- src/mtconnect/ruby/ruby_smart_ptr.hpp | 2 +- src/mtconnect/ruby/ruby_transform.hpp | 2 +- src/mtconnect/ruby/ruby_type.hpp | 2 +- src/mtconnect/ruby/ruby_vm.hpp | 2 +- src/mtconnect/sink/mqtt_sink/mqtt_service.cpp | 2 +- src/mtconnect/sink/mqtt_sink/mqtt_service.hpp | 2 +- src/mtconnect/sink/rest_sink/cached_file.hpp | 2 +- src/mtconnect/sink/rest_sink/file_cache.cpp | 2 +- src/mtconnect/sink/rest_sink/file_cache.hpp | 2 +- src/mtconnect/sink/rest_sink/parameter.hpp | 2 +- src/mtconnect/sink/rest_sink/request.hpp | 2 +- src/mtconnect/sink/rest_sink/response.hpp | 2 +- src/mtconnect/sink/rest_sink/rest_service.cpp | 2 +- src/mtconnect/sink/rest_sink/rest_service.hpp | 2 +- src/mtconnect/sink/rest_sink/routing.hpp | 2 +- src/mtconnect/sink/rest_sink/server.cpp | 2 +- src/mtconnect/sink/rest_sink/server.hpp | 2 +- src/mtconnect/sink/rest_sink/session.hpp | 2 +- src/mtconnect/sink/rest_sink/session_impl.cpp | 2 +- src/mtconnect/sink/rest_sink/session_impl.hpp | 2 +- src/mtconnect/sink/rest_sink/tls_dector.hpp | 2 +- src/mtconnect/sink/sink.cpp | 2 +- src/mtconnect/sink/sink.hpp | 2 +- src/mtconnect/source/adapter/adapter.hpp | 2 +- .../source/adapter/adapter_pipeline.cpp | 2 +- .../source/adapter/adapter_pipeline.hpp | 2 +- .../adapter/agent_adapter/agent_adapter.cpp | 2 +- .../adapter/agent_adapter/agent_adapter.hpp | 2 +- .../adapter/agent_adapter/http_session.hpp | 2 +- .../adapter/agent_adapter/https_session.hpp | 2 +- .../source/adapter/agent_adapter/session.hpp | 2 +- .../adapter/agent_adapter/session_impl.hpp | 2 +- .../adapter/agent_adapter/url_parser.cpp | 2 +- .../adapter/agent_adapter/url_parser.hpp | 2 +- .../source/adapter/mqtt/mqtt_adapter.cpp | 2 +- .../source/adapter/mqtt/mqtt_adapter.hpp | 2 +- .../source/adapter/shdr/connector.cpp | 2 +- .../source/adapter/shdr/connector.hpp | 2 +- .../source/adapter/shdr/shdr_adapter.cpp | 2 +- .../source/adapter/shdr/shdr_adapter.hpp | 2 +- .../source/adapter/shdr/shdr_pipeline.cpp | 2 +- .../source/adapter/shdr/shdr_pipeline.hpp | 2 +- src/mtconnect/source/error_code.hpp | 2 +- src/mtconnect/source/loopback_source.cpp | 2 +- src/mtconnect/source/loopback_source.hpp | 2 +- src/mtconnect/source/source.cpp | 2 +- src/mtconnect/source/source.hpp | 2 +- src/mtconnect/utilities.cpp | 2 +- src/mtconnect/utilities.hpp | 2 +- .../validation/observation_validations.hpp | 39 +++++++++++++++++++ src/mtconnect/validation/observations.cpp | 22 +++++++++++ src/mtconnect/validation/observations.hpp | 29 ++++++++++++++ src/mtconnect/version.cpp | 2 +- test_package/adapter_test.cpp | 2 +- test_package/agent_adapter_test.cpp | 2 +- test_package/agent_device_test.cpp | 2 +- test_package/agent_test.cpp | 2 +- test_package/agent_test_helper.cpp | 2 +- test_package/agent_test_helper.hpp | 2 +- test_package/asset_buffer_test.cpp | 2 +- test_package/asset_hash_test.cpp | 2 +- test_package/asset_test.cpp | 2 +- test_package/change_observer_test.cpp | 2 +- test_package/checkpoint_test.cpp | 2 +- test_package/circular_buffer_test.cpp | 2 +- test_package/component_parameters_test.cpp | 2 +- test_package/component_test.cpp | 2 +- test_package/composition_test.cpp | 2 +- test_package/config_parser_test.cpp | 2 +- test_package/config_test.cpp | 2 +- test_package/connector_test.cpp | 2 +- test_package/coordinate_system_test.cpp | 2 +- test_package/cutting_tool_test.cpp | 2 +- test_package/data_item_mapping_test.cpp | 2 +- test_package/data_item_test.cpp | 2 +- test_package/data_set_test.cpp | 2 +- test_package/device_test.cpp | 2 +- test_package/duplicate_filter_test.cpp | 2 +- test_package/embedded_ruby_test.cpp | 2 +- test_package/entity_parser_test.cpp | 2 +- test_package/entity_printer_test.cpp | 2 +- test_package/entity_test.cpp | 2 +- test_package/file_asset_test.cpp | 2 +- test_package/file_cache_test.cpp | 2 +- test_package/globals_test.cpp | 2 +- test_package/http_server_test.cpp | 2 +- test_package/image_file_test.cpp | 2 +- test_package/json_helper.hpp | 2 +- test_package/json_mapping_test.cpp | 2 +- test_package/json_parser_test.cpp | 2 +- test_package/json_printer_asset_test.cpp | 2 +- test_package/json_printer_error_test.cpp | 2 +- test_package/json_printer_probe_test.cpp | 2 +- test_package/json_printer_stream_test.cpp | 2 +- test_package/json_printer_test.cpp | 2 +- test_package/kinematics_test.cpp | 2 +- test_package/mqtt_adapter_test.cpp | 2 +- test_package/mqtt_isolated_test.cpp | 2 +- test_package/mqtt_sink_2_test.cpp | 2 +- test_package/mqtt_sink_test.cpp | 2 +- test_package/mtconnect_xml_transform_test.cpp | 2 +- test_package/observation_test.cpp | 2 +- test_package/period_filter_test.cpp | 2 +- test_package/pipeline_deliver_test.cpp | 2 +- test_package/pipeline_edit_test.cpp | 2 +- test_package/qif_document_test.cpp | 2 +- test_package/qname_test.cpp | 2 +- test_package/raw_material_test.cpp | 2 +- test_package/references_test.cpp | 2 +- test_package/relationship_test.cpp | 2 +- test_package/response_document_test.cpp | 2 +- test_package/routing_test.cpp | 2 +- test_package/sensor_configuration_test.cpp | 2 +- test_package/shdr_tokenizer_test.cpp | 2 +- test_package/solid_model_test.cpp | 2 +- test_package/specification_test.cpp | 2 +- test_package/table_test.cpp | 2 +- test_package/test_utilities.hpp | 2 +- test_package/testadapter_service.cpp | 2 +- test_package/testadapter_service.hpp | 2 +- test_package/testsink_service.cpp | 2 +- test_package/testsink_service.hpp | 2 +- test_package/timestamp_extractor_test.cpp | 2 +- test_package/tls_http_server_test.cpp | 2 +- test_package/topic_mapping_test.cpp | 2 +- test_package/unit_conversion_test.cpp | 2 +- test_package/url_parser_test.cpp | 2 +- test_package/xml_parser_test.cpp | 2 +- test_package/xml_printer_test.cpp | 2 +- 262 files changed, 424 insertions(+), 287 deletions(-) create mode 100644 src/mtconnect/validation/observation_validations.hpp create mode 100644 src/mtconnect/validation/observations.cpp create mode 100644 src/mtconnect/validation/observations.hpp diff --git a/agent/cppagent.cpp b/agent/cppagent.cpp index ae86382a3..3557e01a4 100644 --- a/agent/cppagent.cpp +++ b/agent/cppagent.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/agent_lib/CMakeLists.txt b/agent_lib/CMakeLists.txt index ac5763e40..975b9fbb5 100644 --- a/agent_lib/CMakeLists.txt +++ b/agent_lib/CMakeLists.txt @@ -273,6 +273,13 @@ set(AGENT_SOURCES "${SOURCE_DIR}/sink/rest_sink/rest_service.cpp" "${SOURCE_DIR}/sink/rest_sink/server.cpp" "${SOURCE_DIR}/sink/rest_sink/session_impl.cpp" + + # validation HEADER_FILES_ONLY + "${SOURCE_DIR}/validation/observations.hpp" + "${SOURCE_DIR}/validation/observation_validations.hpp" + + # validation SOURCE_FILES_ONLY + "${SOURCE_DIR}/validation/observations.cpp" ) if(WITH_RUBY) diff --git a/src/mtconnect/agent.cpp b/src/mtconnect/agent.cpp index 592af871b..a2eaa939c 100644 --- a/src/mtconnect/agent.cpp +++ b/src/mtconnect/agent.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -58,6 +58,8 @@ #include "mtconnect/utilities.hpp" #include "mtconnect/version.h" +#include "mtconnect/validation/observations.hpp" + using namespace std; namespace mtconnect { @@ -83,7 +85,8 @@ namespace mtconnect { m_deviceXmlPath(deviceXmlPath), m_circularBuffer(GetOption(options, config::BufferSize).value_or(17), GetOption(options, config::CheckpointFrequency).value_or(1000)), - m_pretty(IsOptionSet(options, mtconnect::configuration::Pretty)) + m_pretty(IsOptionSet(options, mtconnect::configuration::Pretty)), + m_validation(IsOptionSet(options, mtconnect::configuration::Validation)) { using namespace asset; @@ -104,8 +107,8 @@ namespace mtconnect { uint32_t(GetOption(options, mtconnect::configuration::JsonVersion).value_or(2)); // Create the Printers - m_printers["xml"] = make_unique(m_pretty); - m_printers["json"] = make_unique(jsonVersion, m_pretty); + m_printers["xml"] = make_unique(m_pretty, m_validation); + m_printers["json"] = make_unique(jsonVersion, m_pretty, m_validation); if (m_schemaVersion) { @@ -168,6 +171,13 @@ namespace mtconnect { if (!m_observationsInitialized) { + if (m_intSchemaVersion < SCHEMA_VERSION(2, 5) && IsOptionSet(m_options, mtconnect::configuration::Validation)) + { + m_validation = false; + for (auto &printer : m_printers) + printer.second->setValidation(false); + } + for (auto device : m_deviceIndex) initializeDataItems(device); @@ -191,6 +201,7 @@ namespace mtconnect { } m_observationsInitialized = true; + } } diff --git a/src/mtconnect/agent.hpp b/src/mtconnect/agent.hpp index a3202f3c9..e1425dcc9 100644 --- a/src/mtconnect/agent.hpp +++ b/src/mtconnect/agent.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -542,6 +542,9 @@ namespace mtconnect { // For debugging bool m_pretty; + // validation + bool m_validation {false}; + // Agent hooks configuration::HookManager m_beforeInitializeHooks; configuration::HookManager m_afterInitializeHooks; diff --git a/src/mtconnect/asset/asset.cpp b/src/mtconnect/asset/asset.cpp index ecda782de..ac51d0cd9 100644 --- a/src/mtconnect/asset/asset.cpp +++ b/src/mtconnect/asset/asset.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/asset.hpp b/src/mtconnect/asset/asset.hpp index 0fe001a2e..182186c84 100644 --- a/src/mtconnect/asset/asset.hpp +++ b/src/mtconnect/asset/asset.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/asset_buffer.hpp b/src/mtconnect/asset/asset_buffer.hpp index b4aa75bff..662780745 100644 --- a/src/mtconnect/asset/asset_buffer.hpp +++ b/src/mtconnect/asset/asset_buffer.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/asset_storage.hpp b/src/mtconnect/asset/asset_storage.hpp index dcccae645..ff90e49a4 100644 --- a/src/mtconnect/asset/asset_storage.hpp +++ b/src/mtconnect/asset/asset_storage.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/component_configuration_parameters.cpp b/src/mtconnect/asset/component_configuration_parameters.cpp index 100652671..d341b6d8c 100644 --- a/src/mtconnect/asset/component_configuration_parameters.cpp +++ b/src/mtconnect/asset/component_configuration_parameters.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/component_configuration_parameters.hpp b/src/mtconnect/asset/component_configuration_parameters.hpp index ef45675fb..fc40d3449 100644 --- a/src/mtconnect/asset/component_configuration_parameters.hpp +++ b/src/mtconnect/asset/component_configuration_parameters.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/cutting_tool.cpp b/src/mtconnect/asset/cutting_tool.cpp index 579350bcb..43d5303af 100644 --- a/src/mtconnect/asset/cutting_tool.cpp +++ b/src/mtconnect/asset/cutting_tool.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/cutting_tool.hpp b/src/mtconnect/asset/cutting_tool.hpp index 1c3e820c9..7eec093e6 100644 --- a/src/mtconnect/asset/cutting_tool.hpp +++ b/src/mtconnect/asset/cutting_tool.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/file_asset.cpp b/src/mtconnect/asset/file_asset.cpp index 222b97f97..b001c86ca 100644 --- a/src/mtconnect/asset/file_asset.cpp +++ b/src/mtconnect/asset/file_asset.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/file_asset.hpp b/src/mtconnect/asset/file_asset.hpp index 380f26bcb..9c5ea9797 100644 --- a/src/mtconnect/asset/file_asset.hpp +++ b/src/mtconnect/asset/file_asset.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/qif_document.cpp b/src/mtconnect/asset/qif_document.cpp index bf7b77913..6c762cd12 100644 --- a/src/mtconnect/asset/qif_document.cpp +++ b/src/mtconnect/asset/qif_document.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/qif_document.hpp b/src/mtconnect/asset/qif_document.hpp index e1c58fcfd..45bc7f2f2 100644 --- a/src/mtconnect/asset/qif_document.hpp +++ b/src/mtconnect/asset/qif_document.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/raw_material.cpp b/src/mtconnect/asset/raw_material.cpp index a9a44d3f3..0ca15b37d 100644 --- a/src/mtconnect/asset/raw_material.cpp +++ b/src/mtconnect/asset/raw_material.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/asset/raw_material.hpp b/src/mtconnect/asset/raw_material.hpp index 2612ed5d8..76af8d858 100644 --- a/src/mtconnect/asset/raw_material.hpp +++ b/src/mtconnect/asset/raw_material.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/buffer/checkpoint.cpp b/src/mtconnect/buffer/checkpoint.cpp index a0e32f6e8..fd5ec3034 100644 --- a/src/mtconnect/buffer/checkpoint.cpp +++ b/src/mtconnect/buffer/checkpoint.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/buffer/checkpoint.hpp b/src/mtconnect/buffer/checkpoint.hpp index 7e7c582a8..b830c223d 100644 --- a/src/mtconnect/buffer/checkpoint.hpp +++ b/src/mtconnect/buffer/checkpoint.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/buffer/circular_buffer.hpp b/src/mtconnect/buffer/circular_buffer.hpp index e9b934ae3..eb3b3f4d6 100644 --- a/src/mtconnect/buffer/circular_buffer.hpp +++ b/src/mtconnect/buffer/circular_buffer.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/config.hpp b/src/mtconnect/config.hpp index 219d245d6..a522fe123 100644 --- a/src/mtconnect/config.hpp +++ b/src/mtconnect/config.hpp @@ -1,7 +1,7 @@ #pragma once // -// Copyright Copyright 2009-2022, AMT � The Association For Manufacturing Technology (�AMT�) +// Copyright Copyright 2009-2024, AMT � The Association For Manufacturing Technology (�AMT�) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/configuration/agent_config.cpp b/src/mtconnect/configuration/agent_config.cpp index 80174ad83..bd1349306 100644 --- a/src/mtconnect/configuration/agent_config.cpp +++ b/src/mtconnect/configuration/agent_config.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -789,7 +789,8 @@ namespace mtconnect::configuration { {configuration::TlsVerifyClientCertificate, false}, {configuration::TlsClientCAs, ""s}, {configuration::SuppressIPAddress, false}, - {configuration::AllowPutFrom, ""s}}); + {configuration::AllowPutFrom, ""s}, + {configuration::Validation, false}}); m_workerThreadCount = *GetOption(options, configuration::WorkerThreads); m_monitorFiles = *GetOption(options, configuration::MonitorConfigFiles); diff --git a/src/mtconnect/configuration/agent_config.hpp b/src/mtconnect/configuration/agent_config.hpp index 61b39bbd1..dd68f198f 100644 --- a/src/mtconnect/configuration/agent_config.hpp +++ b/src/mtconnect/configuration/agent_config.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/configuration/async_context.hpp b/src/mtconnect/configuration/async_context.hpp index 0446685e0..47b05d2bd 100644 --- a/src/mtconnect/configuration/async_context.hpp +++ b/src/mtconnect/configuration/async_context.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/configuration/config_options.hpp b/src/mtconnect/configuration/config_options.hpp index ac5bb2d3c..35f33ce5f 100644 --- a/src/mtconnect/configuration/config_options.hpp +++ b/src/mtconnect/configuration/config_options.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -76,6 +76,7 @@ namespace mtconnect { DECLARE_CONFIGURATION(VersionDeviceXml); DECLARE_CONFIGURATION(EnableSourceDeviceModels); DECLARE_CONFIGURATION(WorkerThreads); + DECLARE_CONFIGURATION(Validation); ///@} /// @name MQTT Configuration diff --git a/src/mtconnect/configuration/hook_manager.hpp b/src/mtconnect/configuration/hook_manager.hpp index 4c62cc041..d831146c8 100644 --- a/src/mtconnect/configuration/hook_manager.hpp +++ b/src/mtconnect/configuration/hook_manager.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/configuration/parser.cpp b/src/mtconnect/configuration/parser.cpp index e145441d8..2baeb8e15 100644 --- a/src/mtconnect/configuration/parser.cpp +++ b/src/mtconnect/configuration/parser.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/configuration/parser.hpp b/src/mtconnect/configuration/parser.hpp index 63fe41c3f..13d9bb0d8 100644 --- a/src/mtconnect/configuration/parser.hpp +++ b/src/mtconnect/configuration/parser.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/configuration/service.cpp b/src/mtconnect/configuration/service.cpp index b9669dba0..58ed30689 100644 --- a/src/mtconnect/configuration/service.cpp +++ b/src/mtconnect/configuration/service.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/configuration/service.hpp b/src/mtconnect/configuration/service.hpp index b61b67a81..fca63e1e5 100644 --- a/src/mtconnect/configuration/service.hpp +++ b/src/mtconnect/configuration/service.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/agent_device.cpp b/src/mtconnect/device_model/agent_device.cpp index ef6df6022..dc2e6c6a9 100644 --- a/src/mtconnect/device_model/agent_device.cpp +++ b/src/mtconnect/device_model/agent_device.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/agent_device.hpp b/src/mtconnect/device_model/agent_device.hpp index 6bbe34558..4b693b5e6 100644 --- a/src/mtconnect/device_model/agent_device.hpp +++ b/src/mtconnect/device_model/agent_device.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/component.cpp b/src/mtconnect/device_model/component.cpp index 4935eddaa..779bccc12 100644 --- a/src/mtconnect/device_model/component.cpp +++ b/src/mtconnect/device_model/component.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/component.hpp b/src/mtconnect/device_model/component.hpp index ca0c09d42..911b7a5ad 100644 --- a/src/mtconnect/device_model/component.hpp +++ b/src/mtconnect/device_model/component.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/composition.cpp b/src/mtconnect/device_model/composition.cpp index 923938b34..40f57cd2a 100644 --- a/src/mtconnect/device_model/composition.cpp +++ b/src/mtconnect/device_model/composition.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT The Association For Manufacturing Technology (AMT) +// Copyright Copyright 2009-2024, AMT The Association For Manufacturing Technology (AMT) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/composition.hpp b/src/mtconnect/device_model/composition.hpp index 3ad2046cb..97bdad4c5 100644 --- a/src/mtconnect/device_model/composition.hpp +++ b/src/mtconnect/device_model/composition.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/configuration.cpp b/src/mtconnect/device_model/configuration/configuration.cpp index 4f0a5119f..44cbcaa71 100644 --- a/src/mtconnect/device_model/configuration/configuration.cpp +++ b/src/mtconnect/device_model/configuration/configuration.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/configuration.hpp b/src/mtconnect/device_model/configuration/configuration.hpp index f9f707396..dc01d1f3f 100644 --- a/src/mtconnect/device_model/configuration/configuration.hpp +++ b/src/mtconnect/device_model/configuration/configuration.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/coordinate_systems.cpp b/src/mtconnect/device_model/configuration/coordinate_systems.cpp index d5b96a92c..adc9be6fc 100644 --- a/src/mtconnect/device_model/configuration/coordinate_systems.cpp +++ b/src/mtconnect/device_model/configuration/coordinate_systems.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/coordinate_systems.hpp b/src/mtconnect/device_model/configuration/coordinate_systems.hpp index ea414c33d..8fdc819f3 100644 --- a/src/mtconnect/device_model/configuration/coordinate_systems.hpp +++ b/src/mtconnect/device_model/configuration/coordinate_systems.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/image_file.cpp b/src/mtconnect/device_model/configuration/image_file.cpp index 29d6b9a45..84be05aaa 100644 --- a/src/mtconnect/device_model/configuration/image_file.cpp +++ b/src/mtconnect/device_model/configuration/image_file.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT The Association For Manufacturing Technology (AMT) +// Copyright Copyright 2009-2024, AMT The Association For Manufacturing Technology (AMT) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/image_file.hpp b/src/mtconnect/device_model/configuration/image_file.hpp index 32448fbea..6aac7f61c 100644 --- a/src/mtconnect/device_model/configuration/image_file.hpp +++ b/src/mtconnect/device_model/configuration/image_file.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/motion.cpp b/src/mtconnect/device_model/configuration/motion.cpp index a5ecd8188..5a863a440 100644 --- a/src/mtconnect/device_model/configuration/motion.cpp +++ b/src/mtconnect/device_model/configuration/motion.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT The Association For Manufacturing Technology (AMT) +// Copyright Copyright 2009-2024, AMT The Association For Manufacturing Technology (AMT) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/motion.hpp b/src/mtconnect/device_model/configuration/motion.hpp index ec73c9c27..1594e309d 100644 --- a/src/mtconnect/device_model/configuration/motion.hpp +++ b/src/mtconnect/device_model/configuration/motion.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/relationships.cpp b/src/mtconnect/device_model/configuration/relationships.cpp index bcfba65c1..a2ed6d78f 100644 --- a/src/mtconnect/device_model/configuration/relationships.cpp +++ b/src/mtconnect/device_model/configuration/relationships.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT The Association For Manufacturing Technology (AMT) +// Copyright Copyright 2009-2024, AMT The Association For Manufacturing Technology (AMT) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/relationships.hpp b/src/mtconnect/device_model/configuration/relationships.hpp index 62eeb75ac..c2a6fb462 100644 --- a/src/mtconnect/device_model/configuration/relationships.hpp +++ b/src/mtconnect/device_model/configuration/relationships.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/sensor_configuration.cpp b/src/mtconnect/device_model/configuration/sensor_configuration.cpp index b82abae6c..2bb26ecde 100644 --- a/src/mtconnect/device_model/configuration/sensor_configuration.cpp +++ b/src/mtconnect/device_model/configuration/sensor_configuration.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT The Association For Manufacturing Technology (AMT) +// Copyright Copyright 2009-2024, AMT The Association For Manufacturing Technology (AMT) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/sensor_configuration.hpp b/src/mtconnect/device_model/configuration/sensor_configuration.hpp index 8a4c54b5c..8eeb25b64 100644 --- a/src/mtconnect/device_model/configuration/sensor_configuration.hpp +++ b/src/mtconnect/device_model/configuration/sensor_configuration.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/solid_model.cpp b/src/mtconnect/device_model/configuration/solid_model.cpp index e2341a7fa..6c96236b1 100644 --- a/src/mtconnect/device_model/configuration/solid_model.cpp +++ b/src/mtconnect/device_model/configuration/solid_model.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT The Association For Manufacturing Technology (AMT) +// Copyright Copyright 2009-2024, AMT The Association For Manufacturing Technology (AMT) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/solid_model.hpp b/src/mtconnect/device_model/configuration/solid_model.hpp index 71d60bcfd..fa406d9a5 100644 --- a/src/mtconnect/device_model/configuration/solid_model.hpp +++ b/src/mtconnect/device_model/configuration/solid_model.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/specifications.cpp b/src/mtconnect/device_model/configuration/specifications.cpp index fe74c894c..a4d55bc0c 100644 --- a/src/mtconnect/device_model/configuration/specifications.cpp +++ b/src/mtconnect/device_model/configuration/specifications.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/configuration/specifications.hpp b/src/mtconnect/device_model/configuration/specifications.hpp index 90da6bc3a..226af76a1 100644 --- a/src/mtconnect/device_model/configuration/specifications.hpp +++ b/src/mtconnect/device_model/configuration/specifications.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/data_item/constraints.hpp b/src/mtconnect/device_model/data_item/constraints.hpp index e6b919888..21c362955 100644 --- a/src/mtconnect/device_model/data_item/constraints.hpp +++ b/src/mtconnect/device_model/data_item/constraints.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/data_item/data_item.cpp b/src/mtconnect/device_model/data_item/data_item.cpp index df8d5c331..f65e22381 100644 --- a/src/mtconnect/device_model/data_item/data_item.cpp +++ b/src/mtconnect/device_model/data_item/data_item.cpp @@ -1,6 +1,6 @@ // // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/data_item/data_item.hpp b/src/mtconnect/device_model/data_item/data_item.hpp index 6c4a7803d..1337cd748 100644 --- a/src/mtconnect/device_model/data_item/data_item.hpp +++ b/src/mtconnect/device_model/data_item/data_item.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/data_item/definition.hpp b/src/mtconnect/device_model/data_item/definition.hpp index 69a5d0b5c..f1ba7245b 100644 --- a/src/mtconnect/device_model/data_item/definition.hpp +++ b/src/mtconnect/device_model/data_item/definition.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/data_item/filter.hpp b/src/mtconnect/device_model/data_item/filter.hpp index 0d32733fe..779f6d3cc 100644 --- a/src/mtconnect/device_model/data_item/filter.hpp +++ b/src/mtconnect/device_model/data_item/filter.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/data_item/relationships.hpp b/src/mtconnect/device_model/data_item/relationships.hpp index 47bc187da..10c34c8c3 100644 --- a/src/mtconnect/device_model/data_item/relationships.hpp +++ b/src/mtconnect/device_model/data_item/relationships.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/data_item/source.hpp b/src/mtconnect/device_model/data_item/source.hpp index 561aaa383..e0895282d 100644 --- a/src/mtconnect/device_model/data_item/source.hpp +++ b/src/mtconnect/device_model/data_item/source.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/data_item/unit_conversion.cpp b/src/mtconnect/device_model/data_item/unit_conversion.cpp index 84201a88e..26c853c0c 100644 --- a/src/mtconnect/device_model/data_item/unit_conversion.cpp +++ b/src/mtconnect/device_model/data_item/unit_conversion.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/data_item/unit_conversion.hpp b/src/mtconnect/device_model/data_item/unit_conversion.hpp index c20fd5151..068a43aa7 100644 --- a/src/mtconnect/device_model/data_item/unit_conversion.hpp +++ b/src/mtconnect/device_model/data_item/unit_conversion.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/description.cpp b/src/mtconnect/device_model/description.cpp index fe999e94b..9a7c1cb4f 100644 --- a/src/mtconnect/device_model/description.cpp +++ b/src/mtconnect/device_model/description.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/description.hpp b/src/mtconnect/device_model/description.hpp index c6c5059df..8789eba6f 100644 --- a/src/mtconnect/device_model/description.hpp +++ b/src/mtconnect/device_model/description.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/device.cpp b/src/mtconnect/device_model/device.cpp index bdfed3bdd..e427c02b1 100644 --- a/src/mtconnect/device_model/device.cpp +++ b/src/mtconnect/device_model/device.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/device.hpp b/src/mtconnect/device_model/device.hpp index b811fd79c..d4ae2a80c 100644 --- a/src/mtconnect/device_model/device.hpp +++ b/src/mtconnect/device_model/device.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/reference.cpp b/src/mtconnect/device_model/reference.cpp index c58bb23d0..bc48b32fa 100644 --- a/src/mtconnect/device_model/reference.cpp +++ b/src/mtconnect/device_model/reference.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT The Association For Manufacturing Technology (AMT) +// Copyright Copyright 2009-2024, AMT The Association For Manufacturing Technology (AMT) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/device_model/reference.hpp b/src/mtconnect/device_model/reference.hpp index bb91d55ef..ba9595a5a 100644 --- a/src/mtconnect/device_model/reference.hpp +++ b/src/mtconnect/device_model/reference.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT � The Association For Manufacturing Technology (�AMT�) +// Copyright Copyright 2009-2024, AMT � The Association For Manufacturing Technology (�AMT�) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/data_set.cpp b/src/mtconnect/entity/data_set.cpp index 598d5b811..016f5c302 100644 --- a/src/mtconnect/entity/data_set.cpp +++ b/src/mtconnect/entity/data_set.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/data_set.hpp b/src/mtconnect/entity/data_set.hpp index 1602efb42..0fdaa5983 100644 --- a/src/mtconnect/entity/data_set.hpp +++ b/src/mtconnect/entity/data_set.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/entity.cpp b/src/mtconnect/entity/entity.cpp index 777eb306c..99e0b409c 100644 --- a/src/mtconnect/entity/entity.cpp +++ b/src/mtconnect/entity/entity.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/entity.hpp b/src/mtconnect/entity/entity.hpp index b56eec383..8f45cd319 100644 --- a/src/mtconnect/entity/entity.hpp +++ b/src/mtconnect/entity/entity.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/factory.cpp b/src/mtconnect/entity/factory.cpp index 0d1b24ea6..e763accdd 100644 --- a/src/mtconnect/entity/factory.cpp +++ b/src/mtconnect/entity/factory.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/factory.hpp b/src/mtconnect/entity/factory.hpp index 5b19c0c93..b5e1d411c 100644 --- a/src/mtconnect/entity/factory.hpp +++ b/src/mtconnect/entity/factory.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/json_parser.cpp b/src/mtconnect/entity/json_parser.cpp index 03db5f97c..3976d2fb6 100644 --- a/src/mtconnect/entity/json_parser.cpp +++ b/src/mtconnect/entity/json_parser.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT The Association For Manufacturing Technology (AMT) +// Copyright Copyright 2009-2024, AMT The Association For Manufacturing Technology (AMT) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/json_parser.hpp b/src/mtconnect/entity/json_parser.hpp index 90f2bb015..2fa29a0bb 100644 --- a/src/mtconnect/entity/json_parser.hpp +++ b/src/mtconnect/entity/json_parser.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT � The Association For Manufacturing Technology (�AMT�) +// Copyright Copyright 2009-2024, AMT � The Association For Manufacturing Technology (�AMT�) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/json_printer.hpp b/src/mtconnect/entity/json_printer.hpp index 24e9629ad..424b7617c 100644 --- a/src/mtconnect/entity/json_printer.hpp +++ b/src/mtconnect/entity/json_printer.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/qname.hpp b/src/mtconnect/entity/qname.hpp index 449708404..c2c5b9eda 100644 --- a/src/mtconnect/entity/qname.hpp +++ b/src/mtconnect/entity/qname.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/requirement.cpp b/src/mtconnect/entity/requirement.cpp index e93c7bccc..854fd7e17 100644 --- a/src/mtconnect/entity/requirement.cpp +++ b/src/mtconnect/entity/requirement.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/requirement.hpp b/src/mtconnect/entity/requirement.hpp index 92c57f343..a4a9832bb 100644 --- a/src/mtconnect/entity/requirement.hpp +++ b/src/mtconnect/entity/requirement.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/xml_parser.cpp b/src/mtconnect/entity/xml_parser.cpp index 8fb2c63f1..9c7a37f78 100644 --- a/src/mtconnect/entity/xml_parser.cpp +++ b/src/mtconnect/entity/xml_parser.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/xml_parser.hpp b/src/mtconnect/entity/xml_parser.hpp index 8e66a5f33..d771dc866 100644 --- a/src/mtconnect/entity/xml_parser.hpp +++ b/src/mtconnect/entity/xml_parser.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/xml_printer.cpp b/src/mtconnect/entity/xml_printer.cpp index 97dd96ab3..799cf2561 100644 --- a/src/mtconnect/entity/xml_printer.cpp +++ b/src/mtconnect/entity/xml_printer.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/entity/xml_printer.hpp b/src/mtconnect/entity/xml_printer.hpp index 9d556bbf7..23a8aa5dd 100644 --- a/src/mtconnect/entity/xml_printer.hpp +++ b/src/mtconnect/entity/xml_printer.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/logging.hpp b/src/mtconnect/logging.hpp index 0d21a757e..5e2d613f2 100644 --- a/src/mtconnect/logging.hpp +++ b/src/mtconnect/logging.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/mqtt/mqtt_authorization.hpp b/src/mtconnect/mqtt/mqtt_authorization.hpp index 08105aa27..73c79ace2 100644 --- a/src/mtconnect/mqtt/mqtt_authorization.hpp +++ b/src/mtconnect/mqtt/mqtt_authorization.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/mqtt/mqtt_client.hpp b/src/mtconnect/mqtt/mqtt_client.hpp index d1245848a..70c614045 100644 --- a/src/mtconnect/mqtt/mqtt_client.hpp +++ b/src/mtconnect/mqtt/mqtt_client.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/mqtt/mqtt_client_impl.hpp b/src/mtconnect/mqtt/mqtt_client_impl.hpp index dc1747d4e..0a20377dd 100644 --- a/src/mtconnect/mqtt/mqtt_client_impl.hpp +++ b/src/mtconnect/mqtt/mqtt_client_impl.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/mqtt/mqtt_server.hpp b/src/mtconnect/mqtt/mqtt_server.hpp index 55a0ccf2e..8d38700a9 100644 --- a/src/mtconnect/mqtt/mqtt_server.hpp +++ b/src/mtconnect/mqtt/mqtt_server.hpp @@ -1,5 +1,5 @@ -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. diff --git a/src/mtconnect/mqtt/mqtt_server_impl.hpp b/src/mtconnect/mqtt/mqtt_server_impl.hpp index 13bd773b8..4c3b05715 100644 --- a/src/mtconnect/mqtt/mqtt_server_impl.hpp +++ b/src/mtconnect/mqtt/mqtt_server_impl.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/observation/change_observer.cpp b/src/mtconnect/observation/change_observer.cpp index bdf4143e4..88b5c5da4 100644 --- a/src/mtconnect/observation/change_observer.cpp +++ b/src/mtconnect/observation/change_observer.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/observation/change_observer.hpp b/src/mtconnect/observation/change_observer.hpp index f08ca61ae..3f4e5c2eb 100644 --- a/src/mtconnect/observation/change_observer.hpp +++ b/src/mtconnect/observation/change_observer.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/observation/observation.cpp b/src/mtconnect/observation/observation.cpp index 2a6c33dd5..fc8c56282 100644 --- a/src/mtconnect/observation/observation.cpp +++ b/src/mtconnect/observation/observation.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -41,15 +41,18 @@ namespace mtconnect { static FactoryPtr factory; if (!factory) { - factory = make_shared(Requirements({{"dataItemId", true}, - {"timestamp", ValueType::TIMESTAMP, true}, - {"sequence", false}, - {"subType", false}, - {"name", false}, - {"compositionId", false}}), - [](const std::string &name, Properties &props) -> EntityPtr { - return make_shared(name, props); - }); + factory = make_shared( + Requirements({{"dataItemId", true}, + {"timestamp", ValueType::TIMESTAMP, true}, + {"sequence", false}, + {"subType", false}, + {"name", false}, + {"compositionId", false}, + {"quality", ControlledVocab {"VALID", "INVALID", "UNVERIFIABLE"}, false}, + {"deprecated", ValueType::BOOL, false}}), + [](const std::string &name, Properties &props) -> EntityPtr { + return make_shared(name, props); + }); factory->registerFactory("Events:Message", Message::getFactory()); factory->registerFactory("Events:MessageDiscrete", Message::getFactory()); diff --git a/src/mtconnect/observation/observation.hpp b/src/mtconnect/observation/observation.hpp index ffc0f3d0f..bc2e48537 100644 --- a/src/mtconnect/observation/observation.hpp +++ b/src/mtconnect/observation/observation.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/parser/xml_parser.cpp b/src/mtconnect/parser/xml_parser.cpp index 14b4199ca..6485ecfef 100644 --- a/src/mtconnect/parser/xml_parser.cpp +++ b/src/mtconnect/parser/xml_parser.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/parser/xml_parser.hpp b/src/mtconnect/parser/xml_parser.hpp index eff7ac9cb..e5747c987 100644 --- a/src/mtconnect/parser/xml_parser.hpp +++ b/src/mtconnect/parser/xml_parser.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/convert_sample.hpp b/src/mtconnect/pipeline/convert_sample.hpp index 854109bbb..90dc9e907 100644 --- a/src/mtconnect/pipeline/convert_sample.hpp +++ b/src/mtconnect/pipeline/convert_sample.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/deliver.cpp b/src/mtconnect/pipeline/deliver.cpp index 19f390ea6..bdaa044cb 100644 --- a/src/mtconnect/pipeline/deliver.cpp +++ b/src/mtconnect/pipeline/deliver.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/deliver.hpp b/src/mtconnect/pipeline/deliver.hpp index 47e615b2a..f48b45080 100644 --- a/src/mtconnect/pipeline/deliver.hpp +++ b/src/mtconnect/pipeline/deliver.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/delta_filter.hpp b/src/mtconnect/pipeline/delta_filter.hpp index d84a8084b..313f92e49 100644 --- a/src/mtconnect/pipeline/delta_filter.hpp +++ b/src/mtconnect/pipeline/delta_filter.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/duplicate_filter.hpp b/src/mtconnect/pipeline/duplicate_filter.hpp index 21f5e49d1..c9fbf09d0 100644 --- a/src/mtconnect/pipeline/duplicate_filter.hpp +++ b/src/mtconnect/pipeline/duplicate_filter.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/guard.hpp b/src/mtconnect/pipeline/guard.hpp index 43bf83a23..98cb89dca 100644 --- a/src/mtconnect/pipeline/guard.hpp +++ b/src/mtconnect/pipeline/guard.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/json_mapper.cpp b/src/mtconnect/pipeline/json_mapper.cpp index b81214d53..7bf8dbc1b 100644 --- a/src/mtconnect/pipeline/json_mapper.cpp +++ b/src/mtconnect/pipeline/json_mapper.cpp @@ -1,4 +1,4 @@ -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/json_mapper.hpp b/src/mtconnect/pipeline/json_mapper.hpp index e2c75dcbb..d437a6b5f 100644 --- a/src/mtconnect/pipeline/json_mapper.hpp +++ b/src/mtconnect/pipeline/json_mapper.hpp @@ -1,4 +1,4 @@ -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/message_mapper.hpp b/src/mtconnect/pipeline/message_mapper.hpp index 9588e4465..7f84e078a 100644 --- a/src/mtconnect/pipeline/message_mapper.hpp +++ b/src/mtconnect/pipeline/message_mapper.hpp @@ -1,4 +1,4 @@ -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/mtconnect_xml_transform.hpp b/src/mtconnect/pipeline/mtconnect_xml_transform.hpp index 4236cd467..269913336 100644 --- a/src/mtconnect/pipeline/mtconnect_xml_transform.hpp +++ b/src/mtconnect/pipeline/mtconnect_xml_transform.hpp @@ -1,4 +1,4 @@ -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/period_filter.hpp b/src/mtconnect/pipeline/period_filter.hpp index 4d2826382..6baf6545e 100644 --- a/src/mtconnect/pipeline/period_filter.hpp +++ b/src/mtconnect/pipeline/period_filter.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/pipeline.hpp b/src/mtconnect/pipeline/pipeline.hpp index 1ee849233..c16b9e334 100644 --- a/src/mtconnect/pipeline/pipeline.hpp +++ b/src/mtconnect/pipeline/pipeline.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/pipeline_context.hpp b/src/mtconnect/pipeline/pipeline_context.hpp index bd451f150..42e55b554 100644 --- a/src/mtconnect/pipeline/pipeline_context.hpp +++ b/src/mtconnect/pipeline/pipeline_context.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/pipeline_contract.hpp b/src/mtconnect/pipeline/pipeline_contract.hpp index 4de67eb11..ace303522 100644 --- a/src/mtconnect/pipeline/pipeline_contract.hpp +++ b/src/mtconnect/pipeline/pipeline_contract.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/response_document.cpp b/src/mtconnect/pipeline/response_document.cpp index aaa1b4066..419d4e6eb 100644 --- a/src/mtconnect/pipeline/response_document.cpp +++ b/src/mtconnect/pipeline/response_document.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/response_document.hpp b/src/mtconnect/pipeline/response_document.hpp index 1a915f001..f61016526 100644 --- a/src/mtconnect/pipeline/response_document.hpp +++ b/src/mtconnect/pipeline/response_document.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/shdr_token_mapper.cpp b/src/mtconnect/pipeline/shdr_token_mapper.cpp index 3a65ceabe..a7bc983e2 100644 --- a/src/mtconnect/pipeline/shdr_token_mapper.cpp +++ b/src/mtconnect/pipeline/shdr_token_mapper.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/shdr_token_mapper.hpp b/src/mtconnect/pipeline/shdr_token_mapper.hpp index 23f45a9dc..f12c192d6 100644 --- a/src/mtconnect/pipeline/shdr_token_mapper.hpp +++ b/src/mtconnect/pipeline/shdr_token_mapper.hpp @@ -1,4 +1,4 @@ -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/shdr_tokenizer.hpp b/src/mtconnect/pipeline/shdr_tokenizer.hpp index 5512d7ca9..a9c3d31f0 100644 --- a/src/mtconnect/pipeline/shdr_tokenizer.hpp +++ b/src/mtconnect/pipeline/shdr_tokenizer.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/timestamp_extractor.hpp b/src/mtconnect/pipeline/timestamp_extractor.hpp index 48ceb602f..4164e8fe7 100644 --- a/src/mtconnect/pipeline/timestamp_extractor.hpp +++ b/src/mtconnect/pipeline/timestamp_extractor.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/topic_mapper.hpp b/src/mtconnect/pipeline/topic_mapper.hpp index 3d0067713..7aa52887e 100644 --- a/src/mtconnect/pipeline/topic_mapper.hpp +++ b/src/mtconnect/pipeline/topic_mapper.hpp @@ -1,4 +1,4 @@ -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/transform.hpp b/src/mtconnect/pipeline/transform.hpp index 917237bc3..6fbf9d3a5 100644 --- a/src/mtconnect/pipeline/transform.hpp +++ b/src/mtconnect/pipeline/transform.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/pipeline/upcase_value.hpp b/src/mtconnect/pipeline/upcase_value.hpp index b95bb24ad..fae0d1a42 100644 --- a/src/mtconnect/pipeline/upcase_value.hpp +++ b/src/mtconnect/pipeline/upcase_value.hpp @@ -1,4 +1,4 @@ -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/printer/json_printer.cpp b/src/mtconnect/printer/json_printer.cpp index 1108d0878..2720d5eaa 100644 --- a/src/mtconnect/printer/json_printer.cpp +++ b/src/mtconnect/printer/json_printer.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -47,8 +47,8 @@ namespace mtconnect::printer { using namespace device_model; using namespace rapidjson; - JsonPrinter::JsonPrinter(uint32_t jsonVersion, bool pretty) - : Printer(pretty), m_jsonVersion(jsonVersion) + JsonPrinter::JsonPrinter(uint32_t jsonVersion, bool pretty, bool validation) + : Printer(pretty, validation), m_jsonVersion(jsonVersion) { NAMED_SCOPE("JsonPrinter::JsonPrinter"); char appVersion[32] = {0}; @@ -60,7 +60,8 @@ namespace mtconnect::printer { template inline void header(AutoJsonObject &obj, const string &version, const string &hostname, const uint64_t instanceId, const unsigned int bufferSize, - const string &schemaVersion, const string modelChangeTime) + const string &schemaVersion, const string modelChangeTime, + bool validation) { obj.AddPairs("version", version, "creationTime", getCurrentTime(GMT), "testIndicator", false, "instanceId", instanceId, "sender", hostname, "schemaVersion", schemaVersion); @@ -69,6 +70,9 @@ namespace mtconnect::printer { obj.AddPairs("deviceModelChangeTime", modelChangeTime); if (bufferSize > 0) obj.AddPairs("bufferSize", bufferSize); + if (validation) + obj.AddPairs("validation", true); + } template @@ -76,9 +80,10 @@ namespace mtconnect::printer { const string &hostname, const uint64_t instanceId, const unsigned int bufferSize, const unsigned int assetBufferSize, const unsigned int assetCount, const string &schemaVersion, - const string modelChangeTime) + const string modelChangeTime, + const bool validation) { - header(obj, version, hostname, instanceId, bufferSize, schemaVersion, modelChangeTime); + header(obj, version, hostname, instanceId, bufferSize, schemaVersion, modelChangeTime, validation); obj.AddPairs("assetBufferSize", assetBufferSize, "assetCount", assetCount); } @@ -87,9 +92,10 @@ namespace mtconnect::printer { const uint64_t instanceId, const unsigned int bufferSize, const uint64_t nextSequence, const uint64_t firstSequence, const uint64_t lastSequence, const string &schemaVersion, - const string modelChangeTime) + const string modelChangeTime, + const bool validation) { - header(obj, version, hostname, instanceId, bufferSize, schemaVersion, modelChangeTime); + header(obj, version, hostname, instanceId, bufferSize, schemaVersion, modelChangeTime, validation); obj.AddPairs("nextSequence", nextSequence, "lastSequence", lastSequence, "firstSequence", firstSequence); } @@ -123,7 +129,7 @@ namespace mtconnect::printer { { AutoJsonObject obj(writer, "Header"); header(obj, m_version, m_senderName, instanceId, bufferSize, *m_schemaVersion, - m_modelChangeTime); + m_modelChangeTime, m_validation); } { if (m_jsonVersion > 1) @@ -180,7 +186,7 @@ namespace mtconnect::printer { { AutoJsonObject obj(writer, "Header"); probeAssetHeader(obj, m_version, m_senderName, instanceId, bufferSize, assetBufferSize, - assetCount, *m_schemaVersion, m_modelChangeTime); + assetCount, *m_schemaVersion, m_modelChangeTime, m_validation); } { obj.Key("Devices"); @@ -207,7 +213,8 @@ namespace mtconnect::printer { { AutoJsonObject obj(writer, "Header"); probeAssetHeader(obj, m_version, m_senderName, instanceId, 0, bufferSize, assetCount, - *m_schemaVersion, m_modelChangeTime); + *m_schemaVersion, m_modelChangeTime, + m_validation); } { obj.Key("Assets"); @@ -405,7 +412,8 @@ namespace mtconnect::printer { { AutoJsonObject obj(writer, "Header"); streamHeader(obj, m_version, m_senderName, instanceId, bufferSize, nextSeq, firstSeq, - lastSeq, *m_schemaVersion, m_modelChangeTime); + lastSeq, *m_schemaVersion, m_modelChangeTime, + m_validation); } { diff --git a/src/mtconnect/printer/json_printer.hpp b/src/mtconnect/printer/json_printer.hpp index 2a1e4ea96..fd392133a 100644 --- a/src/mtconnect/printer/json_printer.hpp +++ b/src/mtconnect/printer/json_printer.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -27,7 +27,7 @@ namespace mtconnect::printer { class AGENT_LIB_API JsonPrinter : public Printer { public: - JsonPrinter(uint32_t jsonVersion, bool pretty = false); + JsonPrinter(uint32_t jsonVersion, bool pretty = false, bool validation = false); ~JsonPrinter() override = default; std::string printErrors(const uint64_t instanceId, const unsigned int bufferSize, diff --git a/src/mtconnect/printer/json_printer_helper.hpp b/src/mtconnect/printer/json_printer_helper.hpp index e8bb39b00..61b843e33 100644 --- a/src/mtconnect/printer/json_printer_helper.hpp +++ b/src/mtconnect/printer/json_printer_helper.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/printer/printer.hpp b/src/mtconnect/printer/printer.hpp index cfc0bd270..4e39cb0a8 100644 --- a/src/mtconnect/printer/printer.hpp +++ b/src/mtconnect/printer/printer.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -49,7 +49,7 @@ namespace mtconnect { public: /// @brief construct a printer /// @param pretty `true` if content should be pretty printed - Printer(bool pretty = false) : m_pretty(pretty) {} + Printer(bool pretty = false, bool validation = false) : m_pretty(pretty), m_validation(validation) {} virtual ~Printer() = default; /// @brief Generate an MTConnect Error document @@ -145,9 +145,19 @@ namespace mtconnect { const_cast(this)->m_schemaVersion.emplace(ver); } } + + /// @brief Get validation header flag state + /// @returns validation state + bool getValidation() const { return m_validation; } + + /// @brief sets validation state + /// @param validation the validation state + void setValidation(bool v) { m_validation = v; } + protected: - bool m_pretty; + bool m_pretty; //< Turns pretty printing on + bool m_validation; //< Sets validation flag in header std::string m_modelChangeTime; std::optional m_schemaVersion; std::string m_senderName {"localhost"}; diff --git a/src/mtconnect/printer/xml_helper.hpp b/src/mtconnect/printer/xml_helper.hpp index 94eac2d27..e1758ae55 100644 --- a/src/mtconnect/printer/xml_helper.hpp +++ b/src/mtconnect/printer/xml_helper.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/printer/xml_printer.cpp b/src/mtconnect/printer/xml_printer.cpp index 915193d66..5e0aa1b2e 100644 --- a/src/mtconnect/printer/xml_printer.cpp +++ b/src/mtconnect/printer/xml_printer.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -100,7 +100,7 @@ namespace mtconnect::printer { xmlBufferPtr m_buf; }; - XmlPrinter::XmlPrinter(bool pretty) : Printer(pretty) { NAMED_SCOPE("xml.printer"); } + XmlPrinter::XmlPrinter(bool pretty, bool validation) : Printer(pretty, validation) { NAMED_SCOPE("xml.printer"); } void XmlPrinter::addDevicesNamespace(const std::string &urn, const std::string &location, const std::string &prefix) @@ -636,6 +636,9 @@ namespace mtconnect::printer { addAttribute(writer, "sender", m_senderName); addAttribute(writer, "instanceId", to_string(instanceId)); + + if (m_validation) + addAttribute(writer, "instanceId", "true"s); char version[32] = {0}; sprintf(version, "%d.%d.%d.%d", AGENT_VERSION_MAJOR, AGENT_VERSION_MINOR, AGENT_VERSION_PATCH, diff --git a/src/mtconnect/printer/xml_printer.hpp b/src/mtconnect/printer/xml_printer.hpp index bb4e0c2df..781a297cb 100644 --- a/src/mtconnect/printer/xml_printer.hpp +++ b/src/mtconnect/printer/xml_printer.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -40,7 +40,7 @@ namespace mtconnect { class AGENT_LIB_API XmlPrinter : public Printer { public: - XmlPrinter(bool pretty = false); + XmlPrinter(bool pretty = false, bool validation = false); ~XmlPrinter() override = default; std::string printErrors(const uint64_t instanceId, const unsigned int bufferSize, diff --git a/src/mtconnect/printer/xml_printer_helper.hpp b/src/mtconnect/printer/xml_printer_helper.hpp index 64eab3aa1..3ac60e91a 100644 --- a/src/mtconnect/printer/xml_printer_helper.hpp +++ b/src/mtconnect/printer/xml_printer_helper.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/ruby/embedded.cpp b/src/mtconnect/ruby/embedded.cpp index 6c5538cc8..4942b6885 100644 --- a/src/mtconnect/ruby/embedded.cpp +++ b/src/mtconnect/ruby/embedded.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/ruby/embedded.hpp b/src/mtconnect/ruby/embedded.hpp index 7caec3103..38a5a1102 100644 --- a/src/mtconnect/ruby/embedded.hpp +++ b/src/mtconnect/ruby/embedded.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/ruby/ruby_agent.hpp b/src/mtconnect/ruby/ruby_agent.hpp index 00da26c58..954fff2da 100644 --- a/src/mtconnect/ruby/ruby_agent.hpp +++ b/src/mtconnect/ruby/ruby_agent.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/ruby/ruby_entity.hpp b/src/mtconnect/ruby/ruby_entity.hpp index 6ba905097..6302afe4d 100644 --- a/src/mtconnect/ruby/ruby_entity.hpp +++ b/src/mtconnect/ruby/ruby_entity.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/ruby/ruby_observation.hpp b/src/mtconnect/ruby/ruby_observation.hpp index a41586214..df0dec968 100644 --- a/src/mtconnect/ruby/ruby_observation.hpp +++ b/src/mtconnect/ruby/ruby_observation.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/ruby/ruby_pipeline.hpp b/src/mtconnect/ruby/ruby_pipeline.hpp index beb10a3c4..0e1bf5312 100644 --- a/src/mtconnect/ruby/ruby_pipeline.hpp +++ b/src/mtconnect/ruby/ruby_pipeline.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/ruby/ruby_smart_ptr.hpp b/src/mtconnect/ruby/ruby_smart_ptr.hpp index 97e34f3d3..a8c23106f 100644 --- a/src/mtconnect/ruby/ruby_smart_ptr.hpp +++ b/src/mtconnect/ruby/ruby_smart_ptr.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/ruby/ruby_transform.hpp b/src/mtconnect/ruby/ruby_transform.hpp index 4dc9c4cdf..94693b29d 100644 --- a/src/mtconnect/ruby/ruby_transform.hpp +++ b/src/mtconnect/ruby/ruby_transform.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/ruby/ruby_type.hpp b/src/mtconnect/ruby/ruby_type.hpp index 34641cd3b..087b0e8fd 100644 --- a/src/mtconnect/ruby/ruby_type.hpp +++ b/src/mtconnect/ruby/ruby_type.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/ruby/ruby_vm.hpp b/src/mtconnect/ruby/ruby_vm.hpp index d33134ba9..39267a2e2 100644 --- a/src/mtconnect/ruby/ruby_vm.hpp +++ b/src/mtconnect/ruby/ruby_vm.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/mqtt_sink/mqtt_service.cpp b/src/mtconnect/sink/mqtt_sink/mqtt_service.cpp index 6a2f54e59..b28b72d0f 100644 --- a/src/mtconnect/sink/mqtt_sink/mqtt_service.cpp +++ b/src/mtconnect/sink/mqtt_sink/mqtt_service.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/mqtt_sink/mqtt_service.hpp b/src/mtconnect/sink/mqtt_sink/mqtt_service.hpp index 3b89b2cea..e94d01f55 100644 --- a/src/mtconnect/sink/mqtt_sink/mqtt_service.hpp +++ b/src/mtconnect/sink/mqtt_sink/mqtt_service.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/cached_file.hpp b/src/mtconnect/sink/rest_sink/cached_file.hpp index da2ca52f5..40efea4fb 100644 --- a/src/mtconnect/sink/rest_sink/cached_file.hpp +++ b/src/mtconnect/sink/rest_sink/cached_file.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/file_cache.cpp b/src/mtconnect/sink/rest_sink/file_cache.cpp index d230a490e..07d31e182 100644 --- a/src/mtconnect/sink/rest_sink/file_cache.cpp +++ b/src/mtconnect/sink/rest_sink/file_cache.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/file_cache.hpp b/src/mtconnect/sink/rest_sink/file_cache.hpp index 5ee445a7c..f5125ccd3 100644 --- a/src/mtconnect/sink/rest_sink/file_cache.hpp +++ b/src/mtconnect/sink/rest_sink/file_cache.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/parameter.hpp b/src/mtconnect/sink/rest_sink/parameter.hpp index 9eea8feeb..cb2879c34 100644 --- a/src/mtconnect/sink/rest_sink/parameter.hpp +++ b/src/mtconnect/sink/rest_sink/parameter.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/request.hpp b/src/mtconnect/sink/rest_sink/request.hpp index f62f37dbe..ebff06028 100644 --- a/src/mtconnect/sink/rest_sink/request.hpp +++ b/src/mtconnect/sink/rest_sink/request.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/response.hpp b/src/mtconnect/sink/rest_sink/response.hpp index f8ae3c98e..a67bdbe6b 100644 --- a/src/mtconnect/sink/rest_sink/response.hpp +++ b/src/mtconnect/sink/rest_sink/response.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/rest_service.cpp b/src/mtconnect/sink/rest_sink/rest_service.cpp index 6e123ed84..9237a4645 100644 --- a/src/mtconnect/sink/rest_sink/rest_service.cpp +++ b/src/mtconnect/sink/rest_sink/rest_service.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/rest_service.hpp b/src/mtconnect/sink/rest_sink/rest_service.hpp index 3e8091cb0..51505fd51 100644 --- a/src/mtconnect/sink/rest_sink/rest_service.hpp +++ b/src/mtconnect/sink/rest_sink/rest_service.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/routing.hpp b/src/mtconnect/sink/rest_sink/routing.hpp index 10d852a98..ca8bdf38d 100644 --- a/src/mtconnect/sink/rest_sink/routing.hpp +++ b/src/mtconnect/sink/rest_sink/routing.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/server.cpp b/src/mtconnect/sink/rest_sink/server.cpp index 93b387e1f..7071c02ee 100644 --- a/src/mtconnect/sink/rest_sink/server.cpp +++ b/src/mtconnect/sink/rest_sink/server.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/server.hpp b/src/mtconnect/sink/rest_sink/server.hpp index 07c5c4b59..d72fd1764 100644 --- a/src/mtconnect/sink/rest_sink/server.hpp +++ b/src/mtconnect/sink/rest_sink/server.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/session.hpp b/src/mtconnect/sink/rest_sink/session.hpp index a6443f782..c4ed9041a 100644 --- a/src/mtconnect/sink/rest_sink/session.hpp +++ b/src/mtconnect/sink/rest_sink/session.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/session_impl.cpp b/src/mtconnect/sink/rest_sink/session_impl.cpp index 93aae58f7..43b3cbdea 100644 --- a/src/mtconnect/sink/rest_sink/session_impl.cpp +++ b/src/mtconnect/sink/rest_sink/session_impl.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/session_impl.hpp b/src/mtconnect/sink/rest_sink/session_impl.hpp index 404d25b9c..539c3ece3 100644 --- a/src/mtconnect/sink/rest_sink/session_impl.hpp +++ b/src/mtconnect/sink/rest_sink/session_impl.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/rest_sink/tls_dector.hpp b/src/mtconnect/sink/rest_sink/tls_dector.hpp index 197e9a91b..cf8065899 100644 --- a/src/mtconnect/sink/rest_sink/tls_dector.hpp +++ b/src/mtconnect/sink/rest_sink/tls_dector.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/sink.cpp b/src/mtconnect/sink/sink.cpp index 4fb757485..1a65d10f9 100644 --- a/src/mtconnect/sink/sink.cpp +++ b/src/mtconnect/sink/sink.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/sink/sink.hpp b/src/mtconnect/sink/sink.hpp index 1e517284d..c06d0e1c4 100644 --- a/src/mtconnect/sink/sink.hpp +++ b/src/mtconnect/sink/sink.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/adapter.hpp b/src/mtconnect/source/adapter/adapter.hpp index f27ffc03a..7052d6d87 100644 --- a/src/mtconnect/source/adapter/adapter.hpp +++ b/src/mtconnect/source/adapter/adapter.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/adapter_pipeline.cpp b/src/mtconnect/source/adapter/adapter_pipeline.cpp index 741cabdfb..16a3dd505 100644 --- a/src/mtconnect/source/adapter/adapter_pipeline.cpp +++ b/src/mtconnect/source/adapter/adapter_pipeline.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/adapter_pipeline.hpp b/src/mtconnect/source/adapter/adapter_pipeline.hpp index 3d6155d8e..a21ac3ce3 100644 --- a/src/mtconnect/source/adapter/adapter_pipeline.hpp +++ b/src/mtconnect/source/adapter/adapter_pipeline.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/agent_adapter/agent_adapter.cpp b/src/mtconnect/source/adapter/agent_adapter/agent_adapter.cpp index a38db70a3..8845bbed3 100644 --- a/src/mtconnect/source/adapter/agent_adapter/agent_adapter.cpp +++ b/src/mtconnect/source/adapter/agent_adapter/agent_adapter.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/agent_adapter/agent_adapter.hpp b/src/mtconnect/source/adapter/agent_adapter/agent_adapter.hpp index e949654ac..b7c608005 100644 --- a/src/mtconnect/source/adapter/agent_adapter/agent_adapter.hpp +++ b/src/mtconnect/source/adapter/agent_adapter/agent_adapter.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/agent_adapter/http_session.hpp b/src/mtconnect/source/adapter/agent_adapter/http_session.hpp index 1003a2cd1..2bb063647 100644 --- a/src/mtconnect/source/adapter/agent_adapter/http_session.hpp +++ b/src/mtconnect/source/adapter/agent_adapter/http_session.hpp @@ -1,6 +1,6 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/agent_adapter/https_session.hpp b/src/mtconnect/source/adapter/agent_adapter/https_session.hpp index 0b5b0ad34..4875b06c2 100644 --- a/src/mtconnect/source/adapter/agent_adapter/https_session.hpp +++ b/src/mtconnect/source/adapter/agent_adapter/https_session.hpp @@ -1,6 +1,6 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/agent_adapter/session.hpp b/src/mtconnect/source/adapter/agent_adapter/session.hpp index 89e146829..5edf96986 100644 --- a/src/mtconnect/source/adapter/agent_adapter/session.hpp +++ b/src/mtconnect/source/adapter/agent_adapter/session.hpp @@ -1,6 +1,6 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/agent_adapter/session_impl.hpp b/src/mtconnect/source/adapter/agent_adapter/session_impl.hpp index 43ff13e54..3cfba36d8 100644 --- a/src/mtconnect/source/adapter/agent_adapter/session_impl.hpp +++ b/src/mtconnect/source/adapter/agent_adapter/session_impl.hpp @@ -1,6 +1,6 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/agent_adapter/url_parser.cpp b/src/mtconnect/source/adapter/agent_adapter/url_parser.cpp index b6c3bb17d..1932cd944 100644 --- a/src/mtconnect/source/adapter/agent_adapter/url_parser.cpp +++ b/src/mtconnect/source/adapter/agent_adapter/url_parser.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/agent_adapter/url_parser.hpp b/src/mtconnect/source/adapter/agent_adapter/url_parser.hpp index b14fd0da0..62e1300c7 100644 --- a/src/mtconnect/source/adapter/agent_adapter/url_parser.hpp +++ b/src/mtconnect/source/adapter/agent_adapter/url_parser.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/mqtt/mqtt_adapter.cpp b/src/mtconnect/source/adapter/mqtt/mqtt_adapter.cpp index de1399a03..e673a97ea 100644 --- a/src/mtconnect/source/adapter/mqtt/mqtt_adapter.cpp +++ b/src/mtconnect/source/adapter/mqtt/mqtt_adapter.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/mqtt/mqtt_adapter.hpp b/src/mtconnect/source/adapter/mqtt/mqtt_adapter.hpp index 6d017ad05..66e2554ab 100644 --- a/src/mtconnect/source/adapter/mqtt/mqtt_adapter.hpp +++ b/src/mtconnect/source/adapter/mqtt/mqtt_adapter.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/shdr/connector.cpp b/src/mtconnect/source/adapter/shdr/connector.cpp index 216d4c894..fb7f5979d 100644 --- a/src/mtconnect/source/adapter/shdr/connector.cpp +++ b/src/mtconnect/source/adapter/shdr/connector.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/shdr/connector.hpp b/src/mtconnect/source/adapter/shdr/connector.hpp index 638c0e9dc..d8cd727a8 100644 --- a/src/mtconnect/source/adapter/shdr/connector.hpp +++ b/src/mtconnect/source/adapter/shdr/connector.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/shdr/shdr_adapter.cpp b/src/mtconnect/source/adapter/shdr/shdr_adapter.cpp index d3c685ab2..a96e27c53 100644 --- a/src/mtconnect/source/adapter/shdr/shdr_adapter.cpp +++ b/src/mtconnect/source/adapter/shdr/shdr_adapter.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/shdr/shdr_adapter.hpp b/src/mtconnect/source/adapter/shdr/shdr_adapter.hpp index d04519a26..4b40f514c 100644 --- a/src/mtconnect/source/adapter/shdr/shdr_adapter.hpp +++ b/src/mtconnect/source/adapter/shdr/shdr_adapter.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/shdr/shdr_pipeline.cpp b/src/mtconnect/source/adapter/shdr/shdr_pipeline.cpp index 2a2f6d55a..45116061e 100644 --- a/src/mtconnect/source/adapter/shdr/shdr_pipeline.cpp +++ b/src/mtconnect/source/adapter/shdr/shdr_pipeline.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/adapter/shdr/shdr_pipeline.hpp b/src/mtconnect/source/adapter/shdr/shdr_pipeline.hpp index 5962834f1..f975ee4f2 100644 --- a/src/mtconnect/source/adapter/shdr/shdr_pipeline.hpp +++ b/src/mtconnect/source/adapter/shdr/shdr_pipeline.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/error_code.hpp b/src/mtconnect/source/error_code.hpp index 32f7b4bd2..af3164bb5 100644 --- a/src/mtconnect/source/error_code.hpp +++ b/src/mtconnect/source/error_code.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/loopback_source.cpp b/src/mtconnect/source/loopback_source.cpp index 9befdcf16..6cfbcdc6a 100644 --- a/src/mtconnect/source/loopback_source.cpp +++ b/src/mtconnect/source/loopback_source.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/loopback_source.hpp b/src/mtconnect/source/loopback_source.hpp index cd396e041..42734c076 100644 --- a/src/mtconnect/source/loopback_source.hpp +++ b/src/mtconnect/source/loopback_source.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/source.cpp b/src/mtconnect/source/source.cpp index 5cc0322c3..eb1f8c59a 100644 --- a/src/mtconnect/source/source.cpp +++ b/src/mtconnect/source/source.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/source/source.hpp b/src/mtconnect/source/source.hpp index cdacfb9f5..4debdafb6 100644 --- a/src/mtconnect/source/source.hpp +++ b/src/mtconnect/source/source.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/utilities.cpp b/src/mtconnect/utilities.cpp index 898daf409..e36bd2f53 100644 --- a/src/mtconnect/utilities.cpp +++ b/src/mtconnect/utilities.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/utilities.hpp b/src/mtconnect/utilities.hpp index 8f668b443..87e0110ad 100644 --- a/src/mtconnect/utilities.hpp +++ b/src/mtconnect/utilities.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/src/mtconnect/validation/observation_validations.hpp b/src/mtconnect/validation/observation_validations.hpp new file mode 100644 index 000000000..24af87c85 --- /dev/null +++ b/src/mtconnect/validation/observation_validations.hpp @@ -0,0 +1,39 @@ + Validation ControlledVocabularies { + {"ACTUATOR_STATE", {{"ACTIVE", 0}, {"INACTIVE", 0}}}, + {"AVAILABILITY", {{"AVAILABLE", 0}, {"UNAVAILABLE", 0}}}, + {"AXIS_COUPLING", {{"TANDEM", 0}, {"SYNCHRONOUS", 0}, {"MASTER", 0}, {"SLAVE", 0}}}, + {"AXIS_INTERLOCK", {{"ACTIVE", 0}, {"INACTIVE", 0}}}, + {"AXIS_STATE", {{"HOME", 0}, {"TRAVEL", 0}, {"PARKED", 0}, {"STOPPED", 0}}}, + {"CHUCK_INTERLOCK", {{"ACTIVE", 0}, {"INACTIVE", 0}}}, + {"CHUCK_STATE", {{"OPEN", 0}, {"CLOSED", 0}, {"UNLATCHED", 0}}}, + {"CONTROLLER_MODE", {{"AUTOMATIC", 0}, {"MANUAL", 0}, {"MANUAL_DATA_INPUT", 0}, {"SEMI_AUTOMATIC", 0}, {"EDIT", 0}, {"FEED_HOLD", SCHEMA_VERSION(1, 3)}}}, + {"CONTROLLER_MODE_OVERRIDE", {{"ON", 0}, {"OFF", 0}}}, + {"DIRECTION", {{"CLOCKWISE", SCHEMA_VERSION(1, 4)}, {"COUNTER_CLOCKWISE", SCHEMA_VERSION(1, 4)}, {"POSITIVE", SCHEMA_VERSION(1, 4)}, {"NEGATIVE", SCHEMA_VERSION(1, 4)}}}, + {"DOOR_STATE", {{"OPEN", 0}, {"CLOSED", 0}, {"UNLATCHED", 0}}}, + {"EMERGENCY_STOP", {{"ARMED", 0}, {"TRIGGERED", 0}}}, + {"END_OF_BAR", {{"YES", 0}, {"NO", 0}}}, + {"EQUIPMENT_MODE", {{"ON", 0}, {"OFF", 0}}}, + {"EXECUTION", {{"READY", 0}, {"ACTIVE", 0}, {"INTERRUPTED", 0}, {"FEED_HOLD", 0}, {"STOPPED", 0}, {"OPTIONAL_STOP", 0}, {"PROGRAM_STOPPED", 0}, {"PROGRAM_COMPLETED", 0}, {"WAIT", 0}, {"PROGRAM_OPTIONAL_STOP", SCHEMA_VERSION(1, 4)}}}, + {"FUNCTIONAL_MODE", {{"PRODUCTION", 0}, {"SETUP", 0}, {"TEARDOWN", 0}, {"MAINTENANCE", 0}, {"PROCESS_DEVELOPMENT", 0}}}, + {"PART_DETECT", {{"PRESENT", 0}, {"NOT_PRESENT", 0}}}, + {"PATH_MODE", {{"INDEPENDENT", 0}, {"MASTER", 0}, {"SYNCHRONOUS", 0}, {"MIRROR", 0}}}, + {"POWER_STATE", {{"ON", 0}, {"OFF", 0}}}, + {"POWER_STATUS", {{"ON", SCHEMA_VERSION(1, 1)}, {"OFF", SCHEMA_VERSION(1, 1)}}}, + {"PROGRAM_EDIT", {{"ACTIVE", 0}, {"READY", 0}, {"NOT_READY", 0}}}, + {"PROGRAM_LOCATION_TYPE", {{"LOCAL", 0}, {"EXTERNAL", 0}}}, + {"ROTARY_MODE", {{"SPINDLE", 0}, {"INDEX", 0}, {"CONTOUR", 0}}}, + {"SPINDLE_INTERLOCK", {{"ACTIVE", 0}, {"INACTIVE", 0}}}, + {"WAIT_STATE", {{"POWERING_UP", 0}, {"POWERING_DOWN", 0}, {"PART_LOAD", 0}, {"PART_UNLOAD", 0}, {"TOOL_LOAD", 0}, {"TOOL_UNLOAD", 0}, {"MATERIAL_LOAD", 0}, {"MATERIAL_UNLOAD", 0}, {"SECONDARY_PROCESS", 0}, {"PAUSING", 0}, {"RESUMING", 0}}}, + {"PART_STATUS", {{"PASS", 0}, {"FAIL", 0}}}, + {"CONNECTION_STATUS", {{"CLOSED", 0}, {"LISTEN", 0}, {"ESTABLISHED", 0}}}, + {"PART_PROCESSING_STATE", {{"NEEDS_PROCESSING", 0}, {"IN_PROCESS", 0}, {"PROCESSING_ENDED", 0}, {"PROCESSING_ENDED_COMPLETE", 0}, {"PROCESSING_ENDED_STOPPED", 0}, {"PROCESSING_ENDED_ABORTED", 0}, {"PROCESSING_ENDED_LOST", 0}, {"PROCESSING_ENDED_SKIPPED", 0}, {"PROCESSING_ENDED_REJECTED", 0}, {"WAITING_FOR_TRANSIT", 0}, {"IN_TRANSIT", 0}, {"TRANSIT_COMPLETE", 0}}}, + {"PROCESS_STATE", {{"INITIALIZING", 0}, {"READY", 0}, {"ACTIVE", 0}, {"COMPLETE", 0}, {"INTERRUPTED", 0}, {"ABORTED", 0}}}, + {"VALVE_STATE", {{"OPEN", 0}, {"OPENING", 0}, {"CLOSED", 0}, {"CLOSING", 0}}}, + {"LOCK_STATE", {{"LOCKED", 0}, {"UNLOCKED", 0}}}, + {"OPERATING_MODE", {{"AUTOMATIC", 0}, {"MANUAL", 0}, {"SEMI_AUTOMATIC", 0}}}, + {"PART_COUNT_TYPE", {{"EACH", 0}, {"BATCH", 0}}}, + {"LEAK_DETECT", {{"DETECTED", 0}, {"NOT_DETECTED", 0}}}, + {"BATTERY_STATE", {{"CHARGED", 0}, {"CHARGING", 0}, {"DISCHARGING", 0}, {"DISCHARGED", 0}}}, + {"ADAPTER_URI", {{"PASS", 0}, {"FAIL", 0}, {"REWORK", 0}, {"SYSTEM_ERROR", 0}, {"INDETERMINATE", 0}, {"NOT_ANALYZED", 0}, {"BASIC_OR_THEORETIC_EXACT_DIMENSION", 0}, {"UNDEFINED", 0}}}, + {"UNCERTAINTY_TYPE", {{"COMBINED", 0}, {"MEAN", 0}}} + }; diff --git a/src/mtconnect/validation/observations.cpp b/src/mtconnect/validation/observations.cpp new file mode 100644 index 000000000..4f2825a5d --- /dev/null +++ b/src/mtconnect/validation/observations.cpp @@ -0,0 +1,22 @@ +// +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) +// All rights reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// + +#include "observations.hpp" + +namespace mtconnect::validation::observations { +#include "observation_validations.hpp" +} diff --git a/src/mtconnect/validation/observations.hpp b/src/mtconnect/validation/observations.hpp new file mode 100644 index 000000000..f540d6131 --- /dev/null +++ b/src/mtconnect/validation/observations.hpp @@ -0,0 +1,29 @@ +// +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) +// All rights reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// + +#pragma once + +#include "../utilities.hpp" + +#include +#include + +namespace mtconnect::validation::observations { + using Validation = std::unordered_map>; + + extern Validation ControlledVocabularies; +} diff --git a/src/mtconnect/version.cpp b/src/mtconnect/version.cpp index b27f769f2..8a082fb36 100644 --- a/src/mtconnect/version.cpp +++ b/src/mtconnect/version.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/adapter_test.cpp b/test_package/adapter_test.cpp index 8fa5eba8b..58712ec98 100644 --- a/test_package/adapter_test.cpp +++ b/test_package/adapter_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/agent_adapter_test.cpp b/test_package/agent_adapter_test.cpp index 2942befa8..807e366e2 100644 --- a/test_package/agent_adapter_test.cpp +++ b/test_package/agent_adapter_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/agent_device_test.cpp b/test_package/agent_device_test.cpp index 02a131dfa..da174ed81 100644 --- a/test_package/agent_device_test.cpp +++ b/test_package/agent_device_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/agent_test.cpp b/test_package/agent_test.cpp index b4d441553..d7b673f84 100644 --- a/test_package/agent_test.cpp +++ b/test_package/agent_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/agent_test_helper.cpp b/test_package/agent_test_helper.cpp index 8cc85fba0..c1dd2ccb3 100644 --- a/test_package/agent_test_helper.cpp +++ b/test_package/agent_test_helper.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/agent_test_helper.hpp b/test_package/agent_test_helper.hpp index 39c857883..13c14fc94 100644 --- a/test_package/agent_test_helper.hpp +++ b/test_package/agent_test_helper.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/asset_buffer_test.cpp b/test_package/asset_buffer_test.cpp index 54d5c4076..92efefea8 100644 --- a/test_package/asset_buffer_test.cpp +++ b/test_package/asset_buffer_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/asset_hash_test.cpp b/test_package/asset_hash_test.cpp index 6d5529e48..ae17a1665 100644 --- a/test_package/asset_hash_test.cpp +++ b/test_package/asset_hash_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/asset_test.cpp b/test_package/asset_test.cpp index 49e383f31..f5fd92825 100644 --- a/test_package/asset_test.cpp +++ b/test_package/asset_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/change_observer_test.cpp b/test_package/change_observer_test.cpp index e3f90663a..b7501a6c8 100644 --- a/test_package/change_observer_test.cpp +++ b/test_package/change_observer_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/checkpoint_test.cpp b/test_package/checkpoint_test.cpp index e810b8d31..f874ae5c4 100644 --- a/test_package/checkpoint_test.cpp +++ b/test_package/checkpoint_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/circular_buffer_test.cpp b/test_package/circular_buffer_test.cpp index ca19a6ea2..4e935c94b 100644 --- a/test_package/circular_buffer_test.cpp +++ b/test_package/circular_buffer_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/component_parameters_test.cpp b/test_package/component_parameters_test.cpp index 6df0c76db..076175db9 100644 --- a/test_package/component_parameters_test.cpp +++ b/test_package/component_parameters_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/component_test.cpp b/test_package/component_test.cpp index 53c8c583c..b4b8c1a87 100644 --- a/test_package/component_test.cpp +++ b/test_package/component_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/composition_test.cpp b/test_package/composition_test.cpp index b9e75879b..4501ac3f4 100644 --- a/test_package/composition_test.cpp +++ b/test_package/composition_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/config_parser_test.cpp b/test_package/config_parser_test.cpp index 2bc8f9872..fab7e9ad6 100644 --- a/test_package/config_parser_test.cpp +++ b/test_package/config_parser_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/config_test.cpp b/test_package/config_test.cpp index 296931c9f..b4cf02da3 100644 --- a/test_package/config_test.cpp +++ b/test_package/config_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/connector_test.cpp b/test_package/connector_test.cpp index 480179032..e40c351d8 100644 --- a/test_package/connector_test.cpp +++ b/test_package/connector_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/coordinate_system_test.cpp b/test_package/coordinate_system_test.cpp index 3b9c380a0..4a4f56535 100644 --- a/test_package/coordinate_system_test.cpp +++ b/test_package/coordinate_system_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/cutting_tool_test.cpp b/test_package/cutting_tool_test.cpp index 5f1c04ef1..4647cc036 100644 --- a/test_package/cutting_tool_test.cpp +++ b/test_package/cutting_tool_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/data_item_mapping_test.cpp b/test_package/data_item_mapping_test.cpp index 4a6c983d0..f36ed7399 100644 --- a/test_package/data_item_mapping_test.cpp +++ b/test_package/data_item_mapping_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/data_item_test.cpp b/test_package/data_item_test.cpp index 178bb1ca0..5e88dc6f1 100644 --- a/test_package/data_item_test.cpp +++ b/test_package/data_item_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/data_set_test.cpp b/test_package/data_set_test.cpp index 4c2fd43c6..24566788a 100644 --- a/test_package/data_set_test.cpp +++ b/test_package/data_set_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/device_test.cpp b/test_package/device_test.cpp index a0a728922..6bb14a651 100644 --- a/test_package/device_test.cpp +++ b/test_package/device_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/duplicate_filter_test.cpp b/test_package/duplicate_filter_test.cpp index a9b1de3f3..459c50de8 100644 --- a/test_package/duplicate_filter_test.cpp +++ b/test_package/duplicate_filter_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/embedded_ruby_test.cpp b/test_package/embedded_ruby_test.cpp index b12e36b59..c60dc141d 100644 --- a/test_package/embedded_ruby_test.cpp +++ b/test_package/embedded_ruby_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/entity_parser_test.cpp b/test_package/entity_parser_test.cpp index c34a84858..ab752021d 100644 --- a/test_package/entity_parser_test.cpp +++ b/test_package/entity_parser_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/entity_printer_test.cpp b/test_package/entity_printer_test.cpp index 22dd514b9..2999fe1e3 100644 --- a/test_package/entity_printer_test.cpp +++ b/test_package/entity_printer_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/entity_test.cpp b/test_package/entity_test.cpp index f10318fd5..88396d8de 100644 --- a/test_package/entity_test.cpp +++ b/test_package/entity_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/file_asset_test.cpp b/test_package/file_asset_test.cpp index a2d57c932..9b5a753e9 100644 --- a/test_package/file_asset_test.cpp +++ b/test_package/file_asset_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/file_cache_test.cpp b/test_package/file_cache_test.cpp index 6d453f781..5e916fd28 100644 --- a/test_package/file_cache_test.cpp +++ b/test_package/file_cache_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/globals_test.cpp b/test_package/globals_test.cpp index 23c423393..48cdee99a 100644 --- a/test_package/globals_test.cpp +++ b/test_package/globals_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/http_server_test.cpp b/test_package/http_server_test.cpp index 07d69fb67..da52c633a 100644 --- a/test_package/http_server_test.cpp +++ b/test_package/http_server_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/image_file_test.cpp b/test_package/image_file_test.cpp index eca9fa5e8..9a1ebfe67 100644 --- a/test_package/image_file_test.cpp +++ b/test_package/image_file_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/json_helper.hpp b/test_package/json_helper.hpp index e23afcb76..5ec636147 100644 --- a/test_package/json_helper.hpp +++ b/test_package/json_helper.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/json_mapping_test.cpp b/test_package/json_mapping_test.cpp index 6a33d2d02..25267594d 100644 --- a/test_package/json_mapping_test.cpp +++ b/test_package/json_mapping_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/json_parser_test.cpp b/test_package/json_parser_test.cpp index 3995e78a4..5db25737f 100644 --- a/test_package/json_parser_test.cpp +++ b/test_package/json_parser_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/json_printer_asset_test.cpp b/test_package/json_printer_asset_test.cpp index 7f478b080..d2e61b8f6 100644 --- a/test_package/json_printer_asset_test.cpp +++ b/test_package/json_printer_asset_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/json_printer_error_test.cpp b/test_package/json_printer_error_test.cpp index 147ce7967..f4a2a7291 100644 --- a/test_package/json_printer_error_test.cpp +++ b/test_package/json_printer_error_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/json_printer_probe_test.cpp b/test_package/json_printer_probe_test.cpp index 36b6e711e..b5544bc54 100644 --- a/test_package/json_printer_probe_test.cpp +++ b/test_package/json_printer_probe_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/json_printer_stream_test.cpp b/test_package/json_printer_stream_test.cpp index b00ed3b77..03b1fd8e2 100644 --- a/test_package/json_printer_stream_test.cpp +++ b/test_package/json_printer_stream_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/json_printer_test.cpp b/test_package/json_printer_test.cpp index 686ce425d..1fbb276f1 100644 --- a/test_package/json_printer_test.cpp +++ b/test_package/json_printer_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/kinematics_test.cpp b/test_package/kinematics_test.cpp index 1dd927cb1..a2bf20d36 100644 --- a/test_package/kinematics_test.cpp +++ b/test_package/kinematics_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/mqtt_adapter_test.cpp b/test_package/mqtt_adapter_test.cpp index 9a14699be..2e2c4683f 100644 --- a/test_package/mqtt_adapter_test.cpp +++ b/test_package/mqtt_adapter_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/mqtt_isolated_test.cpp b/test_package/mqtt_isolated_test.cpp index 5b7ae824e..9789436c5 100644 --- a/test_package/mqtt_isolated_test.cpp +++ b/test_package/mqtt_isolated_test.cpp @@ -1,5 +1,5 @@ -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/mqtt_sink_2_test.cpp b/test_package/mqtt_sink_2_test.cpp index 111748a74..bdae53427 100644 --- a/test_package/mqtt_sink_2_test.cpp +++ b/test_package/mqtt_sink_2_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/mqtt_sink_test.cpp b/test_package/mqtt_sink_test.cpp index 85817679b..6675811f3 100644 --- a/test_package/mqtt_sink_test.cpp +++ b/test_package/mqtt_sink_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/mtconnect_xml_transform_test.cpp b/test_package/mtconnect_xml_transform_test.cpp index cb2b345ee..be3e5e6dc 100644 --- a/test_package/mtconnect_xml_transform_test.cpp +++ b/test_package/mtconnect_xml_transform_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/observation_test.cpp b/test_package/observation_test.cpp index feb6a10d4..3040dfe31 100644 --- a/test_package/observation_test.cpp +++ b/test_package/observation_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/period_filter_test.cpp b/test_package/period_filter_test.cpp index 839792cec..d38cd4d11 100644 --- a/test_package/period_filter_test.cpp +++ b/test_package/period_filter_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/pipeline_deliver_test.cpp b/test_package/pipeline_deliver_test.cpp index 4d611663f..3e632ee37 100644 --- a/test_package/pipeline_deliver_test.cpp +++ b/test_package/pipeline_deliver_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/pipeline_edit_test.cpp b/test_package/pipeline_edit_test.cpp index 130c09769..c5b68d90f 100644 --- a/test_package/pipeline_edit_test.cpp +++ b/test_package/pipeline_edit_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/qif_document_test.cpp b/test_package/qif_document_test.cpp index 269353f91..68097689f 100644 --- a/test_package/qif_document_test.cpp +++ b/test_package/qif_document_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/qname_test.cpp b/test_package/qname_test.cpp index 9462d1e0e..05ac55b35 100644 --- a/test_package/qname_test.cpp +++ b/test_package/qname_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/raw_material_test.cpp b/test_package/raw_material_test.cpp index 558dd262c..e7edecf6d 100644 --- a/test_package/raw_material_test.cpp +++ b/test_package/raw_material_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/references_test.cpp b/test_package/references_test.cpp index e81aba959..7d18c1148 100644 --- a/test_package/references_test.cpp +++ b/test_package/references_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/relationship_test.cpp b/test_package/relationship_test.cpp index c4feb60a6..b9ebf7f07 100644 --- a/test_package/relationship_test.cpp +++ b/test_package/relationship_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/response_document_test.cpp b/test_package/response_document_test.cpp index 0ae7316bc..50a513ba9 100644 --- a/test_package/response_document_test.cpp +++ b/test_package/response_document_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/routing_test.cpp b/test_package/routing_test.cpp index b26a86576..d4457f580 100644 --- a/test_package/routing_test.cpp +++ b/test_package/routing_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/sensor_configuration_test.cpp b/test_package/sensor_configuration_test.cpp index 1d94d46ab..eaf783b65 100644 --- a/test_package/sensor_configuration_test.cpp +++ b/test_package/sensor_configuration_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/shdr_tokenizer_test.cpp b/test_package/shdr_tokenizer_test.cpp index 8150df87a..76b754d43 100644 --- a/test_package/shdr_tokenizer_test.cpp +++ b/test_package/shdr_tokenizer_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/solid_model_test.cpp b/test_package/solid_model_test.cpp index 169eea1ef..7cd6696a7 100644 --- a/test_package/solid_model_test.cpp +++ b/test_package/solid_model_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/specification_test.cpp b/test_package/specification_test.cpp index dff297813..3e3529fd6 100644 --- a/test_package/specification_test.cpp +++ b/test_package/specification_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/table_test.cpp b/test_package/table_test.cpp index 8da67faa2..215c8735c 100644 --- a/test_package/table_test.cpp +++ b/test_package/table_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/test_utilities.hpp b/test_package/test_utilities.hpp index 7fe6fea09..df1b0699e 100644 --- a/test_package/test_utilities.hpp +++ b/test_package/test_utilities.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/testadapter_service.cpp b/test_package/testadapter_service.cpp index 79f08bf74..23ae60b83 100644 --- a/test_package/testadapter_service.cpp +++ b/test_package/testadapter_service.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/testadapter_service.hpp b/test_package/testadapter_service.hpp index 29ec1c06e..347324036 100644 --- a/test_package/testadapter_service.hpp +++ b/test_package/testadapter_service.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/testsink_service.cpp b/test_package/testsink_service.cpp index 144ede526..245c9f595 100644 --- a/test_package/testsink_service.cpp +++ b/test_package/testsink_service.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/testsink_service.hpp b/test_package/testsink_service.hpp index affd7c3f6..87b6d551e 100644 --- a/test_package/testsink_service.hpp +++ b/test_package/testsink_service.hpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/timestamp_extractor_test.cpp b/test_package/timestamp_extractor_test.cpp index 49f05525d..dd355f17a 100644 --- a/test_package/timestamp_extractor_test.cpp +++ b/test_package/timestamp_extractor_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/tls_http_server_test.cpp b/test_package/tls_http_server_test.cpp index e141502a6..830d85f06 100644 --- a/test_package/tls_http_server_test.cpp +++ b/test_package/tls_http_server_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/topic_mapping_test.cpp b/test_package/topic_mapping_test.cpp index 71a53f0bc..5d92b44b0 100644 --- a/test_package/topic_mapping_test.cpp +++ b/test_package/topic_mapping_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/unit_conversion_test.cpp b/test_package/unit_conversion_test.cpp index e52ee6e9e..2998ae54f 100644 --- a/test_package/unit_conversion_test.cpp +++ b/test_package/unit_conversion_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/url_parser_test.cpp b/test_package/url_parser_test.cpp index 51afc286f..e2b31c5b4 100644 --- a/test_package/url_parser_test.cpp +++ b/test_package/url_parser_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/xml_parser_test.cpp b/test_package/xml_parser_test.cpp index 85814ea55..f2c532b94 100644 --- a/test_package/xml_parser_test.cpp +++ b/test_package/xml_parser_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/test_package/xml_printer_test.cpp b/test_package/xml_printer_test.cpp index 354bfd238..feba4c780 100644 --- a/test_package/xml_printer_test.cpp +++ b/test_package/xml_printer_test.cpp @@ -1,5 +1,5 @@ // -// Copyright Copyright 2009-2022, AMT – The Association For Manufacturing Technology (“AMT”) +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) // All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); From 071baa5b35fe51eb49c064f18c9ae5a434802171 Mon Sep 17 00:00:00 2001 From: Will Sobel Date: Fri, 5 Apr 2024 23:28:20 -0400 Subject: [PATCH 2/3] first version of validation transform with pipeline --- CMakeLists.txt | 6 +- agent_lib/CMakeLists.txt | 5 +- src/mtconnect/pipeline/period_filter.hpp | 2 +- src/mtconnect/pipeline/validator.hpp | 99 ++++++++++++ src/mtconnect/printer/xml_printer.cpp | 2 +- .../source/adapter/adapter_pipeline.cpp | 5 + src/mtconnect/source/loopback_source.cpp | 7 + .../validation/observation_validations.hpp | 104 ++++++++++++- src/mtconnect/validation/observations.hpp | 2 +- test_package/CMakeLists.txt | 1 + test_package/observation_validation_test.cpp | 143 ++++++++++++++++++ 11 files changed, 366 insertions(+), 10 deletions(-) create mode 100644 src/mtconnect/pipeline/validator.hpp create mode 100644 test_package/observation_validation_test.cpp diff --git a/CMakeLists.txt b/CMakeLists.txt index f47aa6a86..81d1e1c71 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,9 +1,9 @@ # The version number. set(AGENT_VERSION_MAJOR 2) -set(AGENT_VERSION_MINOR 3) +set(AGENT_VERSION_MINOR 5) set(AGENT_VERSION_PATCH 0) -set(AGENT_VERSION_BUILD 5) -set(AGENT_VERSION_RC "") +set(AGENT_VERSION_BUILD 0) +set(AGENT_VERSION_RC "RC1") # This minimum version is to support Visual Studio 2019 and C++ feature checking and FetchContent cmake_minimum_required(VERSION 3.23 FATAL_ERROR) diff --git a/agent_lib/CMakeLists.txt b/agent_lib/CMakeLists.txt index 975b9fbb5..fbbbd70ce 100644 --- a/agent_lib/CMakeLists.txt +++ b/agent_lib/CMakeLists.txt @@ -183,6 +183,7 @@ set(AGENT_SOURCES "${SOURCE_DIR}/pipeline/topic_mapper.hpp" "${SOURCE_DIR}/pipeline/transform.hpp" "${SOURCE_DIR}/pipeline/upcase_value.hpp" + "${SOURCE_DIR}/pipeline/validator.hpp" # src/pipeline SOURCE_FILES_ONLY @@ -246,12 +247,12 @@ set(AGENT_SOURCES # src/sink/mqtt_sink HEADER_FILE_ONLY "${SOURCE_DIR}/sink/mqtt_sink/mqtt_service.hpp" - "${SOURCE_DIR}/sink/mqtt_sink/mqtt2_service.hpp" + "${SOURCE_DIR}/sink/mqtt_sink/mqtt2_service.hpp" #src/sink/mqtt_sink SOURCE_FILES_ONLY "${SOURCE_DIR}/sink/mqtt_sink/mqtt_service.cpp" - "${SOURCE_DIR}/sink/mqtt_sink/mqtt2_service.cpp" + "${SOURCE_DIR}/sink/mqtt_sink/mqtt2_service.cpp" # src/sink/rest_sink HEADER_FILE_ONLY diff --git a/src/mtconnect/pipeline/period_filter.hpp b/src/mtconnect/pipeline/period_filter.hpp index 6baf6545e..9073e8552 100644 --- a/src/mtconnect/pipeline/period_filter.hpp +++ b/src/mtconnect/pipeline/period_filter.hpp @@ -127,7 +127,7 @@ namespace mtconnect::pipeline { } } - return next(obs); + return next(std::move(obs)); } protected: diff --git a/src/mtconnect/pipeline/validator.hpp b/src/mtconnect/pipeline/validator.hpp new file mode 100644 index 000000000..995200c94 --- /dev/null +++ b/src/mtconnect/pipeline/validator.hpp @@ -0,0 +1,99 @@ +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) +// All rights reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// + +#pragma once + +#include +#include + +#include "mtconnect/config.hpp" +#include "mtconnect/entity/entity.hpp" +#include "mtconnect/observation/observation.hpp" +#include "mtconnect/validation/observations.hpp" +#include "transform.hpp" + +namespace mtconnect::pipeline { + using namespace entity; + + /// @brief Map a token list to data items or asset types + class AGENT_LIB_API Validator : public Transform + { + public: + Validator(const Validator &) = default; + Validator(PipelineContextPtr context) + : Transform("Validator"), + m_contract(context->m_contract.get()) + { + m_guard = TypeGuard(RUN) || TypeGuard(SKIP); + } + + EntityPtr operator()(entity::EntityPtr &&entity) override + { + using namespace observation; + using namespace mtconnect::validation::observations; + auto evt = std::dynamic_pointer_cast(entity); + + auto di = evt->getDataItem(); + auto &type = di->getType(); + auto &value = evt->getValue(); + + if (value == "UNAVAILABLE") + { + evt->setProperty("quality", std::string("VALID")); + } + else + { + // Optimize + auto vocab = ControlledVocabularies.find(type); + if (vocab != ControlledVocabularies.end()) + { + auto &lits = vocab->second; + if (lits.size() != 0) + { + auto lit = lits.find(value); + if (lit != lits.end()) + { + evt->setProperty("quality", std::string("VALID")); + // Check for deprecated + } + else + { + evt->setProperty("quality", std::string("INVALID")); + // Log once + LOG(warning) << "Invalid value for '" << type << "' " << evt->getValue(); + } + } + else + { + evt->setProperty("quality", std::string("VALID")); + } + } + else + { + evt->setProperty("quality", std::string("UNVERIFIABLE")); + } + } + + return next(std::move(evt)); + } + + protected: + // Logging Context + std::set m_logOnce; + PipelineContract *m_contract; + std::unordered_map m_dataItemMap; + }; +} // namespace mtconnect::pipeline diff --git a/src/mtconnect/printer/xml_printer.cpp b/src/mtconnect/printer/xml_printer.cpp index 5e0aa1b2e..6448959e7 100644 --- a/src/mtconnect/printer/xml_printer.cpp +++ b/src/mtconnect/printer/xml_printer.cpp @@ -638,7 +638,7 @@ namespace mtconnect::printer { addAttribute(writer, "instanceId", to_string(instanceId)); if (m_validation) - addAttribute(writer, "instanceId", "true"s); + addAttribute(writer, "validation", "true"s); char version[32] = {0}; sprintf(version, "%d.%d.%d.%d", AGENT_VERSION_MAJOR, AGENT_VERSION_MINOR, AGENT_VERSION_PATCH, diff --git a/src/mtconnect/source/adapter/adapter_pipeline.cpp b/src/mtconnect/source/adapter/adapter_pipeline.cpp index 16a3dd505..615b47412 100644 --- a/src/mtconnect/source/adapter/adapter_pipeline.cpp +++ b/src/mtconnect/source/adapter/adapter_pipeline.cpp @@ -28,6 +28,7 @@ #include "mtconnect/pipeline/timestamp_extractor.hpp" #include "mtconnect/pipeline/topic_mapper.hpp" #include "mtconnect/pipeline/upcase_value.hpp" +#include "mtconnect/pipeline/validator.hpp" #include "mtconnect/source/adapter/adapter.hpp" using namespace std; @@ -138,6 +139,10 @@ namespace mtconnect { // Convert values if (IsOptionSet(m_options, configuration::ConversionRequired)) next = next->bind(make_shared()); + + // Validate Values + if (IsOptionSet(m_options, configuration::Validation)) + next = next->bind(make_shared(m_context)); // Filter dups, by delta, and by period next = next->bind(make_shared(m_context)); diff --git a/src/mtconnect/source/loopback_source.cpp b/src/mtconnect/source/loopback_source.cpp index 6cfbcdc6a..c28609b48 100644 --- a/src/mtconnect/source/loopback_source.cpp +++ b/src/mtconnect/source/loopback_source.cpp @@ -27,6 +27,7 @@ #include "mtconnect/pipeline/period_filter.hpp" #include "mtconnect/pipeline/timestamp_extractor.hpp" #include "mtconnect/pipeline/upcase_value.hpp" +#include "mtconnect/pipeline/validator.hpp" using namespace std; @@ -36,6 +37,8 @@ namespace mtconnect::source { using namespace pipeline; void LoopbackPipeline::build(const ConfigOptions &options) { + m_options = options; + clear(); TransformPtr next = m_start; @@ -54,6 +57,10 @@ namespace mtconnect::source { if (IsOptionSet(m_options, configuration::ConversionRequired)) next = next->bind(make_shared()); + // Validate Values + if (IsOptionSet(m_options, configuration::Validation)) + next = next->bind(make_shared(m_context)); + // Deliver next->bind(make_shared(m_context)); applySplices(); diff --git a/src/mtconnect/validation/observation_validations.hpp b/src/mtconnect/validation/observation_validations.hpp index 24af87c85..d0bb08abb 100644 --- a/src/mtconnect/validation/observation_validations.hpp +++ b/src/mtconnect/validation/observation_validations.hpp @@ -1,13 +1,25 @@ - Validation ControlledVocabularies { +const Validation ControlledVocabularies { + {"ACTIVE_AXES", {}}, {"ACTUATOR_STATE", {{"ACTIVE", 0}, {"INACTIVE", 0}}}, + {"ALARM", {}}, + {"ASSET_CHANGED", {}}, + {"ASSET_REMOVED", {}}, {"AVAILABILITY", {{"AVAILABLE", 0}, {"UNAVAILABLE", 0}}}, {"AXIS_COUPLING", {{"TANDEM", 0}, {"SYNCHRONOUS", 0}, {"MASTER", 0}, {"SLAVE", 0}}}, + {"AXIS_FEEDRATE_OVERRIDE", {}}, {"AXIS_INTERLOCK", {{"ACTIVE", 0}, {"INACTIVE", 0}}}, {"AXIS_STATE", {{"HOME", 0}, {"TRAVEL", 0}, {"PARKED", 0}, {"STOPPED", 0}}}, + {"BLOCK", {}}, + {"BLOCK_COUNT", {}}, {"CHUCK_INTERLOCK", {{"ACTIVE", 0}, {"INACTIVE", 0}}}, {"CHUCK_STATE", {{"OPEN", 0}, {"CLOSED", 0}, {"UNLATCHED", 0}}}, + {"CODE", {}}, + {"COMPOSITION_STATE", {}}, {"CONTROLLER_MODE", {{"AUTOMATIC", 0}, {"MANUAL", 0}, {"MANUAL_DATA_INPUT", 0}, {"SEMI_AUTOMATIC", 0}, {"EDIT", 0}, {"FEED_HOLD", SCHEMA_VERSION(1, 3)}}}, {"CONTROLLER_MODE_OVERRIDE", {{"ON", 0}, {"OFF", 0}}}, + {"COUPLED_AXES", {}}, + {"DATE_CODE", {}}, + {"DEVICE_UUID", {}}, {"DIRECTION", {{"CLOCKWISE", SCHEMA_VERSION(1, 4)}, {"COUNTER_CLOCKWISE", SCHEMA_VERSION(1, 4)}, {"POSITIVE", SCHEMA_VERSION(1, 4)}, {"NEGATIVE", SCHEMA_VERSION(1, 4)}}}, {"DOOR_STATE", {{"OPEN", 0}, {"CLOSED", 0}, {"UNLATCHED", 0}}}, {"EMERGENCY_STOP", {{"ARMED", 0}, {"TRIGGERED", 0}}}, @@ -15,25 +27,113 @@ {"EQUIPMENT_MODE", {{"ON", 0}, {"OFF", 0}}}, {"EXECUTION", {{"READY", 0}, {"ACTIVE", 0}, {"INTERRUPTED", 0}, {"FEED_HOLD", 0}, {"STOPPED", 0}, {"OPTIONAL_STOP", 0}, {"PROGRAM_STOPPED", 0}, {"PROGRAM_COMPLETED", 0}, {"WAIT", 0}, {"PROGRAM_OPTIONAL_STOP", SCHEMA_VERSION(1, 4)}}}, {"FUNCTIONAL_MODE", {{"PRODUCTION", 0}, {"SETUP", 0}, {"TEARDOWN", 0}, {"MAINTENANCE", 0}, {"PROCESS_DEVELOPMENT", 0}}}, + {"HARDNESS", {}}, + {"LINE", {}}, + {"LINE_LABEL", {}}, + {"LINE_NUMBER", {}}, + {"MATERIAL", {}}, + {"MATERIAL_LAYER", {}}, + {"MESSAGE", {}}, + {"OPERATOR_ID", {}}, + {"PALLET_ID", {}}, + {"PART_COUNT", {}}, {"PART_DETECT", {{"PRESENT", 0}, {"NOT_PRESENT", 0}}}, + {"PART_ID", {}}, + {"PART_NUMBER", {}}, + {"PATH_FEEDRATE_OVERRIDE", {}}, {"PATH_MODE", {{"INDEPENDENT", 0}, {"MASTER", 0}, {"SYNCHRONOUS", 0}, {"MIRROR", 0}}}, {"POWER_STATE", {{"ON", 0}, {"OFF", 0}}}, {"POWER_STATUS", {{"ON", SCHEMA_VERSION(1, 1)}, {"OFF", SCHEMA_VERSION(1, 1)}}}, + {"PROCESS_TIME", {}}, + {"PROGRAM", {}}, + {"PROGRAM_COMMENT", {}}, {"PROGRAM_EDIT", {{"ACTIVE", 0}, {"READY", 0}, {"NOT_READY", 0}}}, + {"PROGRAM_EDIT_NAME", {}}, + {"PROGRAM_HEADER", {}}, + {"PROGRAM_LOCATION", {}}, {"PROGRAM_LOCATION_TYPE", {{"LOCAL", 0}, {"EXTERNAL", 0}}}, + {"PROGRAM_NEST_LEVEL", {}}, {"ROTARY_MODE", {{"SPINDLE", 0}, {"INDEX", 0}, {"CONTOUR", 0}}}, + {"ROTARY_VELOCITY_OVERRIDE", {}}, + {"SERIAL_NUMBER", {}}, {"SPINDLE_INTERLOCK", {{"ACTIVE", 0}, {"INACTIVE", 0}}}, + {"TOOL_ASSET_ID", {}}, + {"TOOL_GROUP", {}}, + {"TOOL_ID", {}}, + {"TOOL_NUMBER", {}}, + {"TOOL_OFFSET", {}}, + {"USER", {}}, + {"VARIABLE", {}}, {"WAIT_STATE", {{"POWERING_UP", 0}, {"POWERING_DOWN", 0}, {"PART_LOAD", 0}, {"PART_UNLOAD", 0}, {"TOOL_LOAD", 0}, {"TOOL_UNLOAD", 0}, {"MATERIAL_LOAD", 0}, {"MATERIAL_UNLOAD", 0}, {"SECONDARY_PROCESS", 0}, {"PAUSING", 0}, {"RESUMING", 0}}}, + {"WIRE", {}}, + {"WORKHOLDING_ID", {}}, + {"WORK_OFFSET", {}}, + {"OPERATING_SYSTEM", {}}, + {"FIRMWARE", {}}, + {"APPLICATION", {}}, + {"LIBRARY", {}}, + {"HARDWARE", {}}, + {"NETWORK", {}}, + {"ROTATION", {}}, + {"TRANSLATION", {}}, + {"PROCESS_KIND_ID", {}}, {"PART_STATUS", {{"PASS", 0}, {"FAIL", 0}}}, + {"ALARM_LIMIT", {}}, + {"PROCESS_AGGREGATE_ID", {}}, + {"PART_KIND_ID", {}}, + {"ADAPTER_URI", {}}, + {"DEVICE_REMOVED", {}}, + {"DEVICE_CHANGED", {}}, + {"SPECIFICATION_LIMIT", {}}, {"CONNECTION_STATUS", {{"CLOSED", 0}, {"LISTEN", 0}, {"ESTABLISHED", 0}}}, + {"ADAPTER_SOFTWARE_VERSION", {}}, + {"SENSOR_ATTACHMENT", {}}, + {"CONTROL_LIMIT", {}}, + {"DEVICE_ADDED", {}}, + {"MTCONNECT_VERSION", {}}, + {"PROCESS_OCCURRENCE_ID", {}}, + {"PART_GROUP_ID", {}}, + {"PART_UNIQUE_ID", {}}, + {"ACTIVATION_COUNT", {}}, + {"DEACTIVATION_COUNT", {}}, + {"TRANSFER_COUNT", {}}, + {"LOAD_COUNT", {}}, {"PART_PROCESSING_STATE", {{"NEEDS_PROCESSING", 0}, {"IN_PROCESS", 0}, {"PROCESSING_ENDED", 0}, {"PROCESSING_ENDED_COMPLETE", 0}, {"PROCESSING_ENDED_STOPPED", 0}, {"PROCESSING_ENDED_ABORTED", 0}, {"PROCESSING_ENDED_LOST", 0}, {"PROCESSING_ENDED_SKIPPED", 0}, {"PROCESSING_ENDED_REJECTED", 0}, {"WAITING_FOR_TRANSIT", 0}, {"IN_TRANSIT", 0}, {"TRANSIT_COMPLETE", 0}}}, {"PROCESS_STATE", {{"INITIALIZING", 0}, {"READY", 0}, {"ACTIVE", 0}, {"COMPLETE", 0}, {"INTERRUPTED", 0}, {"ABORTED", 0}}}, {"VALVE_STATE", {{"OPEN", 0}, {"OPENING", 0}, {"CLOSED", 0}, {"CLOSING", 0}}}, {"LOCK_STATE", {{"LOCKED", 0}, {"UNLOCKED", 0}}}, + {"UNLOAD_COUNT", {}}, + {"CYCLE_COUNT", {}}, {"OPERATING_MODE", {{"AUTOMATIC", 0}, {"MANUAL", 0}, {"SEMI_AUTOMATIC", 0}}}, + {"ASSET_COUNT", {}}, + {"MAINTENANCE_LIST", {}}, + {"FIXTURE_ID", {}}, {"PART_COUNT_TYPE", {{"EACH", 0}, {"BATCH", 0}}}, + {"CLOCK_TIME", {}}, + {"NETWORK_PORT", {}}, + {"HOST_NAME", {}}, {"LEAK_DETECT", {{"DETECTED", 0}, {"NOT_DETECTED", 0}}}, {"BATTERY_STATE", {{"CHARGED", 0}, {"CHARGING", 0}, {"DISCHARGING", 0}, {"DISCHARGED", 0}}}, + {"FEATURE_PERSISTENT_ID", {}}, + {"SENSOR_STATE", {}}, + {"COMPONENT_DATA", {}}, + {"WORK_OFFSETS", {}}, + {"TOOL_OFFSETS", {}}, + {"FEATURE_MEASUREMENT", {}}, + {"ADAPTER_URI", {}}, + {"MEASUREMENT_TYPE", {}}, + {"MEASUREMENT_VALUE", {}}, + {"MEASUREMENT_UNITS", {}}, {"ADAPTER_URI", {{"PASS", 0}, {"FAIL", 0}, {"REWORK", 0}, {"SYSTEM_ERROR", 0}, {"INDETERMINATE", 0}, {"NOT_ANALYZED", 0}, {"BASIC_OR_THEORETIC_EXACT_DIMENSION", 0}, {"UNDEFINED", 0}}}, - {"UNCERTAINTY_TYPE", {{"COMBINED", 0}, {"MEAN", 0}}} + {"UNCERTAINTY_TYPE", {{"COMBINED", 0}, {"MEAN", 0}}}, + {"UNCERTAINTY", {}}, + {"ALARM_LIMIT", {}}, + {"CONTROL_LIMIT", {}}, + {"SPECIFICATION_LIMIT", {}}, + {"TOOL_CUTTING_ITEM", {}}, + {"LOCATION_ADDRESS", {}}, + {"ACTIVE_POWER_SOURCE", {}}, + {"LOCATION_NARRATIVE", {}}, + {"THICKNESS", {}}, + {"LOCATION_SPATIAL_GEOGRAPHIC", {}} }; diff --git a/src/mtconnect/validation/observations.hpp b/src/mtconnect/validation/observations.hpp index f540d6131..a9d8c0055 100644 --- a/src/mtconnect/validation/observations.hpp +++ b/src/mtconnect/validation/observations.hpp @@ -25,5 +25,5 @@ namespace mtconnect::validation::observations { using Validation = std::unordered_map>; - extern Validation ControlledVocabularies; + const extern Validation ControlledVocabularies; } diff --git a/test_package/CMakeLists.txt b/test_package/CMakeLists.txt index 927946eb0..08a4e1ffd 100644 --- a/test_package/CMakeLists.txt +++ b/test_package/CMakeLists.txt @@ -277,6 +277,7 @@ add_agent_test(pipeline_edit FALSE pipeline) add_agent_test(mtconnect_xml_transform FALSE pipeline) add_agent_test(response_document FALSE pipeline) add_agent_test(json_mapping FALSE pipeline) +add_agent_test(observation_validation TRUE pipeline) add_agent_test(agent TRUE core) add_agent_test(globals FALSE core) diff --git a/test_package/observation_validation_test.cpp b/test_package/observation_validation_test.cpp new file mode 100644 index 000000000..be6699ab0 --- /dev/null +++ b/test_package/observation_validation_test.cpp @@ -0,0 +1,143 @@ +// +// Copyright Copyright 2009-2024, AMT – The Association For Manufacturing Technology (“AMT”) +// All rights reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// + +// Ensure that gtest is the first header otherwise Windows raises an error +#include +// Keep this comment to keep gtest.h above. (clang-format off/on is not working here!) + +#include + +#include "mtconnect/entity/entity.hpp" +#include "mtconnect/observation/observation.hpp" +#include "mtconnect/pipeline/validator.hpp" +#include "mtconnect/asset/asset.hpp" +#include "mtconnect/device_model/data_item/data_item.hpp" + +using namespace mtconnect; +using namespace mtconnect::pipeline; +using namespace mtconnect::observation; +using namespace mtconnect::asset; +using namespace mtconnect::device_model::data_item; +using namespace std; +using namespace date::literals; +using namespace std::literals; + +// main +int main(int argc, char *argv[]) +{ + ::testing::InitGoogleTest(&argc, argv); + return RUN_ALL_TESTS(); +} + +class MockPipelineContract : public PipelineContract +{ +public: + MockPipelineContract(std::map &items, int32_t schemaVersion) + : m_dataItems(items), m_schemaVersion(schemaVersion) + {} + DevicePtr findDevice(const std::string &) override { return nullptr; } + DataItemPtr findDataItem(const std::string &device, const std::string &name) override + { + return m_dataItems[name]; + } + void eachDataItem(EachDataItem fun) override {} + void deliverObservation(observation::ObservationPtr obs) override {} + void deliverAsset(AssetPtr) override {} + void deliverDevices(std::list) override {} + int32_t getSchemaVersion() const override { return m_schemaVersion; } + void deliverAssetCommand(entity::EntityPtr) override {} + void deliverCommand(entity::EntityPtr) override {} + void deliverConnectStatus(entity::EntityPtr, const StringList &, bool) override {} + void sourceFailed(const std::string &id) override {} + const ObservationPtr checkDuplicate(const ObservationPtr &obs) const override { return obs; } + + std::map &m_dataItems; + int32_t m_schemaVersion; +}; + +class ObservationValidationTest : public testing::Test +{ +protected: + void SetUp() override + { + m_context = make_shared(); + m_validator = make_shared(m_context); + m_validator->bind(make_shared(TypeGuard(RUN))); + m_time = Timestamp(date::sys_days(2021_y / jan / 19_d)) + 10h + 1min; + + ErrorList errors; + m_dataItem = DataItem::make( + {{"id", "exec"s}, {"category", "EVENT"s}, {"type", "EXECUTION"s}}, + errors); + } + + void TearDown() override + { + m_validator.reset(); + m_dataItem.reset(); + m_context.reset(); + } + + shared_ptr m_validator; + shared_ptr m_context; + DataItemPtr m_dataItem; + Timestamp m_time; +}; + +TEST_F(ObservationValidationTest, should_validate_value) +{ + ErrorList errors; + auto event = Observation::make(m_dataItem, {{"VALUE", "READY"s}}, m_time, errors); + + auto evt = (*m_validator)(std::move(event)); + auto quality = evt->get("quality"); + ASSERT_EQ("VALID", quality); +} + +TEST_F(ObservationValidationTest, unavailable_should_be_valid) +{ + ErrorList errors; + auto event = Observation::make(m_dataItem, {{"VALUE", "UNAVAILABLE"s}}, m_time, errors); + auto evt = (*m_validator)(std::move(event)); + auto quality = evt->get("quality"); + ASSERT_EQ("VALID", quality); +} + +TEST_F(ObservationValidationTest, should_detect_invalid_value) +{ + ErrorList errors; + auto event = Observation::make(m_dataItem, {{"VALUE", "FLABOR"s}}, m_time, errors); + + auto evt = (*m_validator)(std::move(event)); + auto quality = evt->get("quality"); + ASSERT_EQ("INVALID", quality); +} + +TEST_F(ObservationValidationTest, should_not_validate_unknown_type) +{ + ErrorList errors; + m_dataItem = DataItem::make( + {{"id", "exec"s}, {"category", "EVENT"s}, {"type", "x:FLABOR"s}}, + errors); + + auto event = Observation::make(m_dataItem, {{"VALUE", "FLABOR"s}}, m_time, errors); + + auto evt = (*m_validator)(std::move(event)); + auto quality = evt->get("quality"); + ASSERT_EQ("UNVERIFIABLE", quality); +} + From 367a6949b92703782adb4df539a7cd6eb9746d1b Mon Sep 17 00:00:00 2001 From: Will Sobel Date: Fri, 5 Apr 2024 23:40:31 -0400 Subject: [PATCH 3/3] added log once logic --- src/mtconnect/pipeline/validator.hpp | 12 +++++++++++- src/mtconnect/source/adapter/mqtt/mqtt_adapter.cpp | 2 +- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/src/mtconnect/pipeline/validator.hpp b/src/mtconnect/pipeline/validator.hpp index 995200c94..3524d03de 100644 --- a/src/mtconnect/pipeline/validator.hpp +++ b/src/mtconnect/pipeline/validator.hpp @@ -73,7 +73,17 @@ namespace mtconnect::pipeline { { evt->setProperty("quality", std::string("INVALID")); // Log once - LOG(warning) << "Invalid value for '" << type << "' " << evt->getValue(); + auto &id = di->getId(); + if (m_logOnce.count(id) < 1) + { + LOG(warning) << id << ": Invalid value for '" << type << "' " << evt->getValue(); + m_logOnce.insert(id); + } + else + { + LOG(trace) << id << ": Invalid value for '" << type << "' " << evt->getValue(); + + } } } else diff --git a/src/mtconnect/source/adapter/mqtt/mqtt_adapter.cpp b/src/mtconnect/source/adapter/mqtt/mqtt_adapter.cpp index e673a97ea..7765ef2fb 100644 --- a/src/mtconnect/source/adapter/mqtt/mqtt_adapter.cpp +++ b/src/mtconnect/source/adapter/mqtt/mqtt_adapter.cpp @@ -123,7 +123,7 @@ namespace mtconnect { !IsOptionSet(m_options, configuration::MqttWs)) { m_client = make_shared(m_ioContext, m_options, - move(clientHandler)); + std::move(clientHandler)); } else if (IsOptionSet(m_options, configuration::MqttWs) && IsOptionSet(m_options, configuration::MqttTls))