diff --git a/.gitignore b/.gitignore index 7c7ee90..6ba6148 100644 --- a/.gitignore +++ b/.gitignore @@ -22,7 +22,6 @@ x86/ bld/ [Bb]in/ [Oo]bj/ -[Ll]og/ # Visual Studio 2015/2017 cache/options directory .vs/ diff --git a/.groovy b/.groovy new file mode 100644 index 0000000..7a9c234 --- /dev/null +++ b/.groovy @@ -0,0 +1,172 @@ +#!/usr/bin/env groovy +/* groovylint-disable CompileStatic, ConsecutiveStringConcatenation, DuplicateNumberLiteral, DuplicateStringLiteral, LineLength, NestedBlockDepth, NoDef, VariableTypeRequired */ +import groovy.transform.Field + +@Field String _DDrive = 'D:/' +@Field String _AssemblyName = '...' +@Field String _TargetLocation = '...' +@Field String _GitCommitSeven = '...' +@Field String _GitName = 'MET08DDUPSFS6420' +@Field String _TestProjectDirectory = 'Adaptation' +@Field String _AgentStaging = 'mestsa07ec-ecmeseaf' +@Field String _DDriveNet = "${_DDrive}Framework4.8" +@Field String _AgentProduction = 'messa08ec-ecmeseaf' +@Field String _AgentDevelopment = 'mestsa003-mesedasvc' +@Field String _ProgramFilesDotnet = 'C:/Program Files/dotnet/dotnet.exe' +@Field String _ProgramFilesMSBuild = 'C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe' + +pipeline { + agent { + label env.JENKINS_ENVIRONMENT == 'Development' ? _AgentDevelopment : env.JENKINS_ENVIRONMENT == 'Staging' ? _AgentStaging : env.JENKINS_ENVIRONMENT == 'Production' ? _AgentProduction : 'Else' + } + parameters { + string(name: 'GIT_SERVER', defaultValue: env.JENKINS_ENVIRONMENT == 'Development' ? 'mestsa003.infineon.com' : 'mestsa07ec.ec.local', description: 'git server') + string(name: 'DEFAULT_FILE_SERVER', defaultValue: env.JENKINS_ENVIRONMENT == 'Development' ? 'messv02ecc1_ec_local' : 'messv02ecc1.ec.local', description: 'Default file server...') + } + stages { + stage('Git') { + steps { + bat(returnStatus: true, script: 'git init') + bat(returnStatus: true, script: 'git remote add origin \\\\' + params.GIT_SERVER + '\\Git\\' + _GitName + '.git') + bat(returnStatus: true, script: 'git pull origin master') + } + } + stage('Setup') { + steps { + script { + _AssemblyName = "${env.JOB_NAME}" + _GitCommitSeven = '1234567' + // _GitCommitSeven = env.GIT_COMMIT.substring(0, 7) + def files = findFiles(glob: '*.csproj') + if (files.length != 1) { + error("Build failed because couldn't find a *.csproj file") + } + echo """ + ${files[0].name} + ${files[0].path} + ${files[0].directory} + ${files[0].length} + ${files[0].lastModified} + """ + _AssemblyName = files[0].name.split('[.]csproj')[0] + _TargetLocation = "\\\\${params.DEFAULT_FILE_SERVER}\\EC_EAFRepository\\${env.JENKINS_ENVIRONMENT}\\DeploymentStorage\\Adaptation_${_AssemblyName}" + } + } + } + stage('Info') { + steps { + echo "_AssemblyName ${_AssemblyName}" // ... + echo "BUILD_NUMBER ${env.BUILD_NUMBER}" // 11 + echo "DEFAULT_FILE_SERVER ${params.DEFAULT_FILE_SERVER}" // 11 + echo "GIT_BRANCH ${env.GIT_BRANCH}" // origin/master + echo "GIT_COMMIT ${env.GIT_COMMIT}" // 73b814069f2cf0173a62a8228815a9bc9ba93c41 + echo "GIT_SERVER ${params.GIT_SERVER}" // ... + echo "GIT_URL ${env.GIT_URL}" // D:\ProgramData\Git\....git + echo "JENKINS_ENVIRONMENT ${env.JENKINS_ENVIRONMENT}" // 11 + echo "JENKINS_URL ${env.JENKINS_URL}" // http://localhost:8080/ + echo "JOB_NAME ${env.JOB_NAME}" // ... + echo "WORKSPACE ${env.WORKSPACE}" // D:\.jenkins\_\... + } + } + // stage('Restore') { + // steps { + // bat(returnStatus: true, script: 'dotnet --info') + // } + // } + stage('Safe storage of app secrets') { + steps { + dir(_TestProjectDirectory) { + bat(returnStatus: true, script: '"' + _ProgramFilesDotnet + '" ' + + 'user-secrets init') + bat(returnStatus: true, script: '"' + _ProgramFilesDotnet + '" ' + + 'user-secrets set "BuildNumber" "' + env.BUILD_NUMBER + '"') + bat(returnStatus: true, script: '"' + _ProgramFilesDotnet + '" ' + + 'user-secrets set "GitCommitSeven" "' + _GitCommitSeven + '"') + bat(returnStatus: true, script: '"' + _ProgramFilesDotnet + '" ' + + 'user-secrets set "Server" "' + params.DEFAULT_FILE_SERVER + '"') + } + } + } + stage('Core Build') { + steps { + echo "Build number is ${currentBuild.number}" + dir(_TestProjectDirectory) { + bat(returnStatus: true, script: '"' + _ProgramFilesDotnet + '" ' + + 'build --runtime win-x64 --self-contained --verbosity quiet') + } + } + } + // stage('Test') { + // options { + // timeout(time: 10, unit: 'MINUTES') + // } + // steps { + // dir(_TestProjectDirectory) { + // bat('dotnet --info') + // } + // } + // } + stage('Framework Build') { + steps { + echo "Build number is ${currentBuild.number}" + bat(returnStatus: true, script: '"' + _ProgramFilesMSBuild + '" ' + + '/target:Restore ' + + '/detailedsummary ' + + '/consoleloggerparameters:PerformanceSummary;ErrorsOnly; ' + + '/property:Configuration=Debug;TargetFrameworkVersion=v4.8 ' + + _AssemblyName + '.csproj') + bat(returnStatus: true, script: '"' + _ProgramFilesMSBuild + '" ' + + '/target:Build ' + + '/detailedsummary ' + + '/consoleloggerparameters:PerformanceSummary;ErrorsOnly; ' + + '/property:Configuration=Debug;TargetFrameworkVersion=v4.8 ' + + _AssemblyName + '.csproj') + } + } + stage('Commit Id') { + steps { + dir('bin/Debug') { + writeFile file: "${_AssemblyName}.txt", text: "${env.GIT_COMMIT}-${env.BUILD_NUMBER}-${env.GIT_URL}" + } + } + } + stage('Package') { + steps { + fileOperations([fileZipOperation(folderPath: 'bin/Debug', outputFolderPath: "${_DDriveNet}/${_GitCommitSeven}-${env.BUILD_NUMBER}-${env.JOB_NAME}-Debug")]) + fileOperations([fileCopyOperation(excludes: '', flattenFiles: true, includes: "${_AssemblyName}*", renameFiles: false, sourceCaptureExpression: '', targetLocation: "${_DDriveNet}/${_GitCommitSeven}-${env.BUILD_NUMBER}-${env.JOB_NAME}-Debug", targetNameExpression: '')]) + } + } + // stage('Force Fail') { + // steps { + // error("Build failed because of this and that..") + // } + // } + stage('Copy Files to: file-share') { + steps { + dir('bin/Debug') { + fileOperations([fileCopyOperation(excludes: '', flattenFiles: true, includes: "${_AssemblyName}*.txt", renameFiles: false, sourceCaptureExpression: '', targetLocation: _TargetLocation, targetNameExpression: '')]) + fileOperations([fileCopyOperation(excludes: '', flattenFiles: true, includes: "${_AssemblyName}*.dll", renameFiles: false, sourceCaptureExpression: '', targetLocation: _TargetLocation, targetNameExpression: '')]) + fileOperations([fileCopyOperation(excludes: '', flattenFiles: true, includes: "${_AssemblyName}*.exe", renameFiles: false, sourceCaptureExpression: '', targetLocation: _TargetLocation, targetNameExpression: '')]) + fileOperations([fileCopyOperation(excludes: '', flattenFiles: true, includes: "${_AssemblyName}*.pdb", renameFiles: false, sourceCaptureExpression: '', targetLocation: _TargetLocation, targetNameExpression: '')]) + } + } + } + } + post { + always { + dir('bin') { + deleteDir() + } + dir('obj') { + deleteDir() + } + dir(_TestProjectDirectory + '/bin') { + deleteDir() + } + dir(_TestProjectDirectory + '/obj') { + deleteDir() + } + // cleanWs() + } + } +} diff --git a/Adaptation/.editorconfig b/Adaptation/.editorconfig index a3ebdb2..2220133 100644 --- a/Adaptation/.editorconfig +++ b/Adaptation/.editorconfig @@ -1,137 +1,10 @@ -# Remove the line below if you want to inherit .editorconfig settings from higher directories -root = true - -# C# files [*.cs] - -#### Core EditorConfig Options #### - -# Indentation and spacing -indent_size = 4 -indent_style = space -tab_width = 4 - -# New line preferences -end_of_line = crlf -insert_final_newline = false - -#### .NET Coding Conventions #### - -# Organize usings -dotnet_separate_import_directive_groups = false -dotnet_sort_system_directives_first = false -file_header_template = unset - -# this. and Me. preferences -dotnet_style_qualification_for_event = false:error -dotnet_style_qualification_for_field = false -dotnet_style_qualification_for_method = false:error -dotnet_style_qualification_for_property = false:error - -# Language keywords vs BCL types preferences -dotnet_style_predefined_type_for_locals_parameters_members = true -dotnet_style_predefined_type_for_member_access = true - -# Parentheses preferences -dotnet_style_parentheses_in_arithmetic_binary_operators = always_for_clarity -dotnet_style_parentheses_in_other_binary_operators = always_for_clarity -dotnet_style_parentheses_in_other_operators = never_if_unnecessary -dotnet_style_parentheses_in_relational_binary_operators = always_for_clarity - -# Modifier preferences -dotnet_style_require_accessibility_modifiers = for_non_interface_members - -# Expression-level preferences -dotnet_style_coalesce_expression = true -dotnet_style_collection_initializer = true:warning -dotnet_style_explicit_tuple_names = true:warning -dotnet_style_namespace_match_folder = true -dotnet_style_null_propagation = true:warning -dotnet_style_object_initializer = true:warning -dotnet_style_operator_placement_when_wrapping = beginning_of_line -dotnet_style_prefer_auto_properties = true:warning -dotnet_style_prefer_compound_assignment = true:warning -dotnet_style_prefer_conditional_expression_over_assignment = false -dotnet_style_prefer_conditional_expression_over_return = false -dotnet_style_prefer_inferred_anonymous_type_member_names = true:warning -dotnet_style_prefer_inferred_tuple_names = true:warning -dotnet_style_prefer_is_null_check_over_reference_equality_method = true:warning -dotnet_style_prefer_simplified_boolean_expressions = true:warning -dotnet_style_prefer_simplified_interpolation = true - -# Field preferences -dotnet_style_readonly_field = true:warning - -# Parameter preferences -dotnet_code_quality_unused_parameters = all - -# Suppression preferences -dotnet_remove_unnecessary_suppression_exclusions = 0 - -# New line preferences -dotnet_style_allow_multiple_blank_lines_experimental = false:warning -dotnet_style_allow_statement_immediately_after_block_experimental = true - -#### C# Coding Conventions #### - -# var preferences -csharp_style_var_elsewhere = false:warning -csharp_style_var_for_built_in_types = false:warning -csharp_style_var_when_type_is_apparent = false:warning - -# Expression-bodied members -csharp_style_expression_bodied_accessors = when_on_single_line:warning -csharp_style_expression_bodied_constructors = when_on_single_line:warning -csharp_style_expression_bodied_indexers = when_on_single_line:warning -csharp_style_expression_bodied_lambdas = when_on_single_line:warning -csharp_style_expression_bodied_local_functions = when_on_single_line:warning -csharp_style_expression_bodied_methods = when_on_single_line:warning -csharp_style_expression_bodied_operators = when_on_single_line:warning -csharp_style_expression_bodied_properties = when_on_single_line:warning - -# Pattern matching preferences -csharp_style_pattern_matching_over_as_with_null_check = true:warning -csharp_style_pattern_matching_over_is_with_cast_check = true:warning -csharp_style_prefer_not_pattern = true:warning -csharp_style_prefer_pattern_matching = true:warning -csharp_style_prefer_switch_expression = true:warning - -# Null-checking preferences -csharp_style_conditional_delegate_call = true - -# Modifier preferences -csharp_prefer_static_local_function = true:warning -csharp_preferred_modifier_order = public,private,protected,internal,static,extern,new,virtual,abstract,sealed,override,readonly,unsafe,volatile,async - -# Code-block preferences -csharp_prefer_braces = false -csharp_prefer_simple_using_statement = true:warning -csharp_style_namespace_declarations = file_scoped:warning - -# Expression-level preferences -csharp_prefer_simple_default_expression = true:warning -csharp_style_deconstructed_variable_declaration = false -csharp_style_implicit_object_creation_when_type_is_apparent = true:warning -csharp_style_inlined_variable_declaration = false -csharp_style_pattern_local_over_anonymous_function = true:warning -csharp_style_prefer_index_operator = false:warning -csharp_style_prefer_null_check_over_type_check = true -csharp_style_prefer_range_operator = false:warning -csharp_style_throw_expression = true -csharp_style_unused_value_assignment_preference = discard_variable:warning -csharp_style_unused_value_expression_statement_preference = discard_variable:warning - -# 'using' directive preferences -csharp_using_directive_placement = outside_namespace - -# New line preferences -csharp_style_allow_blank_line_after_colon_in_constructor_initializer_experimental = true -csharp_style_allow_blank_lines_between_consecutive_braces_experimental = true -csharp_style_allow_embedded_statements_on_same_line_experimental = true - -#### C# Formatting Rules #### - -# New line preferences +csharp_indent_block_contents = true +csharp_indent_braces = false +csharp_indent_case_contents = true +csharp_indent_case_contents_when_block = true +csharp_indent_labels = one_less_than_current +csharp_indent_switch_labels = true csharp_new_line_before_catch = true csharp_new_line_before_else = true csharp_new_line_before_finally = true @@ -139,16 +12,13 @@ csharp_new_line_before_members_in_anonymous_types = true csharp_new_line_before_members_in_object_initializers = true csharp_new_line_before_open_brace = all csharp_new_line_between_query_expression_clauses = true - -# Indentation preferences -csharp_indent_block_contents = true -csharp_indent_braces = false -csharp_indent_case_contents = true -csharp_indent_case_contents_when_block = true -csharp_indent_labels = one_less_than_current -csharp_indent_switch_labels = true - -# Space preferences +csharp_prefer_braces = false +csharp_prefer_simple_default_expression = true:warning +csharp_prefer_simple_using_statement = true:warning +csharp_prefer_static_local_function = true:warning +csharp_preferred_modifier_order = public,private,protected,internal,static,extern,new,virtual,abstract,sealed,override,readonly,unsafe,volatile,async +csharp_preserve_single_line_blocks = true +csharp_preserve_single_line_statements = false csharp_space_after_cast = false csharp_space_after_colon_in_inheritance_clause = true csharp_space_after_comma = true @@ -171,166 +41,203 @@ csharp_space_between_method_declaration_name_and_open_parenthesis = false csharp_space_between_method_declaration_parameter_list_parentheses = false csharp_space_between_parentheses = false csharp_space_between_square_brackets = false - -# Wrapping preferences -csharp_preserve_single_line_blocks = true -csharp_preserve_single_line_statements = false - -#### Naming styles #### - -# Naming rules - -dotnet_naming_rule.interface_should_be_begins_with_i.severity = warning -dotnet_naming_rule.interface_should_be_begins_with_i.symbols = interface -dotnet_naming_rule.interface_should_be_begins_with_i.style = begins_with_i - -dotnet_naming_rule.types_should_be_pascal_case.severity = warning -dotnet_naming_rule.types_should_be_pascal_case.symbols = types -dotnet_naming_rule.types_should_be_pascal_case.style = pascal_case - -dotnet_naming_rule.private_or_internal_field_should_be_private_of_internal_field.severity = warning -dotnet_naming_rule.private_or_internal_field_should_be_private_of_internal_field.symbols = private_or_internal_field -dotnet_naming_rule.private_or_internal_field_should_be_private_of_internal_field.style = private_of_internal_field - -dotnet_naming_rule.enum_should_be_pascal_case.severity = warning -dotnet_naming_rule.enum_should_be_pascal_case.symbols = enum -dotnet_naming_rule.enum_should_be_pascal_case.style = pascal_case - -dotnet_naming_rule.public_or_protected_field_should_be_private_of_internal_field.severity = warning -dotnet_naming_rule.public_or_protected_field_should_be_private_of_internal_field.symbols = public_or_protected_field -dotnet_naming_rule.public_or_protected_field_should_be_private_of_internal_field.style = private_of_internal_field - -dotnet_naming_rule.class_should_be_pascal_case.severity = warning -dotnet_naming_rule.class_should_be_pascal_case.symbols = class -dotnet_naming_rule.class_should_be_pascal_case.style = pascal_case - -dotnet_naming_rule.method_should_be_pascal_case.severity = warning -dotnet_naming_rule.method_should_be_pascal_case.symbols = method -dotnet_naming_rule.method_should_be_pascal_case.style = pascal_case - -dotnet_naming_rule.private_or_internal_static_field_should_be_private_of_internal_field.severity = warning -dotnet_naming_rule.private_or_internal_static_field_should_be_private_of_internal_field.symbols = private_or_internal_static_field -dotnet_naming_rule.private_or_internal_static_field_should_be_private_of_internal_field.style = private_of_internal_field - -dotnet_naming_rule.static_field_should_be_pascal_case.severity = warning -dotnet_naming_rule.static_field_should_be_pascal_case.symbols = static_field -dotnet_naming_rule.static_field_should_be_pascal_case.style = pascal_case - -dotnet_naming_rule.property_should_be_pascal_case.severity = warning -dotnet_naming_rule.property_should_be_pascal_case.symbols = property -dotnet_naming_rule.property_should_be_pascal_case.style = pascal_case - -dotnet_naming_rule.static_method_should_be_pascal_case.severity = warning -dotnet_naming_rule.static_method_should_be_pascal_case.symbols = static_method -dotnet_naming_rule.static_method_should_be_pascal_case.style = pascal_case - +csharp_style_allow_blank_line_after_colon_in_constructor_initializer_experimental = true +csharp_style_allow_blank_lines_between_consecutive_braces_experimental = true +csharp_style_allow_embedded_statements_on_same_line_experimental = true +csharp_style_conditional_delegate_call = true +csharp_style_deconstructed_variable_declaration = false +csharp_style_expression_bodied_accessors = when_on_single_line:warning +csharp_style_expression_bodied_constructors = when_on_single_line:warning +csharp_style_expression_bodied_indexers = when_on_single_line:warning +csharp_style_expression_bodied_lambdas = when_on_single_line:warning +csharp_style_expression_bodied_local_functions = when_on_single_line:warning +csharp_style_expression_bodied_methods = when_on_single_line:warning +csharp_style_expression_bodied_operators = when_on_single_line:warning +csharp_style_expression_bodied_properties = when_on_single_line:warning +csharp_style_implicit_object_creation_when_type_is_apparent = true:warning +csharp_style_inlined_variable_declaration = false +csharp_style_namespace_declarations = file_scoped:warning +csharp_style_pattern_local_over_anonymous_function = true:warning +csharp_style_pattern_matching_over_as_with_null_check = true:warning +csharp_style_pattern_matching_over_is_with_cast_check = true:warning +csharp_style_prefer_index_operator = false:warning +csharp_style_prefer_not_pattern = true:warning +csharp_style_prefer_null_check_over_type_check = true +csharp_style_prefer_pattern_matching = true:warning +csharp_style_prefer_range_operator = false:warning +csharp_style_prefer_switch_expression = true:warning +csharp_style_throw_expression = true +csharp_style_unused_value_assignment_preference = discard_variable:warning +csharp_style_unused_value_expression_statement_preference = discard_variable:warning +csharp_style_var_elsewhere = false:warning +csharp_style_var_for_built_in_types = false:warning +csharp_style_var_when_type_is_apparent = false:warning +csharp_using_directive_placement = outside_namespace +dotnet_code_quality_unused_parameters = all +dotnet_code_quality_unused_parameters = non_public # IDE0060: Remove unused parameter +dotnet_code_quality.CAXXXX.api_surface = private, internal +dotnet_diagnostic.CA1825.severity = warning # CA1823: Avoid zero-length array allocations +dotnet_diagnostic.CA1829.severity = warning # CA1829: Use Length/Count property instead of Count() when available +dotnet_diagnostic.CA1834.severity = warning # CA1834: Consider using 'StringBuilder.Append(char)' when applicable +dotnet_diagnostic.IDE0001.severity = warning # IDE0001: Simplify name +dotnet_diagnostic.IDE0002.severity = warning # Simplify (member access) - System.Version.Equals("1", "2"); Version.Equals("1", "2"); +dotnet_diagnostic.IDE0005.severity = warning # Using directive is unnecessary +dotnet_diagnostic.IDE0047.severity = warning # IDE0047: Parentheses can be removed +dotnet_diagnostic.IDE0060.severity = warning # IDE0060: Remove unused parameter dotnet_naming_rule.abstract_method_should_be_pascal_case.severity = warning -dotnet_naming_rule.abstract_method_should_be_pascal_case.symbols = abstract_method dotnet_naming_rule.abstract_method_should_be_pascal_case.style = pascal_case - -dotnet_naming_rule.private_method_should_be_pascal_case.severity = warning -dotnet_naming_rule.private_method_should_be_pascal_case.symbols = private_method -dotnet_naming_rule.private_method_should_be_pascal_case.style = pascal_case - -dotnet_naming_rule.event_should_be_pascal_case.severity = warning -dotnet_naming_rule.event_should_be_pascal_case.symbols = event -dotnet_naming_rule.event_should_be_pascal_case.style = pascal_case - +dotnet_naming_rule.abstract_method_should_be_pascal_case.symbols = abstract_method +dotnet_naming_rule.class_should_be_pascal_case.severity = warning +dotnet_naming_rule.class_should_be_pascal_case.style = pascal_case +dotnet_naming_rule.class_should_be_pascal_case.symbols = class dotnet_naming_rule.delegate_should_be_pascal_case.severity = warning -dotnet_naming_rule.delegate_should_be_pascal_case.symbols = delegate dotnet_naming_rule.delegate_should_be_pascal_case.style = pascal_case - -dotnet_naming_rule.struct_should_be_pascal_case.severity = warning -dotnet_naming_rule.struct_should_be_pascal_case.symbols = struct -dotnet_naming_rule.struct_should_be_pascal_case.style = pascal_case - +dotnet_naming_rule.delegate_should_be_pascal_case.symbols = delegate +dotnet_naming_rule.enum_should_be_pascal_case.severity = warning +dotnet_naming_rule.enum_should_be_pascal_case.style = pascal_case +dotnet_naming_rule.enum_should_be_pascal_case.symbols = enum +dotnet_naming_rule.event_should_be_pascal_case.severity = warning +dotnet_naming_rule.event_should_be_pascal_case.style = pascal_case +dotnet_naming_rule.event_should_be_pascal_case.symbols = event +dotnet_naming_rule.interface_should_be_begins_with_i.severity = warning +dotnet_naming_rule.interface_should_be_begins_with_i.style = begins_with_i +dotnet_naming_rule.interface_should_be_begins_with_i.symbols = interface +dotnet_naming_rule.method_should_be_pascal_case.severity = warning +dotnet_naming_rule.method_should_be_pascal_case.style = pascal_case +dotnet_naming_rule.method_should_be_pascal_case.symbols = method dotnet_naming_rule.non_field_members_should_be_pascal_case.severity = warning -dotnet_naming_rule.non_field_members_should_be_pascal_case.symbols = non_field_members dotnet_naming_rule.non_field_members_should_be_pascal_case.style = pascal_case - -# Symbol specifications - -dotnet_naming_symbols.class.applicable_kinds = class -dotnet_naming_symbols.class.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected -dotnet_naming_symbols.class.required_modifiers = - -dotnet_naming_symbols.interface.applicable_kinds = interface -dotnet_naming_symbols.interface.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected -dotnet_naming_symbols.interface.required_modifiers = - -dotnet_naming_symbols.struct.applicable_kinds = struct -dotnet_naming_symbols.struct.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected -dotnet_naming_symbols.struct.required_modifiers = - -dotnet_naming_symbols.enum.applicable_kinds = enum -dotnet_naming_symbols.enum.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected -dotnet_naming_symbols.enum.required_modifiers = - -dotnet_naming_symbols.delegate.applicable_kinds = delegate -dotnet_naming_symbols.delegate.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected -dotnet_naming_symbols.delegate.required_modifiers = - -dotnet_naming_symbols.event.applicable_kinds = event -dotnet_naming_symbols.event.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected -dotnet_naming_symbols.event.required_modifiers = - -dotnet_naming_symbols.method.applicable_kinds = method -dotnet_naming_symbols.method.applicable_accessibilities = public -dotnet_naming_symbols.method.required_modifiers = - -dotnet_naming_symbols.private_method.applicable_kinds = method -dotnet_naming_symbols.private_method.applicable_accessibilities = private -dotnet_naming_symbols.private_method.required_modifiers = - -dotnet_naming_symbols.abstract_method.applicable_kinds = method -dotnet_naming_symbols.abstract_method.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected -dotnet_naming_symbols.abstract_method.required_modifiers = abstract - -dotnet_naming_symbols.static_method.applicable_kinds = method -dotnet_naming_symbols.static_method.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected -dotnet_naming_symbols.static_method.required_modifiers = static - -dotnet_naming_symbols.property.applicable_kinds = property -dotnet_naming_symbols.property.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected -dotnet_naming_symbols.property.required_modifiers = - -dotnet_naming_symbols.public_or_protected_field.applicable_kinds = field -dotnet_naming_symbols.public_or_protected_field.applicable_accessibilities = public, protected -dotnet_naming_symbols.public_or_protected_field.required_modifiers = - -dotnet_naming_symbols.static_field.applicable_kinds = field -dotnet_naming_symbols.static_field.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected -dotnet_naming_symbols.static_field.required_modifiers = static - -dotnet_naming_symbols.private_or_internal_field.applicable_kinds = field -dotnet_naming_symbols.private_or_internal_field.applicable_accessibilities = internal, private, private_protected -dotnet_naming_symbols.private_or_internal_field.required_modifiers = - -dotnet_naming_symbols.private_or_internal_static_field.applicable_kinds = field -dotnet_naming_symbols.private_or_internal_static_field.applicable_accessibilities = internal, private, private_protected -dotnet_naming_symbols.private_or_internal_static_field.required_modifiers = static - -dotnet_naming_symbols.types.applicable_kinds = class, struct, interface, enum -dotnet_naming_symbols.types.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected -dotnet_naming_symbols.types.required_modifiers = - -dotnet_naming_symbols.non_field_members.applicable_kinds = property, event, method -dotnet_naming_symbols.non_field_members.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected -dotnet_naming_symbols.non_field_members.required_modifiers = - -# Naming styles - -dotnet_naming_style.pascal_case.required_prefix = -dotnet_naming_style.pascal_case.required_suffix = -dotnet_naming_style.pascal_case.word_separator = -dotnet_naming_style.pascal_case.capitalization = pascal_case - +dotnet_naming_rule.non_field_members_should_be_pascal_case.symbols = non_field_members +dotnet_naming_rule.private_method_should_be_pascal_case.severity = warning +dotnet_naming_rule.private_method_should_be_pascal_case.style = pascal_case +dotnet_naming_rule.private_method_should_be_pascal_case.symbols = private_method +dotnet_naming_rule.private_or_internal_field_should_be_private_of_internal_field.severity = warning +dotnet_naming_rule.private_or_internal_field_should_be_private_of_internal_field.style = private_of_internal_field +dotnet_naming_rule.private_or_internal_field_should_be_private_of_internal_field.symbols = private_or_internal_field +dotnet_naming_rule.private_or_internal_static_field_should_be_private_of_internal_field.severity = warning +dotnet_naming_rule.private_or_internal_static_field_should_be_private_of_internal_field.style = private_of_internal_field +dotnet_naming_rule.private_or_internal_static_field_should_be_private_of_internal_field.symbols = private_or_internal_static_field +dotnet_naming_rule.property_should_be_pascal_case.severity = warning +dotnet_naming_rule.property_should_be_pascal_case.style = pascal_case +dotnet_naming_rule.property_should_be_pascal_case.symbols = property +dotnet_naming_rule.public_or_protected_field_should_be_private_of_internal_field.severity = warning +dotnet_naming_rule.public_or_protected_field_should_be_private_of_internal_field.style = private_of_internal_field +dotnet_naming_rule.public_or_protected_field_should_be_private_of_internal_field.symbols = public_or_protected_field +dotnet_naming_rule.static_field_should_be_pascal_case.severity = warning +dotnet_naming_rule.static_field_should_be_pascal_case.style = pascal_case +dotnet_naming_rule.static_field_should_be_pascal_case.symbols = static_field +dotnet_naming_rule.static_method_should_be_pascal_case.severity = warning +dotnet_naming_rule.static_method_should_be_pascal_case.style = pascal_case +dotnet_naming_rule.static_method_should_be_pascal_case.symbols = static_method +dotnet_naming_rule.struct_should_be_pascal_case.severity = warning +dotnet_naming_rule.struct_should_be_pascal_case.style = pascal_case +dotnet_naming_rule.struct_should_be_pascal_case.symbols = struct +dotnet_naming_rule.types_should_be_pascal_case.severity = warning +dotnet_naming_rule.types_should_be_pascal_case.style = pascal_case +dotnet_naming_rule.types_should_be_pascal_case.symbols = types +dotnet_naming_style.begins_with_i.capitalization = pascal_case dotnet_naming_style.begins_with_i.required_prefix = I dotnet_naming_style.begins_with_i.required_suffix = dotnet_naming_style.begins_with_i.word_separator = -dotnet_naming_style.begins_with_i.capitalization = pascal_case - +dotnet_naming_style.pascal_case.capitalization = pascal_case +dotnet_naming_style.pascal_case.required_prefix = +dotnet_naming_style.pascal_case.required_suffix = +dotnet_naming_style.pascal_case.word_separator = +dotnet_naming_style.private_of_internal_field.capitalization = pascal_case dotnet_naming_style.private_of_internal_field.required_prefix = _ dotnet_naming_style.private_of_internal_field.required_suffix = dotnet_naming_style.private_of_internal_field.word_separator = -dotnet_naming_style.private_of_internal_field.capitalization = pascal_case +dotnet_naming_symbols.abstract_method.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.abstract_method.applicable_kinds = method +dotnet_naming_symbols.abstract_method.required_modifiers = abstract +dotnet_naming_symbols.class.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.class.applicable_kinds = class +dotnet_naming_symbols.class.required_modifiers = +dotnet_naming_symbols.delegate.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.delegate.applicable_kinds = delegate +dotnet_naming_symbols.delegate.required_modifiers = +dotnet_naming_symbols.enum.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.enum.applicable_kinds = enum +dotnet_naming_symbols.enum.required_modifiers = +dotnet_naming_symbols.event.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.event.applicable_kinds = event +dotnet_naming_symbols.event.required_modifiers = +dotnet_naming_symbols.interface.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.interface.applicable_kinds = interface +dotnet_naming_symbols.interface.required_modifiers = +dotnet_naming_symbols.method.applicable_accessibilities = public +dotnet_naming_symbols.method.applicable_kinds = method +dotnet_naming_symbols.method.required_modifiers = +dotnet_naming_symbols.non_field_members.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.non_field_members.applicable_kinds = property, event, method +dotnet_naming_symbols.non_field_members.required_modifiers = +dotnet_naming_symbols.private_method.applicable_accessibilities = private +dotnet_naming_symbols.private_method.applicable_kinds = method +dotnet_naming_symbols.private_method.required_modifiers = +dotnet_naming_symbols.private_or_internal_field.applicable_accessibilities = internal, private, private_protected +dotnet_naming_symbols.private_or_internal_field.applicable_kinds = field +dotnet_naming_symbols.private_or_internal_field.required_modifiers = +dotnet_naming_symbols.private_or_internal_static_field.applicable_accessibilities = internal, private, private_protected +dotnet_naming_symbols.private_or_internal_static_field.applicable_kinds = field +dotnet_naming_symbols.private_or_internal_static_field.required_modifiers = static +dotnet_naming_symbols.property.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.property.applicable_kinds = property +dotnet_naming_symbols.property.required_modifiers = +dotnet_naming_symbols.public_or_protected_field.applicable_accessibilities = public, protected +dotnet_naming_symbols.public_or_protected_field.applicable_kinds = field +dotnet_naming_symbols.public_or_protected_field.required_modifiers = +dotnet_naming_symbols.static_field.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.static_field.applicable_kinds = field +dotnet_naming_symbols.static_field.required_modifiers = static +dotnet_naming_symbols.static_method.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.static_method.applicable_kinds = method +dotnet_naming_symbols.static_method.required_modifiers = static +dotnet_naming_symbols.struct.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.struct.applicable_kinds = struct +dotnet_naming_symbols.struct.required_modifiers = +dotnet_naming_symbols.types.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.types.applicable_kinds = class, struct, interface, enum +dotnet_naming_symbols.types.required_modifiers = +dotnet_remove_unnecessary_suppression_exclusions = 0 +dotnet_separate_import_directive_groups = false +dotnet_sort_system_directives_first = false +dotnet_style_allow_multiple_blank_lines_experimental = false:warning +dotnet_style_allow_statement_immediately_after_block_experimental = true +dotnet_style_coalesce_expression = true +dotnet_style_collection_initializer = true:warning +dotnet_style_explicit_tuple_names = true:warning +dotnet_style_namespace_match_folder = true +dotnet_style_null_propagation = true:warning +dotnet_style_object_initializer = true:warning +dotnet_style_operator_placement_when_wrapping = beginning_of_line +dotnet_style_parentheses_in_arithmetic_binary_operators = always_for_clarity +dotnet_style_parentheses_in_other_binary_operators = always_for_clarity +dotnet_style_parentheses_in_other_operators = never_if_unnecessary +dotnet_style_parentheses_in_relational_binary_operators = always_for_clarity +dotnet_style_predefined_type_for_locals_parameters_members = true +dotnet_style_predefined_type_for_member_access = true +dotnet_style_prefer_auto_properties = true:warning +dotnet_style_prefer_compound_assignment = true:warning +dotnet_style_prefer_conditional_expression_over_assignment = false +dotnet_style_prefer_conditional_expression_over_return = false +dotnet_style_prefer_inferred_anonymous_type_member_names = true:warning +dotnet_style_prefer_inferred_tuple_names = true:warning +dotnet_style_prefer_is_null_check_over_reference_equality_method = true:warning +dotnet_style_prefer_simplified_boolean_expressions = true:warning +dotnet_style_prefer_simplified_interpolation = true +dotnet_style_qualification_for_event = false:error +dotnet_style_qualification_for_field = false +dotnet_style_qualification_for_method = false:error +dotnet_style_qualification_for_property = false:error +dotnet_style_readonly_field = true:warning +dotnet_style_require_accessibility_modifiers = for_non_interface_members +end_of_line = crlf +file_header_template = unset +indent_size = 4 +indent_style = space +insert_final_newline = false +root = true +tab_width = 4 +# https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1822 +# https://github.com/dotnet/aspnetcore/blob/main/.editorconfig +# https://github.com/dotnet/project-system/blob/main/.editorconfig \ No newline at end of file diff --git a/Adaptation/.vscode/launch.json b/Adaptation/.vscode/launch.json new file mode 100644 index 0000000..9ac94f5 --- /dev/null +++ b/Adaptation/.vscode/launch.json @@ -0,0 +1,10 @@ +{ + "configurations": [ + { + "name": ".NET Core Attach", + "type": "coreclr", + "request": "attach", + "processId": 13708 + } + ] +} diff --git a/Adaptation/.vscode/settings.json b/Adaptation/.vscode/settings.json index 24cb881..0cb8e33 100644 --- a/Adaptation/.vscode/settings.json +++ b/Adaptation/.vscode/settings.json @@ -41,5 +41,6 @@ "titleBar.inactiveBackground": "#5c277c99", "titleBar.inactiveForeground": "#e7e7e799" }, - "peacock.color": "#5c277c" + "peacock.color": "#5c277c", + "cSpell.enabled": false } \ No newline at end of file diff --git a/Adaptation/Eaf/Management/ConfigurationData/CellAutomation/ModelObjectParameterDefinition.cs b/Adaptation/Eaf/Management/ConfigurationData/CellAutomation/ModelObjectParameterDefinition.cs index 5c0bd65..5742acc 100644 --- a/Adaptation/Eaf/Management/ConfigurationData/CellAutomation/ModelObjectParameterDefinition.cs +++ b/Adaptation/Eaf/Management/ConfigurationData/CellAutomation/ModelObjectParameterDefinition.cs @@ -2,7 +2,7 @@ namespace Adaptation.Eaf.Management.ConfigurationData.CellAutomation; -[System.Runtime.Serialization.DataContractAttribute(IsReference = true)] +[System.Runtime.Serialization.DataContract(IsReference = true)] public class ModelObjectParameterDefinition : IConfigurationObject { @@ -12,15 +12,15 @@ public class ModelObjectParameterDefinition : IConfigurationObject public ModelObjectParameterDefinition(string name, ModelObjectParameterType valueType, object defaultValue) { } public ModelObjectParameterDefinition(string name, Type enumType, object defaultValue) { } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual long Id { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual string Name { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual string Value { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual ModelObjectParameterType ValueType { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual string EnumType { get; set; } public virtual ModelObjectParameterDefinition Clone() => null; diff --git a/Adaptation/Eaf/Management/ConfigurationData/Semiconductor/CellInstances/SecsConnectionConfiguration.cs b/Adaptation/Eaf/Management/ConfigurationData/Semiconductor/CellInstances/SecsConnectionConfiguration.cs index bea5a40..b8c1bd3 100644 --- a/Adaptation/Eaf/Management/ConfigurationData/Semiconductor/CellInstances/SecsConnectionConfiguration.cs +++ b/Adaptation/Eaf/Management/ConfigurationData/Semiconductor/CellInstances/SecsConnectionConfiguration.cs @@ -3,41 +3,41 @@ using System; namespace Adaptation.Eaf.Management.ConfigurationData.Semiconductor.CellInstances; -[System.Runtime.Serialization.DataContractAttribute] +[System.Runtime.Serialization.DataContract] public class SecsConnectionConfiguration { public SecsConnectionConfiguration() { } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual TimeSpan T6HsmsControlMessage { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual TimeSpan T5ConnectionSeperation { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual TimeSpan T4InterBlock { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual TimeSpan T3MessageReply { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual TimeSpan T2Protocol { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual TimeSpan T1InterCharacter { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual SerialBaudRate? BaudRate { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual SecsTransportType? PortType { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual long? Port { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual TimeSpan LinkTestTimer { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual string Host { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual long? DeviceId { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual HsmsSessionMode? SessionMode { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual HsmsConnectionMode? ConnectionMode { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual TimeSpan T7ConnectionIdle { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual TimeSpan T8NetworkIntercharacter { get; set; } } \ No newline at end of file diff --git a/Adaptation/FileHandlers/APC/FileRead.cs b/Adaptation/FileHandlers/APC/FileRead.cs new file mode 100644 index 0000000..d1d78aa --- /dev/null +++ b/Adaptation/FileHandlers/APC/FileRead.cs @@ -0,0 +1,139 @@ +using Adaptation.Eaf.Management.ConfigurationData.CellAutomation; +using Adaptation.Ifx.Eaf.EquipmentConnector.File.Configuration; +using Adaptation.Shared; +using Adaptation.Shared.Duplicator; +using Adaptation.Shared.Methods; +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Text.Json; + +namespace Adaptation.FileHandlers.APC; + +public class FileRead : Shared.FileRead, IFileRead +{ + + public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : + base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted) + { + _MinFileLength = 10; + _NullData = string.Empty; + _Logistics = new(this); + if (_FileParameter is null) + throw new Exception(cellInstanceConnectionName); + if (_ModelObjectParameterDefinitions is null) + throw new Exception(cellInstanceConnectionName); + if (!_IsDuplicator) + throw new Exception(cellInstanceConnectionName); + } + + void IFileRead.Move(Tuple> extractResults, Exception exception) + { + bool isErrorFile = exception is not null; + if (!isErrorFile && !string.IsNullOrEmpty(_Logistics.ReportFullPath)) + { + FileInfo fileInfo = new(_Logistics.ReportFullPath); + if (fileInfo.Exists && fileInfo.LastWriteTime < fileInfo.CreationTime) + File.SetLastWriteTime(_Logistics.ReportFullPath, fileInfo.CreationTime); + } + Move(extractResults); + } + + void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); + + string IFileRead.GetEventDescription() + { + string result = _Description.GetEventDescription(); + return result; + } + + List IFileRead.GetHeaderNames() + { + List results = _Description.GetHeaderNames(); + return results; + } + + string[] IFileRead.Move(Tuple> extractResults, string to, string from, string resolvedFileLocation, Exception exception) + { + string[] results = Move(extractResults, to, from, resolvedFileLocation, exception); + return results; + } + + JsonProperty[] IFileRead.GetDefault() + { + JsonProperty[] results = _Description.GetDefault(this, _Logistics); + return results; + } + + Dictionary IFileRead.GetDisplayNamesJsonElement() + { + Dictionary results = _Description.GetDisplayNamesJsonElement(this); + return results; + } + + List IFileRead.GetDescriptions(IFileRead fileRead, List tests, IProcessData processData) + { + List results = _Description.GetDescriptions(fileRead, _Logistics, tests, processData); + return results; + } + + Tuple> IFileRead.GetExtractResult(string reportFullPath, string eventName) + { + Tuple> results; + if (string.IsNullOrEmpty(eventName)) + throw new Exception(); + _ReportFullPath = reportFullPath; + DateTime dateTime = DateTime.Now; + results = GetExtractResult(reportFullPath, dateTime); + if (results.Item3 is null) + results = new Tuple>(results.Item1, Array.Empty(), JsonSerializer.Deserialize("[]"), results.Item4); + if (results.Item3.Length > 0 && _IsEAFHosted) + WritePDSF(this, results.Item3); + UpdateLastTicksDuration(DateTime.Now.Ticks - dateTime.Ticks); + return results; + } + + Tuple> IFileRead.ReExtract() + { + Tuple> results; + List headerNames = _Description.GetHeaderNames(); + Dictionary keyValuePairs = _Description.GetDisplayNamesJsonElement(this); + results = ReExtract(this, headerNames, keyValuePairs); + return results; + } + + private void FileCopy(string reportFullPath, DateTime dateTime) + { + bool isDummyRun = false; + List<(Shared.Properties.IScopeInfo, string)> tuples = new(); + string[] segments = Path.GetFileNameWithoutExtension(reportFullPath).Split('_'); + string duplicateDirectory = string.Concat(_FileConnectorConfiguration.TargetFileLocation, @"\", segments[0]); + if (segments.Length > 2) + duplicateDirectory = string.Concat(duplicateDirectory, @"-", segments[2]); + if (!Directory.Exists(duplicateDirectory)) + _ = Directory.CreateDirectory(duplicateDirectory); + string duplicateFile = string.Concat(duplicateDirectory, @"\", Path.GetFileName(reportFullPath)); + string successDirectory = string.Concat(Path.GetDirectoryName(_FileConnectorConfiguration.TargetFileLocation), @"\ViewerPath"); + if (!Directory.Exists(successDirectory)) + _ = Directory.CreateDirectory(successDirectory); + File.Copy(reportFullPath, duplicateFile, overwrite: true); + WaitForFileConsumption(dateTime, isDummyRun, successDirectory, duplicateDirectory, tuples, duplicateFile); + } + + private Tuple> GetExtractResult(string reportFullPath, DateTime dateTime) + { + Tuple> results; + Tuple pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); + _Logistics = new Logistics(reportFullPath, pdsf.Item1); + SetFileParameterLotIDToLogisticsMID(); + JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); + List descriptions = GetDuplicatorDescriptions(jsonElements); + Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); + results = new Tuple>(pdsf.Item1, tests, jsonElements, new List()); + if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) + FileCopy(reportFullPath, dateTime); + return results; + } + +} \ No newline at end of file diff --git a/Adaptation/FileHandlers/Archive/FileRead.cs b/Adaptation/FileHandlers/Archive/FileRead.cs index a502d10..5f13ada 100644 --- a/Adaptation/FileHandlers/Archive/FileRead.cs +++ b/Adaptation/FileHandlers/Archive/FileRead.cs @@ -15,21 +15,26 @@ namespace Adaptation.FileHandlers.Archive; public class FileRead : Shared.FileRead, IFileRead { - public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, bool useCyclicalForDescription, bool isEAFHosted) : - base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, useCyclicalForDescription, isEAFHosted) + private readonly string _JobIdParentDirectory; + private readonly string _JobIdArchiveParentDirectory; + + public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : + base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted) { _MinFileLength = 10; _NullData = string.Empty; - _Logistics = new Logistics(this); + _Logistics = new(this); if (_FileParameter is null) throw new Exception(cellInstanceConnectionName); if (_ModelObjectParameterDefinitions is null) throw new Exception(cellInstanceConnectionName); if (!_IsDuplicator) throw new Exception(cellInstanceConnectionName); + _JobIdParentDirectory = GetJobIdParentDirectory(_FileConnectorConfiguration.SourceFileLocation); + _JobIdArchiveParentDirectory = GetJobIdParentDirectory(_FileConnectorConfiguration.TargetFileLocation); } - void IFileRead.Move(Tuple> extractResults, Exception exception) => Move(extractResults, exception); + void IFileRead.Move(Tuple> extractResults, Exception exception) => Move(extractResults); void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); @@ -94,10 +99,20 @@ public class FileRead : Shared.FileRead, IFileRead return results; } - void IFileRead.CheckTests(Test[] tests, bool extra) + private static IEnumerable GetDirectoriesRecursively(string path, string directoryNameSegment = null) { - if (_Description is not Description) - throw new Exception(); + Queue queue = new(); + queue.Enqueue(path); + while (queue.Count > 0) + { + path = queue.Dequeue(); + foreach (string subDirectory in Directory.GetDirectories(path)) + { + queue.Enqueue(subDirectory); + if (string.IsNullOrEmpty(directoryNameSegment) || Path.GetFileName(subDirectory).Contains(directoryNameSegment)) + yield return subDirectory; + } + } } private void MoveArchive(DateTime dateTime) @@ -106,19 +121,18 @@ public class FileRead : Shared.FileRead, IFileRead { } string logisticsSequence = _Logistics.Sequence.ToString(); string weekOfYear = _Calendar.GetWeekOfYear(_Logistics.DateTimeFromSequence, CalendarWeekRule.FirstDay, DayOfWeek.Sunday).ToString("00"); - string weekDirectory = string.Concat(_Logistics.DateTimeFromSequence.ToString("yyyy"), "_Week_", weekOfYear, @"\", _Logistics.DateTimeFromSequence.ToString("yyyy-MM-dd")); - string jobIdDirectory = string.Concat(_FileConnectorConfiguration.TargetFileLocation, @"\", _Logistics.JobID); - if (!Directory.Exists(jobIdDirectory)) - _ = Directory.CreateDirectory(jobIdDirectory); - //string destinationArchiveDirectory = string.Concat(jobIdDirectory, @"\!Archive\", weekDirectory); - string destinationArchiveDirectory = string.Concat(Path.GetDirectoryName(_FileConnectorConfiguration.TargetFileLocation), @"\Archive\", _Logistics.JobID, @"\", weekDirectory); + string weekDirectory = $"{_Logistics.DateTimeFromSequence:yyyy}_Week_{weekOfYear}{@"\"}{_Logistics.DateTimeFromSequence:yyyy-MM-dd}"; + string destinationArchiveDirectory = Path.Combine(_JobIdArchiveParentDirectory, _Logistics.JobID, weekDirectory); if (!Directory.Exists(destinationArchiveDirectory)) _ = Directory.CreateDirectory(destinationArchiveDirectory); + string jobIdDirectory = Path.Combine(_JobIdParentDirectory, _Logistics.JobID); + if (!Directory.Exists(jobIdDirectory)) + _ = Directory.CreateDirectory(jobIdDirectory); string[] matchDirectories = new string[] { GetDirectoriesRecursively(jobIdDirectory, logisticsSequence).FirstOrDefault() }; if ((matchDirectories is null) || matchDirectories.Length != 1) throw new Exception("Didn't find directory by logistics sequence"); string sourceDirectory = Path.GetDirectoryName(matchDirectories[0]); - destinationArchiveDirectory = string.Concat(destinationArchiveDirectory, @"\", Path.GetFileName(sourceDirectory)); + destinationArchiveDirectory = Path.Combine(destinationArchiveDirectory, Path.GetFileName(sourceDirectory)); Directory.Move(sourceDirectory, destinationArchiveDirectory); } @@ -130,9 +144,9 @@ public class FileRead : Shared.FileRead, IFileRead SetFileParameterLotIDToLogisticsMID(); JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); List descriptions = GetDuplicatorDescriptions(jsonElements); - Tuple>> tuple = GetTuple(this, descriptions, extra: false); + Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); MoveArchive(dateTime); - results = new Tuple>(pdsf.Item1, tuple.Item1, jsonElements, new List()); + results = new Tuple>(pdsf.Item1, tests, jsonElements, new List()); return results; } diff --git a/Adaptation/FileHandlers/CellInstanceConnectionName.cs b/Adaptation/FileHandlers/CellInstanceConnectionName.cs index 2f2845e..31d51b9 100644 --- a/Adaptation/FileHandlers/CellInstanceConnectionName.cs +++ b/Adaptation/FileHandlers/CellInstanceConnectionName.cs @@ -9,30 +9,23 @@ namespace Adaptation.FileHandlers; public class CellInstanceConnectionName { - internal static IFileRead Get(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, bool useCyclicalForDescription, bool isEAFHosted) + internal static IFileRead Get(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) { - IFileRead result; - bool isDuplicator = cellInstanceConnectionName.StartsWith(cellInstanceName); - if (isDuplicator) + IFileRead result = cellInstanceConnectionName switch { - string cellInstanceConnectionNameBase = cellInstanceConnectionName.Replace("-", string.Empty); - int hyphens = cellInstanceConnectionName.Length - cellInstanceConnectionNameBase.Length; - result = hyphens switch - { - (int)MET08DDUPSFS6420.Hyphen.IsArchive => new Archive.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, useCyclicalForDescription, isEAFHosted), - (int)MET08DDUPSFS6420.Hyphen.IsDummy => new Dummy.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, useCyclicalForDescription, isEAFHosted), - (int)MET08DDUPSFS6420.Hyphen.IsXToArchive => new ToArchive.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, useCyclicalForDescription, isEAFHosted), - _ => new MET08DDUPSFS6420.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, useCyclicalForDescription, isEAFHosted) - }; - } - else - { - result = cellInstanceConnectionName switch - { - nameof(pcl) => new pcl.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, useCyclicalForDescription, isEAFHosted), - _ => throw new Exception(), - }; - } + nameof(APC) => new APC.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted), + nameof(Archive) => new Archive.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted), + nameof(Dummy) => new Dummy.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted), + nameof(IQSSi) => new IQSSi.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted), + nameof(MoveMatchingFiles) => new MoveMatchingFiles.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted), + nameof(OpenInsight) => new OpenInsight.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted), + nameof(OpenInsightMetrologyViewer) => new OpenInsightMetrologyViewer.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted), + nameof(OpenInsightMetrologyViewerAttachments) => new OpenInsightMetrologyViewerAttachments.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted), + nameof(pcl) => new pcl.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted), + nameof(Processed) => new Processed.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted), + nameof(SPaCe) => new SPaCe.FileRead(smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted), + _ => throw new Exception($"\"{cellInstanceConnectionName}\" not mapped") + }; return result; } diff --git a/Adaptation/FileHandlers/Dummy/FileRead.cs b/Adaptation/FileHandlers/Dummy/FileRead.cs index 6ef5f81..993a12c 100644 --- a/Adaptation/FileHandlers/Dummy/FileRead.cs +++ b/Adaptation/FileHandlers/Dummy/FileRead.cs @@ -23,12 +23,12 @@ public class FileRead : Shared.FileRead, IFileRead private int _LastDummyRunIndex; private readonly string[] _CellNames; - public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, bool useCyclicalForDescription, bool isEAFHosted) : - base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, useCyclicalForDescription, isEAFHosted) + public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : + base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted) { _MinFileLength = 10; _NullData = string.Empty; - _Logistics = new Logistics(this); + _Logistics = new(this); if (_FileParameter is null) throw new Exception(cellInstanceConnectionName); if (_ModelObjectParameterDefinitions is null) @@ -51,7 +51,7 @@ public class FileRead : Shared.FileRead, IFileRead } } - void IFileRead.Move(Tuple> extractResults, Exception exception) => Move(extractResults, exception); + void IFileRead.Move(Tuple> extractResults, Exception exception) => Move(extractResults); void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); @@ -95,12 +95,6 @@ public class FileRead : Shared.FileRead, IFileRead Tuple> IFileRead.ReExtract() => throw new Exception(string.Concat("See ", nameof(CallbackFileExists))); - void IFileRead.CheckTests(Test[] tests, bool extra) - { - if (_Description is not Description) - throw new Exception(); - } - private void CallbackInProcessCleared(string sourceArchiveFile, string traceDummyFile, string targetFileLocation, string monARessource, string inProcessDirectory, long sequence, bool warning) { const string site = "sjc"; @@ -159,7 +153,7 @@ public class FileRead : Shared.FileRead, IFileRead if (!_DummyRuns[monARessource].Contains(sequence)) _DummyRuns[monARessource].Add(sequence); File.AppendAllLines(traceDummyFile, new string[] { sourceArchiveFile }); - string inProcessDirectory = Path.Combine(_ProgressPath, "Dummy In-Process", sequence.ToString()); + string inProcessDirectory = Path.Combine("_ProgressPath", "Dummy In-Process", sequence.ToString()); if (!Directory.Exists(inProcessDirectory)) _ = Directory.CreateDirectory(inProcessDirectory); files = Directory.GetFiles(inProcessDirectory, "*", SearchOption.AllDirectories); diff --git a/Adaptation/FileHandlers/ManualOIEntry/FileRead.cs b/Adaptation/FileHandlers/IQSSi/FileRead.cs similarity index 74% rename from Adaptation/FileHandlers/ManualOIEntry/FileRead.cs rename to Adaptation/FileHandlers/IQSSi/FileRead.cs index 7b8c9a7..7048f14 100644 --- a/Adaptation/FileHandlers/ManualOIEntry/FileRead.cs +++ b/Adaptation/FileHandlers/IQSSi/FileRead.cs @@ -3,24 +3,23 @@ using Adaptation.Ifx.Eaf.EquipmentConnector.File.Configuration; using Adaptation.Shared; using Adaptation.Shared.Duplicator; using Adaptation.Shared.Methods; -using Infineon.Monitoring.MonA; using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Text.Json; -namespace Adaptation.FileHandlers.IsManualOIEntry; +namespace Adaptation.FileHandlers.IQSSi; public class FileRead : Shared.FileRead, IFileRead { - public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, bool useCyclicalForDescription, bool isEAFHosted) : - base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, useCyclicalForDescription, isEAFHosted) + public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : + base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted) { _MinFileLength = 10; _NullData = string.Empty; - _Logistics = new Logistics(this); + _Logistics = new(this); if (_FileParameter is null) throw new Exception(cellInstanceConnectionName); if (_ModelObjectParameterDefinitions is null) @@ -38,7 +37,7 @@ public class FileRead : Shared.FileRead, IFileRead if (fileInfo.Exists && fileInfo.LastWriteTime < fileInfo.CreationTime) File.SetLastWriteTime(_Logistics.ReportFullPath, fileInfo.CreationTime); } - Move(extractResults, exception); + Move(extractResults); } void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); @@ -104,39 +103,18 @@ public class FileRead : Shared.FileRead, IFileRead return results; } - void IFileRead.CheckTests(Test[] tests, bool extra) - { - if (_Description is not Description) - throw new Exception(); - } - private Tuple> GetExtractResult(string reportFullPath, DateTime dateTime) { if (dateTime == DateTime.MinValue) { } - Tuple> results = new(string.Empty, null, null, new List()); - string monARessource; - const string site = "sjc"; - string equipment = string.Empty; - string description = string.Empty; - string stateName = "MANUAL_OI_ENTRY"; - string json = File.ReadAllText(reportFullPath); - JsonElement jsonElement = JsonSerializer.Deserialize(json); - foreach (JsonProperty jsonProperty in jsonElement.EnumerateObject()) - { - if (jsonProperty.Name == "Equipment") - equipment = jsonProperty.Value.ToString(); - else if (jsonProperty.Name == "Description") - description = jsonProperty.Value.ToString(); - } - if (string.IsNullOrEmpty(equipment)) - monARessource = _CellInstanceName; - else - monARessource = equipment; - const string monInURL = "http://moninhttp.sjc.infineon.com/input/text"; - MonIn monIn = MonIn.GetInstance(monInURL); - if (_IsEAFHosted) - _ = monIn.SendStatus(site, monARessource, stateName, State.Warning, description); + Tuple> results; + Tuple pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); + _Logistics = new Logistics(reportFullPath, pdsf.Item1); + SetFileParameterLotIDToLogisticsMID(); + JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); + List descriptions = GetDuplicatorDescriptions(jsonElements); + Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); + results = new Tuple>(pdsf.Item1, tests, jsonElements, new List()); return results; } diff --git a/Adaptation/FileHandlers/MET08DDUPSFS6420/FileRead.cs b/Adaptation/FileHandlers/MET08DDUPSFS6420/FileRead.cs deleted file mode 100644 index 7adc4e9..0000000 --- a/Adaptation/FileHandlers/MET08DDUPSFS6420/FileRead.cs +++ /dev/null @@ -1,305 +0,0 @@ -using Adaptation.Eaf.Management.ConfigurationData.CellAutomation; -using Adaptation.Ifx.Eaf.EquipmentConnector.File.Configuration; -using Adaptation.Shared; -using Adaptation.Shared.Duplicator; -using Adaptation.Shared.Methods; -using Adaptation.Shared.Metrology; -using Infineon.Monitoring.MonA; -using System; -using System.Collections.Generic; -using System.Diagnostics; -using System.Globalization; -using System.IO; -using System.IO.Compression; -using System.Linq; -using System.Text.Json; -using System.Text.Json.Serialization; -using System.Threading; - -namespace Adaptation.FileHandlers.MET08DDUPSFS6420; - -public class FileRead : Shared.FileRead, IFileRead -{ - - private readonly bool _IsNaEDA; - private readonly bool _IsXToAPC; - private readonly string _IqsFile; - private readonly bool _IsXToIQSSi; - private readonly bool _IsXToSPaCe; - private readonly bool _IsXToIQSGaN; - private readonly string _MemoryPath; - private readonly bool _IsXToOpenInsight; - private readonly string _OpenInsightFilePattern; - private readonly bool _IsXToOpenInsightMetrologyViewer; - private readonly Dictionary _CellNames; - private readonly string _OpenInsightMetrologyViewerAPI; - private readonly bool _IsXToOpenInsightMetrologyViewerAttachments; - - public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, bool useCyclicalForDescription, bool isEAFHosted) : - base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, useCyclicalForDescription, isEAFHosted) - { - _MinFileLength = 10; - _NullData = string.Empty; - _Logistics = new Logistics(this); - if (_FileParameter is null) - throw new Exception(cellInstanceConnectionName); - if (_ModelObjectParameterDefinitions is null) - throw new Exception(cellInstanceConnectionName); - if (!_IsDuplicator) - throw new Exception(cellInstanceConnectionName); - _IsNaEDA = _Hyphens == (int)Hyphen.IsNaEDA; - _IsXToAPC = _Hyphens == (int)Hyphen.IsXToAPC; - _CellNames = new Dictionary(); - _IsXToIQSSi = _Hyphens == (int)Hyphen.IsXToIQSSi; - _IsXToSPaCe = _Hyphens == (int)Hyphen.IsXToSPaCe; - _IsXToIQSGaN = _Hyphens == (int)Hyphen.IsXToIQSGaN; - _IsXToOpenInsight = _Hyphens == (int)Hyphen.IsXToOpenInsight; - _IsXToOpenInsightMetrologyViewer = _Hyphens == (int)Hyphen.IsXToOpenInsightMetrologyViewer; - _IqsFile = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "IQS.File"); - _MemoryPath = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "Path.Memory"); - _IsXToOpenInsightMetrologyViewerAttachments = _Hyphens == (int)Hyphen.IsXToOpenInsightMetrologyViewerAttachments; - _OpenInsightFilePattern = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "OpenInsight.FilePattern"); - _OpenInsightMetrologyViewerAPI = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "OpenInsight.MetrologyViewerAPI"); - ModelObjectParameterDefinition[] cellInstanceCollection = GetProperties(cellInstanceConnectionName, modelObjectParameters, "CellInstance.", ".Path"); - foreach (ModelObjectParameterDefinition modelObjectParameterDefinition in cellInstanceCollection) - _CellNames.Add(modelObjectParameterDefinition.Name.Split('.')[1], modelObjectParameterDefinition.Value); - } - - void IFileRead.Move(Tuple> extractResults, Exception exception) => Move(extractResults, exception); - - void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); - - string IFileRead.GetEventDescription() - { - string result = _Description.GetEventDescription(); - return result; - } - - List IFileRead.GetHeaderNames() - { - List results = _Description.GetHeaderNames(); - return results; - } - - string[] IFileRead.Move(Tuple> extractResults, string to, string from, string resolvedFileLocation, Exception exception) - { - string[] results = Move(extractResults, to, from, resolvedFileLocation, exception); - return results; - } - - JsonProperty[] IFileRead.GetDefault() - { - JsonProperty[] results = _Description.GetDefault(this, _Logistics); - return results; - } - - Dictionary IFileRead.GetDisplayNamesJsonElement() - { - Dictionary results = _Description.GetDisplayNamesJsonElement(this); - return results; - } - - List IFileRead.GetDescriptions(IFileRead fileRead, List tests, IProcessData processData) - { - List results = _Description.GetDescriptions(fileRead, _Logistics, tests, processData); - return results; - } - - Tuple> IFileRead.GetExtractResult(string reportFullPath, string eventName) - { - Tuple> results; - if (string.IsNullOrEmpty(eventName)) - throw new Exception(); - _ReportFullPath = reportFullPath; - DateTime dateTime = DateTime.Now; - results = GetExtractResult(reportFullPath, dateTime); - if (results.Item3 is null) - results = new Tuple>(results.Item1, Array.Empty(), JsonSerializer.Deserialize("[]"), results.Item4); - if (results.Item3.Length > 0 && _IsEAFHosted) - WritePDSF(this, results.Item3); - UpdateLastTicksDuration(DateTime.Now.Ticks - dateTime.Ticks); - return results; - } - - Tuple> IFileRead.ReExtract() - { - Tuple> results; - List headerNames = _Description.GetHeaderNames(); - Dictionary keyValuePairs = _Description.GetDisplayNamesJsonElement(this); - results = ReExtract(this, headerNames, keyValuePairs); - return results; - } - - void IFileRead.CheckTests(Test[] tests, bool extra) - { - if (_Description is not Description) - throw new Exception(); - } - - protected static List GetDescriptions(JsonElement[] jsonElements) - { - List results = new(); - pcl.Description description; - JsonSerializerOptions jsonSerializerOptions = new() { NumberHandling = JsonNumberHandling.AllowReadingFromString | JsonNumberHandling.WriteAsString }; - foreach (JsonElement jsonElement in jsonElements) - { - if (jsonElement.ValueKind != JsonValueKind.Object) - throw new Exception(); - description = JsonSerializer.Deserialize(jsonElement.ToString(), jsonSerializerOptions); - results.Add(description); - } - return results; - } - - private Tuple> GetExtractResult(string reportFullPath, DateTime dateTime) - { - Tuple> results; - string duplicateDirectory; - Tuple pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); - _Logistics = new Logistics(reportFullPath, pdsf.Item1); - SetFileParameterLotIDToLogisticsMID(); - JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); - List descriptions = GetDescriptions(jsonElements); - Tuple>> tuple = GetTuple(this, from l in descriptions select (Shared.Properties.IDescription)l, extra: false); - results = new Tuple>(pdsf.Item1, tuple.Item1, jsonElements, new List()); - bool isNotUsedInsightMetrologyViewerAttachments = !(_FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) && _IsXToOpenInsightMetrologyViewerAttachments; - bool isDummyRun = _DummyRuns.Any() && _DummyRuns.ContainsKey(_Logistics.JobID) && _DummyRuns[_Logistics.JobID].Any() && (from l in _DummyRuns[_Logistics.JobID] where l == _Logistics.Sequence select 1).Any(); - if (isDummyRun) - { - try - { File.SetLastWriteTime(reportFullPath, dateTime); } - catch (Exception) { } - } - string[] segments = Path.GetFileNameWithoutExtension(reportFullPath).Split('_'); - if (_IsXToIQSSi) - duplicateDirectory = string.Concat(_FileConnectorConfiguration.TargetFileLocation, @"\All"); - else if (!_IsXToOpenInsight) - duplicateDirectory = string.Concat(_FileConnectorConfiguration.TargetFileLocation, @"\", segments[0]); - else - duplicateDirectory = string.Concat(Path.GetDirectoryName(Path.GetDirectoryName(_FileConnectorConfiguration.TargetFileLocation)), @"\Data"); - if (segments.Length > 2) - duplicateDirectory = string.Concat(duplicateDirectory, @"-", segments[2]); - if (!Directory.Exists(duplicateDirectory)) - _ = Directory.CreateDirectory(duplicateDirectory); - if (isDummyRun || isNotUsedInsightMetrologyViewerAttachments || _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) - { - bool ganPPTST = false; - if (!Directory.Exists(duplicateDirectory)) - _ = Directory.CreateDirectory(duplicateDirectory); - string successDirectory; - if (!_IsXToAPC) - successDirectory = string.Empty; - else - { - successDirectory = string.Concat(Path.GetDirectoryName(_FileConnectorConfiguration.TargetFileLocation), @"\ViewerPath"); - if (!Directory.Exists(successDirectory)) - _ = Directory.CreateDirectory(successDirectory); - } - List> tuples = new(); - string duplicateFile = string.Concat(duplicateDirectory, @"\", Path.GetFileName(reportFullPath)); - string weekOfYear = _Calendar.GetWeekOfYear(_Logistics.DateTimeFromSequence, CalendarWeekRule.FirstDay, DayOfWeek.Sunday).ToString("00"); - string weekDirectory = string.Concat(_Logistics.DateTimeFromSequence.ToString("yyyy"), "_Week_", weekOfYear, @"\", _Logistics.DateTimeFromSequence.ToString("yyyy-MM-dd")); - string logisticsSequenceMemoryDirectory = string.Concat(_MemoryPath, @"\", _EquipmentType, @"\Source\", weekDirectory, @"\", _Logistics.Sequence); - if (!Directory.Exists(logisticsSequenceMemoryDirectory)) - _ = Directory.CreateDirectory(logisticsSequenceMemoryDirectory); - if (_IsXToAPC) - { - if (!isDummyRun && _IsEAFHosted) - File.Copy(reportFullPath, duplicateFile, overwrite: true); - } - else - { - if (_IsXToOpenInsightMetrologyViewer) - { - WSRequest wsRequest = new(this, _Logistics, descriptions); - if (!isDummyRun && _IsEAFHosted) - { - Tuple wsResults = WS.SendData(_OpenInsightMetrologyViewerAPI, wsRequest); - if (!wsResults.Item2.Success) - throw new Exception(wsResults.ToString()); - _Log.Debug(wsResults.Item2.HeaderID); - File.WriteAllText(string.Concat(logisticsSequenceMemoryDirectory, @"\", nameof(WS.Results), ".json"), wsResults.Item1); - } - } - else - { - Test test; - string lines; - Shared.Properties.IScopeInfo scopeInfo; - foreach (KeyValuePair> keyValuePair in tuple.Item2) - { - test = keyValuePair.Key; - //scopeInfo = new ScopeInfo(test); - if (!_IsXToOpenInsight) - scopeInfo = new ScopeInfo(test, _IqsFile); - else - scopeInfo = new ScopeInfo(test, _OpenInsightFilePattern); - //lines = ProcessDataStandardFormat.GetLines(this, scopeInfo, names, values, dateFormat: "M/d/yyyy hh:mm:ss tt", timeFormat: string.Empty, pairedColumns: ExtractResultPairedColumns); - ganPPTST = descriptions[0].Recipe.Contains("GAN_PPTST"); - lines = ProcessData.GetLines(this, _Logistics, descriptions, ganPPTST); - tuples.Add(new Tuple(scopeInfo, lines)); - } - } - if (_IsXToOpenInsightMetrologyViewerAttachments) - { - string[] matchDirectories = Shared1567(reportFullPath, tuples); - if (!isDummyRun && _IsEAFHosted && !isNotUsedInsightMetrologyViewerAttachments) - ProcessData.PostOpenInsightMetrologyViewerAttachments(this, _Logistics, _OpenInsightMetrologyViewerAPI, dateTime, logisticsSequenceMemoryDirectory, descriptions, matchDirectories[0]); - } - } - if (!_IsXToOpenInsightMetrologyViewer && !_IsXToOpenInsightMetrologyViewerAttachments) - { - bool check = false; - if (!_IsXToIQSSi && !_IsXToIQSGaN) - check = true; - else if (_IsXToIQSSi && !ganPPTST) - check = true; - else if (_IsXToIQSGaN && ganPPTST) - check = true; - //else - // Don't write file(s) //throw new Exception(); - if (check) - Shared0413(dateTime, isDummyRun, successDirectory, duplicateDirectory, tuples, duplicateFile); - } - } - if (_IsXToOpenInsightMetrologyViewerAttachments) - { - string destinationDirectory; - //string destinationDirectory = WriteScopeInfo(_ProgressPath, _Logistics, dateTime, duplicateDirectory, tuples); - FileInfo fileInfo = new(reportFullPath); - string logisticsSequence = _Logistics.Sequence.ToString(); - if (fileInfo.Exists && fileInfo.LastWriteTime < fileInfo.CreationTime) - File.SetLastWriteTime(reportFullPath, fileInfo.CreationTime); - string jobIdDirectory = string.Concat(Path.GetDirectoryName(Path.GetDirectoryName(_FileConnectorConfiguration.TargetFileLocation)), @"\", _Logistics.JobID); - if (!Directory.Exists(jobIdDirectory)) - _ = Directory.CreateDirectory(jobIdDirectory); - string[] matchDirectories; - if (!_IsEAFHosted) - matchDirectories = new string[] { Path.GetDirectoryName(Path.GetDirectoryName(reportFullPath)) }; - else - matchDirectories = Directory.GetDirectories(jobIdDirectory, string.Concat(_Logistics.MID, '*', logisticsSequence, '*'), SearchOption.TopDirectoryOnly); - if ((matchDirectories is null) || matchDirectories.Length != 1) - throw new Exception("Didn't find directory by logistics sequence"); - destinationDirectory = matchDirectories[0]; - if (isDummyRun) - Shared0607(reportFullPath, duplicateDirectory, logisticsSequence, destinationDirectory); - else - { - WSRequest wsRequest = new(this, _Logistics, descriptions); - JsonSerializerOptions jsonSerializerOptions = new() { WriteIndented = true }; - string json = JsonSerializer.Serialize(wsRequest, wsRequest.GetType(), jsonSerializerOptions); - if (_IsEAFHosted) - Shared1277(reportFullPath, destinationDirectory, logisticsSequence, jobIdDirectory, json); - else - { - string jsonFileName = Path.ChangeExtension(reportFullPath, ".json"); - string historicalText = File.ReadAllText(jsonFileName); - if (json != historicalText) - throw new Exception("File doesn't match historical!"); - } - } - } - return results; - } - -} \ No newline at end of file diff --git a/Adaptation/FileHandlers/MET08DDUPSFS6420/Hyphen.cs b/Adaptation/FileHandlers/MET08DDUPSFS6420/Hyphen.cs deleted file mode 100644 index f71c3f1..0000000 --- a/Adaptation/FileHandlers/MET08DDUPSFS6420/Hyphen.cs +++ /dev/null @@ -1,17 +0,0 @@ -namespace Adaptation.FileHandlers.MET08DDUPSFS6420; - -public enum Hyphen -{ - IsXToOpenInsightMetrologyViewer, //MetrologyWS.SendData(logic, string.Concat("http://", serverName, "/api/inbound/Tencor"), headerAttachments, detailAttachments); - IsXToIQSSi, //bool WriteFileSPC(Dictionary - IsXToIQSGaN, //GAN_PPTST - IsXToOpenInsight, //bool WriteFileOpenInsight(Dictionary - IsXToOpenInsightMetrologyViewerAttachments, //Site-Two - IsXToAPC, - IsXToSPaCe, - IsXToArchive, - IsArchive, - IsDummy, - IsManualOIEntry, - IsNaEDA -} \ No newline at end of file diff --git a/Adaptation/FileHandlers/MET08DDUPSFS6420/ProcessData.cs b/Adaptation/FileHandlers/MET08DDUPSFS6420/ProcessData.cs deleted file mode 100644 index faa37a8..0000000 --- a/Adaptation/FileHandlers/MET08DDUPSFS6420/ProcessData.cs +++ /dev/null @@ -1,278 +0,0 @@ -using Adaptation.Shared; -using Adaptation.Shared.Metrology; -using Adaptation.Shared.Properties; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Text; -using System.Text.Json; - -namespace Adaptation.FileHandlers.MET08DDUPSFS6420; - -public class ProcessData -{ - - internal static List> HyphenTuples => new() - { - new Tuple(0, Hyphen.IsNaEDA, @"\EC_EDA\Staging\Traces\~\Source"), - new Tuple(15, Hyphen.IsXToOpenInsightMetrologyViewer, @"\EC_EAFLog\TracesMES\~\Source"), - new Tuple(36, Hyphen.IsXToIQSSi, @"\EC_SPC_Si\Traces\~\PollPath"), - new Tuple(36, Hyphen.IsXToIQSGaN, @"\EC_SPC_GaN\Traces\~\PollPath"), - new Tuple(36, Hyphen.IsXToOpenInsight, @"\\messa01ec.ec.local\APPS\Metrology\~\Source"), - new Tuple(36, Hyphen.IsXToOpenInsightMetrologyViewerAttachments, @"\EC_Characterization_Si\In Process\~\Source"), - new Tuple(360, Hyphen.IsXToAPC, @"\EC_APC\Staging\Traces\~\PollPath"), - new Tuple(-36, Hyphen.IsXToSPaCe, @"\EC_SPC_Si\Traces\~\Source"), - new Tuple(180, Hyphen.IsXToArchive, @"\EC_EAFLog\TracesArchive\~\Source"), - new Tuple(36, Hyphen.IsArchive, @"\EC_Characterization_Si\Processed") - //new Tuple("IsDummy" - }; - - internal static string GetLines(IFileRead fileRead, Logistics logistics, List descriptions, bool ganPPTST) - { - if (fileRead is null) - { } - StringBuilder result = new(); - pcl.Description x = descriptions[0]; - if (ganPPTST) - { - string slot; - string reactor; - const int eight = 8; - DateTime dateTime = DateTime.Parse(x.Date); - string lot = x.Lot.ToLower().Replace("69-", string.Empty).Replace("71-", string.Empty).Replace("-", string.Empty); - if (string.IsNullOrEmpty(x.Lot) || x.Lot.Length < 2) - reactor = "R"; - else - reactor = string.Concat("R", x.Lot.Substring(0, 2)); - _ = result.Append(nameof(x.Date)).Append(';'). - Append("Part").Append(';'). - Append(nameof(x.Reactor)).Append(';'). - Append("Lot").Append(';'). - Append(nameof(pcl.Detail.Slot)).Append(';'). - Append(nameof(pcl.Detail.Bin1)).Append(';'). - Append(nameof(pcl.Detail.Bin2)).Append(';'). - Append(nameof(pcl.Detail.Bin3)).Append(';'). - Append(nameof(pcl.Detail.Bin4)).Append(';'). - Append(nameof(pcl.Detail.Bin5)).Append(';'). - Append(nameof(pcl.Detail.Bin6)).Append(';'). - Append("Bin9"). - AppendLine(); - foreach (pcl.Description description in descriptions) - { - slot = description.Slot.Replace("*", string.Empty); - _ = result.Append('!').Append(dateTime.ToString("MM/dd/yyyy HH:mm:ss")).Append(';'). - Append("Particle Adder;"). - Append(reactor).Append(';'). - Append(lot).Append(';'). - Append(slot).Append(';'). - Append(description.Bin1).Append(';'). - Append(description.Bin2).Append(';'). - Append(description.Bin3).Append(';'). - Append(description.Bin4).Append(';'). - Append(description.Bin5).Append(';'). - Append(description.Bin6).Append(';'). - Append(description.AreaCount). - AppendLine(); - } - if (descriptions.Count != eight) - { - string negativeTenThousand = "-10000"; - for (int i = descriptions.Count; i < eight; i++) - { - _ = result.Append('!').Append(dateTime.ToString("MM/dd/yyyy HH:mm:ss")).Append(';'). - Append("Particle Adder;"). - Append(reactor).Append(';'). - Append(lot).Append(';'). - Append(negativeTenThousand).Append(';'). - Append(negativeTenThousand).Append(';'). - Append(negativeTenThousand).Append(';'). - Append(negativeTenThousand).Append(';'). - Append(negativeTenThousand).Append(';'). - Append(negativeTenThousand).Append(';'). - Append(negativeTenThousand).Append(';'). - Append(negativeTenThousand). - AppendLine(); - } - } - if (result.ToString().Split('\n').Length != (eight + 2)) - throw new Exception(string.Concat("Must have ", eight, " samples")); - } - else - { - char del = '\t'; - _ = result.Append(x.AreaCountAvg).Append(del). // 001 - AreaCountAvg - Append(x.AreaCountMax).Append(del). // 002 - AreaCountMax - Append(x.AreaCountMin).Append(del). // 003 - AreaCountMin - Append(x.AreaCountStdDev).Append(del). // 004 - AreaCountStdDev - Append(x.AreaTotalAvg).Append(del). // 005 - AreaTotalAvg - Append(x.AreaTotalMax).Append(del). // 006 - AreaTotalMax - Append(x.AreaTotalMin).Append(del). // 007 - AreaTotalMin - Append(x.AreaTotalStdDev).Append(del). // 008 - AreaTotalStdDev - Append(x.Date).Append(del). // 009 - - Append(x.HazeAverageAvg).Append(del). // 010 - Haze Average - Append(x.HazeAverageMax).Append(del). // 011 - - Append(x.HazeAverageMin).Append(del). // 012 - - Append(x.HazeAverageStdDev).Append(del). // 013 - - Append(x.HazeRegionAvg).Append(del). // 014 - - Append(x.HazeRegionMax).Append(del). // 015 - - Append(x.HazeRegionMin).Append(del). // 016 - - Append(x.HazeRegionStdDev).Append(del). // 017 - - Append(x.Lot).Append(del). // 018 - - Append(x.LPDCM2Avg).Append(del). // 019 - - Append(x.LPDCM2Max).Append(del). // 020 - - Append(x.LPDCM2Min).Append(del). // 021 - - Append(x.LPDCM2StdDev).Append(del). // 022 - - Append(x.LPDCountAvg).Append(del). // 023 - - Append(x.LPDCountMax).Append(del). // 024 - - Append(x.LPDCM2Min).Append(del). // 025 - - Append(x.LPDCountStdDev).Append(del). // 026 - - Append(x.Employee).Append(del). // 027 - - Append(x.RDS).Append(del). // 028 - Lot - Append(x.Reactor).Append(del). // 029 - Process - Append(x.Recipe.Replace(";", string.Empty)).Append(del). // 030 - Part - Append(x.ScratchCountAvg).Append(del). // 031 - Scratch Count - Append(x.ScratchCountMax).Append(del). // 032 - - Append(x.ScratchCountMin).Append(del). // 033 - - Append(x.ScratchTotalStdDev).Append(del). // 034 - - Append(x.ScratchTotalAvg).Append(del). // 035 - Scratch Length - Append(x.ScratchTotalMax).Append(del). // 036 - - Append(x.ScratchTotalMin).Append(del). // 037 - - Append(x.ScratchTotalStdDev).Append(del). // 038 - - Append(x.SumOfDefectsAvg).Append(del). // 039 - Average Sum of Defects - Append(x.SumOfDefectsMax).Append(del). // 040 - Max Sum of Defects - Append(x.SumOfDefectsMin).Append(del). // 041 - Min Sum of Defects - Append(x.SumOfDefectsStdDev).Append(del). // 042 - SumOfDefectsStdDev - Append(logistics.MesEntity).Append(del). // 043 - - AppendLine(); - } - return result.ToString(); - } - - private static void UpdateDataPDF(List descriptions, string checkFileName) - { - string value; - object possiblePage; - object possibleString; - object possibleCOSArray; - java.util.List tokenList; - java.util.List arrayList; - java.io.OutputStream outputStream; - List updateValues = new(); - StringBuilder stringBuilder = new(); - java.util.ListIterator tokenIterator; - java.util.ListIterator arrayIterator; - java.io.File file = new(checkFileName); - string reactorLoadLock = descriptions[0].Comments; - org.apache.pdfbox.pdmodel.common.PDStream pdStream; - org.apache.pdfbox.pdmodel.common.PDStream updatedStream; - org.apache.pdfbox.pdfparser.PDFStreamParser pdfStreamParser; - org.apache.pdfbox.pdfwriter.ContentStreamWriter contentStreamWriter; - org.apache.pdfbox.pdmodel.PDDocument pdDocument = org.apache.pdfbox.pdmodel.PDDocument.load(file); - org.apache.pdfbox.pdmodel.PDDocumentCatalog pdDocumentCatalog = pdDocument.getDocumentCatalog(); - java.util.List pagesList = pdDocumentCatalog.getAllPages(); - java.util.ListIterator pageIterator = pagesList.listIterator(); - for (short i = 1; i < short.MaxValue; i++) - { - if (!pageIterator.hasNext()) - break; - possiblePage = pageIterator.next(); - if (possiblePage is not org.apache.pdfbox.pdmodel.PDPage page) - continue; - pdStream = page.getContents(); - pdfStreamParser = new org.apache.pdfbox.pdfparser.PDFStreamParser(pdStream); - pdfStreamParser.parse(); - tokenList = pdfStreamParser.getTokens(); - tokenIterator = tokenList.listIterator(); - for (short t = 1; i < short.MaxValue; t++) - { - if (!tokenIterator.hasNext()) - break; - possibleCOSArray = tokenIterator.next(); - if (possibleCOSArray is not org.apache.pdfbox.cos.COSArray cossArray) - continue; - _ = stringBuilder.Clear(); - arrayList = cossArray.toList(); - arrayIterator = arrayList.listIterator(); - for (short a = 1; i < short.MaxValue; a++) - { - if (!arrayIterator.hasNext()) - break; - possibleString = arrayIterator.next(); - if (possibleString is not org.apache.pdfbox.cos.COSString cossString) - continue; - value = cossString.getString(); - _ = stringBuilder.Append(value); - if (value != "]") - continue; - updateValues.Add(value); - value = stringBuilder.ToString(); - if (value.Contains("[]")) - cossArray.setString(a - 1, string.Concat("*", reactorLoadLock, "]")); - else - cossArray.setString(a - 1, string.Concat(" {*", reactorLoadLock, "}]")); - } - } - if (updateValues.Any()) - { - updatedStream = new org.apache.pdfbox.pdmodel.common.PDStream(pdDocument); - outputStream = updatedStream.createOutputStream(); - contentStreamWriter = new org.apache.pdfbox.pdfwriter.ContentStreamWriter(outputStream); - contentStreamWriter.writeTokens(tokenList); - outputStream.close(); - page.setContents(updatedStream); - } - } - if (updateValues.Any()) - pdDocument.save(checkFileName); - pdDocument.close(); - } - - internal static void PostOpenInsightMetrologyViewerAttachments(IFileRead fileRead, Logistics logistics, string openInsightMetrologyViewerAPI, DateTime dateTime, string logisticsSequenceMemoryDirectory, List descriptions, string matchDirectory) - { - if (fileRead is null) - { } - if (dateTime == DateTime.MinValue) - { } - if (logisticsSequenceMemoryDirectory is null) - { } - if (descriptions is null) - { } - if (matchDirectory is null) - { } - string checkFileName; - string[] pclFiles = Directory.GetFiles(matchDirectory, "*.pcl", SearchOption.TopDirectoryOnly); - if (pclFiles.Length != 1) - throw new Exception("Invalid source file count!"); - string sourceFileNameNoExt = Path.GetFileNameWithoutExtension(pclFiles[0]); - string wsResultsMemoryFile = string.Concat(logisticsSequenceMemoryDirectory, @"\", nameof(WS.Results), ".json"); - if (!File.Exists(wsResultsMemoryFile)) - throw new Exception(string.Concat("Memory file <", wsResultsMemoryFile, "> doesn't exist!")); - string json = File.ReadAllText(wsResultsMemoryFile); - WS.Results metrologyWSRequest = JsonSerializer.Deserialize(json); - long wsResultsHeaderID = metrologyWSRequest.HeaderID; - List dataAttachments = new(); - List headerAttachments = new(); - checkFileName = string.Concat(matchDirectory, @"\", sourceFileNameNoExt, "_data.pdf"); - if (!File.Exists(checkFileName)) - throw new Exception("Header file doesn't exist!"); - else - { - UpdateDataPDF(descriptions, checkFileName); - headerAttachments.Add(new WS.Attachment(descriptions[0].HeaderUniqueId, "Data.pdf", checkFileName)); - } - foreach (pcl.Description description in descriptions) - { - checkFileName = string.Concat(matchDirectory, @"\", sourceFileNameNoExt, "_", description.Slot.Replace('*', 's'), "_image.pdf"); - if (File.Exists(checkFileName)) - dataAttachments.Add(new WS.Attachment(description.UniqueId, "Image.pdf", checkFileName)); - checkFileName = string.Concat(matchDirectory, @"\", sourceFileNameNoExt, "_", description.Slot.Replace('*', 's'), "_data.pdf"); - if (File.Exists(checkFileName)) - dataAttachments.Add(new WS.Attachment(description.UniqueId, "Data.pdf", checkFileName)); - } - if (dataAttachments.Count == 0 || dataAttachments.Count != descriptions.Count) - throw new Exception("Invalid attachment count!"); - WS.AttachFiles(openInsightMetrologyViewerAPI, wsResultsHeaderID, headerAttachments, dataAttachments); - } - -} \ No newline at end of file diff --git a/Adaptation/FileHandlers/MoveMatchingFiles/FileRead.cs b/Adaptation/FileHandlers/MoveMatchingFiles/FileRead.cs new file mode 100644 index 0000000..32677f5 --- /dev/null +++ b/Adaptation/FileHandlers/MoveMatchingFiles/FileRead.cs @@ -0,0 +1,198 @@ +using Adaptation.Eaf.Management.ConfigurationData.CellAutomation; +using Adaptation.Ifx.Eaf.EquipmentConnector.File.Configuration; +using Adaptation.Shared; +using Adaptation.Shared.Duplicator; +using Adaptation.Shared.Methods; +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Text.Json; + +namespace Adaptation.FileHandlers.MoveMatchingFiles; + +public class FileRead : Shared.FileRead, IFileRead +{ + + public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : + base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted) + { + _MinFileLength = 10; + _NullData = string.Empty; + _Logistics = new(this); + if (_FileParameter is null) + throw new Exception(cellInstanceConnectionName); + if (_ModelObjectParameterDefinitions is null) + throw new Exception(cellInstanceConnectionName); + if (!_IsDuplicator) + throw new Exception(cellInstanceConnectionName); + } + + void IFileRead.Move(Tuple> extractResults, Exception exception) + { + bool isErrorFile = exception is not null; + if (!isErrorFile && !string.IsNullOrEmpty(_Logistics.ReportFullPath)) + { + FileInfo fileInfo = new(_Logistics.ReportFullPath); + if (fileInfo.Exists && fileInfo.LastWriteTime < fileInfo.CreationTime) + File.SetLastWriteTime(_Logistics.ReportFullPath, fileInfo.CreationTime); + } + Move(extractResults); + } + + void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); + + string IFileRead.GetEventDescription() + { + string result = _Description.GetEventDescription(); + return result; + } + + List IFileRead.GetHeaderNames() + { + List results = _Description.GetHeaderNames(); + return results; + } + + string[] IFileRead.Move(Tuple> extractResults, string to, string from, string resolvedFileLocation, Exception exception) + { + string[] results = Move(extractResults, to, from, resolvedFileLocation, exception); + return results; + } + + JsonProperty[] IFileRead.GetDefault() + { + JsonProperty[] results = _Description.GetDefault(this, _Logistics); + return results; + } + + Dictionary IFileRead.GetDisplayNamesJsonElement() + { + Dictionary results = _Description.GetDisplayNamesJsonElement(this); + return results; + } + + List IFileRead.GetDescriptions(IFileRead fileRead, List tests, IProcessData processData) + { + List results = _Description.GetDescriptions(fileRead, _Logistics, tests, processData); + return results; + } + + Tuple> IFileRead.GetExtractResult(string reportFullPath, string eventName) + { + Tuple> results; + if (string.IsNullOrEmpty(eventName)) + throw new Exception(); + _ReportFullPath = reportFullPath; + DateTime dateTime = DateTime.Now; + results = GetExtractResult(reportFullPath, dateTime); + if (results.Item3 is null) + results = new Tuple>(results.Item1, Array.Empty(), JsonSerializer.Deserialize("[]"), results.Item4); + if (results.Item3.Length > 0 && _IsEAFHosted) + WritePDSF(this, results.Item3); + UpdateLastTicksDuration(DateTime.Now.Ticks - dateTime.Ticks); + return results; + } + + Tuple> IFileRead.ReExtract() + { + Tuple> results; + List headerNames = _Description.GetHeaderNames(); + Dictionary keyValuePairs = _Description.GetDisplayNamesJsonElement(this); + results = ReExtract(this, headerNames, keyValuePairs); + return results; + } + + private static List GetSearchDirectories(int numberLength, string parentDirectory) + { + List results = new(); + string[] directories = Directory.GetDirectories(parentDirectory, "*", SearchOption.TopDirectoryOnly); + foreach (string directory in directories) + { + if (Path.GetFileName(directory).Length != numberLength) + continue; + results.Add(directory); + } + results.Sort(); + return results; + } + + private List GetMatchingFiles(long ticks, string reportFullPath, List searchDirectories) + { + List results = new(); + string[] found; + string fileName = Path.GetFileName(reportFullPath); + foreach (string searchDirectory in searchDirectories) + { + for (int i = 0; i < int.MaxValue; i++) + { + found = Directory.GetFiles(searchDirectory, fileName, SearchOption.AllDirectories); + if (found.Any()) + { + results.AddRange(found); + break; + } + if (new TimeSpan(DateTime.Now.Ticks - ticks).TotalSeconds > _BreakAfterSeconds) + break; + } + } + return results; + } + + private static List<(string matchingFile, string checkFile)> GetCollection(int numberLength, string parentDirectory, List matchingFiles) + { + List<(string matchingFile, string checkFile)> results = new(); + string checkFile; + int parentDirectoryLength = parentDirectory.Length; + foreach (string matchingFile in matchingFiles) + { + checkFile = $"{matchingFile[0]}{matchingFile.Substring(parentDirectoryLength + numberLength + 1)}"; + results.Add(new(matchingFile, checkFile)); + } + return results; + } + + private void MoveCollection(long ticks, List<(string matchingFile, string checkFile)> collection) + { + string errFile; + string checkDirectory; + foreach ((string matchingFile, string checkFile) in collection) + { + errFile = string.Concat(checkFile, ".err"); + checkDirectory = Path.GetDirectoryName(checkFile); + if (!Directory.Exists(checkDirectory)) + _ = Directory.CreateDirectory(checkDirectory); + File.Move(matchingFile, checkFile); + for (int i = 0; i < int.MaxValue; i++) + { + if (File.Exists(errFile)) + throw new Exception(File.ReadAllText(errFile)); + if (!File.Exists(checkFile)) + break; + if (new TimeSpan(DateTime.Now.Ticks - ticks).TotalSeconds > _BreakAfterSeconds) + throw new Exception($"Not all files were consumned after {_BreakAfterSeconds} second(s)!"); + } + } + } + + private Tuple> GetExtractResult(string reportFullPath, DateTime dateTime) + { + if (dateTime == DateTime.MinValue) + { } + Tuple> results = new(string.Empty, null, null, new List()); + Tuple pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); + _Logistics = new Logistics(reportFullPath, pdsf.Item1); + SetFileParameterLotIDToLogisticsMID(); + int numberLength = 2; + long ticks = DateTime.Now.Ticks; + string parentDirectory = Path.GetDirectoryName(Path.GetDirectoryName(reportFullPath)); + List searchDirectories = GetSearchDirectories(numberLength, parentDirectory); + List matchingFiles = GetMatchingFiles(ticks, reportFullPath, searchDirectories); + if (matchingFiles.Count != searchDirectories.Count) + throw new Exception($"Didn't find all files after {_BreakAfterSeconds} second(s)!"); + List<(string matchingFile, string checkFile)> collection = GetCollection(numberLength, parentDirectory, matchingFiles); + MoveCollection(ticks, collection); + return results; + } + +} \ No newline at end of file diff --git a/Adaptation/FileHandlers/OpenInsight/FileRead.cs b/Adaptation/FileHandlers/OpenInsight/FileRead.cs new file mode 100644 index 0000000..dad7dc0 --- /dev/null +++ b/Adaptation/FileHandlers/OpenInsight/FileRead.cs @@ -0,0 +1,272 @@ +using Adaptation.Eaf.Management.ConfigurationData.CellAutomation; +using Adaptation.Ifx.Eaf.EquipmentConnector.File.Configuration; +using Adaptation.Shared; +using Adaptation.Shared.Duplicator; +using Adaptation.Shared.Methods; +using Adaptation.Shared.Metrology; +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Text; +using System.Text.Json; + +namespace Adaptation.FileHandlers.OpenInsight; + +public class FileRead : Shared.FileRead, IFileRead +{ + + private readonly string _OpenInsightFilePattern; + + public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : + base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted) + { + _MinFileLength = 10; + _NullData = string.Empty; + _Logistics = new(this); + if (_FileParameter is null) + throw new Exception(cellInstanceConnectionName); + if (_ModelObjectParameterDefinitions is null) + throw new Exception(cellInstanceConnectionName); + if (!_IsDuplicator) + throw new Exception(cellInstanceConnectionName); + _OpenInsightFilePattern = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "OpenInsight.FilePattern"); + } + + void IFileRead.Move(Tuple> extractResults, Exception exception) + { + bool isErrorFile = exception is not null; + if (!isErrorFile && !string.IsNullOrEmpty(_Logistics.ReportFullPath)) + { + FileInfo fileInfo = new(_Logistics.ReportFullPath); + if (fileInfo.Exists && fileInfo.LastWriteTime < fileInfo.CreationTime) + File.SetLastWriteTime(_Logistics.ReportFullPath, fileInfo.CreationTime); + } + Move(extractResults); + } + + void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); + + string IFileRead.GetEventDescription() + { + string result = _Description.GetEventDescription(); + return result; + } + + List IFileRead.GetHeaderNames() + { + List results = _Description.GetHeaderNames(); + return results; + } + + string[] IFileRead.Move(Tuple> extractResults, string to, string from, string resolvedFileLocation, Exception exception) + { + string[] results = Move(extractResults, to, from, resolvedFileLocation, exception); + return results; + } + + JsonProperty[] IFileRead.GetDefault() + { + JsonProperty[] results = _Description.GetDefault(this, _Logistics); + return results; + } + + Dictionary IFileRead.GetDisplayNamesJsonElement() + { + Dictionary results = _Description.GetDisplayNamesJsonElement(this); + return results; + } + + List IFileRead.GetDescriptions(IFileRead fileRead, List tests, IProcessData processData) + { + List results = _Description.GetDescriptions(fileRead, _Logistics, tests, processData); + return results; + } + + Tuple> IFileRead.GetExtractResult(string reportFullPath, string eventName) + { + Tuple> results; + if (string.IsNullOrEmpty(eventName)) + throw new Exception(); + _ReportFullPath = reportFullPath; + DateTime dateTime = DateTime.Now; + results = GetExtractResult(reportFullPath, dateTime); + if (results.Item3 is null) + results = new Tuple>(results.Item1, Array.Empty(), JsonSerializer.Deserialize("[]"), results.Item4); + if (results.Item3.Length > 0 && _IsEAFHosted) + WritePDSF(this, results.Item3); + UpdateLastTicksDuration(DateTime.Now.Ticks - dateTime.Ticks); + return results; + } + + Tuple> IFileRead.ReExtract() + { + Tuple> results; + List headerNames = _Description.GetHeaderNames(); + Dictionary keyValuePairs = _Description.GetDisplayNamesJsonElement(this); + results = ReExtract(this, headerNames, keyValuePairs); + return results; + } + + private string GetLines(List descriptions) + { + StringBuilder result = new(); + pcl.Description x = descriptions[0]; + bool ganPPTST = x.Recipe.Contains("GAN_PPTST"); + if (ganPPTST) + { + string slot; + string reactor; + const int eight = 8; + DateTime dateTime = DateTime.Parse(x.Date); + string lot = x.Lot.ToLower().Replace("69-", string.Empty).Replace("71-", string.Empty).Replace("-", string.Empty); + if (string.IsNullOrEmpty(x.Lot) || x.Lot.Length < 2) + reactor = "R"; + else + reactor = string.Concat("R", x.Lot.Substring(0, 2)); + _ = result.Append(nameof(x.Date)).Append(';'). + Append("Part").Append(';'). + Append(nameof(x.Reactor)).Append(';'). + Append("Lot").Append(';'). + Append(nameof(pcl.Detail.Slot)).Append(';'). + Append(nameof(pcl.Detail.Bin1)).Append(';'). + Append(nameof(pcl.Detail.Bin2)).Append(';'). + Append(nameof(pcl.Detail.Bin3)).Append(';'). + Append(nameof(pcl.Detail.Bin4)).Append(';'). + Append(nameof(pcl.Detail.Bin5)).Append(';'). + Append(nameof(pcl.Detail.Bin6)).Append(';'). + Append("Bin9"). + AppendLine(); + foreach (pcl.Description description in descriptions) + { + slot = description.Slot.Replace("*", string.Empty); + _ = result.Append('!').Append(dateTime.ToString("MM/dd/yyyy HH:mm:ss")).Append(';'). + Append("Particle Adder;"). + Append(reactor).Append(';'). + Append(lot).Append(';'). + Append(slot).Append(';'). + Append(description.Bin1).Append(';'). + Append(description.Bin2).Append(';'). + Append(description.Bin3).Append(';'). + Append(description.Bin4).Append(';'). + Append(description.Bin5).Append(';'). + Append(description.Bin6).Append(';'). + Append(description.AreaCount). + AppendLine(); + } + if (descriptions.Count != eight) + { + string negativeTenThousand = "-10000"; + for (int i = descriptions.Count; i < eight; i++) + { + _ = result.Append('!').Append(dateTime.ToString("MM/dd/yyyy HH:mm:ss")).Append(';'). + Append("Particle Adder;"). + Append(reactor).Append(';'). + Append(lot).Append(';'). + Append(negativeTenThousand).Append(';'). + Append(negativeTenThousand).Append(';'). + Append(negativeTenThousand).Append(';'). + Append(negativeTenThousand).Append(';'). + Append(negativeTenThousand).Append(';'). + Append(negativeTenThousand).Append(';'). + Append(negativeTenThousand).Append(';'). + Append(negativeTenThousand). + AppendLine(); + } + } + if (result.ToString().Split('\n').Length != (eight + 2)) + throw new Exception(string.Concat("Must have ", eight, " samples")); + } + else + { + char del = '\t'; + _ = result.Append(x.AreaCountAvg).Append(del). // 001 - AreaCountAvg + Append(x.AreaCountMax).Append(del). // 002 - AreaCountMax + Append(x.AreaCountMin).Append(del). // 003 - AreaCountMin + Append(x.AreaCountStdDev).Append(del). // 004 - AreaCountStdDev + Append(x.AreaTotalAvg).Append(del). // 005 - AreaTotalAvg + Append(x.AreaTotalMax).Append(del). // 006 - AreaTotalMax + Append(x.AreaTotalMin).Append(del). // 007 - AreaTotalMin + Append(x.AreaTotalStdDev).Append(del). // 008 - AreaTotalStdDev + Append(x.Date).Append(del). // 009 - + Append(x.HazeAverageAvg).Append(del). // 010 - Haze Average + Append(x.HazeAverageMax).Append(del). // 011 - + Append(x.HazeAverageMin).Append(del). // 012 - + Append(x.HazeAverageStdDev).Append(del). // 013 - + Append(x.HazeRegionAvg).Append(del). // 014 - + Append(x.HazeRegionMax).Append(del). // 015 - + Append(x.HazeRegionMin).Append(del). // 016 - + Append(x.HazeRegionStdDev).Append(del). // 017 - + Append(x.Lot).Append(del). // 018 - + Append(x.LPDCM2Avg).Append(del). // 019 - + Append(x.LPDCM2Max).Append(del). // 020 - + Append(x.LPDCM2Min).Append(del). // 021 - + Append(x.LPDCM2StdDev).Append(del). // 022 - + Append(x.LPDCountAvg).Append(del). // 023 - + Append(x.LPDCountMax).Append(del). // 024 - + Append(x.LPDCM2Min).Append(del). // 025 - + Append(x.LPDCountStdDev).Append(del). // 026 - + Append(x.Employee).Append(del). // 027 - + Append(x.RDS).Append(del). // 028 - Lot + Append(x.Reactor).Append(del). // 029 - Process + Append(x.Recipe.Replace(";", string.Empty)).Append(del). // 030 - Part + Append(x.ScratchCountAvg).Append(del). // 031 - Scratch Count + Append(x.ScratchCountMax).Append(del). // 032 - + Append(x.ScratchCountMin).Append(del). // 033 - + Append(x.ScratchTotalStdDev).Append(del). // 034 - + Append(x.ScratchTotalAvg).Append(del). // 035 - Scratch Length + Append(x.ScratchTotalMax).Append(del). // 036 - + Append(x.ScratchTotalMin).Append(del). // 037 - + Append(x.ScratchTotalStdDev).Append(del). // 038 - + Append(x.SumOfDefectsAvg).Append(del). // 039 - Average Sum of Defects + Append(x.SumOfDefectsMax).Append(del). // 040 - Max Sum of Defects + Append(x.SumOfDefectsMin).Append(del). // 041 - Min Sum of Defects + Append(x.SumOfDefectsStdDev).Append(del). // 042 - SumOfDefectsStdDev + Append(_Logistics.MesEntity).Append(del). // 043 - + AppendLine(); + } + return result.ToString(); + } + + private void SaveOpenInsightFile(string reportFullPath, DateTime dateTime, List descriptions, Test[] tests) + { + if (reportFullPath is null) + { } + if (dateTime == DateTime.MinValue) + { } + if (tests.Any()) + { + bool isDummyRun = false; + string lines = GetLines(descriptions); + string successDirectory = string.Empty; + ScopeInfo scopeInfo = new(tests[0], _OpenInsightFilePattern); + List<(Shared.Properties.IScopeInfo, string)> tuples = new(); + if (!string.IsNullOrEmpty(lines)) + tuples.Add(new(scopeInfo, lines)); + string[] segments = Path.GetFileNameWithoutExtension(reportFullPath).Split('_'); + string duplicateDirectory = string.Concat(Path.GetDirectoryName(Path.GetDirectoryName(_FileConnectorConfiguration.TargetFileLocation)), @"\Data"); + if (segments.Length > 2) + duplicateDirectory = string.Concat(duplicateDirectory, @"-", segments[2]); + if (!Directory.Exists(duplicateDirectory)) + _ = Directory.CreateDirectory(duplicateDirectory); + string duplicateFile = string.Concat(duplicateDirectory, @"\", Path.GetFileName(reportFullPath)); + WaitForFileConsumption(dateTime, isDummyRun, successDirectory, duplicateDirectory, tuples, duplicateFile); + } + } + + private Tuple> GetExtractResult(string reportFullPath, DateTime dateTime) + { + Tuple> results; + Tuple pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); + _Logistics = new Logistics(reportFullPath, pdsf.Item1); + SetFileParameterLotIDToLogisticsMID(); + JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); + List descriptions = pcl.ProcessData.GetDescriptions(jsonElements); + Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); + results = new Tuple>(pdsf.Item1, tests, jsonElements, new List()); + if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) + SaveOpenInsightFile(reportFullPath, dateTime, descriptions, tests); + return results; + } + +} \ No newline at end of file diff --git a/Adaptation/FileHandlers/OpenInsightMetrologyViewer/FileRead.cs b/Adaptation/FileHandlers/OpenInsightMetrologyViewer/FileRead.cs new file mode 100644 index 0000000..99082ed --- /dev/null +++ b/Adaptation/FileHandlers/OpenInsightMetrologyViewer/FileRead.cs @@ -0,0 +1,142 @@ +using Adaptation.Eaf.Management.ConfigurationData.CellAutomation; +using Adaptation.Ifx.Eaf.EquipmentConnector.File.Configuration; +using Adaptation.Shared; +using Adaptation.Shared.Duplicator; +using Adaptation.Shared.Methods; +using Adaptation.Shared.Metrology; +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Text.Json; + +namespace Adaptation.FileHandlers.OpenInsightMetrologyViewer; + +public class FileRead : Shared.FileRead, IFileRead +{ + + private readonly string _OpenInsightMetrologyViewerAPI; + + public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : + base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted) + { + _MinFileLength = 10; + _NullData = string.Empty; + _Logistics = new(this); + if (_FileParameter is null) + throw new Exception(cellInstanceConnectionName); + if (_ModelObjectParameterDefinitions is null) + throw new Exception(cellInstanceConnectionName); + if (!_IsDuplicator) + throw new Exception(cellInstanceConnectionName); + _OpenInsightMetrologyViewerAPI = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "OpenInsight.MetrologyViewerAPI"); + } + + void IFileRead.Move(Tuple> extractResults, Exception exception) + { + bool isErrorFile = exception is not null; + if (!isErrorFile && !string.IsNullOrEmpty(_Logistics.ReportFullPath)) + { + FileInfo fileInfo = new(_Logistics.ReportFullPath); + if (fileInfo.Exists && fileInfo.LastWriteTime < fileInfo.CreationTime) + File.SetLastWriteTime(_Logistics.ReportFullPath, fileInfo.CreationTime); + } + Move(extractResults); + } + + void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); + + string IFileRead.GetEventDescription() + { + string result = _Description.GetEventDescription(); + return result; + } + + List IFileRead.GetHeaderNames() + { + List results = _Description.GetHeaderNames(); + return results; + } + + string[] IFileRead.Move(Tuple> extractResults, string to, string from, string resolvedFileLocation, Exception exception) + { + string[] results = Move(extractResults, to, from, resolvedFileLocation, exception); + return results; + } + + JsonProperty[] IFileRead.GetDefault() + { + JsonProperty[] results = _Description.GetDefault(this, _Logistics); + return results; + } + + Dictionary IFileRead.GetDisplayNamesJsonElement() + { + Dictionary results = _Description.GetDisplayNamesJsonElement(this); + return results; + } + + List IFileRead.GetDescriptions(IFileRead fileRead, List tests, IProcessData processData) + { + List results = _Description.GetDescriptions(fileRead, _Logistics, tests, processData); + return results; + } + + Tuple> IFileRead.GetExtractResult(string reportFullPath, string eventName) + { + Tuple> results; + if (string.IsNullOrEmpty(eventName)) + throw new Exception(); + _ReportFullPath = reportFullPath; + DateTime dateTime = DateTime.Now; + results = GetExtractResult(reportFullPath, dateTime); + if (results.Item3 is null) + results = new Tuple>(results.Item1, Array.Empty(), JsonSerializer.Deserialize("[]"), results.Item4); + if (results.Item3.Length > 0 && _IsEAFHosted) + WritePDSF(this, results.Item3); + UpdateLastTicksDuration(DateTime.Now.Ticks - dateTime.Ticks); + return results; + } + + Tuple> IFileRead.ReExtract() + { + Tuple> results; + List headerNames = _Description.GetHeaderNames(); + Dictionary keyValuePairs = _Description.GetDisplayNamesJsonElement(this); + results = ReExtract(this, headerNames, keyValuePairs); + return results; + } + + private void SendData(DateTime dateTime, List descriptions) + { + if (dateTime == DateTime.MinValue) + { } + WSRequest wsRequest = new(this, _Logistics, descriptions); + (string json, WS.Results wsResults) = WS.SendData(_OpenInsightMetrologyViewerAPI, wsRequest); + if (!wsResults.Success) + throw new Exception(wsResults.ToString()); + _Log.Debug(wsResults.HeaderID); + lock (_StaticRuns) + { + if (!_StaticRuns.ContainsKey(_Logistics.Sequence)) + _StaticRuns.Add(_Logistics.Sequence, new()); + _StaticRuns[_Logistics.Sequence].Add(json); + } + } + + private Tuple> GetExtractResult(string reportFullPath, DateTime dateTime) + { + Tuple> results; + Tuple pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); + _Logistics = new Logistics(reportFullPath, pdsf.Item1); + SetFileParameterLotIDToLogisticsMID(); + JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); + List descriptions = pcl.ProcessData.GetDescriptions(jsonElements); + Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); + results = new Tuple>(pdsf.Item1, tests, jsonElements, new List()); + if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) + SendData(dateTime, descriptions); + return results; + } + +} \ No newline at end of file diff --git a/Adaptation/FileHandlers/MET08DDUPSFS6420/WSRequest.cs b/Adaptation/FileHandlers/OpenInsightMetrologyViewer/WSRequest.cs similarity index 53% rename from Adaptation/FileHandlers/MET08DDUPSFS6420/WSRequest.cs rename to Adaptation/FileHandlers/OpenInsightMetrologyViewer/WSRequest.cs index bdd249e..e73087b 100644 --- a/Adaptation/FileHandlers/MET08DDUPSFS6420/WSRequest.cs +++ b/Adaptation/FileHandlers/OpenInsightMetrologyViewer/WSRequest.cs @@ -1,10 +1,14 @@ using Adaptation.Shared; +using Adaptation.Shared.Metrology; using Adaptation.Shared.Properties; using System; using System.Collections.Generic; +using System.IO; using System.Linq; +using System.Text; +using System.Text.Json; -namespace Adaptation.FileHandlers.MET08DDUPSFS6420; +namespace Adaptation.FileHandlers.OpenInsightMetrologyViewer; public class WSRequest { @@ -197,4 +201,134 @@ public class WSRequest } } + private static void UpdateDataPDF(List descriptions, string checkFileName) + { + string value; + object possiblePage; + object possibleString; + object possibleCOSArray; + java.util.List tokenList; + java.util.List arrayList; + java.io.OutputStream outputStream; + List updateValues = new(); + StringBuilder stringBuilder = new(); + java.util.ListIterator tokenIterator; + java.util.ListIterator arrayIterator; + java.io.File file = new(checkFileName); + string reactorLoadLock = descriptions[0].Comments; + org.apache.pdfbox.pdmodel.common.PDStream pdStream; + org.apache.pdfbox.pdmodel.common.PDStream updatedStream; + org.apache.pdfbox.pdfparser.PDFStreamParser pdfStreamParser; + org.apache.pdfbox.pdfwriter.ContentStreamWriter contentStreamWriter; + org.apache.pdfbox.pdmodel.PDDocument pdDocument = org.apache.pdfbox.pdmodel.PDDocument.load(file); + org.apache.pdfbox.pdmodel.PDDocumentCatalog pdDocumentCatalog = pdDocument.getDocumentCatalog(); + java.util.List pagesList = pdDocumentCatalog.getAllPages(); + java.util.ListIterator pageIterator = pagesList.listIterator(); + for (short i = 1; i < short.MaxValue; i++) + { + if (!pageIterator.hasNext()) + break; + possiblePage = pageIterator.next(); + if (possiblePage is not org.apache.pdfbox.pdmodel.PDPage page) + continue; + pdStream = page.getContents(); + pdfStreamParser = new org.apache.pdfbox.pdfparser.PDFStreamParser(pdStream); + pdfStreamParser.parse(); + tokenList = pdfStreamParser.getTokens(); + tokenIterator = tokenList.listIterator(); + for (short t = 1; i < short.MaxValue; t++) + { + if (!tokenIterator.hasNext()) + break; + possibleCOSArray = tokenIterator.next(); + if (possibleCOSArray is not org.apache.pdfbox.cos.COSArray cossArray) + continue; + _ = stringBuilder.Clear(); + arrayList = cossArray.toList(); + arrayIterator = arrayList.listIterator(); + for (short a = 1; i < short.MaxValue; a++) + { + if (!arrayIterator.hasNext()) + break; + possibleString = arrayIterator.next(); + if (possibleString is not org.apache.pdfbox.cos.COSString cossString) + continue; + value = cossString.getString(); + _ = stringBuilder.Append(value); + if (value != "]") + continue; + updateValues.Add(value); + value = stringBuilder.ToString(); + if (value.Contains("[]")) + cossArray.setString(a - 1, string.Concat("*", reactorLoadLock, "]")); + else + cossArray.setString(a - 1, string.Concat(" {*", reactorLoadLock, "}]")); + } + } + if (updateValues.Any()) + { + updatedStream = new org.apache.pdfbox.pdmodel.common.PDStream(pdDocument); + outputStream = updatedStream.createOutputStream(); + contentStreamWriter = new org.apache.pdfbox.pdfwriter.ContentStreamWriter(outputStream); + contentStreamWriter.writeTokens(tokenList); + outputStream.close(); + page.setContents(updatedStream); + } + } + if (updateValues.Any()) + pdDocument.save(checkFileName); + pdDocument.close(); + } + + internal static void PostOpenInsightMetrologyViewerAttachments(IFileRead fileRead, Logistics logistics, string openInsightMetrologyViewerAPI, DateTime dateTime, string json, List descriptions, string matchDirectory) + { + if (fileRead is null) + { } + if (logistics is null) + { } + if (dateTime == DateTime.MinValue) + { } + if (descriptions is null) + { } + string checkFileName; + if (string.IsNullOrEmpty(json)) + { + WSRequest wsRequest = new(fileRead, logistics, descriptions); + (json, WS.Results wsResults) = WS.SendData(openInsightMetrologyViewerAPI, wsRequest); + if (!wsResults.Success) + throw new Exception(wsResults.ToString()); + } + WS.Results metrologyWSRequest = JsonSerializer.Deserialize(json); + long wsResultsHeaderID = metrologyWSRequest.HeaderID; + string[] pclFiles = Directory.GetFiles(matchDirectory, "*.pcl", SearchOption.TopDirectoryOnly); + if (pclFiles.Length != 1) + throw new Exception($"Invalid source file count for <{wsResultsHeaderID}>!{Environment.NewLine}{json}"); + string sourceFileNameNoExt = Path.GetFileNameWithoutExtension(pclFiles[0]); + List dataAttachments = new(); + List headerAttachments = new(); + checkFileName = Path.Combine(matchDirectory, $"{sourceFileNameNoExt}_data.pdf"); + if (!File.Exists(checkFileName)) + throw new Exception("Header file doesn't exist!"); + else + { + UpdateDataPDF(descriptions, checkFileName); + headerAttachments.Add(new WS.Attachment(descriptions[0].HeaderUniqueId, "Data.pdf", checkFileName)); + } + foreach (pcl.Description description in descriptions) + { + checkFileName = Path.Combine(matchDirectory, $"{sourceFileNameNoExt}_{description.Slot.Replace('*', 's')}_image.pdf"); + if (File.Exists(checkFileName)) + dataAttachments.Add(new WS.Attachment(description.UniqueId, "Image.pdf", checkFileName)); + else + { + checkFileName = Path.Combine(matchDirectory, $"{sourceFileNameNoExt}_{description.Slot.Replace('*', 's')}_data.pdf"); + if (File.Exists(checkFileName)) + dataAttachments.Add(new WS.Attachment(description.UniqueId, "Image.pdf", checkFileName)); + } + } + if (dataAttachments.Count == 0 || dataAttachments.Count != descriptions.Count) + throw new Exception($"Invalid attachment count! {dataAttachments.Count} != {descriptions.Count}"); + WS.AttachFiles(openInsightMetrologyViewerAPI, wsResultsHeaderID, headerAttachments, dataAttachments); + } + } \ No newline at end of file diff --git a/Adaptation/FileHandlers/OpenInsightMetrologyViewerAttachments/FileRead.cs b/Adaptation/FileHandlers/OpenInsightMetrologyViewerAttachments/FileRead.cs new file mode 100644 index 0000000..a5dbdb1 --- /dev/null +++ b/Adaptation/FileHandlers/OpenInsightMetrologyViewerAttachments/FileRead.cs @@ -0,0 +1,150 @@ +using Adaptation.Eaf.Management.ConfigurationData.CellAutomation; +using Adaptation.Ifx.Eaf.EquipmentConnector.File.Configuration; +using Adaptation.Shared; +using Adaptation.Shared.Duplicator; +using Adaptation.Shared.Methods; +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Text.Json; + +namespace Adaptation.FileHandlers.OpenInsightMetrologyViewerAttachments; + +public class FileRead : Shared.FileRead, IFileRead +{ + + private readonly string _JobIdParentDirectory; + private readonly string _OpenInsightMetrologyViewerAPI; + + public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : + base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted) + { + _MinFileLength = 10; + _NullData = string.Empty; + _Logistics = new(this); + if (_FileParameter is null) + throw new Exception(cellInstanceConnectionName); + if (_ModelObjectParameterDefinitions is null) + throw new Exception(cellInstanceConnectionName); + if (!_IsDuplicator) + throw new Exception(cellInstanceConnectionName); + _JobIdParentDirectory = GetJobIdParentDirectory(_FileConnectorConfiguration.SourceFileLocation); + _OpenInsightMetrologyViewerAPI = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "OpenInsight.MetrologyViewerAPI"); + } + + void IFileRead.Move(Tuple> extractResults, Exception exception) + { + bool isErrorFile = exception is not null; + if (!isErrorFile && !string.IsNullOrEmpty(_Logistics.ReportFullPath)) + { + FileInfo fileInfo = new(_Logistics.ReportFullPath); + if (fileInfo.Exists && fileInfo.LastWriteTime < fileInfo.CreationTime) + File.SetLastWriteTime(_Logistics.ReportFullPath, fileInfo.CreationTime); + } + Move(extractResults); + } + + void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); + + string IFileRead.GetEventDescription() + { + string result = _Description.GetEventDescription(); + return result; + } + + List IFileRead.GetHeaderNames() + { + List results = _Description.GetHeaderNames(); + return results; + } + + string[] IFileRead.Move(Tuple> extractResults, string to, string from, string resolvedFileLocation, Exception exception) + { + string[] results = Move(extractResults, to, from, resolvedFileLocation, exception); + return results; + } + + JsonProperty[] IFileRead.GetDefault() + { + JsonProperty[] results = _Description.GetDefault(this, _Logistics); + return results; + } + + Dictionary IFileRead.GetDisplayNamesJsonElement() + { + Dictionary results = _Description.GetDisplayNamesJsonElement(this); + return results; + } + + List IFileRead.GetDescriptions(IFileRead fileRead, List tests, IProcessData processData) + { + List results = _Description.GetDescriptions(fileRead, _Logistics, tests, processData); + return results; + } + + Tuple> IFileRead.GetExtractResult(string reportFullPath, string eventName) + { + Tuple> results; + if (string.IsNullOrEmpty(eventName)) + throw new Exception(); + _ReportFullPath = reportFullPath; + DateTime dateTime = DateTime.Now; + results = GetExtractResult(reportFullPath, dateTime); + if (results.Item3 is null) + results = new Tuple>(results.Item1, Array.Empty(), JsonSerializer.Deserialize("[]"), results.Item4); + if (results.Item3.Length > 0 && _IsEAFHosted) + WritePDSF(this, results.Item3); + UpdateLastTicksDuration(DateTime.Now.Ticks - dateTime.Ticks); + return results; + } + + Tuple> IFileRead.ReExtract() + { + Tuple> results; + List headerNames = _Description.GetHeaderNames(); + Dictionary keyValuePairs = _Description.GetDisplayNamesJsonElement(this); + results = ReExtract(this, headerNames, keyValuePairs); + return results; + } + + private void PostOpenInsightMetrologyViewerAttachments(string reportFullPath, DateTime dateTime, List descriptions) + { + if (string.IsNullOrEmpty(reportFullPath)) + { } + if (dateTime == DateTime.MinValue) + { } + string jobIdDirectory = Path.Combine(_JobIdParentDirectory, _Logistics.JobID); + if (!Directory.Exists(jobIdDirectory)) + _ = Directory.CreateDirectory(jobIdDirectory); + string json; + string[] matchDirectories = GetInProcessDirectory(jobIdDirectory); + if (!_StaticRuns.ContainsKey(_Logistics.Sequence)) + json = string.Empty; + else + { + if (_StaticRuns[_Logistics.Sequence].Count != 1) + throw new Exception($"{nameof(_StaticRuns)} has too many values for {_Logistics.Sequence}!"); + json = _StaticRuns[_Logistics.Sequence][0]; + lock (_StaticRuns) + _ = _StaticRuns.Remove(_Logistics.Sequence); + } + OpenInsightMetrologyViewer.WSRequest.PostOpenInsightMetrologyViewerAttachments(this, _Logistics, _OpenInsightMetrologyViewerAPI, dateTime, json, descriptions, matchDirectories[0]); + } + + private Tuple> GetExtractResult(string reportFullPath, DateTime dateTime) + { + Tuple> results; + Tuple pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); + _Logistics = new Logistics(reportFullPath, pdsf.Item1); + SetFileParameterLotIDToLogisticsMID(); + JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); + List descriptions = pcl.ProcessData.GetDescriptions(jsonElements); + Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); + results = new Tuple>(pdsf.Item1, tests, jsonElements, new List()); + if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) + PostOpenInsightMetrologyViewerAttachments(reportFullPath, dateTime, descriptions); + return results; + } + +} \ No newline at end of file diff --git a/Adaptation/FileHandlers/Processed/FileRead.cs b/Adaptation/FileHandlers/Processed/FileRead.cs new file mode 100644 index 0000000..ff94090 --- /dev/null +++ b/Adaptation/FileHandlers/Processed/FileRead.cs @@ -0,0 +1,164 @@ +using Adaptation.Eaf.Management.ConfigurationData.CellAutomation; +using Adaptation.Ifx.Eaf.EquipmentConnector.File.Configuration; +using Adaptation.Shared; +using Adaptation.Shared.Duplicator; +using Adaptation.Shared.Methods; +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Text.Json; + +namespace Adaptation.FileHandlers.Processed; + +public class FileRead : Shared.FileRead, IFileRead +{ + + private readonly string _JobIdParentDirectory; + private readonly string _JobIdProcessParentDirectory; + + public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : + base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted) + { + _MinFileLength = 10; + _NullData = string.Empty; + _Logistics = new(this); + if (_FileParameter is null) + throw new Exception(cellInstanceConnectionName); + if (_ModelObjectParameterDefinitions is null) + throw new Exception(cellInstanceConnectionName); + if (!_IsDuplicator) + throw new Exception(cellInstanceConnectionName); + _JobIdParentDirectory = GetJobIdParentDirectory(_FileConnectorConfiguration.SourceFileLocation); + _JobIdProcessParentDirectory = GetJobIdParentDirectory(_FileConnectorConfiguration.TargetFileLocation); + } + + void IFileRead.Move(Tuple> extractResults, Exception exception) + { + bool isErrorFile = exception is not null; + if (!isErrorFile && !string.IsNullOrEmpty(_Logistics.ReportFullPath)) + { + FileInfo fileInfo = new(_Logistics.ReportFullPath); + if (fileInfo.Exists && fileInfo.LastWriteTime < fileInfo.CreationTime) + File.SetLastWriteTime(_Logistics.ReportFullPath, fileInfo.CreationTime); + } + Move(extractResults); + } + + void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); + + string IFileRead.GetEventDescription() + { + string result = _Description.GetEventDescription(); + return result; + } + + List IFileRead.GetHeaderNames() + { + List results = _Description.GetHeaderNames(); + return results; + } + + string[] IFileRead.Move(Tuple> extractResults, string to, string from, string resolvedFileLocation, Exception exception) + { + string[] results = Move(extractResults, to, from, resolvedFileLocation, exception); + return results; + } + + JsonProperty[] IFileRead.GetDefault() + { + JsonProperty[] results = _Description.GetDefault(this, _Logistics); + return results; + } + + Dictionary IFileRead.GetDisplayNamesJsonElement() + { + Dictionary results = _Description.GetDisplayNamesJsonElement(this); + return results; + } + + List IFileRead.GetDescriptions(IFileRead fileRead, List tests, IProcessData processData) + { + List results = _Description.GetDescriptions(fileRead, _Logistics, tests, processData); + return results; + } + + Tuple> IFileRead.GetExtractResult(string reportFullPath, string eventName) + { + Tuple> results; + if (string.IsNullOrEmpty(eventName)) + throw new Exception(); + _ReportFullPath = reportFullPath; + DateTime dateTime = DateTime.Now; + results = GetExtractResult(reportFullPath, dateTime); + if (results.Item3 is null) + results = new Tuple>(results.Item1, Array.Empty(), JsonSerializer.Deserialize("[]"), results.Item4); + if (results.Item3.Length > 0 && _IsEAFHosted) + WritePDSF(this, results.Item3); + UpdateLastTicksDuration(DateTime.Now.Ticks - dateTime.Ticks); + return results; + } + + Tuple> IFileRead.ReExtract() + { + Tuple> results; + List headerNames = _Description.GetHeaderNames(); + Dictionary keyValuePairs = _Description.GetDisplayNamesJsonElement(this); + results = ReExtract(this, headerNames, keyValuePairs); + return results; + } + + private void DirectoryMove(string reportFullPath, DateTime dateTime, List descriptions) + { + if (dateTime == DateTime.MinValue) + { } + FileInfo fileInfo = new(reportFullPath); + string logisticsSequence = _Logistics.Sequence.ToString(); + string jobIdDirectory = Path.Combine(_JobIdParentDirectory, _Logistics.JobID); + if (!Directory.Exists(jobIdDirectory)) + _ = Directory.CreateDirectory(jobIdDirectory); + string[] matchDirectories = GetInProcessDirectory(jobIdDirectory); + if ((matchDirectories is null) || matchDirectories.Length != 1) + throw new Exception("Didn't find directory by logistics sequence"); + if (fileInfo.Exists && fileInfo.LastWriteTime < fileInfo.CreationTime) + File.SetLastWriteTime(reportFullPath, fileInfo.CreationTime); + OpenInsightMetrologyViewer.WSRequest wsRequest = new(this, _Logistics, descriptions); + JsonSerializerOptions jsonSerializerOptions = new() { WriteIndented = true }; + string json = JsonSerializer.Serialize(wsRequest, wsRequest.GetType(), jsonSerializerOptions); + string directoryName = $"{Path.GetFileName(matchDirectories[0]).Split(new string[] { logisticsSequence }, StringSplitOptions.None)[0]}{_Logistics.DateTimeFromSequence:yyyy-MM-dd_hh;mm_tt_}{DateTime.Now.Ticks - _Logistics.Sequence}"; + string destinationJobIdDirectory = Path.Combine(_JobIdProcessParentDirectory, _Logistics.JobID, directoryName); + string sequenceDirectory = Path.Combine(destinationJobIdDirectory, logisticsSequence); + string jsonFileName = Path.Combine(sequenceDirectory, $"{Path.GetFileNameWithoutExtension(reportFullPath)}.json"); + Directory.Move(matchDirectories[0], destinationJobIdDirectory); + if (!Directory.Exists(sequenceDirectory)) + _ = Directory.CreateDirectory(sequenceDirectory); + File.Copy(reportFullPath, Path.Combine(sequenceDirectory, Path.GetFileName(reportFullPath)), overwrite: true); + File.WriteAllText(jsonFileName, json); + } + + private Tuple> GetExtractResult(string reportFullPath, DateTime dateTime) + { + Tuple> results; + Tuple pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); + _Logistics = new Logistics(reportFullPath, pdsf.Item1); + SetFileParameterLotIDToLogisticsMID(); + JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); + List descriptions = pcl.ProcessData.GetDescriptions(jsonElements); + Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); + results = new Tuple>(pdsf.Item1, tests, jsonElements, new List()); + if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0) + DirectoryMove(reportFullPath, dateTime, descriptions); + else if (!_IsEAFHosted) + { + OpenInsightMetrologyViewer.WSRequest wsRequest = new(this, _Logistics, descriptions); + JsonSerializerOptions jsonSerializerOptions = new() { WriteIndented = true }; + string json = JsonSerializer.Serialize(wsRequest, wsRequest.GetType(), jsonSerializerOptions); + string jsonFileName = Path.ChangeExtension(reportFullPath, ".json"); + string historicalText = File.ReadAllText(jsonFileName); + if (json != historicalText) + throw new Exception("File doesn't match historical!"); + } + return results; + } + +} \ No newline at end of file diff --git a/Adaptation/FileHandlers/SPaCe/FileRead.cs b/Adaptation/FileHandlers/SPaCe/FileRead.cs new file mode 100644 index 0000000..c96c4e2 --- /dev/null +++ b/Adaptation/FileHandlers/SPaCe/FileRead.cs @@ -0,0 +1,121 @@ +using Adaptation.Eaf.Management.ConfigurationData.CellAutomation; +using Adaptation.Ifx.Eaf.EquipmentConnector.File.Configuration; +using Adaptation.Shared; +using Adaptation.Shared.Duplicator; +using Adaptation.Shared.Methods; +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Text.Json; + +namespace Adaptation.FileHandlers.SPaCe; + +public class FileRead : Shared.FileRead, IFileRead +{ + + public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : + base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted) + { + _MinFileLength = 10; + _NullData = string.Empty; + _Logistics = new(this); + if (_FileParameter is null) + throw new Exception(cellInstanceConnectionName); + if (_ModelObjectParameterDefinitions is null) + throw new Exception(cellInstanceConnectionName); + if (!_IsDuplicator) + throw new Exception(cellInstanceConnectionName); + } + + void IFileRead.Move(Tuple> extractResults, Exception exception) + { + bool isErrorFile = exception is not null; + if (!isErrorFile && !string.IsNullOrEmpty(_Logistics.ReportFullPath)) + { + FileInfo fileInfo = new(_Logistics.ReportFullPath); + if (fileInfo.Exists && fileInfo.LastWriteTime < fileInfo.CreationTime) + File.SetLastWriteTime(_Logistics.ReportFullPath, fileInfo.CreationTime); + } + Move(extractResults); + } + + void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); + + string IFileRead.GetEventDescription() + { + string result = _Description.GetEventDescription(); + return result; + } + + List IFileRead.GetHeaderNames() + { + List results = _Description.GetHeaderNames(); + return results; + } + + string[] IFileRead.Move(Tuple> extractResults, string to, string from, string resolvedFileLocation, Exception exception) + { + string[] results = Move(extractResults, to, from, resolvedFileLocation, exception); + return results; + } + + JsonProperty[] IFileRead.GetDefault() + { + JsonProperty[] results = _Description.GetDefault(this, _Logistics); + return results; + } + + Dictionary IFileRead.GetDisplayNamesJsonElement() + { + Dictionary results = _Description.GetDisplayNamesJsonElement(this); + return results; + } + + List IFileRead.GetDescriptions(IFileRead fileRead, List tests, IProcessData processData) + { + List results = _Description.GetDescriptions(fileRead, _Logistics, tests, processData); + return results; + } + + Tuple> IFileRead.GetExtractResult(string reportFullPath, string eventName) + { + Tuple> results; + if (string.IsNullOrEmpty(eventName)) + throw new Exception(); + _ReportFullPath = reportFullPath; + DateTime dateTime = DateTime.Now; + results = GetExtractResult(reportFullPath, dateTime); + if (results.Item3 is null) + results = new Tuple>(results.Item1, Array.Empty(), JsonSerializer.Deserialize("[]"), results.Item4); + if (results.Item3.Length > 0 && _IsEAFHosted) + WritePDSF(this, results.Item3); + UpdateLastTicksDuration(DateTime.Now.Ticks - dateTime.Ticks); + return results; + } + + Tuple> IFileRead.ReExtract() + { + Tuple> results; + List headerNames = _Description.GetHeaderNames(); + Dictionary keyValuePairs = _Description.GetDisplayNamesJsonElement(this); + results = ReExtract(this, headerNames, keyValuePairs); + return results; + } + + private Tuple> GetExtractResult(string reportFullPath, DateTime dateTime) + { + if (dateTime == DateTime.MinValue) + { } + Tuple> results; + Tuple pdsf = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(reportFullPath); + _Logistics = new Logistics(reportFullPath, pdsf.Item1); + SetFileParameterLotIDToLogisticsMID(); + JsonElement[] jsonElements = ProcessDataStandardFormat.GetArray(pdsf); + List descriptions = GetDuplicatorDescriptions(jsonElements); + Test[] tests = (from l in descriptions select (Test)l.Test).ToArray(); + results = new Tuple>(pdsf.Item1, tests, jsonElements, new List()); + return results; + } + +} \ No newline at end of file diff --git a/Adaptation/FileHandlers/ToArchive/FileRead.cs b/Adaptation/FileHandlers/ToArchive/FileRead.cs index 05860a0..d3bb941 100644 --- a/Adaptation/FileHandlers/ToArchive/FileRead.cs +++ b/Adaptation/FileHandlers/ToArchive/FileRead.cs @@ -6,7 +6,6 @@ using Adaptation.Shared.Methods; using System; using System.Collections.Generic; using System.IO; -using System.Linq; using System.Text.Json; namespace Adaptation.FileHandlers.ToArchive; @@ -14,12 +13,12 @@ namespace Adaptation.FileHandlers.ToArchive; public class FileRead : Shared.FileRead, IFileRead { - public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, bool useCyclicalForDescription, bool isEAFHosted) : - base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, useCyclicalForDescription, isEAFHosted) + public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : + base(new Description(), false, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted) { _MinFileLength = 10; _NullData = string.Empty; - _Logistics = new Logistics(this); + _Logistics = new(this); if (_FileParameter is null) throw new Exception(cellInstanceConnectionName); if (_ModelObjectParameterDefinitions is null) @@ -37,7 +36,7 @@ public class FileRead : Shared.FileRead, IFileRead if (fileInfo.Exists && fileInfo.LastWriteTime < fileInfo.CreationTime) File.SetLastWriteTime(_Logistics.ReportFullPath, fileInfo.CreationTime); } - Move(extractResults, exception); + Move(extractResults); } void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); @@ -103,12 +102,6 @@ public class FileRead : Shared.FileRead, IFileRead return results; } - void IFileRead.CheckTests(Test[] tests, bool extra) - { - if (_Description is not Description) - throw new Exception(); - } - private Tuple> GetExtractResult(string reportFullPath, DateTime dateTime) { if (dateTime == DateTime.MinValue) diff --git a/Adaptation/FileHandlers/pcl/FileRead.cs b/Adaptation/FileHandlers/pcl/FileRead.cs index 5288908..df8d81b 100644 --- a/Adaptation/FileHandlers/pcl/FileRead.cs +++ b/Adaptation/FileHandlers/pcl/FileRead.cs @@ -6,7 +6,6 @@ using System; using System.Collections.Generic; using System.IO; using System.Linq; -using System.Reflection; using System.Text.Json; using System.Text.RegularExpressions; @@ -17,24 +16,24 @@ public class FileRead : Shared.FileRead, IFileRead private readonly string _GhostPCLFileName; - public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, bool useCyclicalForDescription, bool isEAFHosted) : - base(new Description(), true, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, useCyclicalForDescription, isEAFHosted) + public FileRead(ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) : + base(new Description(), true, smtp, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted) { _MinFileLength = 15; _NullData = string.Empty; - _Logistics = new Logistics(this); + _Logistics = new(this); if (_FileParameter is null) throw new Exception(cellInstanceConnectionName); if (_ModelObjectParameterDefinitions is null) throw new Exception(cellInstanceConnectionName); if (_IsDuplicator) throw new Exception(cellInstanceConnectionName); - _GhostPCLFileName = string.Concat(Path.GetDirectoryName(Assembly.GetEntryAssembly().Location), @"\gpcl6win64.exe"); + _GhostPCLFileName = Path.Combine(AppContext.BaseDirectory, "gpcl6win64.exe"); if (!File.Exists(_GhostPCLFileName)) throw new Exception("Ghost PCL FileName doesn't Exist!"); } - void IFileRead.Move(Tuple> extractResults, Exception exception) => Move(extractResults, exception); + void IFileRead.Move(Tuple> extractResults, Exception exception) => Move(extractResults); void IFileRead.WaitForThread() => WaitForThread(thread: null, threadExceptions: null); @@ -99,8 +98,6 @@ public class FileRead : Shared.FileRead, IFileRead return results; } - void IFileRead.CheckTests(Test[] tests, bool extra) => throw new Exception(string.Concat("Not ", nameof(_IsDuplicator))); - private Tuple> GetExtractResult(string reportFullPath, DateTime dateTime) { Tuple> results = new(string.Empty, null, null, new List()); @@ -111,16 +108,15 @@ public class FileRead : Shared.FileRead, IFileRead else { IProcessData iProcessData = new ProcessData(this, _Logistics, results.Item4, _GhostPCLFileName); - if (iProcessData is ProcessData processData) - { - string mid = string.Concat(processData.Reactor, "-", processData.RDS, "-", processData.PSN); - mid = Regex.Replace(mid, @"[\\,\/,\:,\*,\?,\"",\<,\>,\|]", "_").Split('\r')[0].Split('\n')[0]; - _Logistics.MID = mid; - SetFileParameterLotID(mid); - _Logistics.ProcessJobID = processData.Reactor; - } + if (iProcessData is not ProcessData processData) + throw new Exception(string.Concat("A) No Data - ", dateTime.Ticks)); + string mid = string.Concat(processData.Reactor, "-", processData.RDS, "-", processData.PSN); + mid = Regex.Replace(mid, @"[\\,\/,\:,\*,\?,\"",\<,\>,\|]", "_").Split('\r')[0].Split('\n')[0]; + _Logistics.MID = mid; + SetFileParameterLotID(mid); + _Logistics.ProcessJobID = processData.Reactor; if (!iProcessData.Details.Any()) - throw new Exception(string.Concat("No Data - ", dateTime.Ticks)); + throw new Exception(string.Concat("B) No Data - ", dateTime.Ticks)); results = iProcessData.GetResults(this, _Logistics, results.Item4); } return results; diff --git a/Adaptation/FileHandlers/pcl/ProcessData.cs b/Adaptation/FileHandlers/pcl/ProcessData.cs index 8b6f795..a8ba99f 100644 --- a/Adaptation/FileHandlers/pcl/ProcessData.cs +++ b/Adaptation/FileHandlers/pcl/ProcessData.cs @@ -5,11 +5,10 @@ using System; using System.Collections.Generic; using System.Data; using System.Diagnostics; -using System.Globalization; using System.IO; using System.Linq; -using System.Text; using System.Text.Json; +using System.Text.Json.Serialization; using System.Text.RegularExpressions; namespace Adaptation.FileHandlers.pcl; @@ -630,4 +629,19 @@ public class ProcessData : IProcessData fileInfoCollection.Add(new FileInfo(logistics.ReportFullPath)); } + internal static List GetDescriptions(JsonElement[] jsonElements) + { + List results = new(); + Description description; + JsonSerializerOptions jsonSerializerOptions = new() { NumberHandling = JsonNumberHandling.AllowReadingFromString | JsonNumberHandling.WriteAsString }; + foreach (JsonElement jsonElement in jsonElements) + { + if (jsonElement.ValueKind != JsonValueKind.Object) + throw new Exception(); + description = JsonSerializer.Deserialize(jsonElement.ToString(), jsonSerializerOptions); + results.Add(description); + } + return results; + } + } \ No newline at end of file diff --git a/Adaptation/Ifx/Eaf/Common/Configuration/ConnectionSetting.cs b/Adaptation/Ifx/Eaf/Common/Configuration/ConnectionSetting.cs index 7c31ecf..7cd0603 100644 --- a/Adaptation/Ifx/Eaf/Common/Configuration/ConnectionSetting.cs +++ b/Adaptation/Ifx/Eaf/Common/Configuration/ConnectionSetting.cs @@ -1,6 +1,6 @@ namespace Adaptation.Ifx.Eaf.Common.Configuration; -[System.Runtime.Serialization.DataContractAttribute] +[System.Runtime.Serialization.DataContract] public class ConnectionSetting { @@ -8,9 +8,9 @@ public class ConnectionSetting public ConnectionSetting(string name, string value) { } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string Name { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string Value { get; set; } } \ No newline at end of file diff --git a/Adaptation/Ifx/Eaf/EquipmentConnector/File/Configuration/FileConnectorConfiguration.cs b/Adaptation/Ifx/Eaf/EquipmentConnector/File/Configuration/FileConnectorConfiguration.cs index 4e4aa83..05fe1cc 100644 --- a/Adaptation/Ifx/Eaf/EquipmentConnector/File/Configuration/FileConnectorConfiguration.cs +++ b/Adaptation/Ifx/Eaf/EquipmentConnector/File/Configuration/FileConnectorConfiguration.cs @@ -4,85 +4,85 @@ using System.Collections.Generic; namespace Adaptation.Ifx.Eaf.EquipmentConnector.File.Configuration; -[System.Runtime.Serialization.DataContractAttribute] +[System.Runtime.Serialization.DataContract] public class FileConnectorConfiguration { public const ulong IDLE_EVENT_WAIT_TIME_DEFAULT = 360; public const ulong FILE_HANDLE_TIMEOUT_DEFAULT = 15; - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual bool? TriggerOnChanged { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual long? PostProcessingRetries { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual bool? CopySourceFolderStructure { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public IfPostProcessingFailsEnum? IfPostProcessingFailsAction { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string AlternateTargetFolder { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public long? FileHandleTimeout { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public bool? DeleteEmptySourceSubFolders { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public long? IdleEventWaitTimeInSeconds { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string FileAgeThreshold { get; set; } public bool? FolderAgeCheckIndividualSubFolders { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual ZipModeEnum? ZipMode { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public FileAgeFilterEnum? FileAgeFilterMode { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string ZipTargetFileName { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string ZipErrorTargetFileName { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public long? ZipFileSubFolderLevel { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string DefaultPlaceHolderValue { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public bool? UseZip64Mode { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public List ConnectionSettings { get; set; } public string SourceDirectoryCloaking { get; set; } public string FolderAgeThreshold { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual long? FileScanningIntervalInSeconds { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual bool? TriggerOnCreated { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual long? ZipFileTime { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string SourceFileLocation { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string SourceFileFilter { get; set; } public List SourceFileFilters { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual bool? IncludeSubDirectories { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual FileScanningOptionEnum? FileScanningOption { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string TargetFileLocation { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string ErrorTargetFileLocation { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string TargetFileName { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual long? FileHandleWaitTime { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public IfFileExistEnum? IfFileExistAction { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public long? ConnectionRetryInterval { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public PreProcessingModeEnum? PreProcessingMode { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public PostProcessingModeEnum? PostProcessingMode { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public PostProcessingModeEnum? ErrorPostProcessingMode { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public virtual long? ZipFileAmount { get; set; } - [System.Runtime.Serialization.DataMemberAttribute] + [System.Runtime.Serialization.DataMember] public string ErrorTargetFileName { get; set; } public void Initialize() => throw new NotImplementedException(); diff --git a/Adaptation/Ifx/Eaf/EquipmentConnector/File/SelfDescription/FileConnectorParameterTypeDefinitionProvider.cs b/Adaptation/Ifx/Eaf/EquipmentConnector/File/SelfDescription/FileConnectorParameterTypeDefinitionProvider.cs index 9d9aa53..57475d5 100644 --- a/Adaptation/Ifx/Eaf/EquipmentConnector/File/SelfDescription/FileConnectorParameterTypeDefinitionProvider.cs +++ b/Adaptation/Ifx/Eaf/EquipmentConnector/File/SelfDescription/FileConnectorParameterTypeDefinitionProvider.cs @@ -1,5 +1,4 @@ using Adaptation.Eaf.EquipmentCore.SelfDescription.ParameterTypes; -using System; using System.Collections.Generic; namespace Adaptation.Ifx.Eaf.EquipmentConnector.File.SelfDescription; diff --git a/Adaptation/MET08DDUPSFS6420.Tests.csproj b/Adaptation/MET08DDUPSFS6420.Tests.csproj index 0c711c0..b80dc0f 100644 --- a/Adaptation/MET08DDUPSFS6420.Tests.csproj +++ b/Adaptation/MET08DDUPSFS6420.Tests.csproj @@ -6,12 +6,12 @@ SAK - enable + disable + false 10.0 disable win-x64 net6.0 - false trx @@ -32,70 +32,58 @@ Linux - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + - - NU1701 - - - NU1701 - - - NU1701 - - - NU1701 - - - NU1701 - + + - - NU1701 + + + + + + + + + all + runtime; build; native; contentfiles; analyzers; buildtransitive - - NU1701 - - - NU1701 - - - NU1701 - - - NU1701 - - - NU1701 - - - NU1701 - - - NU1701 - - + + + + + + + + NU1701 + NU1701 + NU1701 + + + NU1701 + NU1701 + NU1701 + NU1701 + NU1701 + NU1701 + NU1701 + NU1701 + Always diff --git a/Adaptation/Shared/FileRead.cs b/Adaptation/Shared/FileRead.cs index 54813e2..14a9eb8 100644 --- a/Adaptation/Shared/FileRead.cs +++ b/Adaptation/Shared/FileRead.cs @@ -33,8 +33,6 @@ public class FileRead : Properties.IFileRead protected readonly bool _IsDuplicator; protected readonly Calendar _Calendar; protected readonly bool _IsSourceTimer; - protected readonly string _VillachPath; - protected readonly string _ProgressPath; protected readonly string _EquipmentType; protected readonly long _BreakAfterSeconds; protected readonly string _ExceptionSubject; @@ -46,6 +44,7 @@ public class FileRead : Properties.IFileRead protected readonly string _CellInstanceConnectionNameBase; protected readonly Dictionary> _DummyRuns; protected readonly Dictionary _FileParameter; + protected readonly Dictionary> _StaticRuns; protected readonly string _ParameterizedModelObjectDefinitionType; protected readonly FileConnectorConfiguration _FileConnectorConfiguration; protected readonly IList _ModelObjectParameterDefinitions; @@ -63,12 +62,13 @@ public class FileRead : Properties.IFileRead string Properties.IFileRead.CellInstanceConnectionName => _CellInstanceConnectionName; string Properties.IFileRead.ParameterizedModelObjectDefinitionType => _ParameterizedModelObjectDefinitionType; - public FileRead(IDescription description, bool isEvent, ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, bool useCyclicalForDescription, bool isEAFHosted) + public FileRead(IDescription description, bool isEvent, ISMTP smtp, Dictionary fileParameter, string cellInstanceName, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList modelObjectParameters, string equipmentDictionaryName, Dictionary> dummyRuns, Dictionary> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) { _SMTP = smtp; _IsEvent = isEvent; _DummyRuns = dummyRuns; _LastTicksDuration = 0; + _StaticRuns = staticRuns; _IsEAFHosted = isEAFHosted; _Description = description; _FileParameter = fileParameter; @@ -84,6 +84,7 @@ public class FileRead : Properties.IFileRead _IsSourceTimer = fileConnectorConfiguration.SourceFileFilter.StartsWith("*Timer.txt"); string cellInstanceConnectionNameBase = cellInstanceConnectionName.Replace("-", string.Empty); _Hyphens = cellInstanceConnectionName.Length - cellInstanceConnectionNameBase.Length; + _TracePath = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "Path.Trace"); _ExceptionSubject = string.Concat("Exception:", _CellInstanceConnectionName, _FileConnectorConfiguration?.SourceDirectoryCloaking); string suffix; string[] segments = _ParameterizedModelObjectDefinitionType.Split('.'); @@ -111,16 +112,10 @@ public class FileRead : Properties.IFileRead // if (!string.IsNullOrEmpty(equipmentDictionaryName) && isEvent) // throw new Exception(cellInstanceConnectionName); } - ModelObjectParameterDefinition[] paths = GetProperties(cellInstanceConnectionName, modelObjectParameters, "Path."); - if (paths.Length < 3) - throw new Exception(cellInstanceConnectionName); if (isDuplicator) _MesEntity = string.Empty; else _MesEntity = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, string.Concat("CellInstance.", cellInstanceName, ".Alias")); - _TracePath = (from l in paths where l.Name.EndsWith("Trace") select l.Value).FirstOrDefault(); - _VillachPath = (from l in paths where l.Name.EndsWith("Villach") select l.Value).FirstOrDefault(); - _ProgressPath = (from l in paths where l.Name.EndsWith("Progress") select l.Value).FirstOrDefault(); _EventName = eventName; _EventNameFileRead = eventNameFileRead; _EquipmentType = parameterizedModelObjectDefinitionTypeAppended; @@ -130,9 +125,11 @@ public class FileRead : Properties.IFileRead else { if (_FileConnectorConfiguration.FileScanningOption == FileConnectorConfiguration.FileScanningOptionEnum.TimeBased) - breakAfterSeconds = 360; - else + breakAfterSeconds = Math.Abs(_FileConnectorConfiguration.FileHandleTimeout.Value); + else if (_FileConnectorConfiguration.FileScanningOption == FileConnectorConfiguration.FileScanningOptionEnum.FileWatcher) breakAfterSeconds = Math.Abs(_FileConnectorConfiguration.FileScanningIntervalInSeconds.Value); + else + throw new Exception(); } _BreakAfterSeconds = breakAfterSeconds; UpdateLastTicksDuration(breakAfterSeconds * 10000000); @@ -142,13 +139,13 @@ public class FileRead : Properties.IFileRead throw new Exception("_Configuration is empty?"); if (_FileConnectorConfiguration.TargetFileLocation.Contains('%') || _FileConnectorConfiguration.ErrorTargetFileLocation.Contains('%')) throw new Exception("_Configuration is incorrect for a duplicator!"); - if (_FileConnectorConfiguration is not null) - { - if (string.IsNullOrEmpty(_FileConnectorConfiguration.SourceDirectoryCloaking)) - throw new Exception("SourceDirectoryCloaking is empty?"); - if (!_FileConnectorConfiguration.SourceDirectoryCloaking.StartsWith("~")) - throw new Exception("SourceDirectoryCloaking is incorrect for a duplicator!"); - } + // if (_FileConnectorConfiguration is not null) + // { + // if (string.IsNullOrEmpty(_FileConnectorConfiguration.SourceDirectoryCloaking)) + // throw new Exception("SourceDirectoryCloaking is empty?"); + // if (!_FileConnectorConfiguration.SourceDirectoryCloaking.StartsWith("~")) + // throw new Exception("SourceDirectoryCloaking is incorrect for a duplicator!"); + // } } } @@ -183,6 +180,7 @@ public class FileRead : Properties.IFileRead if (ticksDuration < 50000000) ticksDuration = 50000000; _LastTicksDuration = (long)Math.Ceiling(ticksDuration * .667); + _Log.Info($"{new TimeSpan(ticksDuration).TotalMilliseconds} TotalMillisecond(s) to process {Environment.NewLine}{_CellInstanceConnectionName}{Environment.NewLine}<{_ReportFullPath}>"); } protected void WaitForThread(Thread thread, List threadExceptions) @@ -216,35 +214,16 @@ public class FileRead : Properties.IFileRead } } - protected void CreateProgressDirectory(string[] exceptionLines) + private void WriteAllLines(string to, string[] exceptionLines) { - string progressDirectory; - StringBuilder stringBuilder = new(); - if (_Hyphens == 0) - progressDirectory = Path.Combine(_ProgressPath, _CellInstanceConnectionName); - else + string fileName = string.Concat(to, @"\readme.txt"); + try { - _ = stringBuilder.Clear(); - for (int i = 0; i < _Hyphens; i++) - { - if (i > 0 && (i % 2) == 0) - _ = stringBuilder.Append(' '); - _ = stringBuilder.Append('-'); - } - progressDirectory = string.Concat(_ProgressPath, @"\", (_Hyphens + 1).ToString().PadLeft(2, '0'), " ", stringBuilder).Trim(); - } - DateTime dateTime = DateTime.Now; - string weekOfYear = _Calendar.GetWeekOfYear(dateTime, CalendarWeekRule.FirstDay, DayOfWeek.Sunday).ToString("00"); - progressDirectory = string.Concat(progressDirectory, @"\", dateTime.ToString("yyyy"), "_Week_", weekOfYear, @"\", _Logistics.MID, "_", _Logistics.Sequence, "_", DateTime.Now.Ticks - _Logistics.Sequence); - if (!Directory.Exists(progressDirectory)) - _ = Directory.CreateDirectory(progressDirectory); - if (exceptionLines is not null) - { - string fileName = string.Concat(progressDirectory, @"\readme.txt"); - try - { File.WriteAllLines(fileName, exceptionLines); } - catch (Exception) { } + if (!Directory.Exists(to)) + _ = Directory.CreateDirectory(to); + File.WriteAllLines(fileName, exceptionLines); } + catch (Exception ex) { _Log.Error(ex.Message); } } protected string[] Move(Tuple> extractResults, string to, string from, string resolvedFileLocation, Exception exception) @@ -258,7 +237,8 @@ public class FileRead : Properties.IFileRead else { results = new string[] { _Logistics.Sequence.ToString(), _Logistics.ReportFullPath, from, resolvedFileLocation, to, string.Empty, string.Empty, exception.Message, string.Empty, string.Empty, exception.StackTrace }; - Shared0449(to, results); + if (!_IsDuplicator) + WriteAllLines(to, results); } if (extractResults is not null && extractResults.Item4 is not null && extractResults.Item4.Any()) { @@ -279,64 +259,6 @@ public class FileRead : Properties.IFileRead return results; } - protected static IEnumerable GetDirectoriesRecursively(string path, string directoryNameSegment = null) - { - Queue queue = new(); - queue.Enqueue(path); - while (queue.Count > 0) - { - path = queue.Dequeue(); - foreach (string subDirectory in Directory.GetDirectories(path)) - { - queue.Enqueue(subDirectory); - if (string.IsNullOrEmpty(directoryNameSegment) || Path.GetFileName(subDirectory).Contains(directoryNameSegment)) - yield return subDirectory; - } - } - } - - protected string GetProcessedDirectory(string progressPath, Logistics logistics, DateTime dateTime, string duplicateDirectory) - { - string result = duplicateDirectory; - string logisticsSequence = logistics.Sequence.ToString(); - string[] matchDirectories; - if (!_IsEAFHosted) - matchDirectories = new string[] { Path.GetDirectoryName(Path.GetDirectoryName(logistics.ReportFullPath)) }; - else - matchDirectories = new string[] { GetDirectoriesRecursively(Path.GetDirectoryName(progressPath), logisticsSequence).FirstOrDefault() }; - if (matchDirectories.Length == 0 || string.IsNullOrEmpty(matchDirectories[0])) - matchDirectories = Directory.GetDirectories(duplicateDirectory, string.Concat('*', logisticsSequence, '*'), SearchOption.AllDirectories); - if ((matchDirectories is null) || matchDirectories.Length != 1) - throw new Exception("Didn't find directory by logistics sequence"); - if (!matchDirectories[0].Contains("_processed")) - { - result = string.Concat(matchDirectories[0].Split(new string[] { logisticsSequence }, StringSplitOptions.None)[0], logistics.DateTimeFromSequence.ToString("yyyy-MM-dd_hh;mm_tt_"), dateTime.Ticks - logistics.Sequence, "_processed"); - Directory.Move(matchDirectories[0], result); - result = string.Concat(result, @"\", logistics.Sequence); - if (!Directory.Exists(result)) - _ = Directory.CreateDirectory(result); - } - return result; - } - - protected string WriteScopeInfo(string progressPath, Logistics logistics, DateTime dateTime, string duplicateDirectory, List> tuples) - { - string result = GetProcessedDirectory(progressPath, logistics, dateTime, duplicateDirectory); - string tupleFile; - string fileName = Path.GetFileNameWithoutExtension(logistics.ReportFullPath); - string duplicateFile = string.Concat(result, @"\", fileName, ".pdsf"); - foreach (Tuple tuple in tuples) - { - if (tuple.Item1.FileName.StartsWith(@"\")) - tupleFile = tuple.Item1.FileName; - else - tupleFile = string.Concat(result, @"\", fileName, "_", tuple.Item1.FileNameWithoutExtension, ".pdsfc"); - File.WriteAllText(tupleFile, tuple.Item2); - } - File.Copy(logistics.ReportFullPath, duplicateFile, overwrite: true); - return result; - } - protected static string GetTupleFile(Logistics logistics, Properties.IScopeInfo scopeInfo, string duplicateDirectory) { string result; @@ -369,34 +291,34 @@ public class FileRead : Properties.IFileRead return result; } - protected void WaitForFileConsumption(string sourceDirectoryCloaking, Logistics logistics, DateTime dateTime, string successDirectory, string duplicateDirectory, string duplicateFile, List> tuples) + protected void WaitForFileConsumption(string sourceDirectoryCloaking, Logistics logistics, DateTime dateTime, string successDirectory, string duplicateDirectory, string duplicateFile, List<(Properties.IScopeInfo, string)> tuples) { bool check; long preWait; string tupleFile; - List consumedFileIndices = new(); List duplicateFiles = new(); - bool moreThanAnHour = (_BreakAfterSeconds > 3600); StringBuilder stringBuilder = new(); + List consumedFileIndices = new(); + bool moreThanAnHour = _BreakAfterSeconds > 3600; long breakAfter = dateTime.AddSeconds(_BreakAfterSeconds).Ticks; - if (moreThanAnHour) - preWait = dateTime.AddSeconds(30).Ticks; + if (_FileConnectorConfiguration?.FileHandleWaitTime is null) + preWait = dateTime.AddMilliseconds(1234).Ticks; else - preWait = dateTime.AddTicks(_LastTicksDuration).Ticks; + preWait = dateTime.AddMilliseconds(_FileConnectorConfiguration.FileHandleWaitTime.Value).Ticks; if (!tuples.Any()) duplicateFiles.Add(duplicateFile); string fileName = Path.GetFileNameWithoutExtension(logistics.ReportFullPath); string successFile = string.Concat(successDirectory, @"\", Path.GetFileName(logistics.ReportFullPath)); - foreach (Tuple tuple in tuples) + foreach ((Properties.IScopeInfo scopeInfo, string text) in tuples) { - if (tuple.Item1.FileName.StartsWith(@"\")) - tupleFile = tuple.Item1.FileName; - else if (!tuple.Item1.FileName.Contains('%')) - tupleFile = string.Concat(duplicateDirectory, @"\", fileName, "_", tuple.Item1.FileNameWithoutExtension, ".pdsfc"); + if (scopeInfo.FileName.StartsWith(@"\")) + tupleFile = scopeInfo.FileName; + else if (!scopeInfo.FileName.Contains('%')) + tupleFile = string.Concat(duplicateDirectory, @"\", fileName, "_", scopeInfo.FileNameWithoutExtension, ".pdsfc"); else - tupleFile = GetTupleFile(logistics, tuple.Item1, duplicateDirectory); + tupleFile = GetTupleFile(logistics, scopeInfo, duplicateDirectory); duplicateFiles.Add(tupleFile); - File.WriteAllText(tupleFile, tuple.Item2); + File.WriteAllText(tupleFile, text); } for (short i = 0; i < short.MaxValue; i++) { @@ -410,7 +332,7 @@ public class FileRead : Properties.IFileRead { try { - check = (string.IsNullOrEmpty(successDirectory) || File.Exists(successFile)); + check = string.IsNullOrEmpty(successDirectory) || File.Exists(successFile); if (check) { consumedFileIndices.Clear(); @@ -482,7 +404,7 @@ public class FileRead : Properties.IFileRead { string directory; if (!_CellInstanceConnectionName.StartsWith(_CellInstanceName) && _CellInstanceConnectionNameBase == _EquipmentType) - directory = Path.Combine(_VillachPath, _EquipmentType, "Target"); + directory = Path.Combine(_TracePath, _EquipmentType, "Target", _CellInstanceName, _CellInstanceConnectionName); else directory = Path.Combine(_TracePath, _EquipmentType, "Source", _CellInstanceName, _CellInstanceConnectionName); if (!Directory.Exists(directory)) @@ -498,14 +420,8 @@ public class FileRead : Properties.IFileRead } } - protected void Move(Tuple> extractResults, Exception exception) + protected void Move(Tuple> extractResults) { - bool isErrorFile = exception is not null; - if (!isErrorFile && _IsDuplicator) - { - if (_IsEAFHosted && !string.IsNullOrEmpty(_ProgressPath)) - CreateProgressDirectory(exceptionLines: null); - } if (!_IsEAFHosted) { string to; @@ -583,20 +499,6 @@ public class FileRead : Properties.IFileRead return results; } - protected static Dictionary> GetKeyValuePairs(List descriptions) - { - Dictionary> results = new(); - Test testKey; - for (int i = 0; i < descriptions.Count; i++) - { - testKey = (Test)descriptions[i].Test; - if (!results.ContainsKey(testKey)) - results.Add(testKey, new List()); - results[testKey].Add(descriptions[i]); - } - return results; - } - protected static List GetDuplicatorDescriptions(JsonElement[] jsonElements) { List results = new(); @@ -612,34 +514,7 @@ public class FileRead : Properties.IFileRead return results; } - protected static Tuple>> GetTuple(IFileRead fileRead, IEnumerable descriptions, bool extra = false) - { - Tuple>> result; - Dictionary> keyValuePairs = GetKeyValuePairs(descriptions.ToList()); - Test[] tests = (from l in keyValuePairs select l.Key).ToArray(); - fileRead.CheckTests(tests, extra); - result = new Tuple>>(tests, keyValuePairs); - return result; - } - - protected void Shared0449(string to, string[] exceptionLines) - { - if (_IsDuplicator) - CreateProgressDirectory(exceptionLines: null); - else - { - string fileName = string.Concat(to, @"\readme.txt"); - try - { - if (!Directory.Exists(to)) - _ = Directory.CreateDirectory(to); - File.WriteAllLines(fileName, exceptionLines); - } - catch (Exception ex) { _Log.Error(ex.Message); } - } - } - - protected void Shared1880(string itemFile, List directories, FileInfo sourceFile, bool isErrorFile) + private void Shared1880(string itemFile, List directories, FileInfo sourceFile, bool isErrorFile) { string itemDirectory; directories.Add(Path.GetDirectoryName(sourceFile.FullName)); @@ -674,7 +549,7 @@ public class FileRead : Properties.IFileRead } } - protected void Shared1811(string to, FileInfo sourceFile) + private void Shared1811(string to, FileInfo sourceFile) { if (!_IsDuplicator && _FileConnectorConfiguration.SourceFileFilter != "*" && sourceFile.Exists && sourceFile.Length < _MinFileLength) { @@ -682,7 +557,7 @@ public class FileRead : Properties.IFileRead string jobIdDirectory = Path.GetDirectoryName(to); DateTime dateTime = DateTime.Now.AddMinutes(-15); string weekOfYear = _Calendar.GetWeekOfYear(_Logistics.DateTimeFromSequence, CalendarWeekRule.FirstDay, DayOfWeek.Sunday).ToString("00"); - string weekDirectory = string.Concat(_Logistics.DateTimeFromSequence.ToString("yyyy"), "_Week_", weekOfYear, @"\", _Logistics.DateTimeFromSequence.ToString("yyyy-MM-dd")); + string weekDirectory = $"{_Logistics.DateTimeFromSequence:yyyy}_Week_{weekOfYear}{@"\"}{_Logistics.DateTimeFromSequence:yyyy-MM-dd}"; string destinationDirectory = string.Concat(jobIdDirectory, @"\_ Ignore 100 bytes\", weekDirectory, @"\", directoryName); if (!Directory.Exists(destinationDirectory)) _ = Directory.CreateDirectory(destinationDirectory); @@ -711,7 +586,7 @@ public class FileRead : Properties.IFileRead } } - protected void Shared0231(List directories) + private void Shared0231(List directories) { if (_FileConnectorConfiguration.PostProcessingMode != FileConnectorConfiguration.PostProcessingModeEnum.Copy) { @@ -723,7 +598,7 @@ public class FileRead : Properties.IFileRead } } - protected void Shared0413(DateTime dateTime, bool isDummyRun, string successDirectory, string duplicateDirectory, List> tuples, string duplicateFile) + protected void WaitForFileConsumption(DateTime dateTime, bool isDummyRun, string successDirectory, string duplicateDirectory, List<(Properties.IScopeInfo, string)> tuples, string duplicateFile) { if (!isDummyRun && _IsEAFHosted) WaitForFileConsumption(_FileConnectorConfiguration.SourceDirectoryCloaking, _Logistics, dateTime, successDirectory, duplicateDirectory, duplicateFile, tuples); @@ -739,75 +614,33 @@ public class FileRead : Properties.IFileRead } } - protected static void Shared0607(string reportFullPath, string duplicateDirectory, string logisticsSequence, string destinationDirectory) + internal static string GetJobIdParentDirectory(string directory) { - if (destinationDirectory == duplicateDirectory) - throw new Exception("Check Target File Folder for %LotIDWithLogisticsSequence%_in process on CI (not Duplicator)"); - if (destinationDirectory.EndsWith(logisticsSequence)) - destinationDirectory = Path.GetDirectoryName(destinationDirectory); - string[] deleteFiles = Directory.GetFiles(destinationDirectory, "*", SearchOption.AllDirectories); - if (deleteFiles.Length > 250) - throw new Exception("Safety net!"); - foreach (string file in deleteFiles) - File.Delete(file); - Directory.Delete(destinationDirectory, recursive: true); - File.Delete(reportFullPath); + string result; + if (!string.IsNullOrEmpty(Path.GetFileName(directory))) + result = Path.GetFullPath(Path.GetDirectoryName(Path.GetDirectoryName(directory))); + else + result = Path.GetFullPath(Path.GetDirectoryName(Path.GetDirectoryName(Path.GetDirectoryName(directory)))); + if (!Directory.Exists(result)) + _ = Directory.CreateDirectory(result); + return result; } - protected string[] Shared1567(string reportFullPath, List> tuples) + internal string[] GetInProcessDirectory(string jobIdDirectory) { string[] results; - string historicalText; - string logisticsSequence = _Logistics.Sequence.ToString(); - string jobIdDirectory = string.Concat(Path.GetDirectoryName(Path.GetDirectoryName(_FileConnectorConfiguration.TargetFileLocation)), @"\", _Logistics.JobID); - if (!Directory.Exists(jobIdDirectory)) - _ = Directory.CreateDirectory(jobIdDirectory); - string[] matchDirectories; if (!_IsEAFHosted) - matchDirectories = new string[] { Path.GetDirectoryName(Path.GetDirectoryName(reportFullPath)) }; + results = new string[] { jobIdDirectory }; else - matchDirectories = Directory.GetDirectories(jobIdDirectory, string.Concat(_Logistics.MID, '*', logisticsSequence, '*'), SearchOption.TopDirectoryOnly); - if ((matchDirectories is null) || matchDirectories.Length != 1) - throw new Exception("Didn't find directory by logistics sequence"); - string fileName = Path.GetFileNameWithoutExtension(reportFullPath); - string sequenceDirectory = string.Concat(matchDirectories[0], @"\", logisticsSequence); - if (!Directory.Exists(sequenceDirectory)) - _ = Directory.CreateDirectory(sequenceDirectory); - foreach (Tuple tuple in tuples) { - fileName = string.Concat(sequenceDirectory, @"\", fileName, "_", tuple.Item1.FileNameWithoutExtension, ".pdsfc"); - if (_IsEAFHosted) - File.WriteAllText(fileName, tuple.Item2); - else - { - if (File.Exists(fileName)) - { - historicalText = File.ReadAllText(fileName); - if (tuple.Item2 != historicalText) - throw new Exception("File doesn't match historical!"); - } - } + string logisticsSequence = _Logistics.Sequence.ToString(); + results = Directory.GetDirectories(jobIdDirectory, string.Concat(_Logistics.MID, '*', logisticsSequence, '*'), SearchOption.TopDirectoryOnly); } - results = matchDirectories; + if ((results is null) || results.Length != 1) + throw new Exception("Didn't find directory by logistics sequence"); return results; } - protected void Shared1277(string reportFullPath, string destinationDirectory, string logisticsSequence, string jobIdDirectory, string json) - { - string ecCharacterizationSi = Path.GetDirectoryName(Path.GetDirectoryName(jobIdDirectory)); - string destinationJobIdDirectory = string.Concat(ecCharacterizationSi, @"\Processed\", _Logistics.JobID); - if (!Directory.Exists(destinationJobIdDirectory)) - _ = Directory.CreateDirectory(destinationJobIdDirectory); - destinationJobIdDirectory = string.Concat(destinationJobIdDirectory, @"\", Path.GetFileName(destinationDirectory).Split(new string[] { logisticsSequence }, StringSplitOptions.None)[0], _Logistics.DateTimeFromSequence.ToString("yyyy-MM-dd_hh;mm_tt_"), DateTime.Now.Ticks - _Logistics.Sequence); - string sequenceDirectory = string.Concat(destinationJobIdDirectory, @"\", logisticsSequence); - string jsonFileName = string.Concat(sequenceDirectory, @"\", Path.GetFileNameWithoutExtension(reportFullPath), ".json"); - Directory.Move(destinationDirectory, destinationJobIdDirectory); - if (!Directory.Exists(sequenceDirectory)) - _ = Directory.CreateDirectory(sequenceDirectory); - File.Copy(reportFullPath, string.Concat(sequenceDirectory, @"\", Path.GetFileName(reportFullPath)), overwrite: true); - File.WriteAllText(jsonFileName, json); - } - } -// 2022-02-14 -> Shared - FileRead \ No newline at end of file +// 2022-05-13 -> Shared - FileRead \ No newline at end of file diff --git a/Adaptation/Shared/Methods/IFileRead.cs b/Adaptation/Shared/Methods/IFileRead.cs index 4d383c3..3d690c1 100644 --- a/Adaptation/Shared/Methods/IFileRead.cs +++ b/Adaptation/Shared/Methods/IFileRead.cs @@ -12,7 +12,6 @@ public interface IFileRead : Properties.IFileRead JsonProperty[] GetDefault(); string GetEventDescription(); List GetHeaderNames(); - void CheckTests(Test[] tests, bool extra); Dictionary GetDisplayNamesJsonElement(); Tuple> ReExtract(); List GetDescriptions(IFileRead fileRead, List tests, IProcessData processData); diff --git a/Adaptation/Shared/Metrology/WS.cs b/Adaptation/Shared/Metrology/WS.cs index e08d4e3..b892219 100644 --- a/Adaptation/Shared/Metrology/WS.cs +++ b/Adaptation/Shared/Metrology/WS.cs @@ -1,6 +1,6 @@ using System; using System.Collections.Generic; -using System.Linq; +using System.IO; using System.Net.Http; using System.Text; using System.Text.Json; @@ -10,14 +10,14 @@ namespace Adaptation.Shared.Metrology; public partial class WS { - public static Tuple SendData(string url, object payload, int timeoutSeconds = 120) + public static (string, Results) SendData(string url, object payload, int timeoutSeconds = 120) { Results results = new(); string resultsJson = string.Empty; try { string json = JsonSerializer.Serialize(payload, payload.GetType()); - if (string.IsNullOrEmpty(url) || !url.Contains(':') || !url.Contains('.')) + if (string.IsNullOrEmpty(url) || !url.Contains(":") || !url.Contains(".")) throw new Exception("Invalid URL"); using (HttpClient httpClient = new()) { @@ -48,11 +48,11 @@ public partial class WS results.Errors = new List(); results.Errors.Add(stringBuilder.ToString()); } - return new Tuple(resultsJson, results); + return new(resultsJson, results); } // this method is a wrapper for attaching a file to either a header or data record - // URL is the same URL used for SendData, ex: http://localhost/api/inbound/TENCOR + // URL is the same URL used for SendData, ex: http://localhost/api/inbound/CDE // attachToHeaderId is the ID returned by SendData // attachToDataUniqueId is the string unique ID for the data record, aka the Title of the Sharepoint list entry // fileContents is a byte array with the contents of the file @@ -97,12 +97,12 @@ public partial class WS if (headerAttachments is not null) { foreach (Attachment attachment in headerAttachments) - AttachFile(url, headerID, "", System.IO.File.ReadAllBytes(attachment.SourceFileName), attachment.DestinationFileName); + AttachFile(url, headerID, "", File.ReadAllBytes(attachment.SourceFileName), attachment.DestinationFileName); } if (dataAttachments is not null) { foreach (Attachment attachment in dataAttachments) - AttachFile(url, headerID, attachment.UniqueId, System.IO.File.ReadAllBytes(attachment.SourceFileName), attachment.DestinationFileName); + AttachFile(url, headerID, attachment.UniqueId, File.ReadAllBytes(attachment.SourceFileName), attachment.DestinationFileName); } //MessageBox.Show(r.ToString()); } diff --git a/Adaptation/Shared/ProcessDataStandardFormat.cs b/Adaptation/Shared/ProcessDataStandardFormat.cs index 251d1b4..33a248e 100644 --- a/Adaptation/Shared/ProcessDataStandardFormat.cs +++ b/Adaptation/Shared/ProcessDataStandardFormat.cs @@ -348,8 +348,8 @@ public class ProcessDataStandardFormat int startsAt = 0; string[] segments; int? currentGroup = null; - char inputSeperator = '\t'; - char outputSeperator = '\t'; + char inputSeparator = '\t'; + char outputSeparator = '\t'; List vs = new(); List groups = new(); string[] lines = File.ReadAllLines(reportFullPath); @@ -358,7 +358,7 @@ public class ProcessDataStandardFormat { if (string.IsNullOrEmpty(lines[i])) continue; - segments = lines[i].Split(inputSeperator); + segments = lines[i].Split(inputSeparator); if (currentGroup is null) currentGroup = segments.Length; if (segments.Length != currentGroup) @@ -368,20 +368,20 @@ public class ProcessDataStandardFormat startsAt = i; } } - if (startsAt == lines.Length - 1 && lines[0].Split(inputSeperator).Length != currentGroup) + if (startsAt == lines.Length - 1 && lines[0].Split(inputSeparator).Length != currentGroup) groups.Add(new int[] { lines.Length - 1, lines.Length - 1 }); for (int g = 0; g < groups.Count; g++) { vs.Clear(); group = groups[g]; line = lines[group[0]]; - segments = line.Split(inputSeperator); + segments = line.Split(inputSeparator); for (int s = 0; s < segments.Length; s++) vs.Add(segments[s].Length); for (int i = group[0]; i <= group[1]; i++) { line = lines[i]; - segments = line.Split(inputSeperator); + segments = line.Split(inputSeparator); for (int s = 0; s < segments.Length; s++) { if (vs[s] < segments[s].Length) @@ -390,16 +390,16 @@ public class ProcessDataStandardFormat } _ = stringBuilder.Clear(); for (int s = 0; s < segments.Length; s++) - _ = stringBuilder.Append((s + 1).ToString().PadLeft(vs[s], ' ')).Append(outputSeperator); + _ = stringBuilder.Append((s + 1).ToString().PadLeft(vs[s], ' ')).Append(outputSeparator); _ = stringBuilder.Remove(stringBuilder.Length - 1, 1); results.Add(stringBuilder.ToString()); for (int i = group[0]; i <= group[1]; i++) { line = lines[i]; _ = stringBuilder.Clear(); - segments = line.Split(inputSeperator); + segments = line.Split(inputSeparator); for (int s = 0; s < segments.Length; s++) - _ = stringBuilder.Append(segments[s].PadLeft(vs[s], ' ')).Append(outputSeperator); + _ = stringBuilder.Append(segments[s].PadLeft(vs[s], ' ')).Append(outputSeparator); _ = stringBuilder.Remove(stringBuilder.Length - 1, 1); results.Add(stringBuilder.ToString()); } diff --git a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.36.3/TENCOR1.cs b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.36.3/TENCOR1.cs index 48c200a..5fc150a 100644 --- a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.36.3/TENCOR1.cs +++ b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.36.3/TENCOR1.cs @@ -1,16 +1,12 @@ -using Adaptation.Shared; +using Adaptation._Tests.Shared; using Microsoft.Extensions.Logging; using Microsoft.VisualStudio.TestTools.UnitTesting; -using Shared; using System; -using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Reflection; -using System.Text.Json; -using System.Threading; -namespace _Tests.CreateSelfDescription.Staging.v2_36_3; +namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_36_3; [TestClass] public class TENCOR1 : EAFLoggingUnitTesting @@ -57,7 +53,7 @@ public class TENCOR1 : EAFLoggingUnitTesting string check = "*.pcl"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } diff --git a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/MET08DDUPSFS6420.cs b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/MET08DDUPSFS6420.cs index 3ed9294..372fb5d 100644 --- a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/MET08DDUPSFS6420.cs +++ b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/MET08DDUPSFS6420.cs @@ -1,16 +1,12 @@ -using Adaptation.Shared.Methods; +using Adaptation._Tests.Shared; using Microsoft.Extensions.Logging; using Microsoft.VisualStudio.TestTools.UnitTesting; -using Shared; using System; -using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Reflection; -using System.Text.Json; -using System.Threading; -namespace _Tests.CreateSelfDescription.Staging.v2_39_0; +namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_39_0; [TestClass] public class MET08DDUPSFS6420 : EAFLoggingUnitTesting @@ -57,7 +53,7 @@ public class MET08DDUPSFS6420 : EAFLoggingUnitTesting string check = "~IsXToOpenInsightMetrologyViewer"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } @@ -67,7 +63,7 @@ public class MET08DDUPSFS6420 : EAFLoggingUnitTesting string check = "~IsXToIQSSi"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } @@ -77,7 +73,7 @@ public class MET08DDUPSFS6420 : EAFLoggingUnitTesting string check = "~IsXToIQSGaN"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } @@ -87,7 +83,7 @@ public class MET08DDUPSFS6420 : EAFLoggingUnitTesting string check = "~IsXToOpenInsight"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } @@ -97,7 +93,7 @@ public class MET08DDUPSFS6420 : EAFLoggingUnitTesting string check = "~IsXToOpenInsightMetrologyViewerAttachments"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } @@ -107,7 +103,7 @@ public class MET08DDUPSFS6420 : EAFLoggingUnitTesting string check = "~IsXToAPC"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } @@ -117,7 +113,7 @@ public class MET08DDUPSFS6420 : EAFLoggingUnitTesting string check = "~IsXToSPaCe"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } @@ -127,7 +123,7 @@ public class MET08DDUPSFS6420 : EAFLoggingUnitTesting string check = "~IsXToArchive"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } @@ -137,7 +133,7 @@ public class MET08DDUPSFS6420 : EAFLoggingUnitTesting string check = "~IsArchive"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } @@ -147,7 +143,7 @@ public class MET08DDUPSFS6420 : EAFLoggingUnitTesting string check = "~IsDummy"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } @@ -157,7 +153,7 @@ public class MET08DDUPSFS6420 : EAFLoggingUnitTesting string check = "~IsManualOIEntry"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } diff --git a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR1.cs b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR1.cs index 722f779..13d9a41 100644 --- a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR1.cs +++ b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR1.cs @@ -1,16 +1,11 @@ -using Adaptation.Shared; +using Adaptation._Tests.Shared; using Microsoft.Extensions.Logging; using Microsoft.VisualStudio.TestTools.UnitTesting; -using Shared; using System; -using System.Collections.Generic; using System.Diagnostics; using System.IO; -using System.Reflection; -using System.Text.Json; -using System.Threading; -namespace _Tests.CreateSelfDescription.Staging.v2_39_0; +namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_39_0; [TestClass] public class TENCOR1 : EAFLoggingUnitTesting diff --git a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR2.cs b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR2.cs index 8044505..20a27d5 100644 --- a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR2.cs +++ b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR2.cs @@ -1,11 +1,11 @@ +using Adaptation._Tests.Shared; using Microsoft.Extensions.Logging; using Microsoft.VisualStudio.TestTools.UnitTesting; -using Shared; using System; using System.Diagnostics; using System.IO; -namespace _Tests.CreateSelfDescription.Staging.v2_39_0; +namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_39_0; [TestClass] public class TENCOR2 : EAFLoggingUnitTesting diff --git a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR3-EQPT.cs b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR3-EQPT.cs index cfec8a2..cd1f62d 100644 --- a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR3-EQPT.cs +++ b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR3-EQPT.cs @@ -1,13 +1,12 @@ -using Adaptation.Shared.Methods; +using Adaptation._Tests.Shared; using Microsoft.Extensions.Logging; using Microsoft.VisualStudio.TestTools.UnitTesting; -using Shared; using System; using System.Diagnostics; using System.IO; using System.Reflection; -namespace _Tests.CreateSelfDescription.Staging.v2_39_0; +namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_39_0; [TestClass] public class TENCOR3_EQPT : EAFLoggingUnitTesting @@ -54,7 +53,7 @@ public class TENCOR3_EQPT : EAFLoggingUnitTesting string check = "WafrMeas.log|.RsM"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } diff --git a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR3.cs b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR3.cs index 1faa822..c13f6ae 100644 --- a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR3.cs +++ b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.39.0/TENCOR3.cs @@ -1,13 +1,12 @@ -using Adaptation.Shared.Methods; +using Adaptation._Tests.Shared; using Microsoft.Extensions.Logging; using Microsoft.VisualStudio.TestTools.UnitTesting; -using Shared; using System; using System.Diagnostics; using System.IO; using System.Reflection; -namespace _Tests.CreateSelfDescription.Staging.v2_39_0; +namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_39_0; [TestClass] public class TENCOR3 : EAFLoggingUnitTesting @@ -54,7 +53,7 @@ public class TENCOR3 : EAFLoggingUnitTesting string check = "*.RsM"; MethodBase methodBase = new StackFrame().GetMethod(); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); - _ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); } diff --git a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/MET08DDUPSFS6420.cs b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/MET08DDUPSFS6420.cs new file mode 100644 index 0000000..ceef664 --- /dev/null +++ b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/MET08DDUPSFS6420.cs @@ -0,0 +1,150 @@ +using Adaptation._Tests.Shared; +using Microsoft.Extensions.Logging; +using Microsoft.VisualStudio.TestTools.UnitTesting; +using System; +using System.Diagnostics; +using System.IO; +using System.Reflection; + +namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0; + +[TestClass] +public class MET08DDUPSFS6420 : EAFLoggingUnitTesting +{ + +#pragma warning disable CA2254 +#pragma warning disable IDE0060 + + internal static MET08DDUPSFS6420 EAFLoggingUnitTesting { get; private set; } + + public MET08DDUPSFS6420() : base(testContext: null, declaringType: null, skipEquipmentDictionary: false) + { + if (EAFLoggingUnitTesting is null) + throw new Exception(); + } + + public MET08DDUPSFS6420(TestContext testContext) : base(testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) + { + } + + [ClassInitialize] + public static void ClassInitialize(TestContext testContext) + { + if (EAFLoggingUnitTesting is null) + EAFLoggingUnitTesting = new MET08DDUPSFS6420(testContext); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(testContext.TestName, " - ClassInitialize")); + string[] fileNameAndText = EAFLoggingUnitTesting.AdaptationTesting.GetCSharpText(testContext.TestName); + File.WriteAllText(fileNameAndText[0], fileNameAndText[1]); + File.WriteAllText(fileNameAndText[2], fileNameAndText[3]); + } + + [ClassCleanup()] + public static void ClassCleanup() + { + if (EAFLoggingUnitTesting.Logger is not null) + EAFLoggingUnitTesting.Logger.LogInformation("Cleanup"); + if (EAFLoggingUnitTesting is not null) + EAFLoggingUnitTesting.Dispose(); + } + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__MoveMatchingFiles() + { + string check = "*.pdsf"; + MethodBase methodBase = new StackFrame().GetMethod(); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); + } + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__OpenInsightMetrologyViewer() + { + string check = "*.pdsf"; + MethodBase methodBase = new StackFrame().GetMethod(); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); + } + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__IQSSi() + { + string check = "*.pdsf"; + MethodBase methodBase = new StackFrame().GetMethod(); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); + } + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__OpenInsight() + { + string check = "*.pdsf"; + MethodBase methodBase = new StackFrame().GetMethod(); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); + } + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__OpenInsightMetrologyViewerAttachments() + { + string check = "*.pdsf"; + MethodBase methodBase = new StackFrame().GetMethod(); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); + } + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__APC() + { + string check = "*.pdsf"; + MethodBase methodBase = new StackFrame().GetMethod(); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); + } + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__SPaCe() + { + string check = "*.pdsf"; + MethodBase methodBase = new StackFrame().GetMethod(); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); + } + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__Processed() + { + string check = "*.pdsf"; + MethodBase methodBase = new StackFrame().GetMethod(); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); + } + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__Archive() + { + string check = "*.pdsf"; + MethodBase methodBase = new StackFrame().GetMethod(); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); + } + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__Dummy() + { + string check = "637400762024374000.zip"; + MethodBase methodBase = new StackFrame().GetMethod(); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); + } + +} \ No newline at end of file diff --git a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/TENCOR1.cs b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/TENCOR1.cs new file mode 100644 index 0000000..ad6c983 --- /dev/null +++ b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/TENCOR1.cs @@ -0,0 +1,54 @@ +using Adaptation._Tests.Shared; +using Microsoft.Extensions.Logging; +using Microsoft.VisualStudio.TestTools.UnitTesting; +using System; +using System.Diagnostics; +using System.IO; + +namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0; + +[TestClass] +public class TENCOR1 : EAFLoggingUnitTesting +{ + +#pragma warning disable CA2254 +#pragma warning disable IDE0060 + + internal static TENCOR1 EAFLoggingUnitTesting { get; private set; } + + public TENCOR1() : base(testContext: null, declaringType: null, skipEquipmentDictionary: false) + { + if (EAFLoggingUnitTesting is null) + throw new Exception(); + } + + public TENCOR1(TestContext testContext) : base(testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) + { + } + + [ClassInitialize] + public static void ClassInitialize(TestContext testContext) + { + if (EAFLoggingUnitTesting is null) + EAFLoggingUnitTesting = new TENCOR1(testContext); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(testContext.TestName, " - ClassInitialize")); + string[] fileNameAndText = EAFLoggingUnitTesting.AdaptationTesting.GetCSharpText(testContext.TestName); + File.WriteAllText(fileNameAndText[0], fileNameAndText[1]); + File.WriteAllText(fileNameAndText[2], fileNameAndText[3]); + } + + [ClassCleanup()] + public static void ClassCleanup() + { + if (EAFLoggingUnitTesting.Logger is not null) + EAFLoggingUnitTesting.Logger.LogInformation("Cleanup"); + if (EAFLoggingUnitTesting is not null) + EAFLoggingUnitTesting.Dispose(); + } + + [TestMethod] + public void Staging__v2_43_0__TENCOR1__() + { + } + +} \ No newline at end of file diff --git a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/TENCOR2.cs b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/TENCOR2.cs new file mode 100644 index 0000000..c8acb30 --- /dev/null +++ b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/TENCOR2.cs @@ -0,0 +1,54 @@ +using Adaptation._Tests.Shared; +using Microsoft.Extensions.Logging; +using Microsoft.VisualStudio.TestTools.UnitTesting; +using System; +using System.Diagnostics; +using System.IO; + +namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0; + +[TestClass] +public class TENCOR2 : EAFLoggingUnitTesting +{ + +#pragma warning disable CA2254 +#pragma warning disable IDE0060 + + internal static TENCOR2 EAFLoggingUnitTesting { get; private set; } + + public TENCOR2() : base(testContext: null, declaringType: null, skipEquipmentDictionary: false) + { + if (EAFLoggingUnitTesting is null) + throw new Exception(); + } + + public TENCOR2(TestContext testContext) : base(testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) + { + } + + [ClassInitialize] + public static void ClassInitialize(TestContext testContext) + { + if (EAFLoggingUnitTesting is null) + EAFLoggingUnitTesting = new TENCOR2(testContext); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(testContext.TestName, " - ClassInitialize")); + string[] fileNameAndText = EAFLoggingUnitTesting.AdaptationTesting.GetCSharpText(testContext.TestName); + File.WriteAllText(fileNameAndText[0], fileNameAndText[1]); + File.WriteAllText(fileNameAndText[2], fileNameAndText[3]); + } + + [ClassCleanup()] + public static void ClassCleanup() + { + if (EAFLoggingUnitTesting.Logger is not null) + EAFLoggingUnitTesting.Logger.LogInformation("Cleanup"); + if (EAFLoggingUnitTesting is not null) + EAFLoggingUnitTesting.Dispose(); + } + + [TestMethod] + public void Staging__v2_43_0__TENCOR2__() + { + } + +} \ No newline at end of file diff --git a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/TENCOR3-EQPT.cs b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/TENCOR3-EQPT.cs new file mode 100644 index 0000000..6e3234c --- /dev/null +++ b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/TENCOR3-EQPT.cs @@ -0,0 +1,60 @@ +using Adaptation._Tests.Shared; +using Microsoft.Extensions.Logging; +using Microsoft.VisualStudio.TestTools.UnitTesting; +using System; +using System.Diagnostics; +using System.IO; +using System.Reflection; + +namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0; + +[TestClass] +public class TENCOR3_EQPT : EAFLoggingUnitTesting +{ + +#pragma warning disable CA2254 +#pragma warning disable IDE0060 + + internal static TENCOR3_EQPT EAFLoggingUnitTesting { get; private set; } + + public TENCOR3_EQPT() : base(testContext: null, declaringType: null, skipEquipmentDictionary: false) + { + if (EAFLoggingUnitTesting is null) + throw new Exception(); + } + + public TENCOR3_EQPT(TestContext testContext) : base(testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) + { + } + + [ClassInitialize] + public static void ClassInitialize(TestContext testContext) + { + if (EAFLoggingUnitTesting is null) + EAFLoggingUnitTesting = new TENCOR3_EQPT(testContext); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(testContext.TestName, " - ClassInitialize")); + string[] fileNameAndText = EAFLoggingUnitTesting.AdaptationTesting.GetCSharpText(testContext.TestName); + File.WriteAllText(fileNameAndText[0], fileNameAndText[1]); + File.WriteAllText(fileNameAndText[2], fileNameAndText[3]); + } + + [ClassCleanup()] + public static void ClassCleanup() + { + if (EAFLoggingUnitTesting.Logger is not null) + EAFLoggingUnitTesting.Logger.LogInformation("Cleanup"); + if (EAFLoggingUnitTesting is not null) + EAFLoggingUnitTesting.Dispose(); + } + + [TestMethod] + public void Staging__v2_43_0__TENCOR3_EQPT__DownloadRsMFile() + { + string check = "WafrMeas.log|.RsM"; + MethodBase methodBase = new StackFrame().GetMethod(); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); + } + +} \ No newline at end of file diff --git a/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/TENCOR3.cs b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/TENCOR3.cs new file mode 100644 index 0000000..16373e2 --- /dev/null +++ b/Adaptation/_Tests/CreateSelfDescription/Staging/v2.43.0/TENCOR3.cs @@ -0,0 +1,60 @@ +using Adaptation._Tests.Shared; +using Microsoft.Extensions.Logging; +using Microsoft.VisualStudio.TestTools.UnitTesting; +using System; +using System.Diagnostics; +using System.IO; +using System.Reflection; + +namespace Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0; + +[TestClass] +public class TENCOR3 : EAFLoggingUnitTesting +{ + +#pragma warning disable CA2254 +#pragma warning disable IDE0060 + + internal static TENCOR3 EAFLoggingUnitTesting { get; private set; } + + public TENCOR3() : base(testContext: null, declaringType: null, skipEquipmentDictionary: false) + { + if (EAFLoggingUnitTesting is null) + throw new Exception(); + } + + public TENCOR3(TestContext testContext) : base(testContext, new StackFrame().GetMethod().DeclaringType, skipEquipmentDictionary: false) + { + } + + [ClassInitialize] + public static void ClassInitialize(TestContext testContext) + { + if (EAFLoggingUnitTesting is null) + EAFLoggingUnitTesting = new TENCOR3(testContext); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(testContext.TestName, " - ClassInitialize")); + string[] fileNameAndText = EAFLoggingUnitTesting.AdaptationTesting.GetCSharpText(testContext.TestName); + File.WriteAllText(fileNameAndText[0], fileNameAndText[1]); + File.WriteAllText(fileNameAndText[2], fileNameAndText[3]); + } + + [ClassCleanup()] + public static void ClassCleanup() + { + if (EAFLoggingUnitTesting.Logger is not null) + EAFLoggingUnitTesting.Logger.LogInformation("Cleanup"); + if (EAFLoggingUnitTesting is not null) + EAFLoggingUnitTesting.Dispose(); + } + + [TestMethod] + public void Staging__v2_43_0__TENCOR3__RsM() + { + string check = "*.RsM"; + MethodBase methodBase = new StackFrame().GetMethod(); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Getting configuration")); + _ = AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting); + EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, " - Exit")); + } + +} \ No newline at end of file diff --git a/Adaptation/_Tests/Extract/Staging/v2.36.3/TENCOR1.cs b/Adaptation/_Tests/Extract/Staging/v2.36.3/TENCOR1.cs index ebed221..60065c8 100644 --- a/Adaptation/_Tests/Extract/Staging/v2.36.3/TENCOR1.cs +++ b/Adaptation/_Tests/Extract/Staging/v2.36.3/TENCOR1.cs @@ -1,14 +1,10 @@ using Adaptation.Shared; using Adaptation.Shared.Methods; using Microsoft.VisualStudio.TestTools.UnitTesting; -using System; -using System.Collections.Generic; using System.Diagnostics; -using System.IO; using System.Reflection; -using System.Text.Json; -namespace _Tests.Extract.Staging.v2_36_3; +namespace Adaptation._Tests.Extract.Staging.v2_36_3; [TestClass] public class TENCOR1 @@ -38,7 +34,7 @@ public class TENCOR1 string[] variables = _TENCOR1.AdaptationTesting.GetVariables(methodBase, check); IFileRead fileRead = _TENCOR1.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); Logistics logistics = new(fileRead); - _ = Helpers.Metrology.ReExtractComapareUpdatePassDirectory(variables, fileRead, logistics); + _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics); } } \ No newline at end of file diff --git a/Adaptation/_Tests/Extract/Staging/v2.39.0/MET08DDUPSFS6420.cs b/Adaptation/_Tests/Extract/Staging/v2.39.0/MET08DDUPSFS6420.cs index e2943f7..05f8d5d 100644 --- a/Adaptation/_Tests/Extract/Staging/v2.39.0/MET08DDUPSFS6420.cs +++ b/Adaptation/_Tests/Extract/Staging/v2.39.0/MET08DDUPSFS6420.cs @@ -1,14 +1,10 @@ using Adaptation.Shared; using Adaptation.Shared.Methods; using Microsoft.VisualStudio.TestTools.UnitTesting; -using System; -using System.Collections.Generic; using System.Diagnostics; -using System.IO; using System.Reflection; -using System.Text.Json; -namespace _Tests.Extract.Staging.v2_39_0; +namespace Adaptation._Tests.Extract.Staging.v2_39_0; [TestClass] public class MET08DDUPSFS6420 @@ -38,7 +34,7 @@ public class MET08DDUPSFS6420 string[] variables = _MET08DDUPSFS6420.AdaptationTesting.GetVariables(methodBase, check); IFileRead fileRead = _MET08DDUPSFS6420.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false); Logistics logistics = new(fileRead); - _ = Helpers.Metrology.ReExtractComapareUpdatePassDirectory(variables, fileRead, logistics); + _ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics); } [TestMethod] diff --git a/Adaptation/_Tests/Extract/Staging/v2.39.0/TENCOR3-EQPT.cs b/Adaptation/_Tests/Extract/Staging/v2.39.0/TENCOR3-EQPT.cs index 2548e58..c1e9180 100644 --- a/Adaptation/_Tests/Extract/Staging/v2.39.0/TENCOR3-EQPT.cs +++ b/Adaptation/_Tests/Extract/Staging/v2.39.0/TENCOR3-EQPT.cs @@ -1,14 +1,6 @@ -using Adaptation.Shared; -using Adaptation.Shared.Methods; using Microsoft.VisualStudio.TestTools.UnitTesting; -using System; -using System.Collections.Generic; -using System.Diagnostics; -using System.IO; -using System.Reflection; -using System.Text.Json; -namespace _Tests.Extract.Staging.v2_39_0; +namespace Adaptation._Tests.Extract.Staging.v2_39_0; [TestClass] public class TENCOR3_EQPT diff --git a/Adaptation/_Tests/Extract/Staging/v2.39.0/TENCOR3.cs b/Adaptation/_Tests/Extract/Staging/v2.39.0/TENCOR3.cs index c800e27..f0b2375 100644 --- a/Adaptation/_Tests/Extract/Staging/v2.39.0/TENCOR3.cs +++ b/Adaptation/_Tests/Extract/Staging/v2.39.0/TENCOR3.cs @@ -1,14 +1,6 @@ -using Adaptation.Shared; -using Adaptation.Shared.Methods; using Microsoft.VisualStudio.TestTools.UnitTesting; -using System; -using System.Collections.Generic; -using System.Diagnostics; -using System.IO; -using System.Reflection; -using System.Text.Json; -namespace _Tests.Extract.Staging.v2_39_0; +namespace Adaptation._Tests.Extract.Staging.v2_39_0; [TestClass] public class TENCOR3 diff --git a/Adaptation/_Tests/Extract/Staging/v2.43.0/MET08DDUPSFS6420.cs b/Adaptation/_Tests/Extract/Staging/v2.43.0/MET08DDUPSFS6420.cs new file mode 100644 index 0000000..95c75d9 --- /dev/null +++ b/Adaptation/_Tests/Extract/Staging/v2.43.0/MET08DDUPSFS6420.cs @@ -0,0 +1,51 @@ +using Microsoft.VisualStudio.TestTools.UnitTesting; + +namespace Adaptation._Tests.Extract.Staging.v2_43_0; + +[TestClass] +public class MET08DDUPSFS6420 +{ + +#pragma warning disable CA2254 +#pragma warning disable IDE0060 + + private static CreateSelfDescription.Staging.v2_43_0.MET08DDUPSFS6420 _MET08DDUPSFS6420; + + [ClassInitialize] + public static void ClassInitialize(TestContext testContext) + { + CreateSelfDescription.Staging.v2_43_0.MET08DDUPSFS6420.ClassInitialize(testContext); + _MET08DDUPSFS6420 = CreateSelfDescription.Staging.v2_43_0.MET08DDUPSFS6420.EAFLoggingUnitTesting; + } + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__MoveMatchingFiles() => _MET08DDUPSFS6420.Staging__v2_43_0__MET08DDUPSFS6420__MoveMatchingFiles(); + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__OpenInsightMetrologyViewer() => _MET08DDUPSFS6420.Staging__v2_43_0__MET08DDUPSFS6420__OpenInsightMetrologyViewer(); + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__IQSSi() => _MET08DDUPSFS6420.Staging__v2_43_0__MET08DDUPSFS6420__IQSSi(); + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__OpenInsight() => _MET08DDUPSFS6420.Staging__v2_43_0__MET08DDUPSFS6420__OpenInsight(); + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__OpenInsightMetrologyViewerAttachments() => _MET08DDUPSFS6420.Staging__v2_43_0__MET08DDUPSFS6420__OpenInsightMetrologyViewerAttachments(); + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__APC() => _MET08DDUPSFS6420.Staging__v2_43_0__MET08DDUPSFS6420__APC(); + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__SPaCe() => _MET08DDUPSFS6420.Staging__v2_43_0__MET08DDUPSFS6420__SPaCe(); + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__Processed() => _MET08DDUPSFS6420.Staging__v2_43_0__MET08DDUPSFS6420__Processed(); + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__Archive() => _MET08DDUPSFS6420.Staging__v2_43_0__MET08DDUPSFS6420__Archive(); + + [TestMethod] + public void Staging__v2_43_0__MET08DDUPSFS6420__Dummy() => _MET08DDUPSFS6420.Staging__v2_43_0__MET08DDUPSFS6420__Dummy(); + +} \ No newline at end of file diff --git a/Adaptation/_Tests/Extract/Staging/v2.43.0/TENCOR1.cs b/Adaptation/_Tests/Extract/Staging/v2.43.0/TENCOR1.cs new file mode 100644 index 0000000..e69de29 diff --git a/Adaptation/_Tests/Extract/Staging/v2.43.0/TENCOR2.cs b/Adaptation/_Tests/Extract/Staging/v2.43.0/TENCOR2.cs new file mode 100644 index 0000000..e69de29 diff --git a/Adaptation/_Tests/Extract/Staging/v2.43.0/TENCOR3-EQPT.cs b/Adaptation/_Tests/Extract/Staging/v2.43.0/TENCOR3-EQPT.cs new file mode 100644 index 0000000..17fa8c1 --- /dev/null +++ b/Adaptation/_Tests/Extract/Staging/v2.43.0/TENCOR3-EQPT.cs @@ -0,0 +1,24 @@ +using Microsoft.VisualStudio.TestTools.UnitTesting; + +namespace Adaptation._Tests.Extract.Staging.v2_43_0; + +[TestClass] +public class TENCOR3_EQPT +{ + +#pragma warning disable CA2254 +#pragma warning disable IDE0060 + + private static CreateSelfDescription.Staging.v2_43_0.TENCOR3_EQPT _TENCOR3_EQPT; + + [ClassInitialize] + public static void ClassInitialize(TestContext testContext) + { + CreateSelfDescription.Staging.v2_43_0.TENCOR3_EQPT.ClassInitialize(testContext); + _TENCOR3_EQPT = CreateSelfDescription.Staging.v2_43_0.TENCOR3_EQPT.EAFLoggingUnitTesting; + } + + [TestMethod] + public void Staging__v2_43_0__TENCOR3_EQPT__DownloadRsMFile() => _TENCOR3_EQPT.Staging__v2_43_0__TENCOR3_EQPT__DownloadRsMFile(); + +} \ No newline at end of file diff --git a/Adaptation/_Tests/Extract/Staging/v2.43.0/TENCOR3.cs b/Adaptation/_Tests/Extract/Staging/v2.43.0/TENCOR3.cs new file mode 100644 index 0000000..9bea224 --- /dev/null +++ b/Adaptation/_Tests/Extract/Staging/v2.43.0/TENCOR3.cs @@ -0,0 +1,24 @@ +using Microsoft.VisualStudio.TestTools.UnitTesting; + +namespace Adaptation._Tests.Extract.Staging.v2_43_0; + +[TestClass] +public class TENCOR3 +{ + +#pragma warning disable CA2254 +#pragma warning disable IDE0060 + + private static CreateSelfDescription.Staging.v2_43_0.TENCOR3 _TENCOR3; + + [ClassInitialize] + public static void ClassInitialize(TestContext testContext) + { + CreateSelfDescription.Staging.v2_43_0.TENCOR3.ClassInitialize(testContext); + _TENCOR3 = CreateSelfDescription.Staging.v2_43_0.TENCOR3.EAFLoggingUnitTesting; + } + + [TestMethod] + public void Staging__v2_43_0__TENCOR3__RsM() => _TENCOR3.Staging__v2_43_0__TENCOR3__RsM(); + +} \ No newline at end of file diff --git a/Adaptation/_Tests/Helpers/Metrology.cs b/Adaptation/_Tests/Helpers/Metrology.cs deleted file mode 100644 index d397324..0000000 --- a/Adaptation/_Tests/Helpers/Metrology.cs +++ /dev/null @@ -1,189 +0,0 @@ -using Adaptation.Shared; -using Adaptation.Shared.Methods; -using Microsoft.VisualStudio.TestTools.UnitTesting; -using System; -using System.Collections.Generic; -using System.Diagnostics; -using System.IO; -using System.Linq; -using System.Reflection; -using System.Text.Json; - -namespace _Tests.Helpers; - -public class Metrology -{ - - internal static Tuple GetLogisticsColumnsAndBody(string fileFullName) - { - Tuple results; - results = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(fileFullName); - Assert.IsFalse(string.IsNullOrEmpty(results.Item1)); - Assert.IsTrue(results.Item2.Length > 0, "Column check"); - Assert.IsTrue(results.Item3.Length > 0, "Body check"); - return results; - } - - internal static Tuple GetLogisticsColumnsAndBody(string searchDirectory, string searchPattern) - { - Tuple results; - if (searchPattern.Length > 3 && !searchPattern.Contains('*') && File.Exists(searchPattern)) - results = GetLogisticsColumnsAndBody(searchPattern); - else - { - string[] pdsfFiles; - pdsfFiles = Directory.GetFiles(searchDirectory, searchPattern, SearchOption.TopDirectoryOnly); - if (!pdsfFiles.Any()) - _ = Process.Start("explorer.exe", searchDirectory); - Assert.IsTrue(pdsfFiles.Any(), "GetFiles check"); - results = GetLogisticsColumnsAndBody(pdsfFiles[0]); - } - Assert.IsFalse(string.IsNullOrEmpty(results.Item1)); - Assert.IsTrue(results.Item2.Length > 0, "Column check"); - Assert.IsTrue(results.Item3.Length > 0, "Body check"); - return results; - } - - internal static Tuple GetLogisticsColumnsAndBody(IFileRead fileRead, Logistics logistics, Tuple> extractResult, Tuple pdsf) - { - Tuple results; - string text = ProcessDataStandardFormat.GetPDSFText(fileRead, logistics, extractResult.Item3, logisticsText: pdsf.Item1); - string[] lines = text.Split(new string[] { Environment.NewLine }, StringSplitOptions.RemoveEmptyEntries); - results = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(logistics.ReportFullPath, lines); - Assert.IsFalse(string.IsNullOrEmpty(results.Item1)); - Assert.IsTrue(results.Item2.Length > 0, "Column check"); - Assert.IsTrue(results.Item3.Length > 0, "Body check"); - return results; - } - - internal static string[] GetItem2(Tuple pdsf, Tuple pdsfNew) - { - JsonSerializerOptions jsonSerializerOptions = new() { WriteIndented = true }; - string jsonOld = JsonSerializer.Serialize(pdsf.Item2, pdsf.Item2.GetType(), jsonSerializerOptions); - string jsonNew = JsonSerializer.Serialize(pdsfNew.Item2, pdsfNew.Item2.GetType(), jsonSerializerOptions); - return new string[] { jsonOld, jsonNew }; - } - - internal static string[] GetItem3(Tuple pdsf, Tuple pdsfNew) - { - string joinOld = string.Join(Environment.NewLine, from l in pdsf.Item3 select string.Join('\t', from t in l.Split('\t') where !t.Contains(@"\\") select t)); - string joinNew = string.Join(Environment.NewLine, from l in pdsfNew.Item3 select string.Join('\t', from t in l.Split('\t') where !t.Contains(@"\\") select t)); - return new string[] { joinOld, joinNew }; - } - - internal static void UpdatePassDirectory(string searchDirectory) - { - DateTime dateTime = DateTime.Now; - try - { Directory.SetLastWriteTime(searchDirectory, dateTime); } - catch (System.Exception) { } - string ticksDirectory = Path.GetDirectoryName(searchDirectory); - try - { Directory.SetLastWriteTime(ticksDirectory, dateTime); } - catch (System.Exception) { } - string[] directories = Directory.GetDirectories(searchDirectory, "*", SearchOption.TopDirectoryOnly); - foreach (string directory in directories) - { - try - { Directory.SetLastWriteTime(directory, dateTime); } - catch (System.Exception) { } - } - } - - internal static string GetFileName(MethodBase methodBase) - { - string result; - string connectionName; - string seperator = "__"; - string connectionNameAndTicks; - string[] segments = methodBase.Name.Split(new string[] { seperator }, StringSplitOptions.None); - string environment = segments[0]; - string rawVersionName = segments[1]; - string equipmentTypeDirectory = segments[2]; - string ticks = DateTime.Now.Ticks.ToString(); - string comment = segments[segments.Length - 1]; - string versionName = segments[1].Replace('_', '.'); - string before = string.Concat(environment, seperator, rawVersionName, seperator, equipmentTypeDirectory, seperator); - string after = methodBase.Name.Substring(before.Length); - if (after.Length < ticks.Length) - { - connectionName = after; - } - else - { - connectionNameAndTicks = after.Substring(0, after.Length - 2 - comment.Length); - connectionName = connectionNameAndTicks.Substring(0, connectionNameAndTicks.Length - ticks.Length); - ticks = connectionNameAndTicks.Substring(connectionName.Length); - } - result = Path.Combine(environment, equipmentTypeDirectory, versionName, $"{environment}__{rawVersionName}__{equipmentTypeDirectory}__{connectionName}", ticks, $"{connectionName.Replace('_', '-')}.json"); - if (result.Contains('/')) - result = string.Concat('/', result); - else - result = string.Concat('\\', result); - return result; - } - - internal static void CompareSaveTSV(string textFileDirectory, string[] join) - { - if (join[0] != join[1]) - { - _ = Process.Start("explorer.exe", textFileDirectory); - File.WriteAllText(Path.Combine(textFileDirectory, "0.tsv"), join[0]); - File.WriteAllText(Path.Combine(textFileDirectory, "1.tsv"), join[1]); - } - } - - internal static void CompareSaveJSON(string textFileDirectory, string[] json) - { - if (json[0] != json[1]) - { - _ = Process.Start("explorer.exe", textFileDirectory); - File.WriteAllText(Path.Combine(textFileDirectory, "0.json"), json[0]); - File.WriteAllText(Path.Combine(textFileDirectory, "1.json"), json[1]); - } - } - - internal static void CompareSave(string textFileDirectory, Tuple pdsf, Tuple pdsfNew) - { - if (pdsf.Item1 != pdsfNew.Item1) - { - _ = Process.Start("explorer.exe", textFileDirectory); - File.WriteAllText(Path.Combine(textFileDirectory, "0.dat"), pdsf.Item1); - File.WriteAllText(Path.Combine(textFileDirectory, "1.dat"), pdsfNew.Item1); - } - } - - internal static IFileRead GetWriteConfigurationGetFileRead(MethodBase methodBase, string check, Shared.AdaptationTesting adaptationTesting) - { - IFileRead result; - string[] fileNameAndJson = adaptationTesting.GetConfiguration(methodBase); - Assert.IsTrue(fileNameAndJson[1].Contains(check)); - File.WriteAllText(fileNameAndJson[0], fileNameAndJson[1]); - result = adaptationTesting.Get(methodBase, sourceFileLocation: string.Empty, sourceFileFilter: string.Empty, useCyclicalForDescription: false); - Assert.IsFalse(string.IsNullOrEmpty(result.CellInstanceConnectionName)); - return result; - } - - internal static string ReExtractComapareUpdatePassDirectory(string[] variables, IFileRead fileRead, Logistics logistics) - { - string result; - Tuple> extractResult = fileRead.ReExtract(); - Assert.IsFalse(string.IsNullOrEmpty(extractResult?.Item1)); - Assert.IsTrue(extractResult.Item3.Length > 0, "extractResult Array Length check!"); - Assert.IsNotNull(extractResult.Item4); - Tuple pdsf = GetLogisticsColumnsAndBody(variables[2], variables[4]); - Tuple pdsfNew = GetLogisticsColumnsAndBody(fileRead, logistics, extractResult, pdsf); - CompareSave(variables[5], pdsf, pdsfNew); - Assert.IsTrue(pdsf.Item1 == pdsfNew.Item1, "Item1 check!"); - string[] json = GetItem2(pdsf, pdsfNew); - CompareSaveJSON(variables[5], json); - Assert.IsTrue(json[0] == json[1], "Item2 check!"); - string[] join = GetItem3(pdsf, pdsfNew); - CompareSaveTSV(variables[5], join); - Assert.IsTrue(join[0] == join[1], "Item3 (Join) check!"); - UpdatePassDirectory(variables[2]); - result = extractResult.Item1; - return result; - } - -} \ No newline at end of file diff --git a/Adaptation/_Tests/Shared/AdaptationTesting.cs b/Adaptation/_Tests/Shared/AdaptationTesting.cs index ec06ba5..baa2c9d 100644 --- a/Adaptation/_Tests/Shared/AdaptationTesting.cs +++ b/Adaptation/_Tests/Shared/AdaptationTesting.cs @@ -1,12 +1,13 @@ +using Adaptation._Tests.Shared.PasteSpecialXml.EAF.XML.API.CellInstance; +using Adaptation._Tests.Shared.PasteSpecialXml.EAF.XML.API.ConfigurationData; +using Adaptation._Tests.Shared.PasteSpecialXml.EAF.XML.API.EquipmentDictionary; +using Adaptation._Tests.Shared.PasteSpecialXml.EAF.XML.API.EquipmentType; using Adaptation.Eaf.Management.ConfigurationData.CellAutomation; using Adaptation.Ifx.Eaf.Common.Configuration; using Adaptation.Ifx.Eaf.EquipmentConnector.File.Configuration; +using Adaptation.Shared; using Adaptation.Shared.Methods; using Microsoft.VisualStudio.TestTools.UnitTesting; -using Shared.PasteSpecialXml.EAF.XML.API.CellInstance; -using Shared.PasteSpecialXml.EAF.XML.API.ConfigurationData; -using Shared.PasteSpecialXml.EAF.XML.API.EquipmentDictionary; -using Shared.PasteSpecialXml.EAF.XML.API.EquipmentType; using System; using System.Collections.Generic; using System.Diagnostics; @@ -20,7 +21,7 @@ using System.Xml; using System.Xml.Linq; using System.Xml.Serialization; -namespace Shared; +namespace Adaptation._Tests.Shared; public class AdaptationTesting : ISMTP { @@ -175,20 +176,20 @@ public class AdaptationTesting : ISMTP string fileFullName; string comment; string[] textFiles; - string seperator = "__"; + string separator = "__"; string connectionNameAndTicks; string cellInstanceConnectionName; string ticks = DateTime.Now.Ticks.ToString(); string cellInstanceConnectionNameFromMethodBaseName; string testResultsDirectory = GetTestResultsDirectory(); - string[] segments = methodBaseName.Split(new string[] { seperator }, StringSplitOptions.None); + string[] segments = methodBaseName.Split(new string[] { separator }, StringSplitOptions.None); if (segments[0] != _Environment) throw new Exception(); string rawVersionName = segments[1]; string rawCellInstanceName = segments[2]; string cellInstanceVersionName = segments[1].Replace('_', '.'); string cellInstanceName = segments[2].Replace('_', '-').Replace("_EQPT", "-EQPT"); - string before = string.Concat(_Environment, seperator, rawVersionName, seperator, cellInstanceName, seperator); + string before = string.Concat(_Environment, separator, rawVersionName, separator, cellInstanceName, separator); string after = methodBaseName.Substring(before.Length); string versionDirectory = Path.Combine(testResultsDirectory, _Environment, cellInstanceName, cellInstanceVersionName); if (!Directory.Exists(versionDirectory)) @@ -341,7 +342,7 @@ public class AdaptationTesting : ISMTP { xml = XDocument.Load(url).ToString(); } - catch (System.Exception exception) + catch (Exception exception) { throw new Exception(string.Concat(url, System.Environment.NewLine, exception.Message)); } @@ -436,7 +437,7 @@ public class AdaptationTesting : ISMTP AppendLine("using Adaptation.Shared.Methods;"). AppendLine("using Microsoft.Extensions.Logging;"). AppendLine("using Microsoft.VisualStudio.TestTools.UnitTesting;"). - AppendLine("using Shared;"). + AppendLine("using Adaptation._Tests.Shared;"). AppendLine("using System;"). AppendLine("using System.Collections.Generic;"). AppendLine("using System.Diagnostics;"). @@ -445,7 +446,7 @@ public class AdaptationTesting : ISMTP AppendLine("using System.Text.Json;"). AppendLine("using System.Threading;"); _ = stringBuilder.AppendLine(). - Append("namespace _Tests.").Append(loopName).Append('.').Append(_Environment).Append('.').Append(cellInstanceVersionNameAsCode).AppendLine(";"). + Append("namespace Adaptation._Tests.").Append(loopName).Append('.').Append(_Environment).Append('.').Append(cellInstanceVersionNameAsCode).AppendLine(";"). AppendLine(). AppendLine("[TestClass]"); if (i == 2) @@ -541,7 +542,7 @@ public class AdaptationTesting : ISMTP { _ = stringBuilder. AppendLine("[TestMethod]"). - Append("public void ").Append(methodName).Append("() => ").Append('_').Append(cellInstanceNameWithoutHyphen).Append('.').Append(methodName).AppendLine("();"); + Append("public void ").Append(methodName).Append("() => ").Append('_').Append(cellInstanceNameWithoutHyphen).Append('.').Append(methodName).AppendLine("();").AppendLine(); } else if (i == 1) { @@ -555,7 +556,7 @@ public class AdaptationTesting : ISMTP Append("string check = \"").Append(check.Split('\\').Last()).AppendLine("\";"). AppendLine("MethodBase methodBase = new StackFrame().GetMethod();"). AppendLine("EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, \" - Getting configuration\"));"). - AppendLine("_ = Helpers.Metrology.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);"). + AppendLine("_ = Shared.AdaptationTesting.GetWriteConfigurationGetFileRead(methodBase, check, EAFLoggingUnitTesting.AdaptationTesting);"). AppendLine("EAFLoggingUnitTesting.Logger.LogInformation(string.Concat(methodBase.Name, \" - Exit\"));"). AppendLine("}"). AppendLine(); @@ -614,7 +615,7 @@ public class AdaptationTesting : ISMTP foreach (Setting setting in componentsCellComponentCellComponent.Equipment.ConnectionSettings.Setting) result.ConnectionSettings.Add(new ConnectionSetting(null, null) { Name = setting.Name, Value = setting.Value }); } - IEnumerable sourceDirectoryCloakingCollection = (from l in result.ConnectionSettings where l.Name == sourceDirectoryCloaking select l); + IEnumerable sourceDirectoryCloakingCollection = from l in result.ConnectionSettings where l.Name == sourceDirectoryCloaking select l; if (sourceDirectoryCloakingCollection.Any()) result.SourceDirectoryCloaking = sourceDirectoryCloakingCollection.First().Value; else @@ -656,7 +657,7 @@ public class AdaptationTesting : ISMTP { xml = XDocument.Load(url).ToString(); } - catch (System.Exception exception) + catch (Exception exception) { throw new Exception(string.Concat(url, System.Environment.NewLine, exception.Message)); } @@ -777,7 +778,7 @@ public class AdaptationTesting : ISMTP { xml = XDocument.Load(url).ToString(); } - catch (System.Exception exception) + catch (Exception exception) { throw new Exception(string.Concat(url, System.Environment.NewLine, exception.Message)); } @@ -860,7 +861,7 @@ public class AdaptationTesting : ISMTP { Dictionary results = new() { - { nameof(Environment), _Environment }, + { nameof(System.Environment), _Environment }, { nameof(HostNameAndPort), _HostNameAndPort }, { nameof(cellInstanceName), cellInstanceName }, { nameof(equipmentTypeName), equipmentTypeName }, @@ -894,6 +895,7 @@ public class AdaptationTesting : ISMTP { string[] results; string[] segments = GetSegments(methodBase.Name); + string ticks = GetTicks(segments); FileInfo fileInfo = GetFileName(segments); string cellInstanceName = GetCellInstanceName(segments); string cellInstanceVersionName = GetCellInstanceVersionName(segments); @@ -902,6 +904,16 @@ public class AdaptationTesting : ISMTP _ = Directory.CreateDirectory(fileInfo.Directory.FullName); Tuple cellInstanceVersionTuple = GetCellInstanceVersionTuple(cellInstanceName, cellInstanceVersionName); Tuple fileConnectorConfigurationTuple = GetFileConnectorConfigurationTuple(cellInstanceVersionTuple, cellInstanceConnectionName); + if (string.IsNullOrEmpty(ticks) && fileConnectorConfigurationTuple.Item2?.FileScanningIntervalInSeconds is not null) + { + string fileScanningIntervalInSecondsLine; + string versionDirectory = Path.GetDirectoryName(fileInfo.DirectoryName); + if (fileConnectorConfigurationTuple.Item2.FileScanningIntervalInSeconds.Value < 0) + fileScanningIntervalInSecondsLine = $"-\t{fileConnectorConfigurationTuple.Item2.FileScanningIntervalInSeconds.Value:0000}\t{Path.GetFileName(fileInfo.DirectoryName)}"; + else + fileScanningIntervalInSecondsLine = $"+\t{fileConnectorConfigurationTuple.Item2.FileScanningIntervalInSeconds.Value:+0000}\t{Path.GetFileName(fileInfo.DirectoryName)}"; + File.AppendAllLines(Path.Combine(versionDirectory, "FileScanningIntervalInSeconds.txt"), new string[] { fileScanningIntervalInSecondsLine }); + } Tuple equipmentTypeVersionTuple = GetEquipmentTypeVersionTuple(cellInstanceVersionTuple.Item2, cellInstanceConnectionName); Tuple parameterizedModelObjectDefinitionTypeTuple = GetParameterizedModelObjectDefinitionTypeTuple(equipmentTypeVersionTuple); Tuple> modelObjectParametersTuple = GetModelObjectParameters(equipmentTypeVersionTuple); @@ -925,13 +937,13 @@ public class AdaptationTesting : ISMTP if (!string.IsNullOrEmpty(cellInstanceConnectionName) && !Directory.Exists(fileInfo.DirectoryName)) _ = Directory.CreateDirectory(fileInfo.Directory.FullName); Dictionary> dummyRuns = new(); + Dictionary> staticRuns = new(); Tuple cellInstanceVersionTuple = GetCellInstanceVersionTuple(cellInstanceName, cellInstanceVersionName); Tuple fileConnectorConfigurationTuple = GetFileConnectorConfigurationTuple(cellInstanceVersionTuple, cellInstanceConnectionName); Tuple equipmentTypeVersionTuple = GetEquipmentTypeVersionTuple(cellInstanceVersionTuple.Item2, cellInstanceConnectionName); Tuple parameterizedModelObjectDefinitionTypeTuple = GetParameterizedModelObjectDefinitionTypeTuple(equipmentTypeVersionTuple); Tuple> modelObjectParametersTuple = GetModelObjectParameters(equipmentTypeVersionTuple); Tuple equipmentDictionaryVersionTuple = GetEquipmentDictionaryVersionTuple(cellInstanceVersionTuple.Item2, cellInstanceConnectionName, equipmentTypeVersionTuple.Item4); - _ = GetEquipmentDictionaryIsAlwaysEnabledEventsTuple(equipmentDictionaryVersionTuple); if (!string.IsNullOrEmpty(sourceFileLocation) && sourceFileLocation != fileConnectorConfigurationTuple.Item2.SourceFileLocation) fileConnectorConfigurationTuple.Item2.SourceFileLocation = sourceFileLocation; @@ -940,7 +952,16 @@ public class AdaptationTesting : ISMTP fileConnectorConfigurationTuple.Item2.SourceFileFilter = sourceFileFilter; fileConnectorConfigurationTuple.Item2.SourceFileFilters = sourceFileFilter.Split('|').ToList(); } - result = Adaptation.FileHandlers.CellInstanceConnectionName.Get(this, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfigurationTuple.Item2, equipmentTypeVersionTuple.Item2, parameterizedModelObjectDefinitionTypeTuple.Item2, modelObjectParametersTuple.Item2, equipmentDictionaryVersionTuple.Item2, dummyRuns, useCyclicalForDescription, isEAFHosted: false); + if (_TestContext.FullyQualifiedTestClassName.Contains(nameof(Extract))) + { + if (!Directory.Exists(fileConnectorConfigurationTuple.Item2.ErrorTargetFileLocation)) + _ = Directory.CreateDirectory(fileConnectorConfigurationTuple.Item2.ErrorTargetFileLocation); + if (!Directory.Exists(fileConnectorConfigurationTuple.Item2.SourceFileLocation)) + _ = Directory.CreateDirectory(fileConnectorConfigurationTuple.Item2.SourceFileLocation); + if (!Directory.Exists(fileConnectorConfigurationTuple.Item2.TargetFileLocation)) + _ = Directory.CreateDirectory(fileConnectorConfigurationTuple.Item2.TargetFileLocation); + } + result = FileHandlers.CellInstanceConnectionName.Get(this, fileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfigurationTuple.Item2, equipmentTypeVersionTuple.Item2, parameterizedModelObjectDefinitionTypeTuple.Item2, modelObjectParametersTuple.Item2, equipmentDictionaryVersionTuple.Item2, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: false); return result; } @@ -982,6 +1003,8 @@ public class AdaptationTesting : ISMTP throw new Exception("Ticks should only appear once in source file location!"); if (segments.Length != 2) throw new Exception("Ticks missing from source file location!"); + if (segments[1].Contains(ticks)) + throw new Exception("From source file location path should not contain ticks!"); if (!segments[1].EndsWith(methodBaseNameWithActualCICN.Replace(ticks, string.Empty))) throw new Exception("Method name missing from source file location!"); sourceFileLocation = lines[0]; @@ -1041,6 +1064,183 @@ public class AdaptationTesting : ISMTP return results; } + internal static Tuple GetLogisticsColumnsAndBody(string fileFullName) + { + Tuple results; + results = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(fileFullName); + Assert.IsFalse(string.IsNullOrEmpty(results.Item1)); + Assert.IsTrue(results.Item2.Length > 0, "Column check"); + Assert.IsTrue(results.Item3.Length > 0, "Body check"); + return results; + } + + internal static Tuple GetLogisticsColumnsAndBody(string searchDirectory, string searchPattern) + { + Tuple results; + if (searchPattern.Length > 3 && !searchPattern.Contains('*') && File.Exists(searchPattern)) + results = GetLogisticsColumnsAndBody(searchPattern); + else + { + string[] pdsfFiles; + pdsfFiles = Directory.GetFiles(searchDirectory, searchPattern, SearchOption.TopDirectoryOnly); + if (!pdsfFiles.Any()) + _ = Process.Start("explorer.exe", searchDirectory); + Assert.IsTrue(pdsfFiles.Any(), "GetFiles check"); + results = GetLogisticsColumnsAndBody(pdsfFiles[0]); + } + Assert.IsFalse(string.IsNullOrEmpty(results.Item1)); + Assert.IsTrue(results.Item2.Length > 0, "Column check"); + Assert.IsTrue(results.Item3.Length > 0, "Body check"); + return results; + } + + internal static Tuple GetLogisticsColumnsAndBody(IFileRead fileRead, Logistics logistics, Tuple> extractResult, Tuple pdsf) + { + Tuple results; + string text = ProcessDataStandardFormat.GetPDSFText(fileRead, logistics, extractResult.Item3, logisticsText: pdsf.Item1); + string[] lines = text.Split(new string[] { System.Environment.NewLine }, StringSplitOptions.RemoveEmptyEntries); + results = ProcessDataStandardFormat.GetLogisticsColumnsAndBody(logistics.ReportFullPath, lines); + Assert.IsFalse(string.IsNullOrEmpty(results.Item1)); + Assert.IsTrue(results.Item2.Length > 0, "Column check"); + Assert.IsTrue(results.Item3.Length > 0, "Body check"); + return results; + } + + internal static string[] GetItem2(Tuple pdsf, Tuple pdsfNew) + { + JsonSerializerOptions jsonSerializerOptions = new() { WriteIndented = true }; + string jsonOld = JsonSerializer.Serialize(pdsf.Item2, pdsf.Item2.GetType(), jsonSerializerOptions); + string jsonNew = JsonSerializer.Serialize(pdsfNew.Item2, pdsfNew.Item2.GetType(), jsonSerializerOptions); + return new string[] { jsonOld, jsonNew }; + } + + internal static string[] GetItem3(Tuple pdsf, Tuple pdsfNew) + { + string joinOld = string.Join(System.Environment.NewLine, from l in pdsf.Item3 select string.Join('\t', from t in l.Split('\t') where !t.Contains(@"\\") select t)); + string joinNew = string.Join(System.Environment.NewLine, from l in pdsfNew.Item3 select string.Join('\t', from t in l.Split('\t') where !t.Contains(@"\\") select t)); + return new string[] { joinOld, joinNew }; + } + + internal static void UpdatePassDirectory(string searchDirectory) + { + DateTime dateTime = DateTime.Now; + try + { Directory.SetLastWriteTime(searchDirectory, dateTime); } + catch (Exception) { } + string ticksDirectory = Path.GetDirectoryName(searchDirectory); + try + { Directory.SetLastWriteTime(ticksDirectory, dateTime); } + catch (Exception) { } + string[] directories = Directory.GetDirectories(searchDirectory, "*", SearchOption.TopDirectoryOnly); + foreach (string directory in directories) + { + try + { Directory.SetLastWriteTime(directory, dateTime); } + catch (Exception) { } + } + } + + internal static string GetFileName(MethodBase methodBase) + { + string result; + string connectionName; + string separator = "__"; + string connectionNameAndTicks; + string[] segments = methodBase.Name.Split(new string[] { separator }, StringSplitOptions.None); + string environment = segments[0]; + string rawVersionName = segments[1]; + string equipmentTypeDirectory = segments[2]; + string ticks = DateTime.Now.Ticks.ToString(); + string comment = segments[segments.Length - 1]; + string versionName = segments[1].Replace('_', '.'); + string before = string.Concat(environment, separator, rawVersionName, separator, equipmentTypeDirectory, separator); + string after = methodBase.Name.Substring(before.Length); + if (after.Length < ticks.Length) + { + connectionName = after; + } + else + { + connectionNameAndTicks = after.Substring(0, after.Length - 2 - comment.Length); + connectionName = connectionNameAndTicks.Substring(0, connectionNameAndTicks.Length - ticks.Length); + ticks = connectionNameAndTicks.Substring(connectionName.Length); + } + result = Path.Combine(environment, equipmentTypeDirectory, versionName, $"{environment}__{rawVersionName}__{equipmentTypeDirectory}__{connectionName}", ticks, $"{connectionName.Replace('_', '-')}.json"); + if (result.Contains('/')) + result = string.Concat('/', result); + else + result = string.Concat('\\', result); + return result; + } + + internal static void CompareSaveTSV(string textFileDirectory, string[] join) + { + if (join[0] != join[1]) + { + _ = Process.Start("explorer.exe", textFileDirectory); + File.WriteAllText(Path.Combine(textFileDirectory, "0.tsv"), join[0]); + File.WriteAllText(Path.Combine(textFileDirectory, "1.tsv"), join[1]); + } + } + + internal static void CompareSaveJSON(string textFileDirectory, string[] json) + { + if (json[0] != json[1]) + { + _ = Process.Start("explorer.exe", textFileDirectory); + File.WriteAllText(Path.Combine(textFileDirectory, "0.json"), json[0]); + File.WriteAllText(Path.Combine(textFileDirectory, "1.json"), json[1]); + } + } + + internal static void CompareSave(string textFileDirectory, Tuple pdsf, Tuple pdsfNew) + { + if (pdsf.Item1 != pdsfNew.Item1) + { + _ = Process.Start("explorer.exe", textFileDirectory); + File.WriteAllText(Path.Combine(textFileDirectory, "0.dat"), pdsf.Item1); + File.WriteAllText(Path.Combine(textFileDirectory, "1.dat"), pdsfNew.Item1); + } + } + + internal static IFileRead GetWriteConfigurationGetFileRead(MethodBase methodBase, string check, AdaptationTesting adaptationTesting) + { + IFileRead result; + string[] fileNameAndJson = adaptationTesting.GetConfiguration(methodBase); + Assert.IsTrue(fileNameAndJson[1].Contains(check)); + File.WriteAllText(fileNameAndJson[0], fileNameAndJson[1]); + result = adaptationTesting.Get(methodBase, sourceFileLocation: string.Empty, sourceFileFilter: string.Empty, useCyclicalForDescription: false); + Assert.IsFalse(string.IsNullOrEmpty(result.CellInstanceConnectionName)); + return result; + } + + internal static string ReExtractCompareUpdatePassDirectory(string[] variables, IFileRead fileRead, Logistics logistics, bool validatePDSF = true) + { + string result; + Tuple> extractResult = fileRead.ReExtract(); + Assert.IsFalse(string.IsNullOrEmpty(extractResult?.Item1)); + Assert.IsTrue(extractResult.Item3.Length > 0, "extractResult Array Length check!"); + Assert.IsNotNull(extractResult.Item4); + if (!validatePDSF) + _ = GetLogisticsColumnsAndBody(fileRead, logistics, extractResult, new(string.Empty, Array.Empty(), Array.Empty())); + else + { + Tuple pdsf = GetLogisticsColumnsAndBody(variables[2], variables[4]); + Tuple pdsfNew = GetLogisticsColumnsAndBody(fileRead, logistics, extractResult, pdsf); + CompareSave(variables[5], pdsf, pdsfNew); + Assert.IsTrue(pdsf.Item1 == pdsfNew.Item1, "Item1 check!"); + string[] json = GetItem2(pdsf, pdsfNew); + CompareSaveJSON(variables[5], json); + Assert.IsTrue(json[0] == json[1], "Item2 check!"); + string[] join = GetItem3(pdsf, pdsfNew); + CompareSaveTSV(variables[5], join); + Assert.IsTrue(join[0] == join[1], "Item3 (Join) check!"); + } + UpdatePassDirectory(variables[2]); + result = extractResult.Item1; + return result; + } + } -// namespace _Tests.Helpers { public class AdaptationTesting { } } -// 2022-02-02 -> AdaptationTesting \ No newline at end of file +// namespace Adaptation._Tests.Helpers { public class AdaptationTesting { } } +// 2022-05-12 -> AdaptationTesting \ No newline at end of file diff --git a/Adaptation/_Tests/Shared/EAFLoggingUnitTesting.cs b/Adaptation/_Tests/Shared/EAFLoggingUnitTesting.cs index 4504bae..62a6cf7 100644 --- a/Adaptation/_Tests/Shared/EAFLoggingUnitTesting.cs +++ b/Adaptation/_Tests/Shared/EAFLoggingUnitTesting.cs @@ -1,7 +1,7 @@ using Microsoft.VisualStudio.TestTools.UnitTesting; using System; -namespace Shared; +namespace Adaptation._Tests.Shared; public class EAFLoggingUnitTesting : LoggingUnitTesting, IDisposable { diff --git a/Adaptation/_Tests/Shared/IsEnvironment.cs b/Adaptation/_Tests/Shared/IsEnvironment.cs index d47716e..fee5113 100644 --- a/Adaptation/_Tests/Shared/IsEnvironment.cs +++ b/Adaptation/_Tests/Shared/IsEnvironment.cs @@ -2,7 +2,7 @@ using System; using System.Diagnostics; using System.Runtime.InteropServices; -namespace Shared; +namespace Adaptation._Tests.Shared; public class IsEnvironment { @@ -155,11 +155,11 @@ public class IsEnvironment { string result; if (isEnvironment.Windows) - result = nameof(IsEnvironment.Windows); + result = nameof(Windows); else if (isEnvironment.Linux) - result = nameof(IsEnvironment.Linux); + result = nameof(Linux); else if (isEnvironment.OSX) - result = nameof(IsEnvironment.OSX); + result = nameof(OSX); else throw new Exception(); return result; diff --git a/Adaptation/_Tests/Shared/Log/ConsoleLogger.cs b/Adaptation/_Tests/Shared/Log/ConsoleLogger.cs new file mode 100644 index 0000000..8ea4d19 --- /dev/null +++ b/Adaptation/_Tests/Shared/Log/ConsoleLogger.cs @@ -0,0 +1,36 @@ +using Microsoft.Extensions.Logging; +using System; + +namespace Adaptation._Tests.Shared.Log; + +public class ConsoleLogger : ILogger +{ + + public int EventId { get; set; } + + private readonly string _Name; + private readonly LogLevel _LogLevel; + + public ConsoleLogger(LogLevel logLevel, string name) + { + _Name = name; + EventId = 0; + _LogLevel = logLevel; + if (string.IsNullOrEmpty(_Name)) + { } + } + + public IDisposable BeginScope(TState state) => null; + + public bool IsEnabled(LogLevel logLevel) => logLevel >= _LogLevel; + + public void Log(LogLevel logLevel, EventId eventId, TState state, Exception exception, Func formatter) + { + if (IsEnabled(logLevel) && (EventId == 0 || EventId == eventId.Id)) + { + string message = formatter(state, null); + Console.WriteLine(message); + } + } + +} \ No newline at end of file diff --git a/Adaptation/_Tests/Shared/Log/ConsoleProvider.cs b/Adaptation/_Tests/Shared/Log/ConsoleProvider.cs new file mode 100644 index 0000000..94cad4d --- /dev/null +++ b/Adaptation/_Tests/Shared/Log/ConsoleProvider.cs @@ -0,0 +1,27 @@ +using Microsoft.Extensions.Logging; +using System; +using System.Collections.Concurrent; + +namespace Adaptation._Tests.Shared.Log; + +public class ConsoleProvider : ILoggerProvider +{ + + private readonly LogLevel _LogLevel; + private readonly ConcurrentDictionary _Loggers; + + public ConsoleProvider(LogLevel logLevel) + { + _LogLevel = logLevel; + _Loggers = new ConcurrentDictionary(); + } + + public ILogger CreateLogger(string categoryName) => _Loggers.GetOrAdd(categoryName, name => new ConsoleLogger(_LogLevel, name)); + + public void Dispose() + { + _Loggers.Clear(); + GC.SuppressFinalize(this); + } + +} \ No newline at end of file diff --git a/Adaptation/_Tests/Shared/Log/DebugLogger.cs b/Adaptation/_Tests/Shared/Log/DebugLogger.cs new file mode 100644 index 0000000..87e312d --- /dev/null +++ b/Adaptation/_Tests/Shared/Log/DebugLogger.cs @@ -0,0 +1,36 @@ +using Microsoft.Extensions.Logging; +using System; + +namespace Adaptation._Tests.Shared.Log; + +public class DebugLogger : ILogger +{ + + public int EventId { get; set; } + + private readonly string _Name; + private readonly LogLevel _LogLevel; + + public DebugLogger(LogLevel logLevel, string name) + { + _Name = name; + EventId = 0; + _LogLevel = logLevel; + if (string.IsNullOrEmpty(_Name)) + { } + } + + public IDisposable BeginScope(TState state) => null; + + public bool IsEnabled(LogLevel logLevel) => logLevel >= _LogLevel; + + public void Log(LogLevel logLevel, EventId eventId, TState state, Exception exception, Func formatter) + { + if (IsEnabled(logLevel) && (EventId == 0 || EventId == eventId.Id)) + { + string message = formatter(state, null); + System.Diagnostics.Debug.Print(message); + } + } + +} \ No newline at end of file diff --git a/Adaptation/_Tests/Shared/Log/DebugProvider.cs b/Adaptation/_Tests/Shared/Log/DebugProvider.cs new file mode 100644 index 0000000..0511f67 --- /dev/null +++ b/Adaptation/_Tests/Shared/Log/DebugProvider.cs @@ -0,0 +1,27 @@ +using Microsoft.Extensions.Logging; +using System; +using System.Collections.Concurrent; + +namespace Adaptation._Tests.Shared.Log; + +public class DebugProvider : ILoggerProvider +{ + + private readonly LogLevel _LogLevel; + private readonly ConcurrentDictionary _Loggers; + + public DebugProvider(LogLevel logLevel) + { + _LogLevel = logLevel; + _Loggers = new ConcurrentDictionary(); + } + + public ILogger CreateLogger(string categoryName) => _Loggers.GetOrAdd(categoryName, name => new DebugLogger(_LogLevel, name)); + + public void Dispose() + { + _Loggers.Clear(); + GC.SuppressFinalize(this); + } + +} \ No newline at end of file diff --git a/Adaptation/_Tests/Shared/Log/FeedbackLogger.cs b/Adaptation/_Tests/Shared/Log/FeedbackLogger.cs new file mode 100644 index 0000000..5a6cabf --- /dev/null +++ b/Adaptation/_Tests/Shared/Log/FeedbackLogger.cs @@ -0,0 +1,49 @@ +using Microsoft.Extensions.Logging; +using System; + +namespace Adaptation._Tests.Shared.Log; + +public class FeedbackLogger : ILogger +{ + + public int EventId { get; set; } + + private readonly string _Name; + private readonly LogLevel _LogLevel; + private readonly IFeedback _Feedback; + + public FeedbackLogger(LogLevel logLevel, IFeedback feedback, string name) + { + _Feedback = feedback; + _Name = name; + EventId = 0; + _LogLevel = logLevel; + if (string.IsNullOrEmpty(_Name)) + { } + } + + public IDisposable BeginScope(TState state) => null; + + public bool IsEnabled(LogLevel logLevel) => logLevel >= _LogLevel; + + public void Log(LogLevel logLevel, EventId eventId, TState state, Exception exception, Func formatter) + { + if (IsEnabled(logLevel) && (EventId == 0 || EventId == eventId.Id)) + { + string message = formatter(state, null); + int color = logLevel switch + { + LogLevel.Trace => -1, + LogLevel.Debug => -1, + LogLevel.Information => -16776961, + LogLevel.Warning => -65281, + LogLevel.Error => -65536, + LogLevel.Critical => -65536, + LogLevel.None => -1, + _ => throw new Exception(), + }; + _Feedback.Print(message, color); + } + } + +} \ No newline at end of file diff --git a/Adaptation/_Tests/Shared/Log/FeedbackProvider.cs b/Adaptation/_Tests/Shared/Log/FeedbackProvider.cs new file mode 100644 index 0000000..f207b9b --- /dev/null +++ b/Adaptation/_Tests/Shared/Log/FeedbackProvider.cs @@ -0,0 +1,29 @@ +using Microsoft.Extensions.Logging; +using System; +using System.Collections.Concurrent; + +namespace Adaptation._Tests.Shared.Log; + +public class FeedbackProvider : ILoggerProvider +{ + + private readonly LogLevel _LogLevel; + private readonly IFeedback _Feedback; + private readonly ConcurrentDictionary _Loggers; + + public FeedbackProvider(LogLevel logLevel, IFeedback feedback) + { + _LogLevel = logLevel; + _Feedback = feedback; + _Loggers = new ConcurrentDictionary(); + } + + public ILogger CreateLogger(string categoryName) => _Loggers.GetOrAdd(categoryName, name => new FeedbackLogger(_LogLevel, _Feedback, name)); + + public void Dispose() + { + _Loggers.Clear(); + GC.SuppressFinalize(this); + } + +} \ No newline at end of file diff --git a/Adaptation/_Tests/Shared/Log/IFeedback.cs b/Adaptation/_Tests/Shared/Log/IFeedback.cs new file mode 100644 index 0000000..9cd7e79 --- /dev/null +++ b/Adaptation/_Tests/Shared/Log/IFeedback.cs @@ -0,0 +1,11 @@ +using System.Collections.Generic; + +namespace Adaptation._Tests.Shared.Log; + +public interface IFeedback +{ + + List Messages { get; } + void Print(string message, int color); + +} \ No newline at end of file diff --git a/Adaptation/_Tests/Shared/Log/Log.cs b/Adaptation/_Tests/Shared/Log/Log.cs new file mode 100644 index 0000000..8a57ac6 --- /dev/null +++ b/Adaptation/_Tests/Shared/Log/Log.cs @@ -0,0 +1,139 @@ +using Microsoft.Extensions.Logging; +using System; +using System.Collections.Generic; +using System.IO; + +namespace Adaptation._Tests.Shared.Log; + +public class Log +{ + +#pragma warning disable CA2254 +#pragma warning disable IDE0060 + + private readonly ILogger _Logger; + + public Log(ILogger logger) => _Logger = logger; + + public void Black(object message) => _Logger.LogInformation(message.ToString()); + public void Blue(object message) => _Logger.LogInformation(message.ToString()); + public void Gray(object message) => _Logger.LogInformation(message.ToString()); + public void Green(object message) => _Logger.LogInformation(message.ToString()); + public void Magenta(string message, Exception exception) => _Logger.LogWarning(message, exception); + public void Red(string message, Exception exception) => _Logger.LogError(message, exception); + public void White(object message) => _Logger.LogInformation(message.ToString()); + public void Yellow(string message, Exception exception) => _Logger.LogWarning(message, exception); + + // + + public void DoLog(LogLevel logLevel, EventId eventId, Exception exception, string message, params object[] args) => _Logger.Log(logLevel, eventId, exception, message, args); + public void DoLog(LogLevel logLevel, EventId eventId, string message, params object[] args) => _Logger.Log(logLevel, eventId, message, args); + public void DoLog(LogLevel logLevel, Exception exception, string message, params object[] args) => _Logger.Log(logLevel, exception, message, args); + public void DoLog(LogLevel logLevel, string message, params object[] args) => _Logger.Log(logLevel, message, args); + public void LogCritical(EventId eventId, Exception exception, string message, params object[] args) => _Logger.LogCritical(eventId, exception, message, args); + public void LogCritical(EventId eventId, string message, params object[] args) => _Logger.LogCritical(eventId, message, args); + public void LogCritical(Exception exception, string message, params object[] args) => _Logger.LogCritical(exception, message, args); + public void LogCritical(string message, params object[] args) => _Logger.LogCritical(message, args); + public void LogDebug(EventId eventId, Exception exception, string message, params object[] args) => _Logger.LogDebug(eventId, exception, message, args); + public void LogDebug(EventId eventId, string message, params object[] args) => _Logger.LogDebug(eventId, message, args); + public void LogDebug(Exception exception, string message, params object[] args) => _Logger.LogDebug(exception, message, args); + public void LogDebug(string message, params object[] args) => _Logger.LogDebug(message, args); + public void LogError(EventId eventId, Exception exception, string message, params object[] args) => _Logger.LogError(eventId, exception, message, args); + public void LogError(EventId eventId, string message, params object[] args) => _Logger.LogError(eventId, message, args); + public void LogError(Exception exception, string message, params object[] args) => _Logger.LogError(message, args); + public void LogError(string message, params object[] args) => _Logger.LogError(message, args); + public void LogInformation(EventId eventId, Exception exception, string message, params object[] args) => _Logger.LogInformation(eventId, exception, message, args); + public void LogInformation(EventId eventId, string message, params object[] args) => _Logger.LogInformation(eventId, message, args); + public void LogInformation(Exception exception, string message, params object[] args) => _Logger.LogInformation(exception, message, args); + public void LogInformation(string message, params object[] args) => _Logger.LogInformation(message, args); + public void LogTrace(EventId eventId, Exception exception, string message, params object[] args) => _Logger.LogTrace(eventId, exception, message, args); + public void LogTrace(EventId eventId, string message, params object[] args) => _Logger.LogTrace(eventId, message, args); + public void LogTrace(Exception exception, string message, params object[] args) => _Logger.LogTrace(exception, message, args); + public void LogTrace(string message, params object[] args) => _Logger.LogTrace(message, args); + public void LogWarning(EventId eventId, Exception exception, string message, params object[] args) => _Logger.LogWarning(eventId, exception, message, args); + public void LogWarning(EventId eventId, string message, params object[] args) => _Logger.LogWarning(eventId, message, args); + public void LogWarning(Exception exception, string message, params object[] args) => _Logger.LogWarning(exception, message, args); + public void LogWarning(string message, params object[] args) => _Logger.LogWarning(message, args); + + // + + public void Debug() => _Logger.LogDebug(string.Empty); + public void Debug(object message) => _Logger.LogDebug(message.ToString()); + public void Debug(string message, Exception exception) => _Logger.LogDebug(exception, message); + public void DebugFormat(IFormatProvider provider, string format, params object[] args) => _Logger.LogDebug(string.Format(provider, format, args)); + public void DebugFormat(string format, object arg0, object arg1, object arg2) => _Logger.LogDebug(string.Format(format, arg0, arg1, arg2)); + public void DebugFormat(string format, object arg0, object arg1) => _Logger.LogDebug(string.Format(format, arg0, arg1)); + public void DebugFormat(string format, object arg0) => _Logger.LogDebug(string.Format(format, arg0)); + public void DebugFormat(string format, params object[] args) => _Logger.LogDebug(string.Format(format, args)); + public void Error(object message) => _Logger.LogError(message.ToString()); + public void Error(string message, Exception exception) => _Logger.LogError(exception, message.ToString()); + public void ErrorFormat(IFormatProvider provider, string format, params object[] args) => _Logger.LogError(string.Format(provider, format, args)); + public void ErrorFormat(string format, object arg0, object arg1, object arg2) => _Logger.LogError(string.Format(format, arg0, arg1, arg2)); + public void ErrorFormat(string format, object arg0, object arg1) => _Logger.LogError(string.Format(format, arg0, arg1)); + public void ErrorFormat(string format, object arg0) => _Logger.LogError(string.Format(format, arg0)); + public void ErrorFormat(string format, params object[] args) => _Logger.LogError(string.Format(format, args)); + public void Fatal(object message) => _Logger.LogCritical(message.ToString()); + public void Fatal(string message, Exception exception) => _Logger.LogCritical(exception, message.ToString()); + public void FatalFormat(IFormatProvider provider, string format, params object[] args) => _Logger.LogCritical(string.Format(provider, format, args)); + public void FatalFormat(string format, object arg0, object arg1, object arg2) => _Logger.LogCritical(string.Format(format, arg0, arg1, arg2)); + public void FatalFormat(string format, object arg0, object arg1) => _Logger.LogCritical(string.Format(format, arg0, arg1)); + public void FatalFormat(string format, object arg0) => _Logger.LogCritical(string.Format(format, arg0)); + public void FatalFormat(string format, params object[] args) => _Logger.LogCritical(string.Format(format, args)); + public void Info(object message) => _Logger.LogInformation(message.ToString()); + public void Info(string message, Exception exception) => _Logger.LogInformation(exception, message.ToString()); + public void InfoFormat(IFormatProvider provider, string format, params object[] args) => _Logger.LogInformation(string.Format(provider, format, args)); + public void InfoFormat(string format, object arg0, object arg1, object arg2) => _Logger.LogInformation(string.Format(format, arg0, arg1, arg2)); + public void InfoFormat(string format, object arg0, object arg1) => _Logger.LogInformation(string.Format(format, arg0, arg1)); + public void InfoFormat(string format, object arg0) => _Logger.LogInformation(string.Format(format, arg0)); + public void InfoFormat(string format, params object[] args) => _Logger.LogInformation(string.Format(format, args)); + public void Warn(object message) => _Logger.LogWarning(message.ToString()); + public void Warn(string message, Exception exception) => _Logger.LogWarning(exception, message.ToString()); + public void WarnFormat(IFormatProvider provider, string format, params object[] args) => _Logger.LogWarning(string.Format(provider, format, args)); + public void WarnFormat(string format, object arg0, object arg1, object arg2) => _Logger.LogWarning(string.Format(format, arg0, arg1, arg2)); + public void WarnFormat(string format, object arg0, object arg1) => _Logger.LogWarning(string.Format(format, arg0, arg1)); + public void WarnFormat(string format, object arg0) => _Logger.LogWarning(string.Format(format, arg0)); + public void WarnFormat(string format, params object[] args) => _Logger.LogWarning(string.Format(format, args)); + + public static string GetWorkingDirectory(string executingAssemblyName, string subDirectoryName) + { + string result = string.Empty; + string traceFile; + List directories = new(); + Environment.SpecialFolder[] specialFolders = new Environment.SpecialFolder[] + { + Environment.SpecialFolder.LocalApplicationData, + Environment.SpecialFolder.ApplicationData, + Environment.SpecialFolder.History, + Environment.SpecialFolder.CommonApplicationData, + Environment.SpecialFolder.InternetCache + }; + foreach (Environment.SpecialFolder specialFolder in specialFolders) + directories.Add(Path.Combine(Environment.GetFolderPath(specialFolder), subDirectoryName, executingAssemblyName)); + foreach (string directory in directories) + { + for (int i = 1; i < 3; i++) + { + if (i == 1) + result = directory; + else + result = string.Concat("D", directory[1..]); + try + { + if (!Directory.Exists(result)) + _ = Directory.CreateDirectory(result); + traceFile = string.Concat(result, @"\", DateTime.Now.Ticks, ".txt"); + File.WriteAllText(traceFile, traceFile); + File.Delete(traceFile); + break; + } + catch (Exception) { result = string.Empty; } + } + if (!string.IsNullOrEmpty(result)) + break; + } + if (string.IsNullOrEmpty(result)) + throw new Exception("Unable to set working directory!"); + return result; + } + +} \ No newline at end of file diff --git a/Adaptation/_Tests/Shared/LoggingUnitTesting.cs b/Adaptation/_Tests/Shared/LoggingUnitTesting.cs index 1f44068..f5c6a40 100644 --- a/Adaptation/_Tests/Shared/LoggingUnitTesting.cs +++ b/Adaptation/_Tests/Shared/LoggingUnitTesting.cs @@ -1,3 +1,4 @@ +using Adaptation._Tests.Shared.Log; using Microsoft.Extensions.Configuration; using Microsoft.Extensions.Logging; using Microsoft.VisualStudio.TestTools.UnitTesting; @@ -5,7 +6,7 @@ using System; using System.Collections.Generic; using System.IO; -namespace Shared; +namespace Adaptation._Tests.Shared; public class LoggingUnitTesting : UnitTesting, IDisposable { @@ -48,7 +49,7 @@ public class LoggingUnitTesting : UnitTesting, IDisposable configurationSection = _ConfigurationRoot.GetSection(section); if (configurationSection is null) logLevel = LogLevel.Debug; - else if (!Enum.TryParse(configurationSection.Value, out logLevel)) + else if (!Enum.TryParse(configurationSection.Value, out logLevel)) logLevel = LogLevel.Debug; logLevels.Add(logLevel); } diff --git a/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/CellInstance.cs b/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/CellInstance.cs index 304f0b2..77ac5ab 100644 --- a/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/CellInstance.cs +++ b/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/CellInstance.cs @@ -1,11 +1,13 @@ -namespace Shared.PasteSpecialXml.EAF.XML.API.CellInstance; +using System; + +namespace Adaptation._Tests.Shared.PasteSpecialXml.EAF.XML.API.CellInstance; // NOTE: Generated code may require at least .NET Framework 4.5 or .NET Core/Standard 2.0. /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities", IsNullable = false)] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities", IsNullable = false)] public partial class CellInstanceVersion { @@ -13,13 +15,13 @@ public partial class CellInstanceVersion private string createdByField; - private System.DateTime creationDateField; + private DateTime creationDateField; private object descriptionField; private ExtensionsVersionExtension[] extensionsField; - private System.DateTime freezeDateField; + private DateTime freezeDateField; private string frozenByField; @@ -29,7 +31,7 @@ public partial class CellInstanceVersion private bool isRetiredField; - private System.DateTime retireDateField; + private DateTime retireDateField; private object retiredByField; @@ -56,7 +58,7 @@ public partial class CellInstanceVersion private string id1Field; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public string CreatedBy { @@ -65,16 +67,16 @@ public partial class CellInstanceVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] - public System.DateTime CreationDate + public DateTime CreationDate { get => this.creationDateField; set => this.creationDateField = value; } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities", IsNullable = true)] public object Description { @@ -83,9 +85,9 @@ public partial class CellInstanceVersion } /// - [System.Xml.Serialization.XmlArrayAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlArray(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] - [System.Xml.Serialization.XmlArrayItemAttribute("VersionExtension", IsNullable = false)] + [System.Xml.Serialization.XmlArrayItem("VersionExtension", IsNullable = false)] public ExtensionsVersionExtension[] Extensions { get => this.extensionsField; @@ -93,16 +95,16 @@ public partial class CellInstanceVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] - public System.DateTime FreezeDate + public DateTime FreezeDate { get => this.freezeDateField; set => this.freezeDateField = value; } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public string FrozenBy { @@ -111,7 +113,7 @@ public partial class CellInstanceVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public long Id { @@ -120,7 +122,7 @@ public partial class CellInstanceVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public bool IsFrozen { @@ -129,7 +131,7 @@ public partial class CellInstanceVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public bool IsRetired { @@ -138,16 +140,16 @@ public partial class CellInstanceVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] - public System.DateTime RetireDate + public DateTime RetireDate { get => this.retireDateField; set => this.retireDateField = value; } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities", IsNullable = true)] public object RetiredBy { @@ -184,7 +186,7 @@ public partial class CellInstanceVersion } /// - [System.Xml.Serialization.XmlArrayItemAttribute("SelectedDeploymentPackage", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Deployme" + + [System.Xml.Serialization.XmlArrayItem("SelectedDeploymentPackage", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Deployme" + "nt", IsNullable = false)] public SelectedDeploymentPackage[] DeploymentPackages { @@ -200,7 +202,7 @@ public partial class CellInstanceVersion } /// - [System.Xml.Serialization.XmlArrayItemAttribute("EquipmentConnectionSettings", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlArrayItem("EquipmentConnectionSettings", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances", IsNullable = false)] public EquipmentConnectionSettings[] EquipmentConnections { @@ -230,7 +232,7 @@ public partial class CellInstanceVersion } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -239,11 +241,11 @@ public partial class CellInstanceVersion } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Deployme" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Deployme" + "nt")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Deployme" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Deployme" + "nt", IsNullable = false)] public partial class SelectedDeploymentPackage { @@ -277,11 +279,11 @@ public partial class SelectedDeploymentPackage } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances", IsNullable = false)] public partial class EquipmentConnectionSettings { @@ -289,7 +291,7 @@ public partial class EquipmentConnectionSettings private string refField; /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Ref { get => this.refField; @@ -298,9 +300,9 @@ public partial class EquipmentConnectionSettings } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public partial class ExtensionsVersionExtension { @@ -327,7 +329,7 @@ public partial class ExtensionsVersionExtension } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Backbone" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Backbone" + "s")] public string ClassName { @@ -336,7 +338,7 @@ public partial class ExtensionsVersionExtension } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Backbone" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Backbone" + "s", IsNullable = true)] public object Configuration { @@ -345,7 +347,7 @@ public partial class ExtensionsVersionExtension } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Backbone" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Backbone" + "s")] public string Name { @@ -354,7 +356,7 @@ public partial class ExtensionsVersionExtension } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tAutomationClient")] public object Editors { @@ -363,7 +365,7 @@ public partial class ExtensionsVersionExtension } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -371,7 +373,7 @@ public partial class ExtensionsVersionExtension } /// - [System.Xml.Serialization.XmlAttributeAttribute()] + [System.Xml.Serialization.XmlAttribute()] public string i___type { get => this.i___typeField; @@ -380,9 +382,9 @@ public partial class ExtensionsVersionExtension } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public partial class CellInstanceVersionCellSetting { @@ -395,7 +397,7 @@ public partial class CellInstanceVersionCellSetting private string id1Field; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public long Id { @@ -404,7 +406,7 @@ public partial class CellInstanceVersionCellSetting } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public CellType CellType { @@ -413,7 +415,7 @@ public partial class CellInstanceVersionCellSetting } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public string Name { @@ -422,7 +424,7 @@ public partial class CellInstanceVersionCellSetting } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -431,11 +433,11 @@ public partial class CellInstanceVersionCellSetting } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances", IsNullable = false)] public partial class CellType { @@ -449,7 +451,7 @@ public partial class CellType private string id1Field; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public long Id { get => this.idField; @@ -457,7 +459,7 @@ public partial class CellType } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public string Name { get => this.nameField; @@ -465,7 +467,7 @@ public partial class CellType } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public string Version { get => this.versionField; @@ -473,7 +475,7 @@ public partial class CellType } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -482,9 +484,9 @@ public partial class CellType } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public partial class CellInstanceVersionComponentModel { @@ -495,7 +497,7 @@ public partial class CellInstanceVersionComponentModel private string id1Field; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public long Id { @@ -504,9 +506,9 @@ public partial class CellInstanceVersionComponentModel } /// - [System.Xml.Serialization.XmlArrayAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlArray(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] - [System.Xml.Serialization.XmlArrayItemAttribute("CellComponent", IsNullable = false)] + [System.Xml.Serialization.XmlArrayItem("CellComponent", IsNullable = false)] public ComponentsCellComponent[] Components { get => this.componentsField; @@ -514,7 +516,7 @@ public partial class CellInstanceVersionComponentModel } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -523,9 +525,9 @@ public partial class CellInstanceVersionComponentModel } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public partial class ComponentsCellComponent { @@ -545,7 +547,7 @@ public partial class ComponentsCellComponent private string idField; /// - [System.Xml.Serialization.XmlArrayItemAttribute("CellComponent", IsNullable = false)] + [System.Xml.Serialization.XmlArrayItem("CellComponent", IsNullable = false)] public ComponentsCellComponentCellComponent[] Children { get => this.childrenField; @@ -574,7 +576,7 @@ public partial class ComponentsCellComponent } /// - [System.Xml.Serialization.XmlArrayItemAttribute("ComponentParameter", IsNullable = false)] + [System.Xml.Serialization.XmlArrayItem("ComponentParameter", IsNullable = false)] public ComponentsCellComponentComponentParameter[] Parameters { get => this.parametersField; @@ -589,7 +591,7 @@ public partial class ComponentsCellComponent } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -598,9 +600,9 @@ public partial class ComponentsCellComponent } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public partial class ComponentsCellComponentCellComponent { @@ -648,7 +650,7 @@ public partial class ComponentsCellComponentCellComponent } /// - [System.Xml.Serialization.XmlArrayItemAttribute("ComponentParameter", IsNullable = false)] + [System.Xml.Serialization.XmlArrayItem("ComponentParameter", IsNullable = false)] public ComponentsCellComponentCellComponentComponentParameter[] Parameters { get => this.parametersField; @@ -663,7 +665,7 @@ public partial class ComponentsCellComponentCellComponent } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -672,9 +674,9 @@ public partial class ComponentsCellComponentCellComponent } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public partial class ComponentsCellComponentCellComponentEquipment { @@ -800,7 +802,7 @@ public partial class ComponentsCellComponentCellComponentEquipment private string i___typeField; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public long Id { @@ -832,7 +834,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string AlternateTargetFolder { @@ -841,7 +843,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long ConnectionRetryInterval { @@ -850,7 +852,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public ConnectionSettings ConnectionSettings { @@ -859,7 +861,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool CopySourceFolderStructure { @@ -868,7 +870,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string DefaultPlaceHolderValue { @@ -877,7 +879,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool DeleteEmptySourceSubFolders { @@ -886,7 +888,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ErrorPostProcessingMode { @@ -895,7 +897,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ErrorTargetFileLocation { @@ -904,7 +906,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ErrorTargetFileName { @@ -913,7 +915,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string FileAgeFilterMode { @@ -922,7 +924,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string FileAgeThreshold { @@ -931,7 +933,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long FileHandleTimeout { @@ -940,7 +942,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long FileHandleWaitTime { @@ -949,7 +951,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public int FileScanningIntervalInSeconds { @@ -958,7 +960,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string FileScanningOption { @@ -967,7 +969,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public int IdleEventWaitTimeInSeconds { @@ -976,7 +978,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string IfFileExistAction { @@ -985,7 +987,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string IfPostProcessingFailsAction { @@ -994,7 +996,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool IncludeSubDirectories { @@ -1003,7 +1005,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string PostProcessingMode { @@ -1012,7 +1014,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long PostProcessingRetries { @@ -1021,7 +1023,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string PreProcessingMode { @@ -1030,7 +1032,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string SkipSearchDirectoryNames { @@ -1039,7 +1041,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string SourceFileFilter { @@ -1048,7 +1050,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string SourceFileLocation { @@ -1057,7 +1059,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string TargetFileLocation { @@ -1066,7 +1068,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string TargetFileName { @@ -1075,7 +1077,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool TriggerOnChanged { @@ -1084,7 +1086,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool TriggerOnCreated { @@ -1093,7 +1095,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool UseZip64Mode { @@ -1102,7 +1104,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ZipErrorTargetFileName { @@ -1111,7 +1113,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long ZipFileAmount { @@ -1120,7 +1122,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long ZipFileSubFolderLevel { @@ -1129,7 +1131,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long ZipFileTime { @@ -1138,7 +1140,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ZipMode { @@ -1147,7 +1149,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ZipTargetFileName { @@ -1156,7 +1158,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances")] public string BaudRate { @@ -1165,7 +1167,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances")] public string ConnectionMode { @@ -1174,7 +1176,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances")] public byte DeviceId { @@ -1183,7 +1185,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlIgnoreAttribute()] + [System.Xml.Serialization.XmlIgnore()] public bool DeviceIdSpecified { get => this.deviceIdFieldSpecified; @@ -1191,7 +1193,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances")] public string Host { @@ -1200,7 +1202,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances", DataType = "duration")] public string LinkTestTimer { @@ -1209,7 +1211,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances")] public ushort Port { @@ -1218,7 +1220,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlIgnoreAttribute()] + [System.Xml.Serialization.XmlIgnore()] public bool PortSpecified { get => this.portFieldSpecified; @@ -1226,7 +1228,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances")] public string PortType { @@ -1235,7 +1237,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances")] public string SessionMode { @@ -1244,7 +1246,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances", DataType = "duration")] public string T1InterCharacter { @@ -1253,7 +1255,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances", DataType = "duration")] public string T2Protocol { @@ -1262,7 +1264,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances", DataType = "duration")] public string T3MessageReply { @@ -1271,7 +1273,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances", DataType = "duration")] public string T4InterBlock { @@ -1280,7 +1282,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances", DataType = "duration")] public string T5ConnectionSeperation { @@ -1289,7 +1291,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances", DataType = "duration")] public string T6HsmsControlMessage { @@ -1298,7 +1300,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances", DataType = "duration")] public string T7ConnectionIdle { @@ -1307,7 +1309,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Semicond" + "uctor.CellInstances", DataType = "duration")] public string T8NetworkIntercharacter { @@ -1316,7 +1318,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -1324,7 +1326,7 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// - [System.Xml.Serialization.XmlAttributeAttribute()] + [System.Xml.Serialization.XmlAttribute()] public string i___type { get => this.i___typeField; @@ -1333,9 +1335,9 @@ public partial class ComponentsCellComponentCellComponentEquipment } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public partial class ComponentsCellComponentChildrenCellComponentEquipmentEquipmentDictionaries { @@ -1343,7 +1345,7 @@ public partial class ComponentsCellComponentChildrenCellComponentEquipmentEquipm private CellEquipmentDictionaryReference cellEquipmentDictionaryReferenceField; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public CellEquipmentDictionaryReference CellEquipmentDictionaryReference { get => this.cellEquipmentDictionaryReferenceField; @@ -1352,10 +1354,10 @@ public partial class ComponentsCellComponentChildrenCellComponentEquipmentEquipm } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities", IsNullable = false)] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities", IsNullable = false)] public partial class CellEquipmentDictionaryReference { @@ -1389,7 +1391,7 @@ public partial class CellEquipmentDictionaryReference } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -1398,9 +1400,9 @@ public partial class CellEquipmentDictionaryReference } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public partial class ComponentsCellComponentCellComponentEquipmentEquipmentType { @@ -1414,7 +1416,7 @@ public partial class ComponentsCellComponentCellComponentEquipmentEquipmentType private string id1Field; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public long Id { get => this.idField; @@ -1422,7 +1424,7 @@ public partial class ComponentsCellComponentCellComponentEquipmentEquipmentType } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public string Name { get => this.nameField; @@ -1430,7 +1432,7 @@ public partial class ComponentsCellComponentCellComponentEquipmentEquipmentType } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public string Version { get => this.versionField; @@ -1438,7 +1440,7 @@ public partial class ComponentsCellComponentCellComponentEquipmentEquipmentType } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -1447,9 +1449,9 @@ public partial class ComponentsCellComponentCellComponentEquipmentEquipmentType } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public partial class ComponentsCellComponentCellComponentComponentParameter { @@ -1469,7 +1471,7 @@ public partial class ComponentsCellComponentCellComponentComponentParameter private string id1Field; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation", IsNullable = true)] public object EnumType { @@ -1478,7 +1480,7 @@ public partial class ComponentsCellComponentCellComponentComponentParameter } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public long Id { @@ -1487,7 +1489,7 @@ public partial class ComponentsCellComponentCellComponentComponentParameter } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public string Name { @@ -1496,7 +1498,7 @@ public partial class ComponentsCellComponentCellComponentComponentParameter } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public string Value { @@ -1505,7 +1507,7 @@ public partial class ComponentsCellComponentCellComponentComponentParameter } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public string ValueType { @@ -1521,7 +1523,7 @@ public partial class ComponentsCellComponentCellComponentComponentParameter } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -1530,9 +1532,9 @@ public partial class ComponentsCellComponentCellComponentComponentParameter } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public partial class ComponentsCellComponentEquipment { @@ -1624,7 +1626,7 @@ public partial class ComponentsCellComponentEquipment private string i___typeField; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public long Id { @@ -1654,7 +1656,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string AlternateTargetFolder { @@ -1663,7 +1665,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long ConnectionRetryInterval { @@ -1672,7 +1674,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public ConnectionSettings ConnectionSettings { @@ -1681,7 +1683,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool CopySourceFolderStructure { @@ -1690,7 +1692,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string DefaultPlaceHolderValue { @@ -1699,7 +1701,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool DeleteEmptySourceSubFolders { @@ -1708,7 +1710,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ErrorPostProcessingMode { @@ -1717,7 +1719,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ErrorTargetFileLocation { @@ -1726,7 +1728,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ErrorTargetFileName { @@ -1735,7 +1737,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string FileAgeFilterMode { @@ -1744,7 +1746,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string FileAgeThreshold { @@ -1753,7 +1755,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long FileHandleTimeout { @@ -1762,7 +1764,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long FileHandleWaitTime { @@ -1771,7 +1773,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public int FileScanningIntervalInSeconds { @@ -1780,7 +1782,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string FileScanningOption { @@ -1789,7 +1791,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public int IdleEventWaitTimeInSeconds { @@ -1798,7 +1800,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string IfFileExistAction { @@ -1807,7 +1809,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string IfPostProcessingFailsAction { @@ -1816,7 +1818,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool IncludeSubDirectories { @@ -1825,7 +1827,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string PostProcessingMode { @@ -1834,7 +1836,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long PostProcessingRetries { @@ -1843,7 +1845,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string PreProcessingMode { @@ -1852,7 +1854,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string SkipSearchDirectoryNames { @@ -1861,7 +1863,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string SourceFileFilter { @@ -1870,7 +1872,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string SourceFileLocation { @@ -1879,7 +1881,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string TargetFileLocation { @@ -1888,7 +1890,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string TargetFileName { @@ -1897,7 +1899,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool TriggerOnChanged { @@ -1906,7 +1908,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool TriggerOnCreated { @@ -1915,7 +1917,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool UseZip64Mode { @@ -1924,7 +1926,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ZipErrorTargetFileName { @@ -1933,7 +1935,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long ZipFileAmount { @@ -1942,7 +1944,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long ZipFileSubFolderLevel { @@ -1951,7 +1953,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long ZipFileTime { @@ -1960,7 +1962,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ZipMode { @@ -1969,7 +1971,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ZipTargetFileName { @@ -1978,7 +1980,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Ref { get => this.refField; @@ -1986,7 +1988,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -1994,7 +1996,7 @@ public partial class ComponentsCellComponentEquipment } /// - [System.Xml.Serialization.XmlAttributeAttribute()] + [System.Xml.Serialization.XmlAttribute()] public string i___type { get => this.i___typeField; @@ -2003,9 +2005,9 @@ public partial class ComponentsCellComponentEquipment } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public partial class ComponentsCellComponentEquipmentEquipmentType { @@ -2019,7 +2021,7 @@ public partial class ComponentsCellComponentEquipmentEquipmentType private string id1Field; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public long Id { get => this.idField; @@ -2027,7 +2029,7 @@ public partial class ComponentsCellComponentEquipmentEquipmentType } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public string Name { get => this.nameField; @@ -2035,7 +2037,7 @@ public partial class ComponentsCellComponentEquipmentEquipmentType } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public string Version { get => this.versionField; @@ -2043,7 +2045,7 @@ public partial class ComponentsCellComponentEquipmentEquipmentType } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -2052,9 +2054,9 @@ public partial class ComponentsCellComponentEquipmentEquipmentType } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public partial class ComponentsCellComponentComponentParameter { @@ -2074,7 +2076,7 @@ public partial class ComponentsCellComponentComponentParameter private string id1Field; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation", IsNullable = true)] public object EnumType { @@ -2083,7 +2085,7 @@ public partial class ComponentsCellComponentComponentParameter } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public long Id { @@ -2092,7 +2094,7 @@ public partial class ComponentsCellComponentComponentParameter } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public string Name { @@ -2101,7 +2103,7 @@ public partial class ComponentsCellComponentComponentParameter } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public string Value { @@ -2110,7 +2112,7 @@ public partial class ComponentsCellComponentComponentParameter } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public string ValueType { @@ -2126,7 +2128,7 @@ public partial class ComponentsCellComponentComponentParameter } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -2135,9 +2137,9 @@ public partial class ComponentsCellComponentComponentParameter } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public partial class CellInstanceVersionEdaConnection { @@ -2160,7 +2162,7 @@ public partial class CellInstanceVersionEdaConnection private string id1Field; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public long Id { @@ -2169,7 +2171,7 @@ public partial class CellInstanceVersionEdaConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] public int CheckInterval { get => this.checkIntervalField; @@ -2177,7 +2179,7 @@ public partial class CellInstanceVersionEdaConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] public int ConnectionTimeout { get => this.connectionTimeoutField; @@ -2185,7 +2187,7 @@ public partial class CellInstanceVersionEdaConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA", IsNullable = true)] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA", IsNullable = true)] public object EdaClientProxyFactoryProviderName { get => this.edaClientProxyFactoryProviderNameField; @@ -2193,7 +2195,7 @@ public partial class CellInstanceVersionEdaConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] public long MaxLostPings { get => this.maxLostPingsField; @@ -2201,7 +2203,7 @@ public partial class CellInstanceVersionEdaConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] public string PortName { get => this.portNameField; @@ -2209,7 +2211,7 @@ public partial class CellInstanceVersionEdaConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] public int PortNumber { get => this.portNumberField; @@ -2217,7 +2219,7 @@ public partial class CellInstanceVersionEdaConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] public string SSLEnabled { get => this.sSLEnabledField; @@ -2225,7 +2227,7 @@ public partial class CellInstanceVersionEdaConnection } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -2234,9 +2236,9 @@ public partial class CellInstanceVersionEdaConnection } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public partial class CellInstanceVersionParentInstance { @@ -2272,7 +2274,7 @@ public partial class CellInstanceVersionParentInstance } /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public object CurrentHost { get => this.currentHostField; @@ -2287,7 +2289,7 @@ public partial class CellInstanceVersionParentInstance } /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public object Info { get => this.infoField; @@ -2309,7 +2311,7 @@ public partial class CellInstanceVersionParentInstance } /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public object StartTime { get => this.startTimeField; @@ -2324,7 +2326,7 @@ public partial class CellInstanceVersionParentInstance } /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public object StopTime { get => this.stopTimeField; @@ -2339,7 +2341,7 @@ public partial class CellInstanceVersionParentInstance } /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public object TargetHost { get => this.targetHostField; @@ -2347,7 +2349,7 @@ public partial class CellInstanceVersionParentInstance } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -2356,9 +2358,9 @@ public partial class CellInstanceVersionParentInstance } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public partial class CellInstanceVersionEdaTraceHandling { @@ -2373,7 +2375,7 @@ public partial class CellInstanceVersionEdaTraceHandling private TraceSourcePrimaryPrioritiesConnection[] traceSourcePrimaryPrioritiesField; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] public long MaxParameterCollectionTimeDelta { get => this.maxParameterCollectionTimeDeltaField; @@ -2381,7 +2383,7 @@ public partial class CellInstanceVersionEdaTraceHandling } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA", IsNullable = true)] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA", IsNullable = true)] public object MergeStrategyClass { get => this.mergeStrategyClassField; @@ -2389,7 +2391,7 @@ public partial class CellInstanceVersionEdaTraceHandling } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] public object MergeStrategyParameters { get => this.mergeStrategyParametersField; @@ -2397,7 +2399,7 @@ public partial class CellInstanceVersionEdaTraceHandling } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] public long TraceCleanupDaemonInterval { get => this.traceCleanupDaemonIntervalField; @@ -2405,8 +2407,8 @@ public partial class CellInstanceVersionEdaTraceHandling } /// - [System.Xml.Serialization.XmlArrayAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] - [System.Xml.Serialization.XmlArrayItemAttribute("Connection", IsNullable = false)] + [System.Xml.Serialization.XmlArray(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] + [System.Xml.Serialization.XmlArrayItem("Connection", IsNullable = false)] public TraceSourcePrimaryPrioritiesConnection[] TraceSourcePrimaryPriorities { get => this.traceSourcePrimaryPrioritiesField; @@ -2415,9 +2417,9 @@ public partial class CellInstanceVersionEdaTraceHandling } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] public partial class TraceSourcePrimaryPrioritiesConnection { @@ -2506,7 +2508,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection private string i___typeField; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public long Id { @@ -2515,7 +2517,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public object EquipmentDictionaries { @@ -2524,7 +2526,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public EquipmentType EquipmentType { @@ -2533,7 +2535,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] public string Name { @@ -2542,7 +2544,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string AlternateTargetFolder { @@ -2551,7 +2553,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long ConnectionRetryInterval { @@ -2560,7 +2562,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public ConnectionSettings ConnectionSettings { @@ -2569,7 +2571,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool CopySourceFolderStructure { @@ -2578,7 +2580,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string DefaultPlaceHolderValue { @@ -2587,7 +2589,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool DeleteEmptySourceSubFolders { @@ -2596,7 +2598,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ErrorPostProcessingMode { @@ -2605,7 +2607,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ErrorTargetFileLocation { @@ -2614,7 +2616,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ErrorTargetFileName { @@ -2623,7 +2625,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string FileAgeFilterMode { @@ -2632,7 +2634,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string FileAgeThreshold { @@ -2641,7 +2643,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long FileHandleTimeout { @@ -2650,7 +2652,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long FileHandleWaitTime { @@ -2659,7 +2661,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public int FileScanningIntervalInSeconds { @@ -2668,7 +2670,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string FileScanningOption { @@ -2677,7 +2679,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public int IdleEventWaitTimeInSeconds { @@ -2686,7 +2688,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string IfFileExistAction { @@ -2695,7 +2697,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string IfPostProcessingFailsAction { @@ -2704,7 +2706,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool IncludeSubDirectories { @@ -2713,7 +2715,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string PostProcessingMode { @@ -2722,7 +2724,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long PostProcessingRetries { @@ -2731,7 +2733,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string PreProcessingMode { @@ -2740,7 +2742,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string SkipSearchDirectoryNames { @@ -2749,7 +2751,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string SourceFileFilter { @@ -2758,7 +2760,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string SourceFileLocation { @@ -2767,7 +2769,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string TargetFileLocation { @@ -2776,7 +2778,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string TargetFileName { @@ -2785,7 +2787,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool TriggerOnChanged { @@ -2794,7 +2796,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool TriggerOnCreated { @@ -2803,7 +2805,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public bool UseZip64Mode { @@ -2812,7 +2814,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ZipErrorTargetFileName { @@ -2821,7 +2823,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long ZipFileAmount { @@ -2830,7 +2832,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long ZipFileSubFolderLevel { @@ -2839,7 +2841,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public long ZipFileTime { @@ -2848,7 +2850,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ZipMode { @@ -2857,7 +2859,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] public string ZipTargetFileName { @@ -2866,7 +2868,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -2874,7 +2876,7 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// - [System.Xml.Serialization.XmlAttributeAttribute()] + [System.Xml.Serialization.XmlAttribute()] public string i___type { get => this.i___typeField; @@ -2883,11 +2885,11 @@ public partial class TraceSourcePrimaryPrioritiesConnection } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances", IsNullable = false)] public partial class EquipmentType { @@ -2901,7 +2903,7 @@ public partial class EquipmentType private string id1Field; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public long Id { get => this.idField; @@ -2909,7 +2911,7 @@ public partial class EquipmentType } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public string Name { get => this.nameField; @@ -2917,7 +2919,7 @@ public partial class EquipmentType } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public string Version { get => this.versionField; @@ -2925,7 +2927,7 @@ public partial class EquipmentType } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -2934,11 +2936,11 @@ public partial class EquipmentType } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities", IsNullable = false)] public partial class Extensions { @@ -2946,7 +2948,7 @@ public partial class Extensions private ExtensionsVersionExtension[] versionExtensionField; /// - [System.Xml.Serialization.XmlElementAttribute("VersionExtension")] + [System.Xml.Serialization.XmlElement("VersionExtension")] public ExtensionsVersionExtension[] VersionExtension { get => this.versionExtensionField; @@ -2955,11 +2957,11 @@ public partial class Extensions } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities.CellInstances", IsNullable = false)] public partial class Components { @@ -2967,7 +2969,7 @@ public partial class Components private ComponentsCellComponent[] cellComponentField; /// - [System.Xml.Serialization.XmlElementAttribute("CellComponent")] + [System.Xml.Serialization.XmlElement("CellComponent")] public ComponentsCellComponent[] CellComponent { get => this.cellComponentField; @@ -2976,17 +2978,17 @@ public partial class Components } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA", IsNullable = false)] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA")] +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.EDA", IsNullable = false)] public partial class TraceSourcePrimaryPriorities { private TraceSourcePrimaryPrioritiesConnection[] connectionField; /// - [System.Xml.Serialization.XmlElementAttribute("Connection")] + [System.Xml.Serialization.XmlElement("Connection")] public TraceSourcePrimaryPrioritiesConnection[] Connection { get => this.connectionField; @@ -2995,11 +2997,11 @@ public partial class TraceSourcePrimaryPriorities } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.CellInstances", IsNullable = false)] public partial class ConnectionSettings { @@ -3009,7 +3011,7 @@ public partial class ConnectionSettings private string idField; /// - [System.Xml.Serialization.XmlElementAttribute("Setting", Namespace = "http://schemas.datacontract.org/2004/07/Ifx.ManagementInterfaceIfx.Common.Connect" + + [System.Xml.Serialization.XmlElement("Setting", Namespace = "http://schemas.datacontract.org/2004/07/Ifx.ManagementInterfaceIfx.Common.Connect" + "ionSettings")] public Setting[] Setting { @@ -3018,7 +3020,7 @@ public partial class ConnectionSettings } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -3027,11 +3029,11 @@ public partial class ConnectionSettings } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Ifx.ManagementInterfaceIfx.Common.Connect" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Ifx.ManagementInterfaceIfx.Common.Connect" + "ionSettings")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Ifx.ManagementInterfaceIfx.Common.Connect" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Ifx.ManagementInterfaceIfx.Common.Connect" + "ionSettings", IsNullable = false)] public partial class Setting { diff --git a/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/ConfigurationData.cs b/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/ConfigurationData.cs index 40e7492..6fe43f6 100644 --- a/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/ConfigurationData.cs +++ b/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/ConfigurationData.cs @@ -1,6 +1,6 @@ using System.Xml.Serialization; -namespace Shared.PasteSpecialXml.EAF.XML.API.ConfigurationData; +namespace Adaptation._Tests.Shared.PasteSpecialXml.EAF.XML.API.ConfigurationData; [XmlRoot(ElementName = "ChildBackboneMembers", Namespace = "http://schemas.datacontract.org/2004/07/EafManagement.Configuration.Services")] public class ChildBackboneMembers diff --git a/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/EquipmentDictionary.cs b/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/EquipmentDictionary.cs index e54c13c..040401c 100644 --- a/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/EquipmentDictionary.cs +++ b/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/EquipmentDictionary.cs @@ -1,12 +1,14 @@ -namespace Shared.PasteSpecialXml.EAF.XML.API.EquipmentDictionary; +using System; + +namespace Adaptation._Tests.Shared.PasteSpecialXml.EAF.XML.API.EquipmentDictionary; // NOTE: Generated code may require at least .NET Framework 4.5 or .NET Core/Standard 2.0. /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization", IsNullable = false)] public partial class EquipmentDictionaryVersion { @@ -17,7 +19,7 @@ public partial class EquipmentDictionaryVersion private string createdByField; - private System.DateTime creationDateField; + private DateTime creationDateField; private EquipmentDictionaryVersionDataItems dataItemsField; @@ -29,7 +31,7 @@ public partial class EquipmentDictionaryVersion private EquipmentDictionaryVersionEvents eventsField; - private System.DateTime freezeDateField; + private DateTime freezeDateField; private object frozenByField; @@ -43,7 +45,7 @@ public partial class EquipmentDictionaryVersion private EquipmentDictionaryVersionReports reportsField; - private System.DateTime retireDateField; + private DateTime retireDateField; private object retiredByField; @@ -68,7 +70,7 @@ public partial class EquipmentDictionaryVersion } /// - public System.DateTime CreationDate + public DateTime CreationDate { get => this.creationDateField; set => this.creationDateField = value; @@ -110,7 +112,7 @@ public partial class EquipmentDictionaryVersion } /// - public System.DateTime FreezeDate + public DateTime FreezeDate { get => this.freezeDateField; set => this.freezeDateField = value; @@ -159,7 +161,7 @@ public partial class EquipmentDictionaryVersion } /// - public System.DateTime RetireDate + public DateTime RetireDate { get => this.retireDateField; set => this.retireDateField = value; @@ -187,7 +189,7 @@ public partial class EquipmentDictionaryVersion } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -196,9 +198,9 @@ public partial class EquipmentDictionaryVersion } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionAlarms { @@ -208,7 +210,7 @@ public partial class EquipmentDictionaryVersionAlarms private string idField; /// - [System.Xml.Serialization.XmlElementAttribute("Alarm")] + [System.Xml.Serialization.XmlElement("Alarm")] public EquipmentDictionaryVersionAlarmsAlarm[] Alarm { get => this.alarmField; @@ -216,7 +218,7 @@ public partial class EquipmentDictionaryVersionAlarms } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -225,9 +227,9 @@ public partial class EquipmentDictionaryVersionAlarms } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionAlarmsAlarm { @@ -281,7 +283,7 @@ public partial class EquipmentDictionaryVersionAlarmsAlarm } /// - [System.Xml.Serialization.XmlIgnoreAttribute()] + [System.Xml.Serialization.XmlIgnore()] public bool IsVirtualSpecified { get => this.isVirtualFieldSpecified; @@ -317,7 +319,7 @@ public partial class EquipmentDictionaryVersionAlarmsAlarm } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -326,9 +328,9 @@ public partial class EquipmentDictionaryVersionAlarmsAlarm } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionDataItems { @@ -338,7 +340,7 @@ public partial class EquipmentDictionaryVersionDataItems private string idField; /// - [System.Xml.Serialization.XmlElementAttribute("Item")] + [System.Xml.Serialization.XmlElement("Item")] public EquipmentDictionaryVersionDataItemsItem[] Item { get => this.itemField; @@ -346,7 +348,7 @@ public partial class EquipmentDictionaryVersionDataItems } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -355,9 +357,9 @@ public partial class EquipmentDictionaryVersionDataItems } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionDataItemsItem { @@ -428,7 +430,7 @@ public partial class EquipmentDictionaryVersionDataItemsItem } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -437,9 +439,9 @@ public partial class EquipmentDictionaryVersionDataItemsItem } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionEquipmentSettings { @@ -449,7 +451,7 @@ public partial class EquipmentDictionaryVersionEquipmentSettings private string idField; /// - [System.Xml.Serialization.XmlElementAttribute("Setting")] + [System.Xml.Serialization.XmlElement("Setting")] public EquipmentDictionaryVersionEquipmentSettingsSetting[] Setting { get => this.settingField; @@ -457,7 +459,7 @@ public partial class EquipmentDictionaryVersionEquipmentSettings } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -466,9 +468,9 @@ public partial class EquipmentDictionaryVersionEquipmentSettings } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionEquipmentSettingsSetting { @@ -490,7 +492,7 @@ public partial class EquipmentDictionaryVersionEquipmentSettingsSetting private string idField; /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public object Context { get => this.contextField; @@ -540,7 +542,7 @@ public partial class EquipmentDictionaryVersionEquipmentSettingsSetting } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -549,9 +551,9 @@ public partial class EquipmentDictionaryVersionEquipmentSettingsSetting } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionEvents { @@ -561,7 +563,7 @@ public partial class EquipmentDictionaryVersionEvents private string idField; /// - [System.Xml.Serialization.XmlElementAttribute("Event")] + [System.Xml.Serialization.XmlElement("Event")] public EquipmentDictionaryVersionEventsEvent[] Event { get => this.eventField; @@ -569,7 +571,7 @@ public partial class EquipmentDictionaryVersionEvents } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -578,9 +580,9 @@ public partial class EquipmentDictionaryVersionEvents } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionEventsEvent { @@ -651,7 +653,7 @@ public partial class EquipmentDictionaryVersionEventsEvent } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -660,9 +662,9 @@ public partial class EquipmentDictionaryVersionEventsEvent } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionEventsEventValidDataItems { @@ -670,7 +672,7 @@ public partial class EquipmentDictionaryVersionEventsEventValidDataItems private string idField; /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -679,9 +681,9 @@ public partial class EquipmentDictionaryVersionEventsEventValidDataItems } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionObjectTypes { @@ -691,7 +693,7 @@ public partial class EquipmentDictionaryVersionObjectTypes private string idField; /// - [System.Xml.Serialization.XmlElementAttribute("Type")] + [System.Xml.Serialization.XmlElement("Type")] public EquipmentDictionaryVersionObjectTypesType[] Type { get => this.typeField; @@ -699,7 +701,7 @@ public partial class EquipmentDictionaryVersionObjectTypes } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -708,9 +710,9 @@ public partial class EquipmentDictionaryVersionObjectTypes } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionObjectTypesType { @@ -737,7 +739,7 @@ public partial class EquipmentDictionaryVersionObjectTypesType } /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public object BaseType { get => this.baseTypeField; @@ -773,7 +775,7 @@ public partial class EquipmentDictionaryVersionObjectTypesType } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -782,9 +784,9 @@ public partial class EquipmentDictionaryVersionObjectTypesType } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionObjectTypesTypeAlarms { @@ -792,7 +794,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeAlarms private string idField; /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -801,9 +803,9 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeAlarms } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionObjectTypesTypeDataItems { @@ -813,7 +815,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeDataItems private string idField; /// - [System.Xml.Serialization.XmlElementAttribute("Item")] + [System.Xml.Serialization.XmlElement("Item")] public EquipmentDictionaryVersionObjectTypesTypeDataItemsItem[] Item { get => this.itemField; @@ -821,7 +823,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeDataItems } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -830,9 +832,9 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeDataItems } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionObjectTypesTypeDataItemsItem { @@ -867,7 +869,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeDataItemsItem } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -876,9 +878,9 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeDataItemsItem } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionObjectTypesTypeDataItemsItemEquipmentDataItems { @@ -888,7 +890,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeDataItemsItemEquip private string idField; /// - [System.Xml.Serialization.XmlElementAttribute("Item")] + [System.Xml.Serialization.XmlElement("Item")] public EquipmentDictionaryVersionObjectTypesTypeDataItemsItemEquipmentDataItemsItem[] Item { get => this.itemField; @@ -896,7 +898,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeDataItemsItemEquip } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -905,9 +907,9 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeDataItemsItemEquip } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionObjectTypesTypeDataItemsItemEquipmentDataItemsItem { @@ -915,7 +917,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeDataItemsItemEquip private string refField; /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Ref { get => this.refField; @@ -924,9 +926,9 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeDataItemsItemEquip } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionObjectTypesTypeEvents { @@ -936,7 +938,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeEvents private string idField; /// - [System.Xml.Serialization.XmlElementAttribute("Event")] + [System.Xml.Serialization.XmlElement("Event")] public EquipmentDictionaryVersionObjectTypesTypeEventsEvent[] Event { get => this.eventField; @@ -944,7 +946,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeEvents } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -953,9 +955,9 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeEvents } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionObjectTypesTypeEventsEvent { @@ -990,7 +992,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeEventsEvent } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -999,9 +1001,9 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeEventsEvent } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionObjectTypesTypeEventsEventEquipmentEvents { @@ -1018,7 +1020,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeEventsEventEquipme } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -1027,9 +1029,9 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeEventsEventEquipme } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionObjectTypesTypeEventsEventEquipmentEventsEvent { @@ -1037,7 +1039,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeEventsEventEquipme private string refField; /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Ref { get => this.refField; @@ -1046,9 +1048,9 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeEventsEventEquipme } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionObjectTypesTypeSettings { @@ -1056,7 +1058,7 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeSettings private string idField; /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -1065,9 +1067,9 @@ public partial class EquipmentDictionaryVersionObjectTypesTypeSettings } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionReports { @@ -1077,7 +1079,7 @@ public partial class EquipmentDictionaryVersionReports private string idField; /// - [System.Xml.Serialization.XmlElementAttribute("Report")] + [System.Xml.Serialization.XmlElement("Report")] public EquipmentDictionaryVersionReportsReport[] Report { get => this.reportField; @@ -1085,7 +1087,7 @@ public partial class EquipmentDictionaryVersionReports } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -1094,9 +1096,9 @@ public partial class EquipmentDictionaryVersionReports } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionReportsReport { @@ -1158,7 +1160,7 @@ public partial class EquipmentDictionaryVersionReportsReport } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -1167,9 +1169,9 @@ public partial class EquipmentDictionaryVersionReportsReport } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionReportsReportDataItems { @@ -1179,7 +1181,7 @@ public partial class EquipmentDictionaryVersionReportsReportDataItems private string idField; /// - [System.Xml.Serialization.XmlElementAttribute("Item")] + [System.Xml.Serialization.XmlElement("Item")] public EquipmentDictionaryVersionReportsReportDataItemsItem[] Item { get => this.itemField; @@ -1187,7 +1189,7 @@ public partial class EquipmentDictionaryVersionReportsReportDataItems } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -1196,9 +1198,9 @@ public partial class EquipmentDictionaryVersionReportsReportDataItems } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionReportsReportDataItemsItem { @@ -1206,7 +1208,7 @@ public partial class EquipmentDictionaryVersionReportsReportDataItemsItem private string refField; /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Ref { get => this.refField; @@ -1215,9 +1217,9 @@ public partial class EquipmentDictionaryVersionReportsReportDataItemsItem } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionReportsReportLinkEvents { @@ -1227,7 +1229,7 @@ public partial class EquipmentDictionaryVersionReportsReportLinkEvents private string idField; /// - [System.Xml.Serialization.XmlElementAttribute("Event")] + [System.Xml.Serialization.XmlElement("Event")] public EquipmentDictionaryVersionReportsReportLinkEventsEvent[] Event { get => this.eventField; @@ -1235,7 +1237,7 @@ public partial class EquipmentDictionaryVersionReportsReportLinkEvents } /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -1244,9 +1246,9 @@ public partial class EquipmentDictionaryVersionReportsReportLinkEvents } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionReportsReportLinkEventsEvent { @@ -1254,7 +1256,7 @@ public partial class EquipmentDictionaryVersionReportsReportLinkEventsEvent private string refField; /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Ref { get => this.refField; @@ -1263,9 +1265,9 @@ public partial class EquipmentDictionaryVersionReportsReportLinkEventsEvent } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionReportsReportPreLinkedEvents { @@ -1273,7 +1275,7 @@ public partial class EquipmentDictionaryVersionReportsReportPreLinkedEvents private string idField; /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -1282,9 +1284,9 @@ public partial class EquipmentDictionaryVersionReportsReportPreLinkedEvents } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Equipmen" + "tCharacterization")] public partial class EquipmentDictionaryVersionValidityMapDataItemToEvent { diff --git a/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/EquipmentType.cs b/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/EquipmentType.cs index c5efa45..ae223c9 100644 --- a/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/EquipmentType.cs +++ b/Adaptation/_Tests/Shared/PasteSpecialXml/EAF XML API/EquipmentType.cs @@ -1,11 +1,13 @@ -namespace Shared.PasteSpecialXml.EAF.XML.API.EquipmentType; +using System; + +namespace Adaptation._Tests.Shared.PasteSpecialXml.EAF.XML.API.EquipmentType; // NOTE: Generated code may require at least .NET Framework 4.5 or .NET Core/Standard 2.0. /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities", IsNullable = false)] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities", IsNullable = false)] public partial class EquipmentTypeVersion { @@ -13,13 +15,13 @@ public partial class EquipmentTypeVersion private string createdByField; - private System.DateTime creationDateField; + private DateTime creationDateField; private object descriptionField; private ExtensionsVersionExtension[] extensionsField; - private System.DateTime freezeDateField; + private DateTime freezeDateField; private string frozenByField; @@ -29,7 +31,7 @@ public partial class EquipmentTypeVersion private bool isRetiredField; - private System.DateTime retireDateField; + private DateTime retireDateField; private object retiredByField; @@ -58,7 +60,7 @@ public partial class EquipmentTypeVersion private string i___typeField; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public string CreatedBy { @@ -67,16 +69,16 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] - public System.DateTime CreationDate + public DateTime CreationDate { get => this.creationDateField; set => this.creationDateField = value; } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities", IsNullable = true)] public object Description { @@ -85,9 +87,9 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlArrayAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlArray(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] - [System.Xml.Serialization.XmlArrayItemAttribute("VersionExtension", IsNullable = false)] + [System.Xml.Serialization.XmlArrayItem("VersionExtension", IsNullable = false)] public ExtensionsVersionExtension[] Extensions { get => this.extensionsField; @@ -95,16 +97,16 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] - public System.DateTime FreezeDate + public DateTime FreezeDate { get => this.freezeDateField; set => this.freezeDateField = value; } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public string FrozenBy { @@ -113,7 +115,7 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public byte Id { @@ -122,7 +124,7 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public bool IsFrozen { @@ -131,7 +133,7 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public bool IsRetired { @@ -140,16 +142,16 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] - public System.DateTime RetireDate + public DateTime RetireDate { get => this.retireDateField; set => this.retireDateField = value; } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities", IsNullable = true)] public object RetiredBy { @@ -158,7 +160,7 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlArrayItemAttribute("SelectedDeploymentPackage", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Deployme" + + [System.Xml.Serialization.XmlArrayItem("SelectedDeploymentPackage", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Deployme" + "nt", IsNullable = false)] public SelectedDeploymentPackage[] DeploymentPackages { @@ -188,9 +190,9 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlArrayAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlArray(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes")] - [System.Xml.Serialization.XmlArrayItemAttribute("ParameterizedModelObjectDefinition", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlArrayItem("ParameterizedModelObjectDefinition", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation", IsNullable = false)] public ParameterizedModelObjectDefinition[] EquipmentComponents { @@ -199,9 +201,9 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlArrayAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlArray(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes")] - [System.Xml.Serialization.XmlArrayItemAttribute("EventActionSequenceDefinition", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlArrayItem("EventActionSequenceDefinition", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation", IsNullable = false)] public EventActionSequenceDefinition[] EventActionSequences { @@ -210,7 +212,7 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes")] public object FileCommunicatorObjectTypes { @@ -219,7 +221,7 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes")] public FileConfiguration FileConfiguration { @@ -228,7 +230,7 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes")] public FileHandlerObjectTypes FileHandlerObjectTypes { @@ -237,9 +239,9 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlArrayAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + + [System.Xml.Serialization.XmlArray(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes")] - [System.Xml.Serialization.XmlArrayItemAttribute("ParameterizedModelObjectDefinition", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlArrayItem("ParameterizedModelObjectDefinition", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation", IsNullable = false)] public ParameterizedModelObjectDefinition[] TransientEquipmentObjectTypes { @@ -248,7 +250,7 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -256,7 +258,7 @@ public partial class EquipmentTypeVersion } /// - [System.Xml.Serialization.XmlAttributeAttribute()] + [System.Xml.Serialization.XmlAttribute()] public string i___type { get => this.i___typeField; @@ -265,11 +267,11 @@ public partial class EquipmentTypeVersion } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Deployme" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Deployme" + "nt")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Deployme" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Deployme" + "nt", IsNullable = false)] public partial class SelectedDeploymentPackage { @@ -303,9 +305,9 @@ public partial class SelectedDeploymentPackage } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] public partial class ExtensionsVersionExtension { @@ -330,7 +332,7 @@ public partial class ExtensionsVersionExtension } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Backbone" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Backbone" + "s")] public string ClassName { @@ -339,7 +341,7 @@ public partial class ExtensionsVersionExtension } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Backbone" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Backbone" + "s", IsNullable = true)] public object Configuration { @@ -348,7 +350,7 @@ public partial class ExtensionsVersionExtension } /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Backbone" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.Backbone" + "s")] public string Name { @@ -357,7 +359,7 @@ public partial class ExtensionsVersionExtension } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -365,7 +367,7 @@ public partial class ExtensionsVersionExtension } /// - [System.Xml.Serialization.XmlAttributeAttribute()] + [System.Xml.Serialization.XmlAttribute()] public string i___type { get => this.i___typeField; @@ -374,9 +376,9 @@ public partial class ExtensionsVersionExtension } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public partial class EquipmentTypeVersionDictionaries { @@ -391,9 +393,9 @@ public partial class EquipmentTypeVersionDictionaries } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public partial class EquipmentTypeVersionDictionariesEquipmentTypeDictionaryReference { @@ -427,7 +429,7 @@ public partial class EquipmentTypeVersionDictionariesEquipmentTypeDictionaryRefe } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -436,9 +438,9 @@ public partial class EquipmentTypeVersionDictionariesEquipmentTypeDictionaryRefe } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.FactoryEntities")] public partial class EquipmentTypeVersionParentType { @@ -463,7 +465,7 @@ public partial class EquipmentTypeVersionParentType } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -472,11 +474,11 @@ public partial class EquipmentTypeVersionParentType } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation", IsNullable = false)] public partial class ParameterizedModelObjectDefinition { @@ -506,7 +508,7 @@ public partial class ParameterizedModelObjectDefinition } /// - [System.Xml.Serialization.XmlArrayItemAttribute("ModelObjectParameterDefinition", IsNullable = false)] + [System.Xml.Serialization.XmlArrayItem("ModelObjectParameterDefinition", IsNullable = false)] public ParameterizedModelObjectDefinitionModelObjectParameterDefinition[] Parameters { get => this.parametersField; @@ -521,7 +523,7 @@ public partial class ParameterizedModelObjectDefinition } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -530,9 +532,9 @@ public partial class ParameterizedModelObjectDefinition } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public partial class ParameterizedModelObjectDefinitionModelObjectParameterDefinition { @@ -550,7 +552,7 @@ public partial class ParameterizedModelObjectDefinitionModelObjectParameterDefin private string id1Field; /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public string EnumType { get => this.enumTypeField; @@ -586,7 +588,7 @@ public partial class ParameterizedModelObjectDefinitionModelObjectParameterDefin } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -595,11 +597,11 @@ public partial class ParameterizedModelObjectDefinitionModelObjectParameterDefin } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation", IsNullable = false)] public partial class EventActionSequenceDefinition { @@ -615,7 +617,7 @@ public partial class EventActionSequenceDefinition private string id1Field; /// - [System.Xml.Serialization.XmlArrayItemAttribute("EventActionParameterDefinition", IsNullable = false)] + [System.Xml.Serialization.XmlArrayItem("EventActionParameterDefinition", IsNullable = false)] public EventActionSequenceDefinitionEventActionParameterDefinition[] Actions { get => this.actionsField; @@ -644,7 +646,7 @@ public partial class EventActionSequenceDefinition } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -653,11 +655,11 @@ public partial class EventActionSequenceDefinition } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes", IsNullable = false)] public class FileConfiguration { @@ -665,7 +667,7 @@ public class FileConfiguration private string idField; /// - [System.Xml.Serialization.XmlAttributeAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute(Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id { get => this.idField; @@ -674,11 +676,11 @@ public class FileConfiguration } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes", IsNullable = false)] public class FileHandlerObjectTypes { @@ -686,7 +688,7 @@ public class FileHandlerObjectTypes private ParameterizedModelObjectDefinition parameterizedModelObjectDefinitionField; /// - [System.Xml.Serialization.XmlElementAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public ParameterizedModelObjectDefinition ParameterizedModelObjectDefinition { @@ -696,11 +698,11 @@ public class FileHandlerObjectTypes } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.FactoryE" + "ntities", IsNullable = false)] public partial class Extensions { @@ -708,7 +710,7 @@ public partial class Extensions private ExtensionsVersionExtension[] versionExtensionField; /// - [System.Xml.Serialization.XmlElementAttribute("VersionExtension")] + [System.Xml.Serialization.XmlElement("VersionExtension")] public ExtensionsVersionExtension[] VersionExtension { get => this.versionExtensionField; @@ -717,11 +719,11 @@ public partial class Extensions } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes", IsNullable = false)] public partial class EquipmentComponents { @@ -729,7 +731,7 @@ public partial class EquipmentComponents private ParameterizedModelObjectDefinition[] parameterizedModelObjectDefinitionField; /// - [System.Xml.Serialization.XmlElementAttribute("ParameterizedModelObjectDefinition", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement("ParameterizedModelObjectDefinition", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public ParameterizedModelObjectDefinition[] ParameterizedModelObjectDefinition { @@ -739,11 +741,11 @@ public partial class EquipmentComponents } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes", IsNullable = false)] public partial class EventActionSequences { @@ -751,7 +753,7 @@ public partial class EventActionSequences private EventActionSequenceDefinition[] eventActionSequenceDefinitionField; /// - [System.Xml.Serialization.XmlElementAttribute("EventActionSequenceDefinition", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement("EventActionSequenceDefinition", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public EventActionSequenceDefinition[] EventActionSequenceDefinition { @@ -761,11 +763,11 @@ public partial class EventActionSequences } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes")] -[System.Xml.Serialization.XmlRootAttribute(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + +[System.Xml.Serialization.XmlRoot(Namespace = "http://schemas.datacontract.org/2004/07/EafRuntimeIfx.ManagementInterfaceIfx.File" + "Connector.EquipmentTypes", IsNullable = false)] public partial class TransientEquipmentObjectTypes { @@ -773,7 +775,7 @@ public partial class TransientEquipmentObjectTypes private ParameterizedModelObjectDefinition[] parameterizedModelObjectDefinitionField; /// - [System.Xml.Serialization.XmlElementAttribute("ParameterizedModelObjectDefinition", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + + [System.Xml.Serialization.XmlElement("ParameterizedModelObjectDefinition", Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public ParameterizedModelObjectDefinition[] ParameterizedModelObjectDefinition { @@ -783,9 +785,9 @@ public partial class TransientEquipmentObjectTypes } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public partial class EventActionSequenceDefinitionEventActionParameterDefinition { @@ -810,7 +812,7 @@ public partial class EventActionSequenceDefinitionEventActionParameterDefinition } /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public object Name { get => this.nameField; @@ -818,7 +820,7 @@ public partial class EventActionSequenceDefinitionEventActionParameterDefinition } /// - [System.Xml.Serialization.XmlArrayItemAttribute("ModelObjectParameterDefinition", IsNullable = false)] + [System.Xml.Serialization.XmlArrayItem("ModelObjectParameterDefinition", IsNullable = false)] public EventActionSequenceDefinitionEventActionParameterDefinitionModelObjectParameterDefinition[] Parameters { get => this.parametersField; @@ -840,7 +842,7 @@ public partial class EventActionSequenceDefinitionEventActionParameterDefinition } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; @@ -849,9 +851,9 @@ public partial class EventActionSequenceDefinitionEventActionParameterDefinition } /// -[System.SerializableAttribute()] -[System.ComponentModel.DesignerCategoryAttribute("code")] -[System.Xml.Serialization.XmlTypeAttribute(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + +[Serializable()] +[System.ComponentModel.DesignerCategory("code")] +[System.Xml.Serialization.XmlType(AnonymousType = true, Namespace = "http://schemas.datacontract.org/2004/07/Eaf.Management.ConfigurationData.CellAuto" + "mation")] public partial class EventActionSequenceDefinitionEventActionParameterDefinitionModelObjectParameterDefinition { @@ -879,7 +881,7 @@ public partial class EventActionSequenceDefinitionEventActionParameterDefinition private string id1Field; /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public object Category { get => this.categoryField; @@ -887,7 +889,7 @@ public partial class EventActionSequenceDefinitionEventActionParameterDefinition } /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public object Description { get => this.descriptionField; @@ -895,7 +897,7 @@ public partial class EventActionSequenceDefinitionEventActionParameterDefinition } /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public object DisplayName { get => this.displayNameField; @@ -903,7 +905,7 @@ public partial class EventActionSequenceDefinitionEventActionParameterDefinition } /// - [System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] + [System.Xml.Serialization.XmlElement(IsNullable = true)] public object EnumType { get => this.enumTypeField; @@ -953,7 +955,7 @@ public partial class EventActionSequenceDefinitionEventActionParameterDefinition } /// - [System.Xml.Serialization.XmlAttributeAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] + [System.Xml.Serialization.XmlAttribute("Id", Form = System.Xml.Schema.XmlSchemaForm.Qualified, Namespace = "http://schemas.microsoft.com/2003/10/Serialization/")] public string Id1 { get => this.id1Field; diff --git a/Adaptation/_Tests/Shared/UnitTesting.cs b/Adaptation/_Tests/Shared/UnitTesting.cs index 161de0c..3477030 100644 --- a/Adaptation/_Tests/Shared/UnitTesting.cs +++ b/Adaptation/_Tests/Shared/UnitTesting.cs @@ -8,7 +8,7 @@ using System.Text; using System.Text.Json; using System.Threading; -namespace Shared; +namespace Adaptation._Tests.Shared; public class UnitTesting { diff --git a/Adaptation/package.json b/Adaptation/package.json index a57542e..366bc59 100644 --- a/Adaptation/package.json +++ b/Adaptation/package.json @@ -1,27 +1,32 @@ { "scripts": { "Alpha": "ABCDEFGHIJKLMNOPQRSTUVWXYZ", + "nuget-clear": "dotnet nuget locals all --clear", "build": "dotnet build --runtime win-x64 --self-contained", + "build-Package-Management": "dotnet build --runtime win-x64 --self-contained --source https://packagemanagement.eu.infineon.com:4430/api/v2/", + "build-nuget-And-Package-Management": "dotnet build --runtime win-x64 --self-contained --source https://api.nuget.org/v3/index.json --source https://packagemanagement.eu.infineon.com:4430/api/v2/", + "build-All-Sources": "dotnet build --runtime win-x64 --self-contained --source https://api.nuget.org/v3/index.json --source https://packagemanagement.eu.infineon.com:4430/api/v2/ --source https://tfs.intra.infineon.com/tfs/ManufacturingIT/_packaging/eaf/nuget/v3/index.json --source http://192.168.0.73:5002/v3/index.json", "dotnet-format": "dotnet format --report .vscode --verbosity detailed --severity warn", + "MSBuild": "\"C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe\" /target:Build /restore:True /p:RestoreSources=https://api.nuget.org/v3/index.json%3Bhttps://packagemanagement.eu.infineon.com:4430/api/v2/%3Bhttps://tfs.intra.infineon.com/tfs/ManufacturingIT/_packaging/eaf/nuget/v3/index.json /detailedsummary /consoleloggerparameters:PerformanceSummary;ErrorsOnly; /property:Configuration=Debug;TargetFrameworkVersion=v4.8 ../MET08DDUPSFS6420.csproj", "pull": "git pull", "garbage-collect": "git gc", - "AA-CreateSelfDescription.Staging.v2_39_0-TENCOR3_EQPT-Staging__v2_39_0__TENCOR3_EQPT__DownloadRsMFile": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.CreateSelfDescription.Staging.v2_39_0 & ClassName~TENCOR3_EQPT & Staging__v2_39_0__TENCOR3_EQPT__DownloadRsMFile\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "AT-CreateSelfDescription.Staging.v2_39_0-MET08DDUPSFS6420": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.CreateSelfDescription.Staging.v2_39_0 & ClassName~MET08DDUPSFS6420\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "AV-CreateSelfDescription.Staging.v2_39_0-TENCOR1_EQPT": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.CreateSelfDescription.Staging.v2_39_0 & ClassName~TENCOR1_EQPT\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "AW-CreateSelfDescription.Staging.v2_39_0-TENCOR1": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.CreateSelfDescription.Staging.v2_39_0 & ClassName~TENCOR1\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "AV-CreateSelfDescription.Staging.v2_39_0-TENCOR2_EQPT": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.CreateSelfDescription.Staging.v2_39_0 & ClassName~TENCOR2_EQPT\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "AW-CreateSelfDescription.Staging.v2_39_0-TENCOR2": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.CreateSelfDescription.Staging.v2_39_0 & ClassName~TENCOR2\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "AX-CreateSelfDescription.Staging.v2_39_0-TENCOR3_EQPT": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.CreateSelfDescription.Staging.v2_39_0 & ClassName~TENCOR3_EQPT\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "AY-CreateSelfDescription.Staging.v2_39_0-TENCOR3": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.CreateSelfDescription.Staging.v2_39_0 & ClassName~TENCOR3\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "AZ-CreateSelfDescription.Staging.v2_39_0": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.CreateSelfDescription.Staging.v2_39_0\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "BA-Extract.Staging.v2_39_0-TENCOR1-Staging__v2_36_3__TENCOR1__MET08DDUPSFS6420": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.Extract.Staging.v2_36_3 & ClassName~TENCOR1 & Staging__v2_36_3__TENCOR1__MET08DDUPSFS6420637810124350899080__Normal\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "BT-Extract.Staging.v2_39_0-MET08DDUPSFS6420": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.Extract.Staging.v2_39_0 & ClassName~MET08DDUPSFS6420\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "BV-Extract.Staging.v2_39_0-TENCOR1_EQPT": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.Extract.Staging.v2_39_0 & ClassName~TENCOR1_EQPT\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "BW-Extract.Staging.v2_39_0-TENCOR1": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.Extract.Staging.v2_39_0 & ClassName~TENCOR1\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "BV-Extract.Staging.v2_39_0-TENCOR2_EQPT": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.Extract.Staging.v2_39_0 & ClassName~TENCOR2_EQPT\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "BW-Extract.Staging.v2_39_0-TENCOR2": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.Extract.Staging.v2_39_0 & ClassName~TENCOR2\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "BX-Extract.Staging.v2_39_0-TENCOR3_EQPT": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.Extract.Staging.v2_39_0 & ClassName~TENCOR3_EQPT\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "BY-Extract.Staging.v2_39_0-TENCOR3": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.Extract.Staging.v2_39_0 & ClassName~TENCOR3\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", - "BZ-Extract.Staging.v2_39_0": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~_Tests.Extract.Staging.v2_39_0\" --% -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")" + "AA-CreateSelfDescription.Staging.v2_43_0-TENCOR3_EQPT-Staging__v2_43_0__TENCOR3_EQPT__DownloadRsMFile": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0 & ClassName~TENCOR3_EQPT & Name~Staging__v2_43_0__TENCOR3_EQPT__DownloadRsMFile\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "AT-CreateSelfDescription.Staging.v2_43_0-MET08DDUPSFS6420": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0 & ClassName~MET08DDUPSFS6420\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "AV-CreateSelfDescription.Staging.v2_43_0-TENCOR1_EQPT": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0 & ClassName~TENCOR1_EQPT\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "AW-CreateSelfDescription.Staging.v2_43_0-TENCOR1": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0 & ClassName~TENCOR1\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "AV-CreateSelfDescription.Staging.v2_43_0-TENCOR2_EQPT": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0 & ClassName~TENCOR2_EQPT\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "AW-CreateSelfDescription.Staging.v2_43_0-TENCOR2": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0 & ClassName~TENCOR2\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "AX-CreateSelfDescription.Staging.v2_43_0-TENCOR3_EQPT": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0 & ClassName~TENCOR3_EQPT\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "AY-CreateSelfDescription.Staging.v2_43_0-TENCOR3": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0 & ClassName~TENCOR3\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "AZ-CreateSelfDescription.Staging.v2_43_0": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.CreateSelfDescription.Staging.v2_43_0\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "BA-Extract.Staging.v2_43_0-TENCOR1-Staging__v2_36_3__TENCOR1__MET08DDUPSFS6420": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.Extract.Staging.v2_36_3 & ClassName~TENCOR1 & Name~Staging__v2_36_3__TENCOR1__MET08DDUPSFS6420637810124350899080__Normal\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "BT-Extract.Staging.v2_43_0-MET08DDUPSFS6420": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.Extract.Staging.v2_43_0 & ClassName~MET08DDUPSFS6420\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "BV-Extract.Staging.v2_43_0-TENCOR1_EQPT": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.Extract.Staging.v2_43_0 & ClassName~TENCOR1_EQPT\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "BW-Extract.Staging.v2_43_0-TENCOR1": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.Extract.Staging.v2_43_0 & ClassName~TENCOR1\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "BV-Extract.Staging.v2_43_0-TENCOR2_EQPT": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.Extract.Staging.v2_43_0 & ClassName~TENCOR2_EQPT\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "BW-Extract.Staging.v2_43_0-TENCOR2": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.Extract.Staging.v2_43_0 & ClassName~TENCOR2\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "BX-Extract.Staging.v2_43_0-TENCOR3_EQPT": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.Extract.Staging.v2_43_0 & ClassName~TENCOR3_EQPT\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "BY-Extract.Staging.v2_43_0-TENCOR3": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.Extract.Staging.v2_43_0 & ClassName~TENCOR3\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")", + "BZ-Extract.Staging.v2_43_0": "dotnet test --runtime win-x64 --no-build --filter \"FullyQualifiedName~Adaptation._Tests.Extract.Staging.v2_43_0\" -- TestRunParameters.Parameter(name=\\\"Debug\\\", value=\\\"Debugger.IsAttached\\\")" } } \ No newline at end of file diff --git a/FileHandlers/FileRead.cs b/FileHandlers/FileRead.cs index 19b374b..7605403 100644 --- a/FileHandlers/FileRead.cs +++ b/FileHandlers/FileRead.cs @@ -37,8 +37,13 @@ public partial class FileRead : FileReaderHandler, ISMTP private FilePathGenerator _FilePathGeneratorForTarget; private readonly List _EquipmentParameters; private static readonly Dictionary> _DummyRuns; + private static readonly Dictionary> _StaticRuns; - static FileRead() => _DummyRuns = new Dictionary>(); + static FileRead() + { + _DummyRuns = new(); + _StaticRuns = new(); + } public FileRead() { @@ -192,7 +197,7 @@ public partial class FileRead : FileReaderHandler, ISMTP FileConnectorConfiguration fileConnectorConfiguration = Mapper.Map(Configuration); string parameterizedModelObjectDefinitionType = methodBase.DeclaringType.FullName; IList modelObjectParameters = Mapper.Map(ConfiguredParameters); - _FileRead = CellInstanceConnectionName.Get(this, FileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, _DummyRuns, _UseCyclicalForDescription, isEAFHosted: true); + _FileRead = CellInstanceConnectionName.Get(this, FileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, _DummyRuns, _StaticRuns, _UseCyclicalForDescription, isEAFHosted: true); if (_FileRead.IsEvent) AddParameterRangeAndEvent(); } @@ -333,7 +338,7 @@ public partial class FileRead : FileReaderHandler, ISMTP if (modelObjectParameterDefinitionJsonElement.ValueKind != JsonValueKind.Array) throw new Exception(); IList modelObjectParameters = JsonSerializer.Deserialize>(modelObjectParameterDefinitionJsonElement.ToString(), jsonSerializerOptions); - _FileRead = CellInstanceConnectionName.Get(this, FileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, _DummyRuns, _UseCyclicalForDescription, isEAFHosted: false); + _FileRead = CellInstanceConnectionName.Get(this, FileParameter, cellInstanceName, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, _DummyRuns, _StaticRuns, _UseCyclicalForDescription, isEAFHosted: false); results = _FileRead.ReExtract(); if (results?.Item2 is null) throw new Exception(); diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 0000000..442c4ef --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,172 @@ +#!/usr/bin/env groovy +/* groovylint-disable CompileStatic, ConsecutiveStringConcatenation, DuplicateNumberLiteral, DuplicateStringLiteral, LineLength, NestedBlockDepth, NoDef, VariableTypeRequired */ +import groovy.transform.Field + +@Field String _DDrive = 'D:/' +@Field String _AssemblyName = '...' +@Field String _TargetLocation = '...' +@Field String _GitCommitSeven = '...' +@Field String _GitName = 'MET08DDUPSFS6420' +@Field String _TestProjectDirectory = 'Adaptation' +@Field String _AgentStaging = 'mestsa07ec-ecmeseaf' +@Field String _DDriveNet = "${_DDrive}Framework4.8" +@Field String _AgentProduction = 'messa08ec-ecmeseaf' +@Field String _AgentDevelopment = 'mestsa003-mesedasvc' +@Field String _ProgramFilesDotnet = 'C:/Program Files/dotnet/dotnet.exe' +@Field String _ProgramFilesMSBuild = 'C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/MSBuild/Current/Bin/MSBuild.exe' + +pipeline { + agent { + label env.JENKINS_ENVIRONMENT == 'Development' ? _AgentDevelopment : env.JENKINS_ENVIRONMENT == 'Staging' ? _AgentStaging : env.JENKINS_ENVIRONMENT == 'Production' ? _AgentProduction : 'Else' + } + parameters { + string(name: 'GIT_SERVER', defaultValue: env.JENKINS_ENVIRONMENT == 'Development' ? 'mestsa003.infineon.com' : 'mestsa07ec.ec.local', description: 'git server') + string(name: 'DEFAULT_FILE_SERVER', defaultValue: env.JENKINS_ENVIRONMENT == 'Development' ? 'messv02ecc1_ec_local' : 'messv02ecc1.ec.local', description: 'Default file server...') + } + stages { + // stage('Git') { + // steps { + // bat(returnStatus: true, script: 'git init') + // bat(returnStatus: true, script: 'git remote add origin \\\\' + params.GIT_SERVER + '\\Git\\' + _GitName + '.git') + // bat(returnStatus: true, script: 'git pull origin master') + // } + // } + stage('Setup') { + steps { + script { + _AssemblyName = "${env.JOB_NAME}" + // _GitCommitSeven = '1234567' + _GitCommitSeven = env.GIT_COMMIT.substring(0, 7) + def files = findFiles(glob: '*.csproj') + if (files.length != 1) { + error("Build failed because couldn't find a *.csproj file") + } + echo """ + ${files[0].name} + ${files[0].path} + ${files[0].directory} + ${files[0].length} + ${files[0].lastModified} + """ + _AssemblyName = files[0].name.split('[.]csproj')[0] + _TargetLocation = "\\\\${params.DEFAULT_FILE_SERVER}\\EC_EAFRepository\\${env.JENKINS_ENVIRONMENT}\\DeploymentStorage\\Adaptation_${_AssemblyName}" + } + } + } + stage('Info') { + steps { + echo "_AssemblyName ${_AssemblyName}" // ... + echo "BUILD_NUMBER ${env.BUILD_NUMBER}" // 11 + echo "DEFAULT_FILE_SERVER ${params.DEFAULT_FILE_SERVER}" // 11 + echo "GIT_BRANCH ${env.GIT_BRANCH}" // origin/master + echo "GIT_COMMIT ${env.GIT_COMMIT}" // 73b814069f2cf0173a62a8228815a9bc9ba93c41 + echo "GIT_SERVER ${params.GIT_SERVER}" // ... + echo "GIT_URL ${env.GIT_URL}" // D:\ProgramData\Git\....git + echo "JENKINS_ENVIRONMENT ${env.JENKINS_ENVIRONMENT}" // 11 + echo "JENKINS_URL ${env.JENKINS_URL}" // http://localhost:8080/ + echo "JOB_NAME ${env.JOB_NAME}" // ... + echo "WORKSPACE ${env.WORKSPACE}" // D:\.jenkins\_\... + } + } + // stage('Restore') { + // steps { + // bat(returnStatus: true, script: 'dotnet --info') + // } + // } + stage('Safe storage of app secrets') { + steps { + dir(_TestProjectDirectory) { + bat(returnStatus: true, script: '"' + _ProgramFilesDotnet + '" ' + + 'user-secrets init') + bat(returnStatus: true, script: '"' + _ProgramFilesDotnet + '" ' + + 'user-secrets set "BuildNumber" "' + env.BUILD_NUMBER + '"') + bat(returnStatus: true, script: '"' + _ProgramFilesDotnet + '" ' + + 'user-secrets set "GitCommitSeven" "' + _GitCommitSeven + '"') + bat(returnStatus: true, script: '"' + _ProgramFilesDotnet + '" ' + + 'user-secrets set "Server" "' + params.DEFAULT_FILE_SERVER + '"') + } + } + } + stage('Core Build') { + steps { + echo "Build number is ${currentBuild.number}" + dir(_TestProjectDirectory) { + bat(returnStatus: true, script: '"' + _ProgramFilesDotnet + '" ' + + 'build --runtime win-x64 --self-contained --verbosity quiet') + } + } + } + // stage('Test') { + // options { + // timeout(time: 10, unit: 'MINUTES') + // } + // steps { + // dir(_TestProjectDirectory) { + // bat('dotnet --info') + // } + // } + // } + stage('Framework Build') { + steps { + echo "Build number is ${currentBuild.number}" + bat(returnStatus: true, script: '"' + _ProgramFilesMSBuild + '" ' + + '/target:Restore ' + + '/detailedsummary ' + + '/consoleloggerparameters:PerformanceSummary;ErrorsOnly; ' + + '/property:Configuration=Debug;TargetFrameworkVersion=v4.8 ' + + _AssemblyName + '.csproj') + bat(returnStatus: true, script: '"' + _ProgramFilesMSBuild + '" ' + + '/target:Build ' + + '/detailedsummary ' + + '/consoleloggerparameters:PerformanceSummary;ErrorsOnly; ' + + '/property:Configuration=Debug;TargetFrameworkVersion=v4.8 ' + + _AssemblyName + '.csproj') + } + } + stage('Commit Id') { + steps { + dir('bin/Debug') { + writeFile file: "${_AssemblyName}.txt", text: "${env.GIT_COMMIT}-${env.BUILD_NUMBER}-${env.GIT_URL}" + } + } + } + stage('Package') { + steps { + fileOperations([fileZipOperation(folderPath: 'bin/Debug', outputFolderPath: "${_DDriveNet}/${_GitCommitSeven}-${env.BUILD_NUMBER}-${env.JOB_NAME}-Debug")]) + fileOperations([fileCopyOperation(excludes: '', flattenFiles: true, includes: "${_AssemblyName}*", renameFiles: false, sourceCaptureExpression: '', targetLocation: "${_DDriveNet}/${_GitCommitSeven}-${env.BUILD_NUMBER}-${env.JOB_NAME}-Debug", targetNameExpression: '')]) + } + } + // stage('Force Fail') { + // steps { + // error("Build failed because of this and that..") + // } + // } + stage('Copy Files to: file-share') { + steps { + dir('bin/Debug') { + fileOperations([fileCopyOperation(excludes: '', flattenFiles: true, includes: "${_AssemblyName}*.txt", renameFiles: false, sourceCaptureExpression: '', targetLocation: _TargetLocation, targetNameExpression: '')]) + fileOperations([fileCopyOperation(excludes: '', flattenFiles: true, includes: "${_AssemblyName}*.dll", renameFiles: false, sourceCaptureExpression: '', targetLocation: _TargetLocation, targetNameExpression: '')]) + fileOperations([fileCopyOperation(excludes: '', flattenFiles: true, includes: "${_AssemblyName}*.exe", renameFiles: false, sourceCaptureExpression: '', targetLocation: _TargetLocation, targetNameExpression: '')]) + fileOperations([fileCopyOperation(excludes: '', flattenFiles: true, includes: "${_AssemblyName}*.pdb", renameFiles: false, sourceCaptureExpression: '', targetLocation: _TargetLocation, targetNameExpression: '')]) + } + } + } + } + post { + always { + dir('bin') { + deleteDir() + } + dir('obj') { + deleteDir() + } + dir(_TestProjectDirectory + '/bin') { + deleteDir() + } + dir(_TestProjectDirectory + '/obj') { + deleteDir() + } + cleanWs() + } + } +} diff --git a/MET08DDUPSFS6420.csproj b/MET08DDUPSFS6420.csproj index d05b4ff..8effc36 100644 --- a/MET08DDUPSFS6420.csproj +++ b/MET08DDUPSFS6420.csproj @@ -11,7 +11,10 @@ MET08DDUPSFS6420 MET08DDUPSFS6420 v4.8 + win-x86 512 + + SAK SAK SAK @@ -65,8 +68,8 @@ - + @@ -94,18 +97,22 @@ + - - - - + + + + + + - + + @@ -119,12 +126,18 @@ + + + + + + @@ -136,12 +149,6 @@ - - - - - - @@ -151,13 +158,13 @@ 7.2.4630.5 - 2.39.0 + 2.43.0 1.1.1 - 5.0.1 + 6.0.3 diff --git a/Properties/AssemblyInfo.cs b/Properties/AssemblyInfo.cs index ea37ce6..6ee6d30 100644 --- a/Properties/AssemblyInfo.cs +++ b/Properties/AssemblyInfo.cs @@ -32,5 +32,5 @@ using System.Runtime.InteropServices; // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("2.39.0.0")] -[assembly: AssemblyFileVersion("2.39.0.0")] +[assembly: AssemblyVersion("2.43.0.0")] +[assembly: AssemblyFileVersion("2.43.0.0")]