From 8f566fe7edd050ac3b73588c0e499871e39fccda Mon Sep 17 00:00:00 2001 From: antoineatstariongroup Date: Fri, 16 Jan 2026 09:16:50 +0100 Subject: [PATCH] Fix #50: correct implementation for redefined properties --- .../AssociationDeSerializer.cs | 80 ----- .../DependencyDeSerializer.cs | 40 --- .../EnumerationDefinitionDeSerializer.cs | 20 -- .../FeatureTypingDeSerializer.cs | 114 ------ .../AutoGenDeSerializer/FlowDeSerializer.cs | 160 --------- .../FramedConcernMembershipDeSerializer.cs | 222 ------------ .../LiteralIntegerDeSerializer.cs | 40 --- .../LiteralRationalDeSerializer.cs | 40 --- .../MembershipDeSerializer.cs | 40 --- .../OwningMembershipDeSerializer.cs | 97 ----- .../ReferenceSubsettingDeSerializer.cs | 188 ---------- .../RequirementUsageDeSerializer.cs | 173 --------- .../SelectExpressionDeSerializer.cs | 40 --- .../SubclassificationDeSerializer.cs | 114 ------ .../TextualRepresentationDeSerializer.cs | 20 -- .../AutoGenDeSerializer/UsageDeSerializer.cs | 32 -- .../UML/Core/AutoGenDto/Association.cs | 16 +- .../UML/Core/AutoGenDto/Dependency.cs | 18 +- .../Core/AutoGenDto/EnumerationDefinition.cs | 11 +- .../UML/Core/AutoGenDto/FeatureTyping.cs | 46 ++- .../Expected/UML/Core/AutoGenDto/Flow.cs | 24 +- .../AutoGenDto/FramedConcernMembership.cs | 58 ++- .../UML/Core/AutoGenDto/LiteralInteger.cs | 4 +- .../UML/Core/AutoGenDto/LiteralRational.cs | 4 +- .../UML/Core/AutoGenDto/Membership.cs | 19 +- .../UML/Core/AutoGenDto/OwningMembership.cs | 39 +- .../Core/AutoGenDto/ReferenceSubsetting.cs | 63 +++- .../UML/Core/AutoGenDto/RequirementUsage.cs | 29 +- .../UML/Core/AutoGenDto/SelectExpression.cs | 13 +- .../UML/Core/AutoGenDto/Subclassification.cs | 46 ++- .../Core/AutoGenDto/TextualRepresentation.cs | 2 +- .../Expected/UML/Core/AutoGenDto/Usage.cs | 8 +- .../EnumerationDefinitionFactory.cs | 3 +- .../FramedConcernMembershipFactory.cs | 5 +- .../OwningMembershipFactory.cs | 2 - .../RequirementUsageFactory.cs | 2 - .../SelectExpressionFactory.cs | 3 +- .../AutoGenElementFactory/UsageFactory.cs | 1 - .../UML/Core/AutoGenPoco/AnnotatingElement.cs | 1 + .../UML/Core/AutoGenPoco/Association.cs | 17 +- .../UML/Core/AutoGenPoco/Dependency.cs | 19 +- .../Core/AutoGenPoco/EnumerationDefinition.cs | 12 +- .../Expected/UML/Core/AutoGenPoco/Feature.cs | 1 + .../UML/Core/AutoGenPoco/FeatureTyping.cs | 48 ++- .../Expected/UML/Core/AutoGenPoco/Flow.cs | 25 +- .../AutoGenPoco/FramedConcernMembership.cs | 58 ++- .../UML/Core/AutoGenPoco/LiteralInteger.cs | 5 +- .../UML/Core/AutoGenPoco/LiteralRational.cs | 5 +- .../UML/Core/AutoGenPoco/Membership.cs | 19 +- .../UML/Core/AutoGenPoco/MultiplicityRange.cs | 1 + .../UML/Core/AutoGenPoco/OwningMembership.cs | 39 +- .../Core/AutoGenPoco/ReferenceSubsetting.cs | 68 +++- .../UML/Core/AutoGenPoco/RequirementUsage.cs | 30 +- .../UML/Core/AutoGenPoco/SelectExpression.cs | 14 +- .../UML/Core/AutoGenPoco/Subclassification.cs | 51 ++- .../Core/AutoGenPoco/TextualRepresentation.cs | 3 +- .../Expected/UML/Core/AutoGenPoco/Usage.cs | 9 +- .../AssociationExtensions.cs | 38 -- .../DependencyExtensions.cs | 38 -- .../EnumerationDefinitionExtensions.cs | 7 +- .../FeatureTypingExtensions.cs | 58 --- .../AutoGenPocoExtension/FlowExtensions.cs | 38 -- .../FramedConcernMembershipExtensions.cs | 61 +--- .../MembershipExtensions.cs | 38 -- .../OwningMembershipExtensions.cs | 54 --- .../ReferenceSubsettingExtensions.cs | 78 ---- .../RequirementUsageExtensions.cs | 6 - .../SelectExpressionExtensions.cs | 7 +- .../SubclassificationExtensions.cs | 58 --- .../AutoGenPocoExtension/UsageExtensions.cs | 3 - .../AssociationSerializer.cs | 72 ---- .../AutoGenSerializer/DependencySerializer.cs | 48 --- .../EnumerationDefinitionSerializer.cs | 12 - .../FeatureTypingSerializer.cs | 86 ----- .../Core/AutoGenSerializer/FlowSerializer.cs | 120 ------- .../FramedConcernMembershipSerializer.cs | 105 ------ .../LiteralIntegerSerializer.cs | 24 -- .../LiteralRationalSerializer.cs | 24 -- .../AutoGenSerializer/MembershipSerializer.cs | 48 --- .../OwningMembershipSerializer.cs | 75 ---- .../ReferenceSubsettingSerializer.cs | 124 ------- .../RequirementUsageSerializer.cs | 102 ------ .../SelectExpressionSerializer.cs | 24 -- .../SubclassificationSerializer.cs | 86 ----- .../TextualRepresentationSerializer.cs | 12 - .../Core/AutoGenSerializer/UsageSerializer.cs | 18 - ...reDalPocoExtensionsGeneratorTestFixture.cs | 2 +- ...lCoreDalPocoFactoryGeneratorTestFixture.cs | 2 +- .../Extensions/PropertyExtension.cs | 12 + .../HandleBarHelpers/PropertyHelper.cs | 338 +++++++++++++++--- .../Uml/core-dal-poco-uml-extensions.hbs | 30 +- ...ore-json-dto-deserializer-uml-template.hbs | 2 +- .../core-json-dto-serializer-uml-template.hbs | 4 +- .../Uml/core-poco-class-uml-template.hbs | 1 + .../Uml/core-poco-dal-uml-factory.hbs | 8 +- SysML2.NET.Dal.Tests/AssemblerTestFixture.cs | 18 +- .../AcceptActionUsageFactory.cs | 1 - .../ActionUsageFactory.cs | 1 - .../ActorMembershipFactory.cs | 2 - .../AllocationDefinitionFactory.cs | 3 +- .../AllocationUsageFactory.cs | 1 - .../AnalysisCaseUsageFactory.cs | 1 - .../AssertConstraintUsageFactory.cs | 1 - .../AssignmentActionUsageFactory.cs | 1 - .../AttributeUsageFactory.cs | 1 - .../BindingConnectorAsUsageFactory.cs | 1 - .../CalculationUsageFactory.cs | 1 - .../AutoGenElementFactory/CaseUsageFactory.cs | 1 - .../CollectExpressionFactory.cs | 3 +- .../ConcernDefinitionFactory.cs | 1 - .../ConcernUsageFactory.cs | 2 - .../ConnectionDefinitionFactory.cs | 3 +- .../ConnectionUsageFactory.cs | 1 - .../ConstraintUsageFactory.cs | 1 - .../DecisionNodeFactory.cs | 1 - .../ElementFilterMembershipFactory.cs | 2 - .../EndFeatureMembershipFactory.cs | 2 - .../EnumerationDefinitionFactory.cs | 3 +- .../EnumerationUsageFactory.cs | 1 - .../EventOccurrenceUsageFactory.cs | 1 - .../ExhibitStateUsageFactory.cs | 1 - .../FeatureChainExpressionFactory.cs | 3 +- .../FeatureMembershipFactory.cs | 2 - .../FeatureValueFactory.cs | 2 - .../AutoGenElementFactory/FlowUsageFactory.cs | 1 - .../ForLoopActionUsageFactory.cs | 1 - .../AutoGenElementFactory/ForkNodeFactory.cs | 1 - .../FramedConcernMembershipFactory.cs | 5 +- .../IfActionUsageFactory.cs | 1 - .../IncludeUseCaseUsageFactory.cs | 1 - .../IndexExpressionFactory.cs | 3 +- .../InterfaceDefinitionFactory.cs | 3 +- .../InterfaceUsageFactory.cs | 1 - .../AutoGenElementFactory/ItemUsageFactory.cs | 1 - .../AutoGenElementFactory/JoinNodeFactory.cs | 1 - .../MembershipExposeFactory.cs | 6 +- .../AutoGenElementFactory/MergeNodeFactory.cs | 1 - .../MetadataUsageFactory.cs | 1 - .../NamespaceExposeFactory.cs | 6 +- .../ObjectiveMembershipFactory.cs | 2 - .../OccurrenceUsageFactory.cs | 1 - .../OwningMembershipFactory.cs | 2 - .../ParameterMembershipFactory.cs | 2 - .../AutoGenElementFactory/PartUsageFactory.cs | 1 - .../PerformActionUsageFactory.cs | 1 - .../AutoGenElementFactory/PortUsageFactory.cs | 1 - .../ReferenceUsageFactory.cs | 1 - .../RenderingUsageFactory.cs | 1 - .../RequirementConstraintMembershipFactory.cs | 2 - .../RequirementDefinitionFactory.cs | 1 - .../RequirementUsageFactory.cs | 2 - ...equirementVerificationMembershipFactory.cs | 5 +- .../ResultExpressionMembershipFactory.cs | 2 - .../ReturnParameterMembershipFactory.cs | 2 - .../SatisfyRequirementUsageFactory.cs | 2 - .../SelectExpressionFactory.cs | 3 +- .../SendActionUsageFactory.cs | 1 - .../StakeholderMembershipFactory.cs | 2 - .../StateSubactionMembershipFactory.cs | 2 - .../StateUsageFactory.cs | 1 - .../SubjectMembershipFactory.cs | 2 - .../SuccessionAsUsageFactory.cs | 1 - .../SuccessionFlowUsageFactory.cs | 1 - .../TerminateActionUsageFactory.cs | 1 - .../TransitionFeatureMembershipFactory.cs | 2 - .../TransitionUsageFactory.cs | 1 - .../AutoGenElementFactory/UsageFactory.cs | 1 - .../UseCaseUsageFactory.cs | 1 - .../VariantMembershipFactory.cs | 2 - .../VerificationCaseUsageFactory.cs | 1 - .../ViewRenderingMembershipFactory.cs | 2 - .../AutoGenElementFactory/ViewUsageFactory.cs | 1 - .../ViewpointDefinitionFactory.cs | 1 - .../ViewpointUsageFactory.cs | 2 - .../WhileLoopActionUsageFactory.cs | 1 - .../AcceptActionUsageExtensions.cs | 3 - .../ActionUsageExtensions.cs | 3 - .../ActorMembershipExtensions.cs | 54 --- .../AllocationDefinitionExtensions.cs | 45 +-- .../AllocationUsageExtensions.cs | 41 --- .../AnalysisCaseUsageExtensions.cs | 3 - .../AnnotationExtensions.cs | 38 -- .../AssertConstraintUsageExtensions.cs | 3 - .../AssignmentActionUsageExtensions.cs | 3 - .../AssociationExtensions.cs | 38 -- .../AssociationStructureExtensions.cs | 38 -- .../AttributeUsageExtensions.cs | 3 - .../BindingConnectorAsUsageExtensions.cs | 41 --- .../BindingConnectorExtensions.cs | 38 -- .../CalculationUsageExtensions.cs | 3 - .../CaseUsageExtensions.cs | 3 - .../CollectExpressionExtensions.cs | 7 +- .../ConcernDefinitionExtensions.cs | 3 - .../ConcernUsageExtensions.cs | 6 - .../ConjugatedPortTypingExtensions.cs | 68 ---- .../ConjugationExtensions.cs | 38 -- .../ConnectionDefinitionExtensions.cs | 45 +-- .../ConnectionUsageExtensions.cs | 41 --- .../ConnectorExtensions.cs | 38 -- .../ConstraintUsageExtensions.cs | 3 - .../CrossSubsettingExtensions.cs | 78 ---- .../DecisionNodeExtensions.cs | 3 - .../DependencyExtensions.cs | 38 -- .../DifferencingExtensions.cs | 38 -- .../DisjoiningExtensions.cs | 38 -- .../ElementFilterMembershipExtensions.cs | 54 --- .../EndFeatureMembershipExtensions.cs | 54 --- .../EnumerationDefinitionExtensions.cs | 7 +- .../EnumerationUsageExtensions.cs | 3 - .../EventOccurrenceUsageExtensions.cs | 3 - .../ExhibitStateUsageExtensions.cs | 3 - .../FeatureChainExpressionExtensions.cs | 7 +- .../FeatureChainingExtensions.cs | 38 -- .../FeatureInvertingExtensions.cs | 38 -- .../FeatureMembershipExtensions.cs | 54 --- .../FeatureTypingExtensions.cs | 58 --- .../FeatureValueExtensions.cs | 54 --- .../FlowDefinitionExtensions.cs | 38 -- .../AutoGenPocoExtension/FlowExtensions.cs | 38 -- .../FlowUsageExtensions.cs | 41 --- .../ForLoopActionUsageExtensions.cs | 3 - .../ForkNodeExtensions.cs | 3 - .../FramedConcernMembershipExtensions.cs | 61 +--- .../IfActionUsageExtensions.cs | 3 - .../IncludeUseCaseUsageExtensions.cs | 3 - .../IndexExpressionExtensions.cs | 7 +- .../InteractionExtensions.cs | 38 -- .../InterfaceDefinitionExtensions.cs | 45 +-- .../InterfaceUsageExtensions.cs | 41 --- .../IntersectingExtensions.cs | 38 -- .../ItemUsageExtensions.cs | 3 - .../JoinNodeExtensions.cs | 3 - .../MembershipExposeExtensions.cs | 52 +-- .../MembershipExtensions.cs | 38 -- .../MembershipImportExtensions.cs | 38 -- .../MergeNodeExtensions.cs | 3 - .../MetadataUsageExtensions.cs | 3 - .../NamespaceExposeExtensions.cs | 52 +-- .../NamespaceImportExtensions.cs | 38 -- .../ObjectiveMembershipExtensions.cs | 54 --- .../OccurrenceUsageExtensions.cs | 3 - .../OwningMembershipExtensions.cs | 54 --- .../ParameterMembershipExtensions.cs | 54 --- .../PartUsageExtensions.cs | 3 - .../PerformActionUsageExtensions.cs | 3 - .../PortConjugationExtensions.cs | 48 --- .../PortUsageExtensions.cs | 3 - .../RedefinitionExtensions.cs | 78 ---- .../ReferenceSubsettingExtensions.cs | 78 ---- .../ReferenceUsageExtensions.cs | 3 - .../RenderingUsageExtensions.cs | 3 - ...quirementConstraintMembershipExtensions.cs | 54 --- .../RequirementDefinitionExtensions.cs | 3 - .../RequirementUsageExtensions.cs | 6 - ...irementVerificationMembershipExtensions.cs | 61 +--- .../ResultExpressionMembershipExtensions.cs | 54 --- .../ReturnParameterMembershipExtensions.cs | 54 --- .../SatisfyRequirementUsageExtensions.cs | 6 - .../SelectExpressionExtensions.cs | 7 +- .../SendActionUsageExtensions.cs | 3 - .../SpecializationExtensions.cs | 38 -- .../StakeholderMembershipExtensions.cs | 54 --- .../StateSubactionMembershipExtensions.cs | 54 --- .../StateUsageExtensions.cs | 3 - .../SubclassificationExtensions.cs | 58 --- .../SubjectMembershipExtensions.cs | 54 --- .../SubsettingExtensions.cs | 58 --- .../SuccessionAsUsageExtensions.cs | 41 --- .../SuccessionExtensions.cs | 38 -- .../SuccessionFlowExtensions.cs | 38 -- .../SuccessionFlowUsageExtensions.cs | 41 --- .../TerminateActionUsageExtensions.cs | 3 - .../TransitionFeatureMembershipExtensions.cs | 54 --- .../TransitionUsageExtensions.cs | 3 - .../TypeFeaturingExtensions.cs | 38 -- .../UnioningExtensions.cs | 38 -- .../AutoGenPocoExtension/UsageExtensions.cs | 3 - .../UseCaseUsageExtensions.cs | 3 - .../VariantMembershipExtensions.cs | 54 --- .../VerificationCaseUsageExtensions.cs | 3 - .../ViewRenderingMembershipExtensions.cs | 54 --- .../ViewUsageExtensions.cs | 3 - .../ViewpointDefinitionExtensions.cs | 3 - .../ViewpointUsageExtensions.cs | 6 - .../WhileLoopActionUsageExtensions.cs | 3 - .../AcceptActionUsageDeSerializer.cs | 112 ------ .../ActionDefinitionDeSerializer.cs | 20 -- .../ActionUsageDeSerializer.cs | 112 ------ .../ActorMembershipDeSerializer.cs | 197 ---------- .../AllocationDefinitionDeSerializer.cs | 100 ------ .../AllocationUsageDeSerializer.cs | 172 --------- .../AnalysisCaseDefinitionDeSerializer.cs | 20 -- .../AnalysisCaseUsageDeSerializer.cs | 204 ----------- .../AnnotationDeSerializer.cs | 40 --- .../AssertConstraintUsageDeSerializer.cs | 140 -------- .../AssignmentActionUsageDeSerializer.cs | 112 ------ .../AssociationDeSerializer.cs | 80 ----- .../AssociationStructureDeSerializer.cs | 80 ----- .../AttributeUsageDeSerializer.cs | 52 --- .../BehaviorDeSerializer.cs | 20 -- .../BindingConnectorAsUsageDeSerializer.cs | 112 ------ .../BindingConnectorDeSerializer.cs | 100 ------ .../BooleanExpressionDeSerializer.cs | 64 ---- .../CalculationDefinitionDeSerializer.cs | 20 -- .../CalculationUsageDeSerializer.cs | 156 -------- .../CaseDefinitionDeSerializer.cs | 20 -- .../CaseUsageDeSerializer.cs | 180 ---------- .../CollectExpressionDeSerializer.cs | 40 --- .../ConcernDefinitionDeSerializer.cs | 29 -- .../ConcernUsageDeSerializer.cs | 197 ---------- .../ConjugatedPortDefinitionDeSerializer.cs | 48 --- .../ConjugatedPortTypingDeSerializer.cs | 139 ------- .../ConjugationDeSerializer.cs | 40 --- .../ConnectionDefinitionDeSerializer.cs | 100 ------ .../ConnectionUsageDeSerializer.cs | 152 -------- .../ConnectorDeSerializer.cs | 100 ------ .../ConstraintDefinitionDeSerializer.cs | 20 -- .../ConstraintUsageDeSerializer.cs | 140 -------- .../ConstructorExpressionDeSerializer.cs | 40 --- .../CrossSubsettingDeSerializer.cs | 188 ---------- .../DecisionNodeDeSerializer.cs | 112 ------ .../DependencyDeSerializer.cs | 40 --- .../DifferencingDeSerializer.cs | 40 --- .../DisjoiningDeSerializer.cs | 40 --- .../DocumentationDeSerializer.cs | 20 -- .../ElementFilterMembershipDeSerializer.cs | 122 ------- .../EndFeatureMembershipDeSerializer.cs | 147 -------- .../EnumerationDefinitionDeSerializer.cs | 20 -- .../EnumerationUsageDeSerializer.cs | 72 ---- .../EventOccurrenceUsageDeSerializer.cs | 52 --- .../ExhibitStateUsageDeSerializer.cs | 182 ---------- .../ExpressionDeSerializer.cs | 40 --- .../FeatureChainExpressionDeSerializer.cs | 40 --- .../FeatureChainingDeSerializer.cs | 40 --- .../FeatureInvertingDeSerializer.cs | 40 --- .../FeatureMembershipDeSerializer.cs | 147 -------- .../FeatureReferenceExpressionDeSerializer.cs | 40 --- .../FeatureTypingDeSerializer.cs | 114 ------ .../FeatureValueDeSerializer.cs | 122 ------- .../AutoGenDeSerializer/FlowDeSerializer.cs | 160 --------- .../FlowDefinitionDeSerializer.cs | 120 ------- .../FlowUsageDeSerializer.cs | 252 ------------- .../ForLoopActionUsageDeSerializer.cs | 112 ------ .../ForkNodeDeSerializer.cs | 112 ------ .../FramedConcernMembershipDeSerializer.cs | 222 ------------ .../FunctionDeSerializer.cs | 20 -- .../IfActionUsageDeSerializer.cs | 112 ------ .../IncludeUseCaseUsageDeSerializer.cs | 254 ------------- .../IndexExpressionDeSerializer.cs | 40 --- .../InteractionDeSerializer.cs | 100 ------ .../InterfaceDefinitionDeSerializer.cs | 120 ------- .../InterfaceUsageDeSerializer.cs | 172 --------- .../IntersectingDeSerializer.cs | 40 --- .../InvariantDeSerializer.cs | 64 ---- .../InvocationExpressionDeSerializer.cs | 40 --- .../ItemUsageDeSerializer.cs | 52 --- .../JoinNodeDeSerializer.cs | 112 ------ .../LiteralBooleanDeSerializer.cs | 40 --- .../LiteralExpressionDeSerializer.cs | 40 --- .../LiteralInfinityDeSerializer.cs | 40 --- .../LiteralIntegerDeSerializer.cs | 40 --- .../LiteralRationalDeSerializer.cs | 40 --- .../LiteralStringDeSerializer.cs | 40 --- .../MembershipDeSerializer.cs | 40 --- .../MembershipExposeDeSerializer.cs | 40 --- .../MembershipImportDeSerializer.cs | 40 --- .../MergeNodeDeSerializer.cs | 112 ------ .../MetadataAccessExpressionDeSerializer.cs | 40 --- .../MetadataUsageDeSerializer.cs | 96 ----- .../NamespaceExposeDeSerializer.cs | 40 --- .../NamespaceImportDeSerializer.cs | 40 --- .../NullExpressionDeSerializer.cs | 40 --- .../ObjectiveMembershipDeSerializer.cs | 172 --------- .../OccurrenceUsageDeSerializer.cs | 52 --- .../OperatorExpressionDeSerializer.cs | 40 --- .../OwningMembershipDeSerializer.cs | 97 ----- .../ParameterMembershipDeSerializer.cs | 172 --------- .../PartUsageDeSerializer.cs | 52 --- .../PerformActionUsageDeSerializer.cs | 137 ------- .../PortConjugationDeSerializer.cs | 89 ----- .../PortUsageDeSerializer.cs | 72 ---- .../PredicateDeSerializer.cs | 20 -- .../RedefinitionDeSerializer.cs | 164 --------- .../ReferenceSubsettingDeSerializer.cs | 188 ---------- .../ReferenceUsageDeSerializer.cs | 32 -- .../RenderingUsageDeSerializer.cs | 72 ---- ...irementConstraintMembershipDeSerializer.cs | 172 --------- .../RequirementDefinitionDeSerializer.cs | 29 -- .../RequirementUsageDeSerializer.cs | 173 --------- ...ementVerificationMembershipDeSerializer.cs | 222 ------------ .../ResultExpressionMembershipDeSerializer.cs | 172 --------- .../ReturnParameterMembershipDeSerializer.cs | 172 --------- .../SatisfyRequirementUsageDeSerializer.cs | 198 ---------- .../SelectExpressionDeSerializer.cs | 40 --- .../SendActionUsageDeSerializer.cs | 112 ------ .../SpecializationDeSerializer.cs | 40 --- .../StakeholderMembershipDeSerializer.cs | 197 ---------- .../StateDefinitionDeSerializer.cs | 20 -- .../StateSubactionMembershipDeSerializer.cs | 172 --------- .../StateUsageDeSerializer.cs | 132 ------- .../AutoGenDeSerializer/StepDeSerializer.cs | 20 -- .../SubclassificationDeSerializer.cs | 114 ------ .../SubjectMembershipDeSerializer.cs | 197 ---------- .../SubsettingDeSerializer.cs | 114 ------ .../SuccessionAsUsageDeSerializer.cs | 112 ------ .../SuccessionDeSerializer.cs | 100 ------ .../SuccessionFlowDeSerializer.cs | 160 --------- .../SuccessionFlowUsageDeSerializer.cs | 252 ------------- .../TerminateActionUsageDeSerializer.cs | 112 ------ .../TextualRepresentationDeSerializer.cs | 20 -- ...TransitionFeatureMembershipDeSerializer.cs | 172 --------- .../TransitionUsageDeSerializer.cs | 112 ------ ...TriggerInvocationExpressionDeSerializer.cs | 40 --- .../TypeFeaturingDeSerializer.cs | 40 --- .../UnioningDeSerializer.cs | 40 --- .../AutoGenDeSerializer/UsageDeSerializer.cs | 32 -- .../UseCaseDefinitionDeSerializer.cs | 20 -- .../UseCaseUsageDeSerializer.cs | 204 ----------- .../VariantMembershipDeSerializer.cs | 122 ------- .../VerificationCaseDefinitionDeSerializer.cs | 20 -- .../VerificationCaseUsageDeSerializer.cs | 180 ---------- .../ViewRenderingMembershipDeSerializer.cs | 172 --------- .../ViewUsageDeSerializer.cs | 72 ---- .../ViewpointDefinitionDeSerializer.cs | 29 -- .../ViewpointUsageDeSerializer.cs | 197 ---------- .../WhileLoopActionUsageDeSerializer.cs | 112 ------ .../AcceptActionUsageSerializer.cs | 66 ---- .../ActionDefinitionSerializer.cs | 12 - .../ActionUsageSerializer.cs | 66 ---- .../ActorMembershipSerializer.cs | 99 ----- .../AllocationDefinitionSerializer.cs | 84 ----- .../AllocationUsageSerializer.cs | 126 ------- .../AnalysisCaseDefinitionSerializer.cs | 12 - .../AnalysisCaseUsageSerializer.cs | 120 ------- .../AutoGenSerializer/AnnotationSerializer.cs | 48 --- .../AssertConstraintUsageSerializer.cs | 82 ----- .../AssignmentActionUsageSerializer.cs | 66 ---- .../AssociationSerializer.cs | 72 ---- .../AssociationStructureSerializer.cs | 72 ---- .../AttributeUsageSerializer.cs | 30 -- .../AutoGenSerializer/BehaviorSerializer.cs | 12 - .../BindingConnectorAsUsageSerializer.cs | 90 ----- .../BindingConnectorSerializer.cs | 84 ----- .../BooleanExpressionSerializer.cs | 38 -- .../CalculationDefinitionSerializer.cs | 12 - .../CalculationUsageSerializer.cs | 92 ----- .../CaseDefinitionSerializer.cs | 12 - .../AutoGenSerializer/CaseUsageSerializer.cs | 106 ------ .../CollectExpressionSerializer.cs | 24 -- .../ConcernDefinitionSerializer.cs | 18 - .../ConcernUsageSerializer.cs | 116 ------ .../ConjugatedPortDefinitionSerializer.cs | 28 -- .../ConjugatedPortTypingSerializer.cs | 98 ----- .../ConjugationSerializer.cs | 48 --- .../ConnectionDefinitionSerializer.cs | 84 ----- .../ConnectionUsageSerializer.cs | 114 ------ .../AutoGenSerializer/ConnectorSerializer.cs | 84 ----- .../ConstraintDefinitionSerializer.cs | 12 - .../ConstraintUsageSerializer.cs | 82 ----- .../ConstructorExpressionSerializer.cs | 24 -- .../CrossSubsettingSerializer.cs | 124 ------- .../DecisionNodeSerializer.cs | 66 ---- .../AutoGenSerializer/DependencySerializer.cs | 48 --- .../DifferencingSerializer.cs | 48 --- .../AutoGenSerializer/DisjoiningSerializer.cs | 48 --- .../DocumentationSerializer.cs | 12 - .../ElementFilterMembershipSerializer.cs | 81 ----- .../EndFeatureMembershipSerializer.cs | 87 ----- .../EnumerationDefinitionSerializer.cs | 12 - .../EnumerationUsageSerializer.cs | 42 --- .../EventOccurrenceUsageSerializer.cs | 30 -- .../ExhibitStateUsageSerializer.cs | 90 ----- .../AutoGenSerializer/ExpressionSerializer.cs | 24 -- .../FeatureChainExpressionSerializer.cs | 24 -- .../FeatureChainingSerializer.cs | 48 --- .../FeatureInvertingSerializer.cs | 48 --- .../FeatureMembershipSerializer.cs | 87 ----- .../FeatureReferenceExpressionSerializer.cs | 24 -- .../FeatureTypingSerializer.cs | 86 ----- .../FeatureValueSerializer.cs | 81 ----- .../FlowDefinitionSerializer.cs | 96 ----- .../Core/AutoGenSerializer/FlowSerializer.cs | 120 ------- .../AutoGenSerializer/FlowUsageSerializer.cs | 174 --------- .../ForLoopActionUsageSerializer.cs | 66 ---- .../AutoGenSerializer/ForkNodeSerializer.cs | 66 ---- .../FramedConcernMembershipSerializer.cs | 105 ------ .../AutoGenSerializer/FunctionSerializer.cs | 12 - .../IfActionUsageSerializer.cs | 66 ---- .../IncludeUseCaseUsageSerializer.cs | 132 ------- .../IndexExpressionSerializer.cs | 24 -- .../InteractionSerializer.cs | 84 ----- .../InterfaceDefinitionSerializer.cs | 96 ----- .../InterfaceUsageSerializer.cs | 126 ------- .../IntersectingSerializer.cs | 48 --- .../AutoGenSerializer/InvariantSerializer.cs | 38 -- .../InvocationExpressionSerializer.cs | 24 -- .../AutoGenSerializer/ItemUsageSerializer.cs | 30 -- .../AutoGenSerializer/JoinNodeSerializer.cs | 66 ---- .../LiteralBooleanSerializer.cs | 24 -- .../LiteralExpressionSerializer.cs | 24 -- .../LiteralInfinitySerializer.cs | 24 -- .../LiteralIntegerSerializer.cs | 24 -- .../LiteralRationalSerializer.cs | 24 -- .../LiteralStringSerializer.cs | 24 -- .../MembershipExposeSerializer.cs | 48 --- .../MembershipImportSerializer.cs | 48 --- .../AutoGenSerializer/MembershipSerializer.cs | 48 --- .../AutoGenSerializer/MergeNodeSerializer.cs | 66 ---- .../MetadataAccessExpressionSerializer.cs | 24 -- .../MetadataUsageSerializer.cs | 56 --- .../NamespaceExposeSerializer.cs | 48 --- .../NamespaceImportSerializer.cs | 48 --- .../NullExpressionSerializer.cs | 24 -- .../ObjectiveMembershipSerializer.cs | 93 ----- .../OccurrenceUsageSerializer.cs | 30 -- .../OperatorExpressionSerializer.cs | 24 -- .../OwningMembershipSerializer.cs | 75 ---- .../ParameterMembershipSerializer.cs | 93 ----- .../AutoGenSerializer/PartUsageSerializer.cs | 30 -- .../PerformActionUsageSerializer.cs | 72 ---- .../PortConjugationSerializer.cs | 74 ---- .../AutoGenSerializer/PortUsageSerializer.cs | 42 --- .../AutoGenSerializer/PredicateSerializer.cs | 12 - .../RedefinitionSerializer.cs | 110 ------ .../ReferenceSubsettingSerializer.cs | 124 ------- .../ReferenceUsageSerializer.cs | 18 - .../RenderingUsageSerializer.cs | 42 --- ...quirementConstraintMembershipSerializer.cs | 93 ----- .../RequirementDefinitionSerializer.cs | 18 - .../RequirementUsageSerializer.cs | 102 ------ ...irementVerificationMembershipSerializer.cs | 105 ------ .../ResultExpressionMembershipSerializer.cs | 93 ----- .../ReturnParameterMembershipSerializer.cs | 93 ----- .../SatisfyRequirementUsageSerializer.cs | 108 ------ .../SelectExpressionSerializer.cs | 24 -- .../SendActionUsageSerializer.cs | 66 ---- .../SpecializationSerializer.cs | 48 --- .../StakeholderMembershipSerializer.cs | 99 ----- .../StateDefinitionSerializer.cs | 12 - .../StateSubactionMembershipSerializer.cs | 93 ----- .../AutoGenSerializer/StateUsageSerializer.cs | 78 ---- .../Core/AutoGenSerializer/StepSerializer.cs | 12 - .../SubclassificationSerializer.cs | 86 ----- .../SubjectMembershipSerializer.cs | 99 ----- .../AutoGenSerializer/SubsettingSerializer.cs | 86 ----- .../SuccessionAsUsageSerializer.cs | 90 ----- .../SuccessionFlowSerializer.cs | 120 ------- .../SuccessionFlowUsageSerializer.cs | 174 --------- .../AutoGenSerializer/SuccessionSerializer.cs | 84 ----- .../TerminateActionUsageSerializer.cs | 66 ---- .../TextualRepresentationSerializer.cs | 12 - .../TransitionFeatureMembershipSerializer.cs | 93 ----- .../TransitionUsageSerializer.cs | 66 ---- .../TriggerInvocationExpressionSerializer.cs | 24 -- .../TypeFeaturingSerializer.cs | 48 --- .../AutoGenSerializer/UnioningSerializer.cs | 48 --- .../Core/AutoGenSerializer/UsageSerializer.cs | 18 - .../UseCaseDefinitionSerializer.cs | 12 - .../UseCaseUsageSerializer.cs | 120 ------- .../VariantMembershipSerializer.cs | 81 ----- .../VerificationCaseDefinitionSerializer.cs | 12 - .../VerificationCaseUsageSerializer.cs | 106 ------ .../ViewRenderingMembershipSerializer.cs | 93 ----- .../AutoGenSerializer/ViewUsageSerializer.cs | 42 --- .../ViewpointDefinitionSerializer.cs | 18 - .../ViewpointUsageSerializer.cs | 116 ------ .../WhileLoopActionUsageSerializer.cs | 66 ---- .../Core/AutoGenDto/AcceptActionUsage.cs | 16 +- .../Core/AutoGenDto/ActionDefinition.cs | 2 +- SysML2.NET/Core/AutoGenDto/ActionUsage.cs | 16 +- SysML2.NET/Core/AutoGenDto/ActorMembership.cs | 47 ++- .../Core/AutoGenDto/AllocationDefinition.cs | 27 +- SysML2.NET/Core/AutoGenDto/AllocationUsage.cs | 30 +- .../Core/AutoGenDto/AnalysisCaseDefinition.cs | 2 +- .../Core/AutoGenDto/AnalysisCaseUsage.cs | 24 +- SysML2.NET/Core/AutoGenDto/Annotation.cs | 19 +- .../Core/AutoGenDto/AssertConstraintUsage.cs | 18 +- .../Core/AutoGenDto/AssignmentActionUsage.cs | 16 +- SysML2.NET/Core/AutoGenDto/Association.cs | 16 +- .../Core/AutoGenDto/AssociationStructure.cs | 16 +- SysML2.NET/Core/AutoGenDto/AttributeUsage.cs | 12 +- SysML2.NET/Core/AutoGenDto/Behavior.cs | 2 +- .../Core/AutoGenDto/BindingConnector.cs | 18 +- .../AutoGenDto/BindingConnectorAsUsage.cs | 24 +- .../Core/AutoGenDto/BooleanExpression.cs | 6 +- .../Core/AutoGenDto/CalculationDefinition.cs | 2 +- .../Core/AutoGenDto/CalculationUsage.cs | 20 +- SysML2.NET/Core/AutoGenDto/CaseDefinition.cs | 2 +- SysML2.NET/Core/AutoGenDto/CaseUsage.cs | 22 +- .../Core/AutoGenDto/CollectExpression.cs | 13 +- .../Core/AutoGenDto/ConcernDefinition.cs | 11 +- SysML2.NET/Core/AutoGenDto/ConcernUsage.cs | 31 +- .../AutoGenDto/ConjugatedPortDefinition.cs | 4 +- .../Core/AutoGenDto/ConjugatedPortTyping.cs | 55 ++- SysML2.NET/Core/AutoGenDto/Conjugation.cs | 26 +- .../Core/AutoGenDto/ConnectionDefinition.cs | 27 +- SysML2.NET/Core/AutoGenDto/ConnectionUsage.cs | 28 +- SysML2.NET/Core/AutoGenDto/Connector.cs | 18 +- .../Core/AutoGenDto/ConstraintDefinition.cs | 2 +- SysML2.NET/Core/AutoGenDto/ConstraintUsage.cs | 18 +- .../Core/AutoGenDto/ConstructorExpression.cs | 4 +- SysML2.NET/Core/AutoGenDto/CrossSubsetting.cs | 63 +++- SysML2.NET/Core/AutoGenDto/DecisionNode.cs | 16 +- SysML2.NET/Core/AutoGenDto/Dependency.cs | 18 +- SysML2.NET/Core/AutoGenDto/Differencing.cs | 19 +- SysML2.NET/Core/AutoGenDto/Disjoining.cs | 26 +- SysML2.NET/Core/AutoGenDto/Documentation.cs | 2 +- .../AutoGenDto/ElementFilterMembership.cs | 41 ++- .../Core/AutoGenDto/EndFeatureMembership.cs | 45 ++- .../Core/AutoGenDto/EnumerationDefinition.cs | 11 +- .../Core/AutoGenDto/EnumerationUsage.cs | 14 +- .../Core/AutoGenDto/EventOccurrenceUsage.cs | 12 +- .../Core/AutoGenDto/ExhibitStateUsage.cs | 24 +- SysML2.NET/Core/AutoGenDto/Expression.cs | 4 +- .../Core/AutoGenDto/FeatureChainExpression.cs | 13 +- SysML2.NET/Core/AutoGenDto/FeatureChaining.cs | 19 +- .../Core/AutoGenDto/FeatureInverting.cs | 26 +- .../Core/AutoGenDto/FeatureMembership.cs | 43 ++- .../AutoGenDto/FeatureReferenceExpression.cs | 4 +- SysML2.NET/Core/AutoGenDto/FeatureTyping.cs | 46 ++- SysML2.NET/Core/AutoGenDto/FeatureValue.cs | 41 ++- SysML2.NET/Core/AutoGenDto/Flow.cs | 24 +- SysML2.NET/Core/AutoGenDto/FlowDefinition.cs | 20 +- SysML2.NET/Core/AutoGenDto/FlowUsage.cs | 38 +- .../Core/AutoGenDto/ForLoopActionUsage.cs | 16 +- SysML2.NET/Core/AutoGenDto/ForkNode.cs | 16 +- .../AutoGenDto/FramedConcernMembership.cs | 58 ++- SysML2.NET/Core/AutoGenDto/Function.cs | 2 +- SysML2.NET/Core/AutoGenDto/IfActionUsage.cs | 16 +- .../Core/AutoGenDto/IncludeUseCaseUsage.cs | 30 +- SysML2.NET/Core/AutoGenDto/IndexExpression.cs | 13 +- SysML2.NET/Core/AutoGenDto/Interaction.cs | 18 +- .../Core/AutoGenDto/InterfaceDefinition.cs | 29 +- SysML2.NET/Core/AutoGenDto/InterfaceUsage.cs | 30 +- SysML2.NET/Core/AutoGenDto/Intersecting.cs | 19 +- SysML2.NET/Core/AutoGenDto/Invariant.cs | 6 +- .../Core/AutoGenDto/InvocationExpression.cs | 4 +- SysML2.NET/Core/AutoGenDto/ItemUsage.cs | 10 +- SysML2.NET/Core/AutoGenDto/JoinNode.cs | 16 +- SysML2.NET/Core/AutoGenDto/LiteralBoolean.cs | 4 +- .../Core/AutoGenDto/LiteralExpression.cs | 4 +- SysML2.NET/Core/AutoGenDto/LiteralInfinity.cs | 4 +- SysML2.NET/Core/AutoGenDto/LiteralInteger.cs | 4 +- SysML2.NET/Core/AutoGenDto/LiteralRational.cs | 4 +- SysML2.NET/Core/AutoGenDto/LiteralString.cs | 4 +- SysML2.NET/Core/AutoGenDto/Membership.cs | 19 +- .../Core/AutoGenDto/MembershipExpose.cs | 37 +- .../Core/AutoGenDto/MembershipImport.cs | 19 +- SysML2.NET/Core/AutoGenDto/MergeNode.cs | 16 +- .../AutoGenDto/MetadataAccessExpression.cs | 4 +- SysML2.NET/Core/AutoGenDto/MetadataUsage.cs | 14 +- SysML2.NET/Core/AutoGenDto/NamespaceExpose.cs | 37 +- SysML2.NET/Core/AutoGenDto/NamespaceImport.cs | 19 +- SysML2.NET/Core/AutoGenDto/NullExpression.cs | 4 +- .../Core/AutoGenDto/ObjectiveMembership.cs | 45 ++- SysML2.NET/Core/AutoGenDto/OccurrenceUsage.cs | 10 +- .../Core/AutoGenDto/OperatorExpression.cs | 4 +- .../Core/AutoGenDto/OwningMembership.cs | 39 +- .../Core/AutoGenDto/ParameterMembership.cs | 45 ++- SysML2.NET/Core/AutoGenDto/PartUsage.cs | 10 +- .../Core/AutoGenDto/PerformActionUsage.cs | 20 +- SysML2.NET/Core/AutoGenDto/PortConjugation.cs | 37 +- SysML2.NET/Core/AutoGenDto/PortUsage.cs | 12 +- SysML2.NET/Core/AutoGenDto/Predicate.cs | 2 +- SysML2.NET/Core/AutoGenDto/Redefinition.cs | 64 +++- .../Core/AutoGenDto/ReferenceSubsetting.cs | 63 +++- SysML2.NET/Core/AutoGenDto/ReferenceUsage.cs | 10 +- SysML2.NET/Core/AutoGenDto/RenderingUsage.cs | 12 +- .../RequirementConstraintMembership.cs | 45 ++- .../Core/AutoGenDto/RequirementDefinition.cs | 11 +- .../Core/AutoGenDto/RequirementUsage.cs | 29 +- .../RequirementVerificationMembership.cs | 58 ++- .../AutoGenDto/ResultExpressionMembership.cs | 45 ++- .../AutoGenDto/ReturnParameterMembership.cs | 45 ++- .../AutoGenDto/SatisfyRequirementUsage.cs | 31 +- .../Core/AutoGenDto/SelectExpression.cs | 13 +- SysML2.NET/Core/AutoGenDto/SendActionUsage.cs | 16 +- SysML2.NET/Core/AutoGenDto/Specialization.cs | 26 +- .../Core/AutoGenDto/StakeholderMembership.cs | 47 ++- SysML2.NET/Core/AutoGenDto/StateDefinition.cs | 2 +- .../AutoGenDto/StateSubactionMembership.cs | 45 ++- SysML2.NET/Core/AutoGenDto/StateUsage.cs | 18 +- SysML2.NET/Core/AutoGenDto/Step.cs | 2 +- .../Core/AutoGenDto/Subclassification.cs | 46 ++- .../Core/AutoGenDto/SubjectMembership.cs | 47 ++- SysML2.NET/Core/AutoGenDto/Subsetting.cs | 46 ++- SysML2.NET/Core/AutoGenDto/Succession.cs | 18 +- .../Core/AutoGenDto/SuccessionAsUsage.cs | 24 +- SysML2.NET/Core/AutoGenDto/SuccessionFlow.cs | 24 +- .../Core/AutoGenDto/SuccessionFlowUsage.cs | 38 +- .../Core/AutoGenDto/TerminateActionUsage.cs | 16 +- .../Core/AutoGenDto/TextualRepresentation.cs | 2 +- .../AutoGenDto/TransitionFeatureMembership.cs | 45 ++- SysML2.NET/Core/AutoGenDto/TransitionUsage.cs | 16 +- .../AutoGenDto/TriggerInvocationExpression.cs | 4 +- SysML2.NET/Core/AutoGenDto/TypeFeaturing.cs | 26 +- SysML2.NET/Core/AutoGenDto/Unioning.cs | 19 +- SysML2.NET/Core/AutoGenDto/Usage.cs | 8 +- .../Core/AutoGenDto/UseCaseDefinition.cs | 2 +- SysML2.NET/Core/AutoGenDto/UseCaseUsage.cs | 24 +- .../Core/AutoGenDto/VariantMembership.cs | 41 ++- .../AutoGenDto/VerificationCaseDefinition.cs | 2 +- .../Core/AutoGenDto/VerificationCaseUsage.cs | 22 +- .../AutoGenDto/ViewRenderingMembership.cs | 45 ++- SysML2.NET/Core/AutoGenDto/ViewUsage.cs | 12 +- .../Core/AutoGenDto/ViewpointDefinition.cs | 11 +- SysML2.NET/Core/AutoGenDto/ViewpointUsage.cs | 31 +- .../Core/AutoGenDto/WhileLoopActionUsage.cs | 16 +- .../Core/AutoGenPoco/AcceptActionUsage.cs | 17 +- .../Core/AutoGenPoco/ActionDefinition.cs | 3 +- SysML2.NET/Core/AutoGenPoco/ActionUsage.cs | 17 +- .../Core/AutoGenPoco/ActorMembership.cs | 47 ++- .../Core/AutoGenPoco/AllocationDefinition.cs | 28 +- .../Core/AutoGenPoco/AllocationUsage.cs | 31 +- .../AutoGenPoco/AnalysisCaseDefinition.cs | 3 +- .../Core/AutoGenPoco/AnalysisCaseUsage.cs | 25 +- .../Core/AutoGenPoco/AnnotatingElement.cs | 1 + SysML2.NET/Core/AutoGenPoco/Annotation.cs | 19 +- .../Core/AutoGenPoco/AssertConstraintUsage.cs | 19 +- .../Core/AutoGenPoco/AssignmentActionUsage.cs | 17 +- SysML2.NET/Core/AutoGenPoco/Association.cs | 17 +- .../Core/AutoGenPoco/AssociationStructure.cs | 17 +- .../Core/AutoGenPoco/AttributeDefinition.cs | 1 + SysML2.NET/Core/AutoGenPoco/AttributeUsage.cs | 13 +- SysML2.NET/Core/AutoGenPoco/Behavior.cs | 3 +- .../Core/AutoGenPoco/BindingConnector.cs | 19 +- .../AutoGenPoco/BindingConnectorAsUsage.cs | 25 +- .../Core/AutoGenPoco/BooleanExpression.cs | 7 +- .../Core/AutoGenPoco/CalculationDefinition.cs | 3 +- .../Core/AutoGenPoco/CalculationUsage.cs | 21 +- SysML2.NET/Core/AutoGenPoco/CaseDefinition.cs | 3 +- SysML2.NET/Core/AutoGenPoco/CaseUsage.cs | 23 +- SysML2.NET/Core/AutoGenPoco/Class.cs | 1 + SysML2.NET/Core/AutoGenPoco/Classifier.cs | 1 + .../Core/AutoGenPoco/CollectExpression.cs | 14 +- SysML2.NET/Core/AutoGenPoco/Comment.cs | 1 + .../Core/AutoGenPoco/ConcernDefinition.cs | 12 +- SysML2.NET/Core/AutoGenPoco/ConcernUsage.cs | 32 +- .../AutoGenPoco/ConjugatedPortDefinition.cs | 5 +- .../Core/AutoGenPoco/ConjugatedPortTyping.cs | 60 +++- SysML2.NET/Core/AutoGenPoco/Conjugation.cs | 25 +- .../Core/AutoGenPoco/ConnectionDefinition.cs | 28 +- .../Core/AutoGenPoco/ConnectionUsage.cs | 29 +- SysML2.NET/Core/AutoGenPoco/Connector.cs | 19 +- .../Core/AutoGenPoco/ConnectorAsUsage.cs | 25 +- .../Core/AutoGenPoco/ConstraintDefinition.cs | 3 +- .../Core/AutoGenPoco/ConstraintUsage.cs | 19 +- .../Core/AutoGenPoco/ConstructorExpression.cs | 5 +- SysML2.NET/Core/AutoGenPoco/ControlNode.cs | 17 +- .../Core/AutoGenPoco/CrossSubsetting.cs | 68 +++- SysML2.NET/Core/AutoGenPoco/DataType.cs | 1 + SysML2.NET/Core/AutoGenPoco/DecisionNode.cs | 17 +- SysML2.NET/Core/AutoGenPoco/Definition.cs | 1 + SysML2.NET/Core/AutoGenPoco/Dependency.cs | 19 +- SysML2.NET/Core/AutoGenPoco/Differencing.cs | 19 +- SysML2.NET/Core/AutoGenPoco/Disjoining.cs | 25 +- SysML2.NET/Core/AutoGenPoco/Documentation.cs | 3 +- SysML2.NET/Core/AutoGenPoco/Element.cs | 1 + .../AutoGenPoco/ElementFilterMembership.cs | 41 ++- .../Core/AutoGenPoco/EndFeatureMembership.cs | 45 ++- .../Core/AutoGenPoco/EnumerationDefinition.cs | 12 +- .../Core/AutoGenPoco/EnumerationUsage.cs | 15 +- .../Core/AutoGenPoco/EventOccurrenceUsage.cs | 13 +- .../Core/AutoGenPoco/ExhibitStateUsage.cs | 25 +- SysML2.NET/Core/AutoGenPoco/Expose.cs | 25 +- SysML2.NET/Core/AutoGenPoco/Expression.cs | 5 +- SysML2.NET/Core/AutoGenPoco/Feature.cs | 1 + .../AutoGenPoco/FeatureChainExpression.cs | 14 +- .../Core/AutoGenPoco/FeatureChaining.cs | 19 +- .../Core/AutoGenPoco/FeatureInverting.cs | 25 +- .../Core/AutoGenPoco/FeatureMembership.cs | 43 ++- .../AutoGenPoco/FeatureReferenceExpression.cs | 5 +- SysML2.NET/Core/AutoGenPoco/FeatureTyping.cs | 48 ++- SysML2.NET/Core/AutoGenPoco/FeatureValue.cs | 41 ++- SysML2.NET/Core/AutoGenPoco/Flow.cs | 25 +- SysML2.NET/Core/AutoGenPoco/FlowDefinition.cs | 21 +- SysML2.NET/Core/AutoGenPoco/FlowEnd.cs | 1 + SysML2.NET/Core/AutoGenPoco/FlowUsage.cs | 39 +- .../Core/AutoGenPoco/ForLoopActionUsage.cs | 17 +- SysML2.NET/Core/AutoGenPoco/ForkNode.cs | 17 +- .../AutoGenPoco/FramedConcernMembership.cs | 58 ++- SysML2.NET/Core/AutoGenPoco/Function.cs | 3 +- SysML2.NET/Core/AutoGenPoco/IfActionUsage.cs | 17 +- SysML2.NET/Core/AutoGenPoco/Import.cs | 7 +- .../Core/AutoGenPoco/IncludeUseCaseUsage.cs | 31 +- .../Core/AutoGenPoco/IndexExpression.cs | 14 +- .../AutoGenPoco/InstantiationExpression.cs | 5 +- SysML2.NET/Core/AutoGenPoco/Interaction.cs | 19 +- .../Core/AutoGenPoco/InterfaceDefinition.cs | 30 +- SysML2.NET/Core/AutoGenPoco/InterfaceUsage.cs | 31 +- SysML2.NET/Core/AutoGenPoco/Intersecting.cs | 19 +- SysML2.NET/Core/AutoGenPoco/Invariant.cs | 7 +- .../Core/AutoGenPoco/InvocationExpression.cs | 5 +- SysML2.NET/Core/AutoGenPoco/ItemDefinition.cs | 1 + SysML2.NET/Core/AutoGenPoco/ItemUsage.cs | 11 +- SysML2.NET/Core/AutoGenPoco/JoinNode.cs | 17 +- SysML2.NET/Core/AutoGenPoco/LibraryPackage.cs | 1 + SysML2.NET/Core/AutoGenPoco/LiteralBoolean.cs | 5 +- .../Core/AutoGenPoco/LiteralExpression.cs | 5 +- .../Core/AutoGenPoco/LiteralInfinity.cs | 5 +- SysML2.NET/Core/AutoGenPoco/LiteralInteger.cs | 5 +- .../Core/AutoGenPoco/LiteralRational.cs | 5 +- SysML2.NET/Core/AutoGenPoco/LiteralString.cs | 5 +- .../Core/AutoGenPoco/LoopActionUsage.cs | 17 +- SysML2.NET/Core/AutoGenPoco/Membership.cs | 19 +- .../Core/AutoGenPoco/MembershipExpose.cs | 37 +- .../Core/AutoGenPoco/MembershipImport.cs | 19 +- SysML2.NET/Core/AutoGenPoco/MergeNode.cs | 17 +- SysML2.NET/Core/AutoGenPoco/Metaclass.cs | 1 + .../AutoGenPoco/MetadataAccessExpression.cs | 5 +- .../Core/AutoGenPoco/MetadataDefinition.cs | 1 + .../Core/AutoGenPoco/MetadataFeature.cs | 1 + SysML2.NET/Core/AutoGenPoco/MetadataUsage.cs | 15 +- SysML2.NET/Core/AutoGenPoco/Multiplicity.cs | 1 + .../Core/AutoGenPoco/MultiplicityRange.cs | 1 + SysML2.NET/Core/AutoGenPoco/Namespace.cs | 1 + .../Core/AutoGenPoco/NamespaceExpose.cs | 37 +- .../Core/AutoGenPoco/NamespaceImport.cs | 19 +- SysML2.NET/Core/AutoGenPoco/NullExpression.cs | 5 +- .../Core/AutoGenPoco/ObjectiveMembership.cs | 45 ++- .../Core/AutoGenPoco/OccurrenceDefinition.cs | 1 + .../Core/AutoGenPoco/OccurrenceUsage.cs | 11 +- .../Core/AutoGenPoco/OperatorExpression.cs | 5 +- .../Core/AutoGenPoco/OwningMembership.cs | 39 +- SysML2.NET/Core/AutoGenPoco/Package.cs | 1 + .../Core/AutoGenPoco/ParameterMembership.cs | 45 ++- SysML2.NET/Core/AutoGenPoco/PartDefinition.cs | 1 + SysML2.NET/Core/AutoGenPoco/PartUsage.cs | 11 +- SysML2.NET/Core/AutoGenPoco/PayloadFeature.cs | 1 + .../Core/AutoGenPoco/PerformActionUsage.cs | 21 +- .../Core/AutoGenPoco/PortConjugation.cs | 39 +- SysML2.NET/Core/AutoGenPoco/PortDefinition.cs | 1 + SysML2.NET/Core/AutoGenPoco/PortUsage.cs | 13 +- SysML2.NET/Core/AutoGenPoco/Predicate.cs | 3 +- SysML2.NET/Core/AutoGenPoco/Redefinition.cs | 69 +++- .../Core/AutoGenPoco/ReferenceSubsetting.cs | 68 +++- SysML2.NET/Core/AutoGenPoco/ReferenceUsage.cs | 11 +- SysML2.NET/Core/AutoGenPoco/Relationship.cs | 1 + .../Core/AutoGenPoco/RenderingDefinition.cs | 1 + SysML2.NET/Core/AutoGenPoco/RenderingUsage.cs | 13 +- .../RequirementConstraintMembership.cs | 45 ++- .../Core/AutoGenPoco/RequirementDefinition.cs | 12 +- .../Core/AutoGenPoco/RequirementUsage.cs | 30 +- .../RequirementVerificationMembership.cs | 58 ++- .../AutoGenPoco/ResultExpressionMembership.cs | 45 ++- .../AutoGenPoco/ReturnParameterMembership.cs | 45 ++- .../AutoGenPoco/SatisfyRequirementUsage.cs | 32 +- .../Core/AutoGenPoco/SelectExpression.cs | 14 +- .../Core/AutoGenPoco/SendActionUsage.cs | 17 +- SysML2.NET/Core/AutoGenPoco/Specialization.cs | 25 +- .../Core/AutoGenPoco/StakeholderMembership.cs | 47 ++- .../Core/AutoGenPoco/StateDefinition.cs | 3 +- .../AutoGenPoco/StateSubactionMembership.cs | 45 ++- SysML2.NET/Core/AutoGenPoco/StateUsage.cs | 19 +- SysML2.NET/Core/AutoGenPoco/Step.cs | 3 +- SysML2.NET/Core/AutoGenPoco/Structure.cs | 1 + .../Core/AutoGenPoco/Subclassification.cs | 51 ++- .../Core/AutoGenPoco/SubjectMembership.cs | 47 ++- SysML2.NET/Core/AutoGenPoco/Subsetting.cs | 51 ++- SysML2.NET/Core/AutoGenPoco/Succession.cs | 19 +- .../Core/AutoGenPoco/SuccessionAsUsage.cs | 25 +- SysML2.NET/Core/AutoGenPoco/SuccessionFlow.cs | 25 +- .../Core/AutoGenPoco/SuccessionFlowUsage.cs | 39 +- .../Core/AutoGenPoco/TerminateActionUsage.cs | 17 +- .../Core/AutoGenPoco/TextualRepresentation.cs | 3 +- .../TransitionFeatureMembership.cs | 45 ++- .../Core/AutoGenPoco/TransitionUsage.cs | 17 +- .../TriggerInvocationExpression.cs | 5 +- SysML2.NET/Core/AutoGenPoco/Type.cs | 1 + SysML2.NET/Core/AutoGenPoco/TypeFeaturing.cs | 25 +- SysML2.NET/Core/AutoGenPoco/Unioning.cs | 19 +- SysML2.NET/Core/AutoGenPoco/Usage.cs | 9 +- .../Core/AutoGenPoco/UseCaseDefinition.cs | 3 +- SysML2.NET/Core/AutoGenPoco/UseCaseUsage.cs | 25 +- .../Core/AutoGenPoco/VariantMembership.cs | 41 ++- .../AutoGenPoco/VerificationCaseDefinition.cs | 3 +- .../Core/AutoGenPoco/VerificationCaseUsage.cs | 23 +- SysML2.NET/Core/AutoGenPoco/ViewDefinition.cs | 1 + .../AutoGenPoco/ViewRenderingMembership.cs | 45 ++- SysML2.NET/Core/AutoGenPoco/ViewUsage.cs | 13 +- .../Core/AutoGenPoco/ViewpointDefinition.cs | 12 +- SysML2.NET/Core/AutoGenPoco/ViewpointUsage.cs | 32 +- .../Core/AutoGenPoco/WhileLoopActionUsage.cs | 17 +- SysML2.NET/SysML2.NET.csproj | 1 + 884 files changed, 5930 insertions(+), 30215 deletions(-) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/AssociationDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/AssociationDeSerializer.cs index 1570e770..416adac3 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/AssociationDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/AssociationDeSerializer.cs @@ -214,26 +214,6 @@ internal static IAssociation DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the elementId Json property was not found in the Association: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the Association: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("feature"u8, out var featureProperty)) { foreach (var arrayItem in featureProperty.EnumerateArray()) @@ -1012,26 +992,6 @@ internal static IAssociation DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the qualifiedName Json property was not found in the Association: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the Association: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedType"u8, out var relatedTypeProperty)) { foreach (var arrayItem in relatedTypeProperty.EnumerateArray()) @@ -1061,26 +1021,6 @@ internal static IAssociation DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the shortName Json property was not found in the Association: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Association: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceType"u8, out var sourceTypeProperty)) { if (sourceTypeProperty.ValueKind == JsonValueKind.Null) @@ -1105,26 +1045,6 @@ internal static IAssociation DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the sourceType Json property was not found in the Association: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Association: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetType"u8, out var targetTypeProperty)) { foreach (var arrayItem in targetTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/DependencyDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/DependencyDeSerializer.cs index 09f4b28c..096b32ba 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/DependencyDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/DependencyDeSerializer.cs @@ -457,26 +457,6 @@ internal static IDependency DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the shortName Json property was not found in the Dependency: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Dependency: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("supplier"u8, out var supplierProperty)) { foreach (var arrayItem in supplierProperty.EnumerateArray()) @@ -497,26 +477,6 @@ internal static IDependency DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the supplier Json property was not found in the Dependency: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Dependency: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/EnumerationDefinitionDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/EnumerationDefinitionDeSerializer.cs index a109d21e..97080515 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/EnumerationDefinitionDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/EnumerationDefinitionDeSerializer.cs @@ -1597,26 +1597,6 @@ internal static IEnumerationDefinition DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the usage Json property was not found in the EnumerationDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("variant"u8, out var variantProperty)) - { - foreach (var arrayItem in variantProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var variantExternalIdProperty)) - { - var propertyValue = variantExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.variant.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the variant Json property was not found in the EnumerationDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("variantMembership"u8, out var variantMembershipProperty)) { foreach (var arrayItem in variantMembershipProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/FeatureTypingDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/FeatureTypingDeSerializer.cs index d5fa2bb7..5e26ee9e 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/FeatureTypingDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/FeatureTypingDeSerializer.cs @@ -154,31 +154,6 @@ internal static IFeatureTyping DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the elementId Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("general"u8, out var generalProperty)) - { - if (generalProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.General = Guid.Empty; - logger.LogDebug($"the FeatureTyping.General property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (generalProperty.TryGetProperty("@id"u8, out var generalExternalIdProperty)) - { - var propertyValue = generalExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.General = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the general Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isImplied"u8, out var isImpliedProperty)) { if (isImpliedProperty.ValueKind != JsonValueKind.Null) @@ -448,30 +423,6 @@ internal static IFeatureTyping DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the owningRelationship Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningType"u8, out var owningTypeProperty)) - { - if (owningTypeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningType = null; - } - else - { - if (owningTypeProperty.TryGetProperty("@id"u8, out var owningTypeExternalIdProperty)) - { - var propertyValue = owningTypeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningType = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningType Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -510,71 +461,6 @@ internal static IFeatureTyping DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the shortName Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("specific"u8, out var specificProperty)) - { - if (specificProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.Specific = Guid.Empty; - logger.LogDebug($"the FeatureTyping.Specific property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (specificProperty.TryGetProperty("@id"u8, out var specificExternalIdProperty)) - { - var propertyValue = specificExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Specific = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the specific Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/FlowDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/FlowDeSerializer.cs index 7d28ee1d..18274448 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/FlowDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/FlowDeSerializer.cs @@ -102,46 +102,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the aliasIds Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("association"u8, out var associationProperty)) - { - foreach (var arrayItem in associationProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var associationExternalIdProperty)) - { - var propertyValue = associationExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.association.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the association Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -268,26 +228,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the differencingType Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); @@ -331,26 +271,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the elementId Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -1594,26 +1514,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the qualifiedName Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -1643,26 +1543,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the shortName Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -1711,26 +1591,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the sourceOutputFeature Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -1795,26 +1655,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the textualRepresentation Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/FramedConcernMembershipDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/FramedConcernMembershipDeSerializer.cs index 92833128..e6ed1845 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/FramedConcernMembershipDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/FramedConcernMembershipDeSerializer.cs @@ -199,88 +199,6 @@ internal static IFramedConcernMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the kind Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the FramedConcernMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the FramedConcernMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -335,31 +253,6 @@ internal static IFramedConcernMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the ownedConcern Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedConstraint"u8, out var ownedConstraintProperty)) - { - if (ownedConstraintProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedConstraint = Guid.Empty; - logger.LogDebug($"the FramedConcernMembership.ownedConstraint property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedConstraintProperty.TryGetProperty("@id"u8, out var ownedConstraintExternalIdProperty)) - { - var propertyValue = ownedConstraintExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedConstraint = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedConstraint Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedElement"u8, out var ownedElementProperty)) { foreach (var arrayItem in ownedElementProperty.EnumerateArray()) @@ -380,31 +273,6 @@ internal static IFramedConcernMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the ownedElement Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the FramedConcernMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -419,31 +287,6 @@ internal static IFramedConcernMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the ownedMemberElementId Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the FramedConcernMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -681,31 +524,6 @@ internal static IFramedConcernMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the referencedConcern Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("referencedConstraint"u8, out var referencedConstraintProperty)) - { - if (referencedConstraintProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.referencedConstraint = Guid.Empty; - logger.LogDebug($"the FramedConcernMembership.referencedConstraint property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (referencedConstraintProperty.TryGetProperty("@id"u8, out var referencedConstraintExternalIdProperty)) - { - var propertyValue = referencedConstraintExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.referencedConstraint = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the referencedConstraint Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) { foreach (var arrayItem in relatedElementProperty.EnumerateArray()) @@ -735,46 +553,6 @@ internal static IFramedConcernMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the shortName Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/LiteralIntegerDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/LiteralIntegerDeSerializer.cs index 6940054a..a233bc5f 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/LiteralIntegerDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/LiteralIntegerDeSerializer.cs @@ -102,26 +102,6 @@ internal static ILiteralInteger DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the aliasIds Json property was not found in the LiteralInteger: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the LiteralInteger: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static ILiteralInteger DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the differencingType Json property was not found in the LiteralInteger: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the LiteralInteger: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/LiteralRationalDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/LiteralRationalDeSerializer.cs index b9a2abc2..7d656cdb 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/LiteralRationalDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/LiteralRationalDeSerializer.cs @@ -102,26 +102,6 @@ internal static ILiteralRational DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the aliasIds Json property was not found in the LiteralRational: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the LiteralRational: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static ILiteralRational DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the differencingType Json property was not found in the LiteralRational: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the LiteralRational: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/MembershipDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/MembershipDeSerializer.cs index 2d26f987..5ab23a1b 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/MembershipDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/MembershipDeSerializer.cs @@ -519,46 +519,6 @@ internal static IMembership DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the shortName Json property was not found in the Membership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Membership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Membership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/OwningMembershipDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/OwningMembershipDeSerializer.cs index 9c23ceb2..2418ccc2 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/OwningMembershipDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/OwningMembershipDeSerializer.cs @@ -190,54 +190,6 @@ internal static IOwningMembership DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the isLibraryElement Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the OwningMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) { if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) @@ -263,15 +215,6 @@ internal static IOwningMembership DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the membershipOwningNamespace Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -576,46 +519,6 @@ internal static IOwningMembership DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the shortName Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/ReferenceSubsettingDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/ReferenceSubsettingDeSerializer.cs index 7a19c373..dbb3051c 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/ReferenceSubsettingDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/ReferenceSubsettingDeSerializer.cs @@ -154,31 +154,6 @@ internal static IReferenceSubsetting DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the elementId Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("general"u8, out var generalProperty)) - { - if (generalProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.General = Guid.Empty; - logger.LogDebug($"the ReferenceSubsetting.General property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (generalProperty.TryGetProperty("@id"u8, out var generalExternalIdProperty)) - { - var propertyValue = generalExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.General = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the general Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isImplied"u8, out var isImpliedProperty)) { if (isImpliedProperty.ValueKind != JsonValueKind.Null) @@ -328,30 +303,6 @@ internal static IReferenceSubsetting DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the owner Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningFeature"u8, out var owningFeatureProperty)) - { - if (owningFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningFeature = null; - } - else - { - if (owningFeatureProperty.TryGetProperty("@id"u8, out var owningFeatureExternalIdProperty)) - { - var propertyValue = owningFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningFeature Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("owningMembership"u8, out var owningMembershipProperty)) { if (owningMembershipProperty.ValueKind == JsonValueKind.Null) @@ -448,30 +399,6 @@ internal static IReferenceSubsetting DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the owningRelationship Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningType"u8, out var owningTypeProperty)) - { - if (owningTypeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningType = null; - } - else - { - if (owningTypeProperty.TryGetProperty("@id"u8, out var owningTypeExternalIdProperty)) - { - var propertyValue = owningTypeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningType = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningType Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -560,121 +487,6 @@ internal static IReferenceSubsetting DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the shortName Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("specific"u8, out var specificProperty)) - { - if (specificProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.Specific = Guid.Empty; - logger.LogDebug($"the ReferenceSubsetting.Specific property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (specificProperty.TryGetProperty("@id"u8, out var specificExternalIdProperty)) - { - var propertyValue = specificExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Specific = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the specific Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("subsettedFeature"u8, out var subsettedFeatureProperty)) - { - if (subsettedFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.SubsettedFeature = Guid.Empty; - logger.LogDebug($"the ReferenceSubsetting.SubsettedFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (subsettedFeatureProperty.TryGetProperty("@id"u8, out var subsettedFeatureExternalIdProperty)) - { - var propertyValue = subsettedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.SubsettedFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the subsettedFeature Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("subsettingFeature"u8, out var subsettingFeatureProperty)) - { - if (subsettingFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.SubsettingFeature = Guid.Empty; - logger.LogDebug($"the ReferenceSubsetting.SubsettingFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (subsettingFeatureProperty.TryGetProperty("@id"u8, out var subsettingFeatureExternalIdProperty)) - { - var propertyValue = subsettingFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.SubsettingFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the subsettingFeature Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/RequirementUsageDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/RequirementUsageDeSerializer.cs index dd1df263..9d611404 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/RequirementUsageDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/RequirementUsageDeSerializer.cs @@ -142,26 +142,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the assumedConstraint Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -182,30 +162,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the chainingFeature Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("constraintDefinition"u8, out var constraintDefinitionProperty)) - { - if (constraintDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.constraintDefinition = null; - } - else - { - if (constraintDefinitionProperty.TryGetProperty("@id"u8, out var constraintDefinitionExternalIdProperty)) - { - var propertyValue = constraintDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.constraintDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the constraintDefinition Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("crossFeature"u8, out var crossFeatureProperty)) { if (crossFeatureProperty.ValueKind == JsonValueKind.Null) @@ -239,35 +195,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the declaredName Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("declaredShortName"u8, out var declaredShortNameProperty)) - { - dtoInstance.DeclaredShortName = declaredShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the declaredShortName Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -288,26 +215,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the differencingType Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -520,30 +427,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the framedConcern Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -848,18 +731,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the isUnique Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2230,30 +2101,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the portionKind Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("predicate"u8, out var predicateProperty)) - { - if (predicateProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.predicate = null; - } - else - { - if (predicateProperty.TryGetProperty("@id"u8, out var predicateExternalIdProperty)) - { - var propertyValue = predicateExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.predicate = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the predicate Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -2432,26 +2279,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the textualRepresentation Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/SelectExpressionDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/SelectExpressionDeSerializer.cs index bafae0d1..8c524c31 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/SelectExpressionDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/SelectExpressionDeSerializer.cs @@ -122,26 +122,6 @@ internal static ISelectExpression DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the argument Json property was not found in the SelectExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the SelectExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -224,26 +204,6 @@ internal static ISelectExpression DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the differencingType Json property was not found in the SelectExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the SelectExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/SubclassificationDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/SubclassificationDeSerializer.cs index 7d0a0800..08b87b06 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/SubclassificationDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/SubclassificationDeSerializer.cs @@ -154,31 +154,6 @@ internal static ISubclassification DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the elementId Json property was not found in the Subclassification: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("general"u8, out var generalProperty)) - { - if (generalProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.General = Guid.Empty; - logger.LogDebug($"the Subclassification.General property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (generalProperty.TryGetProperty("@id"u8, out var generalExternalIdProperty)) - { - var propertyValue = generalExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.General = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the general Json property was not found in the Subclassification: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isImplied"u8, out var isImpliedProperty)) { if (isImpliedProperty.ValueKind != JsonValueKind.Null) @@ -448,30 +423,6 @@ internal static ISubclassification DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the owningRelationship Json property was not found in the Subclassification: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningType"u8, out var owningTypeProperty)) - { - if (owningTypeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningType = null; - } - else - { - if (owningTypeProperty.TryGetProperty("@id"u8, out var owningTypeExternalIdProperty)) - { - var propertyValue = owningTypeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningType = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningType Json property was not found in the Subclassification: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -510,51 +461,6 @@ internal static ISubclassification DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the shortName Json property was not found in the Subclassification: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Subclassification: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("specific"u8, out var specificProperty)) - { - if (specificProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.Specific = Guid.Empty; - logger.LogDebug($"the Subclassification.Specific property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (specificProperty.TryGetProperty("@id"u8, out var specificExternalIdProperty)) - { - var propertyValue = specificExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Specific = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the specific Json property was not found in the Subclassification: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("subclassifier"u8, out var subclassifierProperty)) { if (subclassifierProperty.ValueKind == JsonValueKind.Null) @@ -605,26 +511,6 @@ internal static ISubclassification DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the superclassifier Json property was not found in the Subclassification: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Subclassification: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/TextualRepresentationDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/TextualRepresentationDeSerializer.cs index 6603632e..6111bc8f 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/TextualRepresentationDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/TextualRepresentationDeSerializer.cs @@ -102,26 +102,6 @@ internal static ITextualRepresentation DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the aliasIds Json property was not found in the TextualRepresentation: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("annotatedElement"u8, out var annotatedElementProperty)) - { - foreach (var arrayItem in annotatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var annotatedElementExternalIdProperty)) - { - var propertyValue = annotatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.annotatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the annotatedElement Json property was not found in the TextualRepresentation: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("annotation"u8, out var annotationProperty)) { foreach (var arrayItem in annotationProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/UsageDeSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/UsageDeSerializer.cs index 4fca12fd..2e6c3e65 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/UsageDeSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDeSerializer/UsageDeSerializer.cs @@ -672,18 +672,6 @@ internal static IUsage DeSerialize(JsonElement jsonElement, SerializationModeKin logger.LogDebug("the isUnique Json property was not found in the Usage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the Usage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2043,26 +2031,6 @@ internal static IUsage DeSerialize(JsonElement jsonElement, SerializationModeKin logger.LogDebug("the textualRepresentation Json property was not found in the Usage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the Usage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Association.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Association.cs index d9a7e722..4492698c 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Association.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Association.cs @@ -127,7 +127,7 @@ public partial class Association : IAssociation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.associationEnd; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -507,7 +507,7 @@ public partial class Association : IAssociation [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedType; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -535,7 +535,11 @@ public partial class Association : IAssociation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType.HasValue ? [this.sourceType.Value] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -553,7 +557,11 @@ public partial class Association : IAssociation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetType; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Dependency.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Dependency.cs index 1d52d4d3..2ec9d8c3 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Dependency.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Dependency.cs @@ -246,7 +246,14 @@ public partial class Dependency : IDependency [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDependency.Client")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.Client; + set + { + this.Client = value; + } + } /// /// The Element or Elements on which the client Elements depend in some respect. @@ -263,7 +270,14 @@ public partial class Dependency : IDependency [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDependency.Supplier")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.Supplier; + set + { + this.Supplier = value; + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/EnumerationDefinition.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/EnumerationDefinition.cs index 0a98030f..f464ccd9 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/EnumerationDefinition.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/EnumerationDefinition.cs @@ -259,7 +259,14 @@ public partial class EnumerationDefinition : IEnumerationDefinition [Property(xmiId: "_19_0_2_12e503d9_1590978283180_265362_419", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IEnumerationDefinition.IsVariation")] [Implements(implementation: "IDefinition.IsVariation")] - bool Systems.DefinitionAndUsage.IDefinition.IsVariation { get; set; } + bool Systems.DefinitionAndUsage.IDefinition.IsVariation + { + get => this.IsVariation; + set + { + this.IsVariation = value; + } + } /// /// The set of all member Elements of this Namespace, which are the memberElements of all memberships of @@ -765,7 +772,7 @@ public partial class EnumerationDefinition : IEnumerationDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674979_259543_43268")] [RedefinedByProperty("IEnumerationDefinition.EnumeratedValue")] [Implements(implementation: "IDefinition.Variant")] - public List variant { get; internal set; } = []; + List Systems.DefinitionAndUsage.IDefinition.variant => this.enumeratedValue; /// /// The ownedMemberships of this Definition that are VariantMemberships. If isVariation = true, then diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/FeatureTyping.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/FeatureTyping.cs index 6184f9ff..ffa0795f 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/FeatureTyping.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/FeatureTyping.cs @@ -96,7 +96,14 @@ public partial class FeatureTyping : IFeatureTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IFeatureTyping.Type")] [Implements(implementation: "ISpecialization.General")] - public Guid General { get; set; } + Guid Core.Types.ISpecialization.General + { + get => this.Type; + set + { + this.Type = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -227,7 +234,7 @@ public partial class FeatureTyping : IFeatureTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("IFeatureTyping.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public Guid? owningType { get; internal set; } + Guid? Core.Types.ISpecialization.owningType => this.owningFeature.HasValue ? this.owningFeature.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -266,7 +273,18 @@ public partial class FeatureTyping : IFeatureTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific = value[0]; + } + + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -275,7 +293,14 @@ public partial class FeatureTyping : IFeatureTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureTyping.TypedFeature")] [Implements(implementation: "ISpecialization.Specific")] - public Guid Specific { get; set; } + Guid Core.Types.ISpecialization.Specific + { + get => this.TypedFeature; + set + { + this.TypedFeature = value; + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -284,7 +309,18 @@ public partial class FeatureTyping : IFeatureTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Flow.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Flow.cs index bedd547b..57dba154 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Flow.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Flow.cs @@ -62,7 +62,7 @@ public partial class Flow : IFlow [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IConnector.Association")] - public List association { get; internal set; } = []; + List Kernel.Connectors.IConnector.association => this.interaction; /// /// The Behaviors that type this Step. @@ -71,7 +71,7 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.interaction; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -151,7 +151,7 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -185,7 +185,7 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -788,7 +788,7 @@ public partial class Flow : IFlow [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -816,7 +816,11 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -842,7 +846,11 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -880,7 +888,7 @@ public partial class Flow : IFlow [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Kernel.Connectors.IConnector)this).association; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/FramedConcernMembership.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/FramedConcernMembership.cs index f2afad4e..fdf66bc9 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/FramedConcernMembership.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/FramedConcernMembership.cs @@ -128,7 +128,14 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_2_12e503d9_1584048161309_821854_390", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IFramedConcernMembership.Kind")] [Implements(implementation: "IRequirementConstraintMembership.Kind")] - RequirementConstraintKind IRequirementConstraintMembership.Kind { get; set; } + RequirementConstraintKind IRequirementConstraintMembership.Kind + { + get => this.Kind; + set + { + this.Kind = value; + } + } /// /// The Element that becomes a member of the membershipOwningNamespace due to this Membership. @@ -137,7 +144,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -145,7 +156,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -153,7 +164,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -164,7 +179,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -172,7 +187,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -209,7 +228,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674993_898044_43344")] [RedefinedByProperty("IFramedConcernMembership.OwnedConcern")] [Implements(implementation: "IRequirementConstraintMembership.OwnedConstraint")] - public Guid ownedConstraint { get; internal set; } + Guid IRequirementConstraintMembership.ownedConstraint => this.ownedConcern; /// /// The Elements owned by this Element, derived as the ownedRelatedElements of the ownedRelationships of @@ -228,7 +247,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -246,7 +265,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IRequirementConstraintMembership.OwnedConstraint")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => ((SysML2.NET.Core.DTO.Systems.Requirements.IRequirementConstraintMembership)this).ownedConstraint; /// /// The name of the ownedMemberElement. @@ -361,7 +380,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_4_12e503d9_1617118807597_77864_3544", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IFramedConcernMembership.ReferencedConcern")] [Implements(implementation: "IRequirementConstraintMembership.ReferencedConstraint")] - public Guid referencedConstraint { get; internal set; } + Guid IRequirementConstraintMembership.referencedConstraint => this.referencedConcern; /// /// The Elements that are related by this Relationship, derived as the union of the source and target @@ -388,7 +407,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -397,7 +420,18 @@ public partial class FramedConcernMembership : IFramedConcernMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/LiteralInteger.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/LiteralInteger.cs index e6d4e5c3..efe9f18d 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/LiteralInteger.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/LiteralInteger.cs @@ -60,7 +60,7 @@ public partial class LiteralInteger : ILiteralInteger [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -121,7 +121,7 @@ public partial class LiteralInteger : ILiteralInteger [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/LiteralRational.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/LiteralRational.cs index 8bc176e6..828c6405 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/LiteralRational.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/LiteralRational.cs @@ -60,7 +60,7 @@ public partial class LiteralRational : ILiteralRational [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -121,7 +121,7 @@ public partial class LiteralRational : ILiteralRational [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Membership.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Membership.cs index 9288ceee..6dc6ae7a 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Membership.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Membership.cs @@ -281,7 +281,11 @@ public partial class Membership : IMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -290,7 +294,18 @@ public partial class Membership : IMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.MemberElement]; + set + { + if (value.Count != 0) + { + this.MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/OwningMembership.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/OwningMembership.cs index 520c7443..2cd617ba 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/OwningMembership.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/OwningMembership.cs @@ -120,7 +120,11 @@ public partial class OwningMembership : IOwningMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid IMembership.MemberElement + { + get => this.ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -128,7 +132,7 @@ public partial class OwningMembership : IOwningMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -136,7 +140,11 @@ public partial class OwningMembership : IOwningMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -154,7 +162,11 @@ public partial class OwningMembership : IOwningMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -313,7 +325,11 @@ public partial class OwningMembership : IOwningMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -322,7 +338,18 @@ public partial class OwningMembership : IOwningMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/ReferenceSubsetting.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/ReferenceSubsetting.cs index 64523e47..f9b0888d 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/ReferenceSubsetting.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/ReferenceSubsetting.cs @@ -97,7 +97,14 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubsetting.SubsettedFeature")] [Implements(implementation: "ISpecialization.General")] - public Guid General { get; set; } + Guid Core.Types.ISpecialization.General + { + get => ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettedFeature; + set + { + ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettedFeature = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -185,7 +192,7 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_573157_43226")] [RedefinedByProperty("IReferenceSubsetting.ReferencingFeature")] [Implements(implementation: "ISubsetting.OwningFeature")] - public Guid? owningFeature { get; internal set; } + Guid? ISubsetting.owningFeature => this.referencingFeature; /// /// The owningRelationship of this Element, if that Relationship is a Membership. @@ -229,7 +236,7 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubsetting.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public Guid? owningType { get; internal set; } + Guid? Core.Types.ISpecialization.owningType => ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).owningFeature.HasValue ? ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).owningFeature.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -285,7 +292,18 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific = value[0]; + } + + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -294,7 +312,14 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubsetting.SubsettingFeature")] [Implements(implementation: "ISpecialization.Specific")] - public Guid Specific { get; set; } + Guid Core.Types.ISpecialization.Specific + { + get => ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettingFeature; + set + { + ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettingFeature = value; + } + } /// /// The Feature that is subsetted by the subsettingFeature of this Subsetting. @@ -303,7 +328,14 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674980_563969_43273")] [RedefinedByProperty("IReferenceSubsetting.ReferencedFeature")] [Implements(implementation: "ISubsetting.SubsettedFeature")] - public Guid SubsettedFeature { get; set; } + Guid ISubsetting.SubsettedFeature + { + get => this.ReferencedFeature; + set + { + this.ReferencedFeature = value; + } + } /// /// The Feature that is a subset of the subsettedFeature of this Subsetting. @@ -312,7 +344,11 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("IReferenceSubsetting.ReferencingFeature")] [Implements(implementation: "ISubsetting.SubsettingFeature")] - public Guid SubsettingFeature { get; set; } + Guid ISubsetting.SubsettingFeature + { + get => this.referencingFeature; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -321,7 +357,18 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/RequirementUsage.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/RequirementUsage.cs index f1c91718..39868330 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/RequirementUsage.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/RequirementUsage.cs @@ -80,7 +80,7 @@ public partial class RequirementUsage : IRequirementUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -103,7 +103,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578025035149_386_969")] [RedefinedByProperty("IRequirementUsage.RequirementDefinition")] [Implements(implementation: "IConstraintUsage.ConstraintDefinition")] - public Guid? constraintDefinition { get; internal set; } + Guid? Systems.Constraints.IConstraintUsage.constraintDefinition => this.requirementDefinition.HasValue ? this.requirementDefinition.Value : Guid.Empty; /// /// The second chainingFeature of the crossedFeature of the ownedCrossSubsetting of this Feature, if it @@ -131,7 +131,14 @@ public partial class RequirementUsage : IRequirementUsage [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementUsage.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The Classifiers that are the types of this Usage. Nominally, these are Definitions, but other kinds @@ -142,7 +149,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -164,7 +171,7 @@ public partial class RequirementUsage : IRequirementUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -268,7 +275,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.HasValue ? ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -459,7 +466,11 @@ public partial class RequirementUsage : IRequirementUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1066,7 +1077,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public Guid? predicate { get; internal set; } + Guid? Kernel.Functions.IBooleanExpression.predicate => ((SysML2.NET.Core.DTO.Systems.Constraints.IConstraintUsage)this).constraintDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Constraints.IConstraintUsage)this).constraintDefinition.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1173,7 +1184,7 @@ public partial class RequirementUsage : IRequirementUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/SelectExpression.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/SelectExpression.cs index b4f157d6..7de13805 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/SelectExpression.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/SelectExpression.cs @@ -70,7 +70,7 @@ public partial class SelectExpression : ISelectExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -131,7 +131,7 @@ public partial class SelectExpression : ISelectExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -443,7 +443,14 @@ public partial class SelectExpression : ISelectExpression [Property(xmiId: "_18_5_3_12e503d9_1557528808100_646606_111674", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("ISelectExpression.Operator")] [Implements(implementation: "IOperatorExpression.Operator")] - string IOperatorExpression.Operator { get; set; } + string IOperatorExpression.Operator + { + get => this.Operator; + set + { + this.Operator = value; + } + } /// /// All features related to this Type by FeatureMemberships that have direction out or inout. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Subclassification.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Subclassification.cs index e27b7096..f9e87666 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Subclassification.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Subclassification.cs @@ -94,7 +94,14 @@ public partial class Subclassification : ISubclassification [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubclassification.Superclassifier")] [Implements(implementation: "ISpecialization.General")] - public Guid General { get; set; } + Guid Core.Types.ISpecialization.General + { + get => this.Superclassifier; + set + { + this.Superclassifier = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -224,7 +231,7 @@ public partial class Subclassification : ISubclassification [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubclassification.OwningClassifier")] [Implements(implementation: "ISpecialization.OwningType")] - public Guid? owningType { get; internal set; } + Guid? Core.Types.ISpecialization.owningType => this.owningClassifier.HasValue ? this.owningClassifier.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -263,7 +270,18 @@ public partial class Subclassification : ISubclassification [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific = value[0]; + } + + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -272,7 +290,14 @@ public partial class Subclassification : ISubclassification [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubclassification.Subclassifier")] [Implements(implementation: "ISpecialization.Specific")] - public Guid Specific { get; set; } + Guid Core.Types.ISpecialization.Specific + { + get => this.Subclassifier; + set + { + this.Subclassifier = value; + } + } /// /// The more specific Classifier in this Subclassification. @@ -297,7 +322,18 @@ public partial class Subclassification : ISubclassification [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/TextualRepresentation.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/TextualRepresentation.cs index eea9fb43..8e31e69b 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/TextualRepresentation.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/TextualRepresentation.cs @@ -82,7 +82,7 @@ public partial class TextualRepresentation : ITextualRepresentation [Property(xmiId: "_19_0_2_12e503d9_1594145755058_99428_86", aggregation: AggregationKind.None, lowerValue: 1, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("ITextualRepresentation.RepresentedElement")] [Implements(implementation: "IAnnotatingElement.AnnotatedElement")] - public List annotatedElement { get; internal set; } = []; + List IAnnotatingElement.annotatedElement => [this.representedElement]; /// /// The Annotations that relate this AnnotatingElement to its annotatedElements. This includes the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Usage.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Usage.cs index 2fe52c1c..142615bb 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Usage.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenDto/Usage.cs @@ -380,7 +380,11 @@ public partial class Usage : IUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -992,7 +996,7 @@ public partial class Usage : IUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => this.definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/EnumerationDefinitionFactory.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/EnumerationDefinitionFactory.cs index aaf9c0e1..4eeaf66d 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/EnumerationDefinitionFactory.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/EnumerationDefinitionFactory.cs @@ -62,8 +62,7 @@ public Core.POCO.Systems.Enumerations.EnumerationDefinition Create(Core.DTO.Syst poco.IsAbstract = dto.IsAbstract; poco.IsImpliedIncluded = dto.IsImpliedIncluded; poco.IsSufficient = dto.IsSufficient; - ((Core.POCO.Systems.Enumerations.IEnumerationDefinition)poco).IsVariation = ((Core.DTO.Systems.Enumerations.IEnumerationDefinition)dto).IsVariation; - ((Core.POCO.Systems.DefinitionAndUsage.IDefinition)poco).IsVariation = ((Core.DTO.Systems.DefinitionAndUsage.IDefinition)dto).IsVariation; + poco.IsVariation = dto.IsVariation; return poco; } diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/FramedConcernMembershipFactory.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/FramedConcernMembershipFactory.cs index 56fa97d6..81a74e09 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/FramedConcernMembershipFactory.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/FramedConcernMembershipFactory.cs @@ -61,10 +61,7 @@ public Core.POCO.Systems.Requirements.FramedConcernMembership Create(Core.DTO.Sy poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - ((Core.POCO.Systems.Requirements.IFramedConcernMembership)poco).Kind = ((Core.DTO.Systems.Requirements.IFramedConcernMembership)dto).Kind; - ((Core.POCO.Systems.Requirements.IRequirementConstraintMembership)poco).Kind = ((Core.DTO.Systems.Requirements.IRequirementConstraintMembership)dto).Kind; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; + poco.Kind = dto.Kind; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/OwningMembershipFactory.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/OwningMembershipFactory.cs index 7926722f..9141e471 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/OwningMembershipFactory.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/OwningMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Root.Namespaces.OwningMembership Create(Core.DTO.Root.Namespace poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/RequirementUsageFactory.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/RequirementUsageFactory.cs index 696f52e2..a9a1f811 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/RequirementUsageFactory.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/RequirementUsageFactory.cs @@ -57,7 +57,6 @@ public Core.POCO.Systems.Requirements.RequirementUsage Create(Core.DTO.Systems.R poco.Id = dto.Id; poco.AliasIds = dto.AliasIds; poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; poco.Direction = dto.Direction; poco.ElementId = dto.ElementId; poco.IsAbstract = dto.IsAbstract; @@ -71,7 +70,6 @@ public Core.POCO.Systems.Requirements.RequirementUsage Create(Core.DTO.Systems.R poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; poco.ReqId = dto.ReqId; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/SelectExpressionFactory.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/SelectExpressionFactory.cs index 237c2f0f..afb2eddc 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/SelectExpressionFactory.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/SelectExpressionFactory.cs @@ -71,8 +71,7 @@ public Core.POCO.Kernel.Expressions.SelectExpression Create(Core.DTO.Kernel.Expr poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; poco.IsVariable = dto.IsVariable; - ((Core.POCO.Kernel.Expressions.ISelectExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.ISelectExpression)dto).Operator; - ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator; + poco.Operator = dto.Operator; return poco; } diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/UsageFactory.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/UsageFactory.cs index 734e3a46..f34aa5a4 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/UsageFactory.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenElementFactory/UsageFactory.cs @@ -70,7 +70,6 @@ public Core.POCO.Systems.DefinitionAndUsage.Usage Create(Core.DTO.Systems.Defini poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; return poco; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/AnnotatingElement.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/AnnotatingElement.cs index 163d17d5..f743d7fd 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/AnnotatingElement.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/AnnotatingElement.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Annotations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Elements; using SysML2.NET.Core.POCO.Root.Namespaces; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Association.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Association.cs index afc56508..7e843483 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Association.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Association.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Associations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -131,7 +132,7 @@ public partial class Association : IAssociation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.associationEnd]; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -511,7 +512,7 @@ public partial class Association : IAssociation [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedType]; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -539,7 +540,11 @@ public partial class Association : IAssociation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType != null ? [this.sourceType] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -557,7 +562,11 @@ public partial class Association : IAssociation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetType]; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Dependency.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Dependency.cs index 006059c1..ded1b9ed 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Dependency.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Dependency.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Dependencies using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Elements; @@ -248,7 +249,14 @@ public partial class Dependency : IDependency [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDependency.Client")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [.. this.Client]; + set + { + this.Client = value; + } + } /// /// The Element or Elements on which the client Elements depend in some respect. @@ -265,7 +273,14 @@ public partial class Dependency : IDependency [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDependency.Supplier")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.Supplier]; + set + { + this.Supplier = value; + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/EnumerationDefinition.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/EnumerationDefinition.cs index 31cd19d1..db2e84b9 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/EnumerationDefinition.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/EnumerationDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Enumerations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -285,7 +286,14 @@ public partial class EnumerationDefinition : IEnumerationDefinition [Property(xmiId: "_19_0_2_12e503d9_1590978283180_265362_419", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IEnumerationDefinition.IsVariation")] [Implements(implementation: "IDefinition.IsVariation")] - bool Systems.DefinitionAndUsage.IDefinition.IsVariation { get; set; } + bool Systems.DefinitionAndUsage.IDefinition.IsVariation + { + get => this.IsVariation; + set + { + this.IsVariation = value; + } + } /// /// The set of all member Elements of this Namespace, which are the memberElements of all memberships of @@ -791,7 +799,7 @@ public partial class EnumerationDefinition : IEnumerationDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674979_259543_43268")] [RedefinedByProperty("IEnumerationDefinition.EnumeratedValue")] [Implements(implementation: "IDefinition.Variant")] - public List variant => this.ComputeVariant(); + List Systems.DefinitionAndUsage.IDefinition.variant => [.. this.enumeratedValue]; /// /// The ownedMemberships of this Definition that are VariantMemberships. If isVariation = true, then diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Feature.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Feature.cs index 4129388e..9c1d526d 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Feature.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Feature.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Types; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/FeatureTyping.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/FeatureTyping.cs index cc029982..9bfc9e11 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/FeatureTyping.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/FeatureTyping.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Types; using SysML2.NET.Core.POCO.Root.Annotations; @@ -99,7 +100,14 @@ public partial class FeatureTyping : IFeatureTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IFeatureTyping.Type")] [Implements(implementation: "ISpecialization.General")] - public IType General { get; set; } + IType Core.Types.ISpecialization.General + { + get => this.Type; + set + { + this.Type = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -230,7 +238,7 @@ public partial class FeatureTyping : IFeatureTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("IFeatureTyping.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public IType owningType => this.ComputeOwningType(); + IType Core.Types.ISpecialization.owningType => this.owningFeature; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -269,7 +277,17 @@ public partial class FeatureTyping : IFeatureTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific = firstValue; + } + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -278,7 +296,17 @@ public partial class FeatureTyping : IFeatureTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureTyping.TypedFeature")] [Implements(implementation: "ISpecialization.Specific")] - public IType Specific { get; set; } + IType Core.Types.ISpecialization.Specific + { + get => this.TypedFeature; + set + { + if (value is IFeature castedValue) + { + this.TypedFeature = castedValue; + } + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -287,7 +315,17 @@ public partial class FeatureTyping : IFeatureTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Flow.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Flow.cs index 80a56b08..e1463d10 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Flow.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Flow.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Interactions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Classifiers; @@ -69,7 +70,7 @@ public partial class Flow : IFlow [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IConnector.Association")] - public List association => this.ComputeAssociation(); + List Kernel.Connectors.IConnector.association => [.. this.interaction]; /// /// The Behaviors that type this Step. @@ -78,7 +79,7 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.interaction]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -158,7 +159,7 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -192,7 +193,7 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -795,7 +796,7 @@ public partial class Flow : IFlow [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -823,7 +824,11 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -849,7 +854,11 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -887,7 +896,7 @@ public partial class Flow : IFlow [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Kernel.Connectors.IConnector)this).association]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/FramedConcernMembership.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/FramedConcernMembership.cs index e3e9b0ad..6aea3cc1 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/FramedConcernMembership.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/FramedConcernMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Requirements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.Systems.Requirements; @@ -134,7 +135,14 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_2_12e503d9_1584048161309_821854_390", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IFramedConcernMembership.Kind")] [Implements(implementation: "IRequirementConstraintMembership.Kind")] - RequirementConstraintKind IRequirementConstraintMembership.Kind { get; set; } + RequirementConstraintKind IRequirementConstraintMembership.Kind + { + get => this.Kind; + set + { + this.Kind = value; + } + } /// /// The Element that becomes a member of the membershipOwningNamespace due to this Membership. @@ -143,7 +151,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -151,7 +163,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -159,7 +171,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -170,7 +186,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -178,7 +194,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -215,7 +235,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674993_898044_43344")] [RedefinedByProperty("IFramedConcernMembership.OwnedConcern")] [Implements(implementation: "IRequirementConstraintMembership.OwnedConstraint")] - public IConstraintUsage ownedConstraint => this.ComputeOwnedConstraint(); + IConstraintUsage IRequirementConstraintMembership.ownedConstraint => this.ownedConcern; /// /// The Elements owned by this Element, derived as the ownedRelatedElements of the ownedRelationships of @@ -234,7 +254,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -252,7 +272,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IRequirementConstraintMembership.OwnedConstraint")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => ((SysML2.NET.Core.POCO.Systems.Requirements.IRequirementConstraintMembership)this).ownedConstraint; /// /// The name of the ownedMemberElement. @@ -367,7 +387,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_4_12e503d9_1617118807597_77864_3544", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IFramedConcernMembership.ReferencedConcern")] [Implements(implementation: "IRequirementConstraintMembership.ReferencedConstraint")] - public IConstraintUsage referencedConstraint => this.ComputeReferencedConstraint(); + IConstraintUsage IRequirementConstraintMembership.referencedConstraint => this.referencedConcern; /// /// The Elements that are related by this Relationship, derived as the union of the source and target @@ -394,7 +414,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -403,7 +427,17 @@ public partial class FramedConcernMembership : IFramedConcernMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/LiteralInteger.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/LiteralInteger.cs index 841d4856..850bab5a 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/LiteralInteger.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/LiteralInteger.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -67,7 +68,7 @@ public partial class LiteralInteger : ILiteralInteger [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -128,7 +129,7 @@ public partial class LiteralInteger : ILiteralInteger [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/LiteralRational.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/LiteralRational.cs index 61c54fea..43fb70c4 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/LiteralRational.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/LiteralRational.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -67,7 +68,7 @@ public partial class LiteralRational : ILiteralRational [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -128,7 +129,7 @@ public partial class LiteralRational : ILiteralRational [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Membership.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Membership.cs index f299d450..f078b967 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Membership.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Membership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Namespaces using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Root.Annotations; @@ -282,7 +283,11 @@ public partial class Membership : IMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.membershipOwningNamespace != null ? [this.membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -291,7 +296,17 @@ public partial class Membership : IMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.MemberElement != null ? [this.MemberElement] : []; + set + { + if (value.Count != 0) + { + this.MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/MultiplicityRange.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/MultiplicityRange.cs index 34d194ec..40f5bf6f 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/MultiplicityRange.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/MultiplicityRange.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Multiplicities using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/OwningMembership.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/OwningMembership.cs index a2676641..5b88987b 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/OwningMembership.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/OwningMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Namespaces using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Root.Annotations; @@ -122,7 +123,11 @@ public partial class OwningMembership : IOwningMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement IMembership.MemberElement + { + get => this.ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -130,7 +135,7 @@ public partial class OwningMembership : IOwningMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -138,7 +143,11 @@ public partial class OwningMembership : IOwningMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -156,7 +165,11 @@ public partial class OwningMembership : IOwningMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -315,7 +328,11 @@ public partial class OwningMembership : IOwningMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.membershipOwningNamespace != null ? [this.membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -324,7 +341,17 @@ public partial class OwningMembership : IOwningMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/ReferenceSubsetting.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/ReferenceSubsetting.cs index 710fee41..6ca20a99 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/ReferenceSubsetting.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/ReferenceSubsetting.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Types; using SysML2.NET.Core.POCO.Root.Annotations; @@ -101,7 +102,17 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubsetting.SubsettedFeature")] [Implements(implementation: "ISpecialization.General")] - public IType General { get; set; } + IType Core.Types.ISpecialization.General + { + get => ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettedFeature; + set + { + if (value is IFeature castedValue) + { + ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettedFeature = castedValue; + } + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -189,7 +200,7 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_573157_43226")] [RedefinedByProperty("IReferenceSubsetting.ReferencingFeature")] [Implements(implementation: "ISubsetting.OwningFeature")] - public IFeature owningFeature => this.ComputeOwningFeature(); + IFeature ISubsetting.owningFeature => this.referencingFeature; /// /// The owningRelationship of this Element, if that Relationship is a Membership. @@ -233,7 +244,7 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubsetting.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public IType owningType => this.ComputeOwningType(); + IType Core.Types.ISpecialization.owningType => ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).owningFeature; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -289,7 +300,17 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific = firstValue; + } + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -298,7 +319,17 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubsetting.SubsettingFeature")] [Implements(implementation: "ISpecialization.Specific")] - public IType Specific { get; set; } + IType Core.Types.ISpecialization.Specific + { + get => ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettingFeature; + set + { + if (value is IFeature castedValue) + { + ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettingFeature = castedValue; + } + } + } /// /// The Feature that is subsetted by the subsettingFeature of this Subsetting. @@ -307,7 +338,14 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674980_563969_43273")] [RedefinedByProperty("IReferenceSubsetting.ReferencedFeature")] [Implements(implementation: "ISubsetting.SubsettedFeature")] - public IFeature SubsettedFeature { get; set; } + IFeature ISubsetting.SubsettedFeature + { + get => this.ReferencedFeature; + set + { + this.ReferencedFeature = value; + } + } /// /// The Feature that is a subset of the subsettedFeature of this Subsetting. @@ -316,7 +354,11 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("IReferenceSubsetting.ReferencingFeature")] [Implements(implementation: "ISubsetting.SubsettingFeature")] - public IFeature SubsettingFeature { get; set; } + IFeature ISubsetting.SubsettingFeature + { + get => this.referencingFeature; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -325,7 +367,17 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/RequirementUsage.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/RequirementUsage.cs index cf45508a..c5d713f2 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/RequirementUsage.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/RequirementUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Requirements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -109,7 +110,7 @@ public partial class RequirementUsage : IRequirementUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -132,7 +133,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578025035149_386_969")] [RedefinedByProperty("IRequirementUsage.RequirementDefinition")] [Implements(implementation: "IConstraintUsage.ConstraintDefinition")] - public IPredicate constraintDefinition => this.ComputeConstraintDefinition(); + IPredicate Systems.Constraints.IConstraintUsage.constraintDefinition => this.requirementDefinition; /// /// The second chainingFeature of the crossedFeature of the ownedCrossSubsetting of this Feature, if it @@ -160,7 +161,14 @@ public partial class RequirementUsage : IRequirementUsage [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementUsage.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The Classifiers that are the types of this Usage. Nominally, these are Definitions, but other kinds @@ -171,7 +179,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -193,7 +201,7 @@ public partial class RequirementUsage : IRequirementUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -297,7 +305,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => ((SysML2.NET.Core.POCO.Kernel.Functions.IBooleanExpression)this).predicate; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -488,7 +496,11 @@ public partial class RequirementUsage : IRequirementUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1095,7 +1107,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public IPredicate predicate => this.ComputePredicate(); + IPredicate Kernel.Functions.IBooleanExpression.predicate => ((SysML2.NET.Core.POCO.Systems.Constraints.IConstraintUsage)this).constraintDefinition; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1202,7 +1214,7 @@ public partial class RequirementUsage : IRequirementUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/SelectExpression.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/SelectExpression.cs index ccb87dd6..86c207f6 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/SelectExpression.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/SelectExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -77,7 +78,7 @@ public partial class SelectExpression : ISelectExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -138,7 +139,7 @@ public partial class SelectExpression : ISelectExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -450,7 +451,14 @@ public partial class SelectExpression : ISelectExpression [Property(xmiId: "_18_5_3_12e503d9_1557528808100_646606_111674", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("ISelectExpression.Operator")] [Implements(implementation: "IOperatorExpression.Operator")] - string IOperatorExpression.Operator { get; set; } + string IOperatorExpression.Operator + { + get => this.Operator; + set + { + this.Operator = value; + } + } /// /// All features related to this Type by FeatureMemberships that have direction out or inout. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Subclassification.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Subclassification.cs index d075a275..43fe7deb 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Subclassification.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Subclassification.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Classifiers using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Types; using SysML2.NET.Core.POCO.Root.Annotations; @@ -97,7 +98,17 @@ public partial class Subclassification : ISubclassification [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubclassification.Superclassifier")] [Implements(implementation: "ISpecialization.General")] - public IType General { get; set; } + IType Core.Types.ISpecialization.General + { + get => this.Superclassifier; + set + { + if (value is IClassifier castedValue) + { + this.Superclassifier = castedValue; + } + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -227,7 +238,7 @@ public partial class Subclassification : ISubclassification [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubclassification.OwningClassifier")] [Implements(implementation: "ISpecialization.OwningType")] - public IType owningType => this.ComputeOwningType(); + IType Core.Types.ISpecialization.owningType => this.owningClassifier; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -266,7 +277,17 @@ public partial class Subclassification : ISubclassification [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific = firstValue; + } + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -275,7 +296,17 @@ public partial class Subclassification : ISubclassification [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubclassification.Subclassifier")] [Implements(implementation: "ISpecialization.Specific")] - public IType Specific { get; set; } + IType Core.Types.ISpecialization.Specific + { + get => this.Subclassifier; + set + { + if (value is IClassifier castedValue) + { + this.Subclassifier = castedValue; + } + } + } /// /// The more specific Classifier in this Subclassification. @@ -300,7 +331,17 @@ public partial class Subclassification : ISubclassification [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/TextualRepresentation.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/TextualRepresentation.cs index 300dc499..99f0269d 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/TextualRepresentation.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/TextualRepresentation.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Annotations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Elements; using SysML2.NET.Core.POCO.Root.Namespaces; @@ -84,7 +85,7 @@ public partial class TextualRepresentation : ITextualRepresentation [Property(xmiId: "_19_0_2_12e503d9_1594145755058_99428_86", aggregation: AggregationKind.None, lowerValue: 1, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("ITextualRepresentation.RepresentedElement")] [Implements(implementation: "IAnnotatingElement.AnnotatedElement")] - public List annotatedElement => this.ComputeAnnotatedElement(); + List IAnnotatingElement.annotatedElement => this.representedElement != null ? [this.representedElement] : []; /// /// The Annotations that relate this AnnotatingElement to its annotatedElements. This includes the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Usage.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Usage.cs index 413f6221..bb2f5a02 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Usage.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPoco/Usage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.DefinitionAndUsage using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Classifiers; @@ -406,7 +407,11 @@ public partial class Usage : IUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1018,7 +1023,7 @@ public partial class Usage : IUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. this.definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/AssociationExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/AssociationExtensions.cs index eb055ce6..c62b19ae 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/AssociationExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/AssociationExtensions.cs @@ -101,22 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -193,26 +177,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Associations. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -241,8 +205,6 @@ public static Core.DTO.Kernel.Associations.Association ToDto(this Core.POCO.Kern dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/DependencyExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/DependencyExtensions.cs index e1e1e651..a4be9c0a 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/DependencyExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/DependencyExtensions.cs @@ -105,14 +105,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - var supplierToDelete = poco.Supplier.Select(x => x.Id).Except(dto.Supplier); foreach (var identifier in supplierToDelete) @@ -121,14 +113,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t } - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -215,16 +199,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Dependencies.De poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - var supplierToAdd = dto.Supplier.Except(poco.Supplier.Select(x => x.Id)); foreach (var identifier in supplierToAdd) @@ -235,16 +209,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Dependencies.De } } - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -272,9 +236,7 @@ public static Core.DTO.Root.Dependencies.Dependency ToDto(this Core.POCO.Root.De dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); dto.Supplier = poco.Supplier.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/EnumerationDefinitionExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/EnumerationDefinitionExtensions.cs index c7e6df9a..7d4a889f 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/EnumerationDefinitionExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/EnumerationDefinitionExtensions.cs @@ -81,9 +81,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsSufficient = dto.IsSufficient; - ((Core.POCO.Systems.Enumerations.IEnumerationDefinition)poco).IsVariation = ((Core.DTO.Systems.Enumerations.IEnumerationDefinition)dto).IsVariation; - - ((Core.POCO.Systems.DefinitionAndUsage.IDefinition)poco).IsVariation = ((Core.DTO.Systems.DefinitionAndUsage.IDefinition)dto).IsVariation; + poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -174,8 +172,7 @@ public static Core.DTO.Systems.Enumerations.EnumerationDefinition ToDto(this Cor dto.IsAbstract = poco.IsAbstract; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.IsSufficient = poco.IsSufficient; - ((Core.DTO.Systems.Enumerations.IEnumerationDefinition)dto).IsVariation = ((Core.POCO.Systems.Enumerations.IEnumerationDefinition)poco).IsVariation; - ((Core.DTO.Systems.DefinitionAndUsage.IDefinition)dto).IsVariation = ((Core.POCO.Systems.DefinitionAndUsage.IDefinition)poco).IsVariation; + dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/FeatureTypingExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/FeatureTypingExtensions.cs index 87fc2ee5..efe734f5 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/FeatureTypingExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/FeatureTypingExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -151,15 +135,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Featur Lazy lazyPoco; - if (cache.TryGetValue(dto.General, out lazyPoco)) - { - poco.General = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.General = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -198,35 +173,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Featur poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - if (cache.TryGetValue(dto.Specific, out lazyPoco)) - { - poco.Specific = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.Specific = null; - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - if (cache.TryGetValue(dto.Type, out lazyPoco)) { poco.Type = (Core.POCO.Core.Types.Type)lazyPoco.Value; @@ -265,16 +211,12 @@ public static Core.DTO.Core.Features.FeatureTyping ToDto(this Core.POCO.Core.Fea dto.DeclaredName = poco.DeclaredName; dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; - dto.General = poco.General.Id; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Specific = poco.Specific.Id; - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Type = poco.Type.Id; dto.TypedFeature = poco.TypedFeature.Id; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/FlowExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/FlowExtensions.cs index 41e08951..93d2d21d 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/FlowExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/FlowExtensions.cs @@ -119,22 +119,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -211,26 +195,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Interactions. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -268,8 +232,6 @@ public static Core.DTO.Kernel.Interactions.Flow ToDto(this Core.POCO.Kernel.Inte dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/FramedConcernMembershipExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/FramedConcernMembershipExtensions.cs index 715e2131..e3e89d51 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/FramedConcernMembershipExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/FramedConcernMembershipExtensions.cs @@ -79,13 +79,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - ((Core.POCO.Systems.Requirements.IFramedConcernMembership)poco).Kind = ((Core.DTO.Systems.Requirements.IFramedConcernMembership)dto).Kind; - - ((Core.POCO.Systems.Requirements.IRequirementConstraintMembership)poco).Kind = ((Core.DTO.Systems.Requirements.IRequirementConstraintMembership)dto).Kind; - - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; + poco.Kind = dto.Kind; var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); @@ -105,22 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -161,15 +139,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Requirements Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -208,26 +177,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Requirements poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -250,17 +199,11 @@ public static Core.DTO.Systems.Requirements.FramedConcernMembership ToDto(this C dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - ((Core.DTO.Systems.Requirements.IFramedConcernMembership)dto).Kind = ((Core.POCO.Systems.Requirements.IFramedConcernMembership)poco).Kind; - ((Core.DTO.Systems.Requirements.IRequirementConstraintMembership)dto).Kind = ((Core.POCO.Systems.Requirements.IRequirementConstraintMembership)poco).Kind; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; + dto.Kind = poco.Kind; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/MembershipExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/MembershipExtensions.cs index 92d75722..566557df 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/MembershipExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/MembershipExtensions.cs @@ -101,22 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -204,26 +188,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Namespaces.Memb poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -253,8 +217,6 @@ public static Core.DTO.Root.Namespaces.Membership ToDto(this Core.POCO.Root.Name dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/OwningMembershipExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/OwningMembershipExtensions.cs index 4bef18f5..b03bb9a2 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/OwningMembershipExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/OwningMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Namespaces.Owni Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Namespaces.Owni poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Root.Namespaces.OwningMembership ToDto(this Core.POCO.Roo dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/ReferenceSubsettingExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/ReferenceSubsettingExtensions.cs index 7ffa1865..f26bf9e6 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/ReferenceSubsettingExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/ReferenceSubsettingExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -151,15 +135,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Refere Lazy lazyPoco; - if (cache.TryGetValue(dto.General, out lazyPoco)) - { - poco.General = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.General = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -207,53 +182,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Refere poco.ReferencedFeature = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - if (cache.TryGetValue(dto.Specific, out lazyPoco)) - { - poco.Specific = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.Specific = null; - } - - if (cache.TryGetValue(dto.SubsettedFeature, out lazyPoco)) - { - poco.SubsettedFeature = (Core.POCO.Core.Features.Feature)lazyPoco.Value; - } - else - { - poco.SubsettedFeature = null; - } - - if (cache.TryGetValue(dto.SubsettingFeature, out lazyPoco)) - { - poco.SubsettingFeature = (Core.POCO.Core.Features.Feature)lazyPoco.Value; - } - else - { - poco.SubsettingFeature = null; - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -274,7 +202,6 @@ public static Core.DTO.Core.Features.ReferenceSubsetting ToDto(this Core.POCO.Co dto.DeclaredName = poco.DeclaredName; dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; - dto.General = poco.General.Id; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); @@ -282,11 +209,6 @@ public static Core.DTO.Core.Features.ReferenceSubsetting ToDto(this Core.POCO.Co dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; dto.ReferencedFeature = poco.ReferencedFeature.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Specific = poco.Specific.Id; - dto.SubsettedFeature = poco.SubsettedFeature.Id; - dto.SubsettingFeature = poco.SubsettingFeature.Id; - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/RequirementUsageExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/RequirementUsageExtensions.cs index 7ad1ded2..51243dce 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/RequirementUsageExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/RequirementUsageExtensions.cs @@ -71,8 +71,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; - poco.Direction = dto.Direction; poco.ElementId = dto.ElementId; @@ -99,8 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -191,7 +187,6 @@ public static Core.DTO.Systems.Requirements.RequirementUsage ToDto(this Core.POC dto.Id = poco.Id; dto.AliasIds = poco.AliasIds; dto.DeclaredName = poco.DeclaredName; - dto.DeclaredShortName = poco.DeclaredShortName; dto.Direction = poco.Direction; dto.ElementId = poco.ElementId; dto.IsAbstract = poco.IsAbstract; @@ -205,7 +200,6 @@ public static Core.DTO.Systems.Requirements.RequirementUsage ToDto(this Core.POC dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/SelectExpressionExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/SelectExpressionExtensions.cs index 59354981..f8a80471 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/SelectExpressionExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/SelectExpressionExtensions.cs @@ -99,9 +99,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsVariable = dto.IsVariable; - ((Core.POCO.Kernel.Expressions.ISelectExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.ISelectExpression)dto).Operator; - - ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator; + poco.Operator = dto.Operator; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -201,8 +199,7 @@ public static Core.DTO.Kernel.Expressions.SelectExpression ToDto(this Core.POCO. dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; dto.IsVariable = poco.IsVariable; - ((Core.DTO.Kernel.Expressions.ISelectExpression)dto).Operator = ((Core.POCO.Kernel.Expressions.ISelectExpression)poco).Operator; - ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator = ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator; + dto.Operator = poco.Operator; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/SubclassificationExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/SubclassificationExtensions.cs index b9b0d83d..738e2dbe 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/SubclassificationExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/SubclassificationExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -151,15 +135,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Classifiers.Sub Lazy lazyPoco; - if (cache.TryGetValue(dto.General, out lazyPoco)) - { - poco.General = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.General = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -198,25 +173,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Classifiers.Sub poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - if (cache.TryGetValue(dto.Specific, out lazyPoco)) - { - poco.Specific = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.Specific = null; - } - if (cache.TryGetValue(dto.Subclassifier, out lazyPoco)) { poco.Subclassifier = (Core.POCO.Core.Classifiers.Classifier)lazyPoco.Value; @@ -235,16 +191,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Classifiers.Sub poco.Superclassifier = null; } - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -265,18 +211,14 @@ public static Core.DTO.Core.Classifiers.Subclassification ToDto(this Core.POCO.C dto.DeclaredName = poco.DeclaredName; dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; - dto.General = poco.General.Id; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Specific = poco.Specific.Id; dto.Subclassifier = poco.Subclassifier.Id; dto.Superclassifier = poco.Superclassifier.Id; - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/UsageExtensions.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/UsageExtensions.cs index 8519e813..2b2aaddf 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/UsageExtensions.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenPocoExtension/UsageExtensions.cs @@ -97,8 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -198,7 +196,6 @@ public static Core.DTO.Systems.DefinitionAndUsage.Usage ToDto(this Core.POCO.Sys dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/AssociationSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/AssociationSerializer.cs index 7c994785..695fed1b 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/AssociationSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/AssociationSerializer.cs @@ -156,18 +156,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssociation iAssociati writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iAssociation.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iAssociation.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("feature"u8); foreach (var item in iAssociation.feature) @@ -602,18 +590,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssociation iAssociati writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iAssociation.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iAssociation.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedType"u8); foreach (var item in iAssociation.relatedType) @@ -629,18 +605,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssociation iAssociati writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iAssociation.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iAssociation.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceType"u8); if (iAssociation.sourceType.HasValue) @@ -655,18 +619,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssociation iAssociati writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iAssociation.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetType"u8); foreach (var item in iAssociation.targetType) @@ -798,30 +750,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IAssociation iAssoci writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iAssociation.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iAssociation.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/DependencySerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/DependencySerializer.cs index 6209a62f..6e93e85f 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/DependencySerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/DependencySerializer.cs @@ -280,18 +280,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDependency iDependency writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iDependency.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iDependency.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("supplier"u8); foreach (var item in iDependency.Supplier) @@ -304,18 +292,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDependency iDependency writer.WriteEndArray(); - writer.WriteStartArray("target"u8); - - foreach (var item in iDependency.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iDependency.textualRepresentation) @@ -429,18 +405,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IDependency iDepende writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iDependency.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("supplier"u8); foreach (var item in iDependency.Supplier) @@ -453,18 +417,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IDependency iDepende writer.WriteEndArray(); - writer.WriteStartArray("target"u8); - - foreach (var item in iDependency.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/EnumerationDefinitionSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/EnumerationDefinitionSerializer.cs index f5075336..55be9e28 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/EnumerationDefinitionSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/EnumerationDefinitionSerializer.cs @@ -951,18 +951,6 @@ private static void SerializeAsJsonWithDerivedProperties(IEnumerationDefinition writer.WriteEndArray(); - writer.WriteStartArray("variant"u8); - - foreach (var item in iEnumerationDefinition.variant) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("variantMembership"u8); foreach (var item in iEnumerationDefinition.variantMembership) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/FeatureTypingSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/FeatureTypingSerializer.cs index 0d2e618b..9f53bba5 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/FeatureTypingSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/FeatureTypingSerializer.cs @@ -120,12 +120,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureTyping iFeature writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iFeatureTyping.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureTyping.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iFeatureTyping.IsImplied); @@ -270,20 +264,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureTyping iFeature writer.WriteNullValue(); } - writer.WritePropertyName("owningType"u8); - - if (iFeatureTyping.owningType.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureTyping.owningType.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iFeatureTyping.qualifiedName); @@ -302,36 +282,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureTyping iFeature writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iFeatureTyping.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iFeatureTyping.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureTyping.Specific); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFeatureTyping.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iFeatureTyping.textualRepresentation) @@ -387,12 +337,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFeatureTyping iFeat writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iFeatureTyping.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureTyping.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iFeatureTyping.IsImplied); @@ -451,36 +395,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFeatureTyping iFeat writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iFeatureTyping.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureTyping.Specific); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFeatureTyping.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("type"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/FlowSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/FlowSerializer.cs index 348f2753..37d58e0a 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/FlowSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/FlowSerializer.cs @@ -99,30 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WriteEndArray(); - writer.WriteStartArray("association"u8); - - foreach (var item in iFlow.association) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("behavior"u8); - - foreach (var item in iFlow.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iFlow.chainingFeature) @@ -193,18 +169,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iFlow.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iFlow.Direction.HasValue) @@ -231,18 +195,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iFlow.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iFlow.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iFlow.endOwningType.HasValue) @@ -911,18 +863,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iFlow.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iFlow.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iFlow.relatedFeature) @@ -938,18 +878,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iFlow.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iFlow.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iFlow.sourceFeature.HasValue) @@ -978,18 +906,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iFlow.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iFlow.targetFeature) @@ -1028,18 +944,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iFlow.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iFlow.unioningType) @@ -1182,30 +1086,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFlow iFlow, Utf8Jso writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iFlow.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFlow.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/FramedConcernMembershipSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/FramedConcernMembershipSerializer.cs index dcc15c59..4b092ba3 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/FramedConcernMembershipSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/FramedConcernMembershipSerializer.cs @@ -132,27 +132,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFramedConcernMembershi writer.WritePropertyName("kind"u8); writer.WriteStringValue(iFramedConcernMembership.Kind.ToString().ToLower()); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iFramedConcernMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iFramedConcernMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iFramedConcernMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iFramedConcernMembership.name); @@ -174,12 +153,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFramedConcernMembershi writer.WriteStringValue(iFramedConcernMembership.ownedConcern); writer.WriteEndObject(); - writer.WritePropertyName("ownedConstraint"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.ownedConstraint); - writer.WriteEndObject(); - writer.WriteStartArray("ownedElement"u8); foreach (var item in iFramedConcernMembership.ownedElement) @@ -192,21 +165,9 @@ private static void SerializeAsJsonWithDerivedProperties(IFramedConcernMembershi writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iFramedConcernMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iFramedConcernMembership.ownedMemberName); @@ -322,12 +283,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFramedConcernMembershi writer.WriteStringValue(iFramedConcernMembership.referencedConcern); writer.WriteEndObject(); - writer.WritePropertyName("referencedConstraint"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.referencedConstraint); - writer.WriteEndObject(); - writer.WriteStartArray("relatedElement"u8); foreach (var item in iFramedConcernMembership.relatedElement) @@ -343,30 +298,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFramedConcernMembershi writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iFramedConcernMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iFramedConcernMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFramedConcernMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iFramedConcernMembership.textualRepresentation) @@ -422,18 +353,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFramedConcernMember writer.WritePropertyName("kind"u8); writer.WriteStringValue(iFramedConcernMembership.Kind.ToString().ToLower()); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iFramedConcernMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iFramedConcernMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iFramedConcernMembership.OwnedRelatedElement) @@ -486,30 +405,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFramedConcernMember writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iFramedConcernMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFramedConcernMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iFramedConcernMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/LiteralIntegerSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/LiteralIntegerSerializer.cs index 57fce9ec..880c0ff2 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/LiteralIntegerSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/LiteralIntegerSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralInteger iLitera writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iLiteralInteger.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iLiteralInteger.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralInteger iLitera writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iLiteralInteger.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iLiteralInteger.Direction.HasValue) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/LiteralRationalSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/LiteralRationalSerializer.cs index 0a0427ab..7e7ddd4f 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/LiteralRationalSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/LiteralRationalSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralRational iLiter writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iLiteralRational.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iLiteralRational.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralRational iLiter writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iLiteralRational.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iLiteralRational.Direction.HasValue) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/MembershipSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/MembershipSerializer.cs index afd21edc..fd54e59b 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/MembershipSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/MembershipSerializer.cs @@ -289,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMembership iMembership writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iMembership.textualRepresentation) @@ -429,30 +405,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IMembership iMembers writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/OwningMembershipSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/OwningMembershipSerializer.cs index 0d664aa7..1359bec8 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/OwningMembershipSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/OwningMembershipSerializer.cs @@ -129,27 +129,12 @@ private static void SerializeAsJsonWithDerivedProperties(IOwningMembership iOwni writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iOwningMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iOwningMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iOwningMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iOwningMembership.MemberName); - writer.WritePropertyName("membershipOwningNamespace"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); writer.WriteStringValue(iOwningMembership.membershipOwningNamespace); writer.WriteEndObject(); - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iOwningMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iOwningMembership.name); @@ -304,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IOwningMembership iOwni writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iOwningMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iOwningMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iOwningMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iOwningMembership.textualRepresentation) @@ -380,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IOwningMembership iO writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iOwningMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iOwningMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iOwningMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iOwningMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iOwningMembership.OwnedRelatedElement) @@ -444,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IOwningMembership iO writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iOwningMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iOwningMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iOwningMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/ReferenceSubsettingSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/ReferenceSubsettingSerializer.cs index d7158143..8aad493e 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/ReferenceSubsettingSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/ReferenceSubsettingSerializer.cs @@ -120,12 +120,6 @@ private static void SerializeAsJsonWithDerivedProperties(IReferenceSubsetting iR writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iReferenceSubsetting.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iReferenceSubsetting.IsImplied); @@ -200,20 +194,6 @@ private static void SerializeAsJsonWithDerivedProperties(IReferenceSubsetting iR writer.WriteNullValue(); } - writer.WritePropertyName("owningFeature"u8); - - if (iReferenceSubsetting.owningFeature.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.owningFeature.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("owningMembership"u8); if (iReferenceSubsetting.owningMembership.HasValue) @@ -270,20 +250,6 @@ private static void SerializeAsJsonWithDerivedProperties(IReferenceSubsetting iR writer.WriteNullValue(); } - writer.WritePropertyName("owningType"u8); - - if (iReferenceSubsetting.owningType.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.owningType.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iReferenceSubsetting.qualifiedName); @@ -314,48 +280,6 @@ private static void SerializeAsJsonWithDerivedProperties(IReferenceSubsetting iR writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iReferenceSubsetting.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iReferenceSubsetting.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.Specific); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettedFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.SubsettedFeature); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettingFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.SubsettingFeature); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iReferenceSubsetting.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iReferenceSubsetting.textualRepresentation) @@ -399,12 +323,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IReferenceSubsetting writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iReferenceSubsetting.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iReferenceSubsetting.IsImplied); @@ -469,48 +387,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IReferenceSubsetting writer.WriteStringValue(iReferenceSubsetting.ReferencedFeature); writer.WriteEndObject(); - writer.WriteStartArray("source"u8); - - foreach (var item in iReferenceSubsetting.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.Specific); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettedFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.SubsettedFeature); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettingFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.SubsettingFeature); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iReferenceSubsetting.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/RequirementUsageSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/RequirementUsageSerializer.cs index 3ae50784..4cfb73c9 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/RequirementUsageSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/RequirementUsageSerializer.cs @@ -123,18 +123,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iRequirementUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iRequirementUsage.chainingFeature) @@ -147,20 +135,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WriteEndArray(); - writer.WritePropertyName("constraintDefinition"u8); - - if (iRequirementUsage.constraintDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementUsage.constraintDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("crossFeature"u8); if (iRequirementUsage.crossFeature.HasValue) @@ -178,21 +152,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iRequirementUsage.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iRequirementUsage.DeclaredShortName); - - writer.WriteStartArray("definition"u8); - - foreach (var item in iRequirementUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iRequirementUsage.differencingType) @@ -205,18 +164,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iRequirementUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iRequirementUsage.directedUsage) @@ -335,20 +282,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iRequirementUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iRequirementUsage.importedMembership) @@ -468,9 +401,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iRequirementUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iRequirementUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iRequirementUsage.IsVariation); @@ -1283,20 +1213,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WriteNullValue(); } - writer.WritePropertyName("predicate"u8); - - if (iRequirementUsage.predicate.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementUsage.predicate.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iRequirementUsage.qualifiedName); @@ -1377,18 +1293,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iRequirementUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iRequirementUsage.unioningType) @@ -1462,9 +1366,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IRequirementUsage iR writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iRequirementUsage.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iRequirementUsage.DeclaredShortName); - writer.WritePropertyName("direction"u8); if (iRequirementUsage.Direction.HasValue) @@ -1512,9 +1413,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IRequirementUsage iR writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iRequirementUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iRequirementUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iRequirementUsage.IsVariation); diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/SelectExpressionSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/SelectExpressionSerializer.cs index 84be29b5..c0bc9c0d 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/SelectExpressionSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/SelectExpressionSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISelectExpression iSele writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iSelectExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iSelectExpression.chainingFeature) @@ -167,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISelectExpression iSele writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iSelectExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iSelectExpression.Direction.HasValue) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/SubclassificationSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/SubclassificationSerializer.cs index f627523c..242f3b84 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/SubclassificationSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/SubclassificationSerializer.cs @@ -120,12 +120,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubclassification iSub writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iSubclassification.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubclassification.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iSubclassification.IsImplied); @@ -270,20 +264,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubclassification iSub writer.WriteNullValue(); } - writer.WritePropertyName("owningType"u8); - - if (iSubclassification.owningType.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubclassification.owningType.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iSubclassification.qualifiedName); @@ -302,24 +282,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubclassification iSub writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iSubclassification.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iSubclassification.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubclassification.Specific); - writer.WriteEndObject(); - writer.WritePropertyName("subclassifier"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -332,18 +294,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubclassification iSub writer.WriteStringValue(iSubclassification.Superclassifier); writer.WriteEndObject(); - writer.WriteStartArray("target"u8); - - foreach (var item in iSubclassification.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iSubclassification.textualRepresentation) @@ -387,12 +337,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISubclassification i writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iSubclassification.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubclassification.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iSubclassification.IsImplied); @@ -451,24 +395,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISubclassification i writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iSubclassification.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubclassification.Specific); - writer.WriteEndObject(); - writer.WritePropertyName("subclassifier"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -481,18 +407,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISubclassification i writer.WriteStringValue(iSubclassification.Superclassifier); writer.WriteEndObject(); - writer.WriteStartArray("target"u8); - - foreach (var item in iSubclassification.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/TextualRepresentationSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/TextualRepresentationSerializer.cs index 210ba1a2..64b762cf 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/TextualRepresentationSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/TextualRepresentationSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITextualRepresentation writer.WriteEndArray(); - writer.WriteStartArray("annotatedElement"u8); - - foreach (var item in iTextualRepresentation.annotatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("annotation"u8); foreach (var item in iTextualRepresentation.annotation) diff --git a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/UsageSerializer.cs b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/UsageSerializer.cs index 0ffb507e..af6b7b22 100644 --- a/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/UsageSerializer.cs +++ b/SysML2.NET.CodeGenerator.Tests/Expected/UML/Core/AutoGenSerializer/UsageSerializer.cs @@ -372,9 +372,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUsage iUsage, Utf8Json writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iUsage.IsVariation); @@ -1170,18 +1167,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUsage iUsage, Utf8Json writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iUsage.unioningType) @@ -1302,9 +1287,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IUsage iUsage, Utf8J writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iUsage.IsVariation); diff --git a/SysML2.NET.CodeGenerator.Tests/Generators/UmlHandleBarsGenerators/UmlCoreDalPocoExtensionsGeneratorTestFixture.cs b/SysML2.NET.CodeGenerator.Tests/Generators/UmlHandleBarsGenerators/UmlCoreDalPocoExtensionsGeneratorTestFixture.cs index 51af88c9..99c397c1 100644 --- a/SysML2.NET.CodeGenerator.Tests/Generators/UmlHandleBarsGenerators/UmlCoreDalPocoExtensionsGeneratorTestFixture.cs +++ b/SysML2.NET.CodeGenerator.Tests/Generators/UmlHandleBarsGenerators/UmlCoreDalPocoExtensionsGeneratorTestFixture.cs @@ -54,7 +54,7 @@ public async Task VerifyCanGeneratePocoExtensions() [Test] [TestCaseSource(typeof(ExpectedConcreteClasses))] [Category("Expected")] - public async Task VerifyExpectedPocoExtensionsMachtes(string className) + public async Task VerifyExpectedPocoExtensionsMatches(string className) { var generatedCode = await this.umlCoreDalPocoExtensionsGenerator.GenerateDalPocoExtension(GeneratorSetupFixture.XmiReaderResult, this.umlPocoExtensionDirectoryInfo, diff --git a/SysML2.NET.CodeGenerator.Tests/Generators/UmlHandleBarsGenerators/UmlCoreDalPocoFactoryGeneratorTestFixture.cs b/SysML2.NET.CodeGenerator.Tests/Generators/UmlHandleBarsGenerators/UmlCoreDalPocoFactoryGeneratorTestFixture.cs index 33bd2c99..a39d59d9 100644 --- a/SysML2.NET.CodeGenerator.Tests/Generators/UmlHandleBarsGenerators/UmlCoreDalPocoFactoryGeneratorTestFixture.cs +++ b/SysML2.NET.CodeGenerator.Tests/Generators/UmlHandleBarsGenerators/UmlCoreDalPocoFactoryGeneratorTestFixture.cs @@ -54,7 +54,7 @@ public async Task VerifyCanGeneratePocoFactory() [Test] [TestCaseSource(typeof(ExpectedConcreteClasses))] [Category("Expected")] - public async Task VerifyExpectedPocoFactoryMachtes(string className) + public async Task VerifyExpectedPocoFactoryMatches(string className) { var generatedCode = await this.umlCoreDalPocoExtensionsGenerator.GenerateDalPocoFactory(GeneratorSetupFixture.XmiReaderResult, this.umlPocoFactoryDirectoryInfo, diff --git a/SysML2.NET.CodeGenerator/Extensions/PropertyExtension.cs b/SysML2.NET.CodeGenerator/Extensions/PropertyExtension.cs index 5523c1e7..33f9fe85 100644 --- a/SysML2.NET.CodeGenerator/Extensions/PropertyExtension.cs +++ b/SysML2.NET.CodeGenerator/Extensions/PropertyExtension.cs @@ -72,5 +72,17 @@ public static bool QueryIsEnumPropertyWithDefaultValue(this IProperty property) return false; } + + /// + /// Gets the name of the property. + /// + /// The + /// The with the first letter lowered case in case of derived property, in upper case otherwise + public static string QueryPropertyNameBasedOnUmlProperties(this IProperty property) + { + ArgumentNullException.ThrowIfNull(property); + + return property.IsDerived || property.IsDerivedUnion ? StringExtensions.LowerCaseFirstLetter(property.Name) : StringExtensions.CapitalizeFirstLetter(property.Name); + } } } diff --git a/SysML2.NET.CodeGenerator/HandleBarHelpers/PropertyHelper.cs b/SysML2.NET.CodeGenerator/HandleBarHelpers/PropertyHelper.cs index 86986a18..e701712a 100644 --- a/SysML2.NET.CodeGenerator/HandleBarHelpers/PropertyHelper.cs +++ b/SysML2.NET.CodeGenerator/HandleBarHelpers/PropertyHelper.cs @@ -38,7 +38,7 @@ namespace SysML2.NET.CodeGenerator.HandleBarHelpers /// /// A handlebars block helper for the interface /// - public static class PropertyHelper + public static class PropertyHelper { /// /// Registers the @@ -131,13 +131,13 @@ public static void RegisterPropertyHelper(this IHandlebars handlebars) } var property = (parameters[0] as IProperty)!; - var generatedClass = (parameters[1] as IClass)!; + var classContext = (parameters[1] as IClass)!; var sb = new StringBuilder(); var propertyName = StringExtensions.CapitalizeFirstLetter(property.Name); - var isRedefinedByPropertyWithTheSameName = property.TryQueryRedefinedByProperty(generatedClass, out var redefiningProperty) && redefiningProperty.Name == property.Name; + var isRedefinedPropertyInContext = property.TryQueryRedefinedByProperty(classContext, out var redefiningProperty); - if (!isRedefinedByPropertyWithTheSameName) + if (!isRedefinedPropertyInContext) { sb.Append(property.Visibility.ToString().ToLower(CultureInfo.InvariantCulture)); sb.Append(' '); @@ -187,14 +187,14 @@ public static void RegisterPropertyHelper(this IHandlebars handlebars) propertyName = StringExtensions.LowerCaseFirstLetter(propertyName); } - if (isRedefinedByPropertyWithTheSameName) + if (isRedefinedPropertyInContext) { var owner = (INamedElement)property.Owner; propertyName = $"I{owner.Name}.{propertyName}"; var ownerNamespace = owner.QueryNamespace(); - if (ownerNamespace != generatedClass.QueryNamespace()) + if (ownerNamespace != classContext.QueryNamespace()) { propertyName = $"{ownerNamespace}.{propertyName}"; } @@ -205,45 +205,71 @@ public static void RegisterPropertyHelper(this IHandlebars handlebars) if (property.IsReadOnly || property.IsDerived || property.IsDerivedUnion) { - if(isRedefinedByPropertyWithTheSameName) + if (isRedefinedPropertyInContext) { - sb.Append("{ get; }"); + sb.Append($"=> {GetRedefinedPropertyGetterImplementationForDto(property, redefiningProperty, classContext)}"); } else { sb.Append("{ get; internal set; }"); - } - if (property.QueryIsEnumerable()) - { - sb.Append(" = [];"); + if (property.QueryIsEnumerable()) + { + sb.Append(" = [];"); + } } } else { - sb.Append("{ get; set; }"); + if (isRedefinedPropertyInContext) + { + sb.AppendLine("{"); + sb.AppendLine($"\tget => {GetRedefinedPropertyGetterImplementationForDto(property, redefiningProperty, classContext)}"); + var setterImplementation = GetRedefinedPropertySetterImplementationForDto(property, redefiningProperty, classContext); - if (property.QueryIsEnumerable()) + if (string.IsNullOrWhiteSpace(setterImplementation)) + { + sb.AppendLine("\tset { }"); + } + else + { + sb.AppendLine("\tset "); + sb.AppendLine("{"); + sb.AppendLine($"\t{setterImplementation}"); + sb.Append('}'); + } + + sb.Append('}'); + } + else { - sb.Append(" = [];"); + sb.Append("{ get; set; }"); + + if (property.QueryIsEnumerable()) + { + sb.Append(" = [];"); + } } } - - if (property.QueryIsDefaultValueDifferentThanDefault()) + + if (!isRedefinedPropertyInContext) { - if (property.QueryIsString()) + if (property.QueryIsDefaultValueDifferentThanDefault()) { - sb.Append($" = \"{property.QueryDefaultValueAsString()}\";"); + if (property.QueryIsString()) + { + sb.Append($" = \"{property.QueryDefaultValueAsString()}\";"); + } + else + { + sb.Append($" = {property.QueryDefaultValueAsString()};"); + } } - else + else if (property.QueryIsEnumPropertyWithDefaultValue()) { - sb.Append($" = {property.QueryDefaultValueAsString()};"); + sb.Append($" = {StringExtensions.CapitalizeFirstLetter(property.Type.Name)}.{StringExtensions.CapitalizeFirstLetter(property.QueryDefaultValueAsString())};"); } } - else if (property.QueryIsEnumPropertyWithDefaultValue()) - { - sb.Append($" = {StringExtensions.CapitalizeFirstLetter(property.Type.Name)}.{StringExtensions.CapitalizeFirstLetter(property.QueryDefaultValueAsString())};"); - } writer.WriteSafeString(sb + Environment.NewLine); }); @@ -317,18 +343,18 @@ public static void RegisterPropertyHelper(this IHandlebars handlebars) throw new ArgumentException("The #Property.WriteForPOCOClass supposed to be have 2 arguments IProperty"); } - if (arguments[1] is not IClass generatedClass) + if (arguments[1] is not IClass classContext) { throw new ArgumentException("The #Property.WriteForPOCOClass supposed to be have an IClass as second argument"); } var sb = new StringBuilder(); - var isRedefinedByPropertyWithTheSameName = property.TryQueryRedefinedByProperty(generatedClass, out var redefiningProperty) && redefiningProperty.Name == property.Name; + var isRedefinedPropertyInContext = property.TryQueryRedefinedByProperty(classContext, out var redefiningProperty); var typeName = property.QueryCSharpTypeName(); var propertyName = StringExtensions.CapitalizeFirstLetter(property.Name); - if (!isRedefinedByPropertyWithTheSameName) + if (!isRedefinedPropertyInContext) { sb.Append(property.Visibility.ToString().ToLower(CultureInfo.InvariantCulture)); sb.Append(' '); @@ -360,14 +386,14 @@ public static void RegisterPropertyHelper(this IHandlebars handlebars) propertyName = StringExtensions.LowerCaseFirstLetter(propertyName); } - if (isRedefinedByPropertyWithTheSameName) + if (isRedefinedPropertyInContext) { var owner = (INamedElement)property.Owner; propertyName = $"I{owner.Name}.{propertyName}"; var ownerNamespace = owner.QueryNamespace(); - if (ownerNamespace != generatedClass.QueryNamespace()) + if (ownerNamespace != classContext.QueryNamespace()) { propertyName = $"{ownerNamespace}.{propertyName}"; } @@ -377,10 +403,9 @@ public static void RegisterPropertyHelper(this IHandlebars handlebars) if (property.IsDerived || property.IsDerivedUnion) { - if (isRedefinedByPropertyWithTheSameName) + if (isRedefinedPropertyInContext) { - var owningClass = redefiningProperty.Owner as IClass; - sb.Append($"=> throw new InvalidOperationException(\"Redefined by property I{owningClass?.Name}.{StringExtensions.CapitalizeFirstLetter(redefiningProperty.Name)}\");"); + sb.Append($"=> {GetRedefinedPropertyGetterImplementationForPoco(property, redefiningProperty, classContext)}"); } else { @@ -389,10 +414,9 @@ public static void RegisterPropertyHelper(this IHandlebars handlebars) } else if (property.IsReadOnly) { - if (isRedefinedByPropertyWithTheSameName) + if (isRedefinedPropertyInContext) { - var owningClass = redefiningProperty.Owner as IClass; - sb.Append($"=> throw new InvalidOperationException(\"Redefined by property I{owningClass?.Name}.{StringExtensions.CapitalizeFirstLetter(redefiningProperty.Name)}\");"); + sb.Append($"=> {GetRedefinedPropertyGetterImplementationForPoco(property, redefiningProperty, classContext)}"); } else { @@ -401,15 +425,39 @@ public static void RegisterPropertyHelper(this IHandlebars handlebars) } else { - sb.Append(" { get; set; }"); - - if (property.QueryIsEnumerable()) + if (isRedefinedPropertyInContext) { - sb.Append(" = [];"); + sb.AppendLine("{"); + sb.AppendLine($"\tget => {GetRedefinedPropertyGetterImplementationForPoco(property, redefiningProperty, classContext)}"); + + var setterImplementation = GetRedefinedPropertySetterImplementationForPoco(property, redefiningProperty, classContext); + + if (string.IsNullOrWhiteSpace(setterImplementation)) + { + sb.AppendLine("\tset { }"); + } + else + { + sb.AppendLine("\tset "); + sb.AppendLine("{"); + sb.AppendLine($"\t{setterImplementation}"); + sb.Append('}'); + } + + sb.Append('}'); + } + else + { + sb.Append(" { get; set; }"); + + if (property.QueryIsEnumerable()) + { + sb.Append(" = [];"); + } } } - if (!property.IsDerived || property.IsDerivedUnion) + if ((!property.IsDerived || property.IsDerivedUnion) && !isRedefinedPropertyInContext) { if (property.QueryIsDefaultValueDifferentThanDefault()) { @@ -538,8 +586,7 @@ public static void RegisterPropertyHelper(this IHandlebars handlebars) throw new ArgumentException("The #Property.WritePropertyName context supposed to be IProperty"); } - var propertyName = property.IsDerived || property.IsDerivedUnion ? StringExtensions.LowerCaseFirstLetter(property.Name) : StringExtensions.CapitalizeFirstLetter(property.Name); - writer.WriteSafeString(propertyName); + writer.WriteSafeString(property.QueryPropertyNameBasedOnUmlProperties()); }); handlebars.RegisterHelper("Property.WritePropertyWithExplicitInterfaceIfRequiredForDTO", (writer, context, arguments) => @@ -561,17 +608,212 @@ public static void RegisterPropertyHelper(this IHandlebars handlebars) var variableName = arguments[2].ToString(); var propertyName = property.IsDerived || property.IsDerivedUnion ? StringExtensions.LowerCaseFirstLetter(property.Name) : StringExtensions.CapitalizeFirstLetter(property.Name); - + if (property.TryQueryRedefinedByProperty(generatedClass, out var redefinitionProperty) && redefinitionProperty.Name == property.Name) { var owner = (INamedElement)property.Owner; - writer.WriteSafeString($"((SysML2.NET.Core.DTO.{owner.QueryNamespace()}.I{owner.Name}){variableName}).{propertyName}"); + writer.WriteSafeString($"((SysML2.NET.Core.DTO.{owner.QueryNamespace()}.I{owner.Name}){variableName}).{propertyName}"); } else { - writer.WriteSafeString($"{variableName}.{propertyName}"); + writer.WriteSafeString($"{variableName}.{propertyName}"); } }); + } + + /// + /// Gets the getter implementation for an that has been redefined, for DTO generation + /// + /// The redefined property + /// The property that redefines + /// Gets the context + /// The getter imlementation + private static string GetRedefinedPropertyGetterImplementationForDto(IProperty redefinedProperty, IProperty redefinition, IClass context) + { + string redefinitionPropertyName; + + if (redefinition.TryQueryRedefinedByProperty(context, out _)) + { + var owner = (INamedElement)redefinition.Owner; + redefinitionPropertyName = $"((SysML2.NET.Core.DTO.{owner.QueryNamespace()}.I{owner.Name})this).{redefinition.QueryPropertyNameBasedOnUmlProperties()}"; + } + else + { + redefinitionPropertyName = $"this.{redefinition.QueryPropertyNameBasedOnUmlProperties()}"; + } + + if (redefinedProperty.QueryIsEnumerable() && redefinition.QueryIsEnumerable()) + { + return $"{redefinitionPropertyName};"; + } + + if (redefinedProperty.QueryIsEnumerable() && !redefinition.QueryIsEnumerable()) + { + return redefinition.QueryIsNullableAndNotString() + ? $"{redefinitionPropertyName}.HasValue ? [{redefinitionPropertyName}.Value] : [];" + : $"[{redefinitionPropertyName}];"; + } + + return redefinition.QueryIsNullableAndNotString() + ? $"{redefinitionPropertyName}.HasValue ? {redefinitionPropertyName}.Value : {(redefinedProperty.QueryIsReferenceProperty() ? "Guid.Empty" : "default")};" + : $"{redefinitionPropertyName};"; + } + + /// + /// Gets the getter implementation for an that has been redefined, for POCO generation + /// + /// The redefined property + /// The property that redefines + /// Gets the context + /// The getter imlementation + private static string GetRedefinedPropertyGetterImplementationForPoco(IProperty redefinedProperty, IProperty redefinition, IClass context) + { + string redefinitionPropertyName; + + if (redefinition.TryQueryRedefinedByProperty(context, out _)) + { + var owner = (INamedElement)redefinition.Owner; + redefinitionPropertyName = $"((SysML2.NET.Core.POCO.{owner.QueryNamespace()}.I{owner.Name})this).{redefinition.QueryPropertyNameBasedOnUmlProperties()}"; + } + else + { + redefinitionPropertyName = $"this.{redefinition.QueryPropertyNameBasedOnUmlProperties()}"; + } + + if (redefinedProperty.QueryIsEnumerable() && redefinition.QueryIsEnumerable()) + { + return $"[..{redefinitionPropertyName}];"; + } + + if (redefinedProperty.QueryIsEnumerable() && !redefinition.QueryIsEnumerable()) + { + if (redefinedProperty.QueryIsReferenceProperty()) + { + return $"{redefinitionPropertyName} != null ? [{redefinitionPropertyName}] : [];"; + } + + if (redefinedProperty.QueryIsString()) + { + return $"string.IsNullOrWhiteSpace({redefinitionPropertyName}) ? [{redefinitionPropertyName}] : [];"; + } + + return redefinition.QueryIsNullableAndNotString() + ? $"{redefinitionPropertyName}.HasValue ? [{redefinitionPropertyName}.Value] : [];" + : $"[{redefinitionPropertyName}];"; + } + + return redefinition.QueryIsNullableAndNotString() && !redefinedProperty.QueryIsReferenceProperty() + ? $"{redefinitionPropertyName}.HasValue ? {redefinitionPropertyName}.Value : default;" + : $"{redefinitionPropertyName};"; + } + + /// + /// Gets the setter implementation for an that has been redefined, for DTO generation + /// + /// The redefined property + /// The property that redefines + /// Gets the context + /// The setter imlementation + private static string GetRedefinedPropertySetterImplementationForDto(IProperty redefinedProperty, IProperty redefinition, IClass context) + { + if (redefinition.IsDerived || redefinition.IsDerivedUnion || redefinition.IsReadOnly) + { + return string.Empty; + } + + string redefinitionPropertyName; + + if (redefinition.TryQueryRedefinedByProperty(context, out _)) + { + var owner = (INamedElement)redefinition.Owner; + redefinitionPropertyName = $"((SysML2.NET.Core.DTO.{owner.QueryNamespace()}.I{owner.Name})this).{redefinition.QueryPropertyNameBasedOnUmlProperties()}"; + } + else + { + redefinitionPropertyName = $"this.{redefinition.QueryPropertyNameBasedOnUmlProperties()}"; + } + + if (redefinedProperty.QueryIsEnumerable() == redefinition.QueryIsEnumerable()) + { + return $"{redefinitionPropertyName} = value;"; + } + + var stringBuilder = new StringBuilder(); + stringBuilder.AppendLine("if(value.Count != 0)"); + stringBuilder.AppendLine("{"); + stringBuilder.AppendLine($"\t{redefinitionPropertyName} = value[0];"); + stringBuilder.AppendLine("}"); + return stringBuilder.ToString(); + } + + /// + /// Gets the setter implementation for an that has been redefined, for POCO generation + /// + /// The redefined property + /// The property that redefines + /// Gets the context + /// The setter imlementation + private static string GetRedefinedPropertySetterImplementationForPoco(IProperty redefinedProperty, IProperty redefinition, IClass context) + { + if (redefinition.IsDerived || redefinition.IsDerivedUnion || redefinition.IsReadOnly) + { + return string.Empty; + } + + string redefinitionPropertyName; + + if (redefinition.TryQueryRedefinedByProperty(context, out _)) + { + var owner = (INamedElement)redefinition.Owner; + redefinitionPropertyName = $"((SysML2.NET.Core.POCO.{owner.QueryNamespace()}.I{owner.Name})this).{redefinition.QueryPropertyNameBasedOnUmlProperties()}"; + } + else + { + redefinitionPropertyName = $"this.{redefinition.QueryPropertyNameBasedOnUmlProperties()}"; + } + + var redefinitionPropertyTypeName = redefinition.QueryIsReferenceProperty() ? $"I{redefinition.Type.Name}" : redefinition.QueryCSharpTypeName(); + + if (redefinedProperty.QueryIsEnumerable() && redefinition.QueryIsEnumerable()) + { + return redefinedProperty.Type == redefinition.Type ? $"{redefinitionPropertyName} = value;" : $"{redefinitionPropertyName} = [..value.OfType<{redefinitionPropertyTypeName}>()];"; + } + + var stringBuilder = new StringBuilder(); + + if (redefinedProperty.QueryIsEnumerable()) + { + if (redefinedProperty.Type == redefinition.Type) + { + stringBuilder.AppendLine("if(value.Count != 0)"); + stringBuilder.AppendLine("{"); + stringBuilder.AppendLine($"\t{redefinitionPropertyName} = value[0];"); + } + else + { + stringBuilder.AppendLine($"if(value.OfType<{redefinitionPropertyTypeName}>().FirstOrDefault() is {{ }} firstValue)"); + stringBuilder.AppendLine("{"); + stringBuilder.AppendLine($"\t{redefinitionPropertyName} = firstValue;"); + } + + stringBuilder.Append('}'); + } + else + { + if (redefinedProperty.Type == redefinition.Type) + { + stringBuilder.Append($"{redefinitionPropertyName} = value;"); + } + else + { + stringBuilder.AppendLine($"if(value is {redefinitionPropertyTypeName} castedValue)"); + stringBuilder.AppendLine("{"); + stringBuilder.AppendLine($"\t{redefinitionPropertyName} = castedValue;"); + stringBuilder.Append('}'); + } + } + + return stringBuilder.ToString(); + } } - } -} \ No newline at end of file +} diff --git a/SysML2.NET.CodeGenerator/Templates/Uml/core-dal-poco-uml-extensions.hbs b/SysML2.NET.CodeGenerator/Templates/Uml/core-dal-poco-uml-extensions.hbs index e877310d..c7be4196 100644 --- a/SysML2.NET.CodeGenerator/Templates/Uml/core-dal-poco-uml-extensions.hbs +++ b/SysML2.NET.CodeGenerator/Templates/Uml/core-dal-poco-uml-extensions.hbs @@ -67,9 +67,11 @@ namespace SysML2.NET.Dal var identifiersOfObjectsToDelete = new List(); + {{#with this as |class |}} {{#each (Class.QueryAllProperties this) as | property |}} {{#unless property.IsDerived }} {{#unless property.IsTransient }} + {{#unless (Property.IsPropertyRedefinedInClass this class)}} {{#if (Property.QueryIsReferenceProperty property)}} {{#if (Property.QueryIsEnumerable property) }} var {{ property.Name}}ToDelete = poco.{{ String.PascalCase property.Name}}.Select(x => x.Id).Except(dto.{{ String.PascalCase property.Name}}); @@ -85,16 +87,14 @@ namespace SysML2.NET.Dal {{/if}} {{else}} - {{#if (Property.IsRedefinedOrRedifines this ../this)}} - ((Core.POCO.{{ #NamedElement.WriteFullyQualifiedNameSpace property.Owner }}.I{{property.Owner.Name}})poco).{{ String.PascalCase property.Name }} = ((Core.DTO.{{ #NamedElement.WriteFullyQualifiedNameSpace property.Owner }}.I{{property.Owner.Name}})dto).{{ String.PascalCase property.Name }}; - {{else}} poco.{{ String.PascalCase property.Name }} = dto.{{ String.PascalCase property.Name }}; - {{/if}} - + {{/if}} {{/unless}} {{/unless}} + {{/unless}} {{/each}} + {{/with}} return identifiersOfObjectsToDelete; } @@ -132,11 +132,13 @@ namespace SysML2.NET.Dal } Lazy lazyPoco; - + + {{#with this as | class |}} {{#each (Class.QueryAllProperties this) as | property |}} {{#unless property.IsDerived }} {{#unless property.IsTransient }} - {{#if (Property.QueryIsReferenceProperty property)}} + {{#unless (Property.IsPropertyRedefinedInClass this class)}} + {{#if (Property.QueryIsReferenceProperty property)}} {{#if (Property.QueryIsEnumerable property) }} var {{ property.Name}}ToAdd = dto.{{ String.PascalCase property.Name}}.Except(poco.{{ String.PascalCase property.Name}}.Select(x => x.Id)); @@ -184,7 +186,9 @@ namespace SysML2.NET.Dal {{/if}} {{/unless}} {{/unless}} + {{/unless}} {{/each}} + {{/with}} } /// @@ -201,10 +205,12 @@ namespace SysML2.NET.Dal var dto = new Core.DTO.{{ #NamedElement.WriteFullyQualifiedNameSpace this }}.{{ this.Name }}(); dto.Id = poco.Id; + {{#with this as | class |}} {{#each (Class.QueryAllProperties this) as | property |}} {{#unless property.IsDerived }} {{#unless property.IsTransient }} - {{#if (Property.QueryIsReferenceProperty property) }} + {{#unless (Property.IsPropertyRedefinedInClass this class)}} + {{#if (Property.QueryIsReferenceProperty property) }} {{#if (Property.QueryIsEnumerable property)}} dto.{{ String.PascalCase property.Name }} = poco.{{ String.PascalCase property.Name }}.Select(x => x.Id).ToList(); {{ else if (Property.QueryIsNullable property)}} @@ -213,16 +219,14 @@ namespace SysML2.NET.Dal dto.{{ String.PascalCase property.Name }} = poco.{{ String.PascalCase property.Name }}.Id; {{/if}} {{ else }} - {{#if (Property.IsRedefinedOrRedifines this ../this)}} - ((Core.DTO.{{ #NamedElement.WriteFullyQualifiedNameSpace property.Owner }}.I{{property.Owner.Name}})dto).{{ String.PascalCase property.Name }} = ((Core.POCO.{{ #NamedElement.WriteFullyQualifiedNameSpace property.Owner }}.I{{property.Owner.Name}})poco).{{ String.PascalCase property.Name }}; - {{else}} dto.{{ String.PascalCase property.Name }} = poco.{{ String.PascalCase property.Name }}; - {{/if}} {{/if}} {{/unless}} {{/unless}} + {{/unless}} {{/each}} - + {{/with}} + return dto; } } diff --git a/SysML2.NET.CodeGenerator/Templates/Uml/core-json-dto-deserializer-uml-template.hbs b/SysML2.NET.CodeGenerator/Templates/Uml/core-json-dto-deserializer-uml-template.hbs index c45ec131..69834029 100644 --- a/SysML2.NET.CodeGenerator/Templates/Uml/core-json-dto-deserializer-uml-template.hbs +++ b/SysML2.NET.CodeGenerator/Templates/Uml/core-json-dto-deserializer-uml-template.hbs @@ -88,7 +88,7 @@ namespace SysML2.NET.Serializer.Json.Core.DTO {{#with this as |class| }} {{ #each (Class.QueryAllProperties this) as | property | }} {{#unless this.IsTransient}} - {{#unless (Property.IsRedefinedByPropertyWithSameName this class)}} + {{#unless (Property.IsPropertyRedefinedInClass this class)}} if (jsonElement.TryGetProperty("{{ property.Name }}"u8, out var {{ property.Name }}Property)) { {{#if (Property.QueryIsReferenceProperty property)}} diff --git a/SysML2.NET.CodeGenerator/Templates/Uml/core-json-dto-serializer-uml-template.hbs b/SysML2.NET.CodeGenerator/Templates/Uml/core-json-dto-serializer-uml-template.hbs index e36e89e2..9b702c75 100644 --- a/SysML2.NET.CodeGenerator/Templates/Uml/core-json-dto-serializer-uml-template.hbs +++ b/SysML2.NET.CodeGenerator/Templates/Uml/core-json-dto-serializer-uml-template.hbs @@ -93,7 +93,7 @@ namespace SysML2.NET.Serializer.Json.Core.DTO {{#with this as |class| }} {{ #each (Class.QueryAllProperties this) as | property | }} {{#unless this.IsTransient}} - {{#unless (Property.IsRedefinedByPropertyWithSameName this class)}} + {{#unless (Property.IsPropertyRedefinedInClass this class)}} {{#if (Property.QueryIsEnumerable property)}} writer.WriteStartArray("{{String.LowerCaseFirstLetter property.Name }}"u8); @@ -185,7 +185,7 @@ namespace SysML2.NET.Serializer.Json.Core.DTO {{ #each (Class.QueryAllProperties this) as | property | }} {{#unless this.IsDerived}} {{#unless this.IsTransient}} - {{#unless (Property.IsRedefinedByPropertyWithSameName this class)}} + {{#unless (Property.IsPropertyRedefinedInClass this class)}} {{#if (Property.QueryIsEnumerable property)}} writer.WriteStartArray("{{String.LowerCaseFirstLetter property.Name }}"u8); diff --git a/SysML2.NET.CodeGenerator/Templates/Uml/core-poco-class-uml-template.hbs b/SysML2.NET.CodeGenerator/Templates/Uml/core-poco-class-uml-template.hbs index 3624f207..abef3916 100644 --- a/SysML2.NET.CodeGenerator/Templates/Uml/core-poco-class-uml-template.hbs +++ b/SysML2.NET.CodeGenerator/Templates/Uml/core-poco-class-uml-template.hbs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.{{ #NamedElement.WriteFullyQualifiedNameSpace thi using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; {{ #Class.WriteEnumerationNameSpaces this}} {{ #Class.WriteNameSpaces this POCO}} diff --git a/SysML2.NET.CodeGenerator/Templates/Uml/core-poco-dal-uml-factory.hbs b/SysML2.NET.CodeGenerator/Templates/Uml/core-poco-dal-uml-factory.hbs index 9386fdc1..9dc93f17 100644 --- a/SysML2.NET.CodeGenerator/Templates/Uml/core-poco-dal-uml-factory.hbs +++ b/SysML2.NET.CodeGenerator/Templates/Uml/core-poco-dal-uml-factory.hbs @@ -59,12 +59,10 @@ namespace SysML2.NET.Dal {{#each (Class.QueryAllProperties this) as | property |}} {{#unless property.IsDerived }} {{#unless property.IsTransient }} - {{#unless (Property.QueryIsReferenceProperty property) }} - {{#if (Property.IsRedefinedOrRedifines this ../this)}} - ((Core.POCO.{{ #NamedElement.WriteFullyQualifiedNameSpace property.Owner }}.I{{property.Owner.Name}})poco).{{String.CapitalizeFirstLetter property.Name }} = ((Core.DTO.{{ #NamedElement.WriteFullyQualifiedNameSpace property.Owner }}.I{{property.Owner.Name}})dto).{{String.CapitalizeFirstLetter property.Name }}; - {{else}} + {{#unless (Property.IsPropertyRedefinedInClass this class)}} + {{#unless (Property.QueryIsReferenceProperty property) }} poco.{{String.CapitalizeFirstLetter property.Name }} = dto.{{String.CapitalizeFirstLetter property.Name }}; - {{/if}} + {{/unless}} {{/unless}} {{/unless}} {{/unless}} diff --git a/SysML2.NET.Dal.Tests/AssemblerTestFixture.cs b/SysML2.NET.Dal.Tests/AssemblerTestFixture.cs index 7b78cbb0..62fd27bf 100644 --- a/SysML2.NET.Dal.Tests/AssemblerTestFixture.cs +++ b/SysML2.NET.Dal.Tests/AssemblerTestFixture.cs @@ -66,8 +66,8 @@ public void Verify_that_synchronize_Works_as_Expected() var membershipDto = new Core.DTO.Root.Namespaces.Membership { Id = Guid.Parse("215054ad-eb1d-45f6-8537-d43a3470e73c"), - Source = new List { packageDto.Id }, - Target = new List { featureDto.Id }, + OwnedRelatedElement = new List { packageDto.Id }, + OwningRelatedElement = featureDto.Id , }; dtos.Add(packageDto); @@ -93,8 +93,20 @@ public void Verify_that_synchronize_Works_as_Expected() membershipPoco = (Core.POCO.Root.Namespaces.Membership)this.lazyPoco.Value; } - Assert.That(membershipPoco.Target.Contains(featurePoco), Is.True); + Assert.That(membershipPoco.OwningRelatedElement, Is.EqualTo(featurePoco)); + + Core.POCO.Root.Elements.IRelationship relation = membershipPoco; + + Assert.That(membershipPoco.MemberElement, Is.Null); + + relation.Target = [featurePoco, membershipPoco]; + using (Assert.EnterMultipleScope()) + { + Assert.That(membershipPoco.MemberElement, Is.EqualTo(featurePoco)); + Assert.That(relation.Target, Is.EquivalentTo([featurePoco])); + } + dtos.Clear(); featureDto.DeclaredName = "some updated feature"; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/AcceptActionUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/AcceptActionUsageFactory.cs index bc455593..9f92e593 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/AcceptActionUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/AcceptActionUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.AcceptActionUsage Create(Core.DTO.Systems.Actio poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ActionUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ActionUsageFactory.cs index 61550645..1a0c0c86 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ActionUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ActionUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.ActionUsage Create(Core.DTO.Systems.Actions.Act poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ActorMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ActorMembershipFactory.cs index 895a78c9..4a5e4671 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ActorMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ActorMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Systems.Requirements.ActorMembership Create(Core.DTO.Systems.Re poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/AllocationDefinitionFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/AllocationDefinitionFactory.cs index 0f991567..8c484641 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/AllocationDefinitionFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/AllocationDefinitionFactory.cs @@ -63,8 +63,7 @@ public Core.POCO.Systems.Allocations.AllocationDefinition Create(Core.DTO.System poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; poco.IsIndividual = dto.IsIndividual; - ((Core.POCO.Systems.Connections.IConnectionDefinition)poco).IsSufficient = ((Core.DTO.Systems.Connections.IConnectionDefinition)dto).IsSufficient; - ((Core.POCO.Core.Types.IType)poco).IsSufficient = ((Core.DTO.Core.Types.IType)dto).IsSufficient; + poco.IsSufficient = dto.IsSufficient; poco.IsVariation = dto.IsVariation; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/AllocationUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/AllocationUsageFactory.cs index 838954a5..50fcef8d 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/AllocationUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/AllocationUsageFactory.cs @@ -72,7 +72,6 @@ public Core.POCO.Systems.Allocations.AllocationUsage Create(Core.DTO.Systems.All poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/AnalysisCaseUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/AnalysisCaseUsageFactory.cs index 9481caf9..2d4386a5 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/AnalysisCaseUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/AnalysisCaseUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.AnalysisCases.AnalysisCaseUsage Create(Core.DTO.Systems poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/AssertConstraintUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/AssertConstraintUsageFactory.cs index b83cff42..44a7b4ba 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/AssertConstraintUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/AssertConstraintUsageFactory.cs @@ -72,7 +72,6 @@ public Core.POCO.Systems.Constraints.AssertConstraintUsage Create(Core.DTO.Syste poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/AssignmentActionUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/AssignmentActionUsageFactory.cs index 0257d256..8de84510 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/AssignmentActionUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/AssignmentActionUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.AssignmentActionUsage Create(Core.DTO.Systems.A poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/AttributeUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/AttributeUsageFactory.cs index 31412a0b..7f6a6a61 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/AttributeUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/AttributeUsageFactory.cs @@ -70,7 +70,6 @@ public Core.POCO.Systems.Attributes.AttributeUsage Create(Core.DTO.Systems.Attri poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/BindingConnectorAsUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/BindingConnectorAsUsageFactory.cs index b3be136a..c378a54a 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/BindingConnectorAsUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/BindingConnectorAsUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Connections.BindingConnectorAsUsage Create(Core.DTO.Sys poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/CalculationUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/CalculationUsageFactory.cs index 154ede3f..ef86d59a 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/CalculationUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/CalculationUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Calculations.CalculationUsage Create(Core.DTO.Systems.C poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/CaseUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/CaseUsageFactory.cs index 4c0db303..22311744 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/CaseUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/CaseUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Cases.CaseUsage Create(Core.DTO.Systems.Cases.CaseUsage poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/CollectExpressionFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/CollectExpressionFactory.cs index 36910cff..90e813fb 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/CollectExpressionFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/CollectExpressionFactory.cs @@ -71,8 +71,7 @@ public Core.POCO.Kernel.Expressions.CollectExpression Create(Core.DTO.Kernel.Exp poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; poco.IsVariable = dto.IsVariable; - ((Core.POCO.Kernel.Expressions.ICollectExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.ICollectExpression)dto).Operator; - ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator; + poco.Operator = dto.Operator; return poco; } diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ConcernDefinitionFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ConcernDefinitionFactory.cs index eef1fce9..0d6120c4 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ConcernDefinitionFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ConcernDefinitionFactory.cs @@ -57,7 +57,6 @@ public Core.POCO.Systems.Requirements.ConcernDefinition Create(Core.DTO.Systems. poco.Id = dto.Id; poco.AliasIds = dto.AliasIds; poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; poco.ElementId = dto.ElementId; poco.IsAbstract = dto.IsAbstract; poco.IsImpliedIncluded = dto.IsImpliedIncluded; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ConcernUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ConcernUsageFactory.cs index 2f3c7608..002bd620 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ConcernUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ConcernUsageFactory.cs @@ -57,7 +57,6 @@ public Core.POCO.Systems.Requirements.ConcernUsage Create(Core.DTO.Systems.Requi poco.Id = dto.Id; poco.AliasIds = dto.AliasIds; poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; poco.Direction = dto.Direction; poco.ElementId = dto.ElementId; poco.IsAbstract = dto.IsAbstract; @@ -71,7 +70,6 @@ public Core.POCO.Systems.Requirements.ConcernUsage Create(Core.DTO.Systems.Requi poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; poco.ReqId = dto.ReqId; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ConnectionDefinitionFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ConnectionDefinitionFactory.cs index 753c2480..56631595 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ConnectionDefinitionFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ConnectionDefinitionFactory.cs @@ -63,8 +63,7 @@ public Core.POCO.Systems.Connections.ConnectionDefinition Create(Core.DTO.System poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; poco.IsIndividual = dto.IsIndividual; - ((Core.POCO.Systems.Connections.IConnectionDefinition)poco).IsSufficient = ((Core.DTO.Systems.Connections.IConnectionDefinition)dto).IsSufficient; - ((Core.POCO.Core.Types.IType)poco).IsSufficient = ((Core.DTO.Core.Types.IType)dto).IsSufficient; + poco.IsSufficient = dto.IsSufficient; poco.IsVariation = dto.IsVariation; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ConnectionUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ConnectionUsageFactory.cs index 3520ac82..db2fcc4a 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ConnectionUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ConnectionUsageFactory.cs @@ -72,7 +72,6 @@ public Core.POCO.Systems.Connections.ConnectionUsage Create(Core.DTO.Systems.Con poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ConstraintUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ConstraintUsageFactory.cs index 3cb862a0..53d18efa 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ConstraintUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ConstraintUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Constraints.ConstraintUsage Create(Core.DTO.Systems.Con poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/DecisionNodeFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/DecisionNodeFactory.cs index 967ab496..e8a3d307 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/DecisionNodeFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/DecisionNodeFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.DecisionNode Create(Core.DTO.Systems.Actions.De poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ElementFilterMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ElementFilterMembershipFactory.cs index 7e6df47f..106eca07 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ElementFilterMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ElementFilterMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Kernel.Packages.ElementFilterMembership Create(Core.DTO.Kernel. poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/EndFeatureMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/EndFeatureMembershipFactory.cs index aae2c537..fb869669 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/EndFeatureMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/EndFeatureMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Core.Features.EndFeatureMembership Create(Core.DTO.Core.Feature poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/EnumerationDefinitionFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/EnumerationDefinitionFactory.cs index c9481177..24d26878 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/EnumerationDefinitionFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/EnumerationDefinitionFactory.cs @@ -62,8 +62,7 @@ public Core.POCO.Systems.Enumerations.EnumerationDefinition Create(Core.DTO.Syst poco.IsAbstract = dto.IsAbstract; poco.IsImpliedIncluded = dto.IsImpliedIncluded; poco.IsSufficient = dto.IsSufficient; - ((Core.POCO.Systems.Enumerations.IEnumerationDefinition)poco).IsVariation = ((Core.DTO.Systems.Enumerations.IEnumerationDefinition)dto).IsVariation; - ((Core.POCO.Systems.DefinitionAndUsage.IDefinition)poco).IsVariation = ((Core.DTO.Systems.DefinitionAndUsage.IDefinition)dto).IsVariation; + poco.IsVariation = dto.IsVariation; return poco; } diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/EnumerationUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/EnumerationUsageFactory.cs index 924f51e6..8710b09a 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/EnumerationUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/EnumerationUsageFactory.cs @@ -70,7 +70,6 @@ public Core.POCO.Systems.Enumerations.EnumerationUsage Create(Core.DTO.Systems.E poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/EventOccurrenceUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/EventOccurrenceUsageFactory.cs index c345da24..fe028d28 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/EventOccurrenceUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/EventOccurrenceUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Occurrences.EventOccurrenceUsage Create(Core.DTO.System poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ExhibitStateUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ExhibitStateUsageFactory.cs index c1f165a0..addcf1ee 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ExhibitStateUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ExhibitStateUsageFactory.cs @@ -72,7 +72,6 @@ public Core.POCO.Systems.States.ExhibitStateUsage Create(Core.DTO.Systems.States poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/FeatureChainExpressionFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/FeatureChainExpressionFactory.cs index 80c28698..2b0a43ad 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/FeatureChainExpressionFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/FeatureChainExpressionFactory.cs @@ -71,8 +71,7 @@ public Core.POCO.Kernel.Expressions.FeatureChainExpression Create(Core.DTO.Kerne poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; poco.IsVariable = dto.IsVariable; - ((Core.POCO.Kernel.Expressions.IFeatureChainExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IFeatureChainExpression)dto).Operator; - ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator; + poco.Operator = dto.Operator; return poco; } diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/FeatureMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/FeatureMembershipFactory.cs index 1fe41a0c..661f48b9 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/FeatureMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/FeatureMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Core.Types.FeatureMembership Create(Core.DTO.Core.Types.Feature poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/FeatureValueFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/FeatureValueFactory.cs index 49aafc32..03f2b47f 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/FeatureValueFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/FeatureValueFactory.cs @@ -63,8 +63,6 @@ public Core.POCO.Kernel.FeatureValues.FeatureValue Create(Core.DTO.Kernel.Featur poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; poco.IsInitial = dto.IsInitial; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/FlowUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/FlowUsageFactory.cs index 5cadbd5c..8748d3ad 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/FlowUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/FlowUsageFactory.cs @@ -72,7 +72,6 @@ public Core.POCO.Systems.Flows.FlowUsage Create(Core.DTO.Systems.Flows.FlowUsage poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ForLoopActionUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ForLoopActionUsageFactory.cs index 0ef4155a..60f5cb7a 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ForLoopActionUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ForLoopActionUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.ForLoopActionUsage Create(Core.DTO.Systems.Acti poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ForkNodeFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ForkNodeFactory.cs index 908ed399..208fd27b 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ForkNodeFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ForkNodeFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.ForkNode Create(Core.DTO.Systems.Actions.ForkNo poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/FramedConcernMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/FramedConcernMembershipFactory.cs index 836dda19..76fb9702 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/FramedConcernMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/FramedConcernMembershipFactory.cs @@ -61,10 +61,7 @@ public Core.POCO.Systems.Requirements.FramedConcernMembership Create(Core.DTO.Sy poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - ((Core.POCO.Systems.Requirements.IFramedConcernMembership)poco).Kind = ((Core.DTO.Systems.Requirements.IFramedConcernMembership)dto).Kind; - ((Core.POCO.Systems.Requirements.IRequirementConstraintMembership)poco).Kind = ((Core.DTO.Systems.Requirements.IRequirementConstraintMembership)dto).Kind; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; + poco.Kind = dto.Kind; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/IfActionUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/IfActionUsageFactory.cs index 3d4f3861..171f36bc 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/IfActionUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/IfActionUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.IfActionUsage Create(Core.DTO.Systems.Actions.I poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/IncludeUseCaseUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/IncludeUseCaseUsageFactory.cs index bb9b12b5..b5f6f034 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/IncludeUseCaseUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/IncludeUseCaseUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.UseCases.IncludeUseCaseUsage Create(Core.DTO.Systems.Us poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/IndexExpressionFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/IndexExpressionFactory.cs index 35dccd20..34fec89b 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/IndexExpressionFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/IndexExpressionFactory.cs @@ -71,8 +71,7 @@ public Core.POCO.Kernel.Expressions.IndexExpression Create(Core.DTO.Kernel.Expre poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; poco.IsVariable = dto.IsVariable; - ((Core.POCO.Kernel.Expressions.IIndexExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IIndexExpression)dto).Operator; - ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator; + poco.Operator = dto.Operator; return poco; } diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/InterfaceDefinitionFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/InterfaceDefinitionFactory.cs index c743e8c2..a70e05f7 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/InterfaceDefinitionFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/InterfaceDefinitionFactory.cs @@ -63,8 +63,7 @@ public Core.POCO.Systems.Interfaces.InterfaceDefinition Create(Core.DTO.Systems. poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; poco.IsIndividual = dto.IsIndividual; - ((Core.POCO.Systems.Connections.IConnectionDefinition)poco).IsSufficient = ((Core.DTO.Systems.Connections.IConnectionDefinition)dto).IsSufficient; - ((Core.POCO.Core.Types.IType)poco).IsSufficient = ((Core.DTO.Core.Types.IType)dto).IsSufficient; + poco.IsSufficient = dto.IsSufficient; poco.IsVariation = dto.IsVariation; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/InterfaceUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/InterfaceUsageFactory.cs index b8919afd..f6680c62 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/InterfaceUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/InterfaceUsageFactory.cs @@ -72,7 +72,6 @@ public Core.POCO.Systems.Interfaces.InterfaceUsage Create(Core.DTO.Systems.Inter poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ItemUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ItemUsageFactory.cs index 5d6fdce0..9845e7ab 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ItemUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ItemUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Items.ItemUsage Create(Core.DTO.Systems.Items.ItemUsage poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/JoinNodeFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/JoinNodeFactory.cs index 27d87dd4..7ff22c27 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/JoinNodeFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/JoinNodeFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.JoinNode Create(Core.DTO.Systems.Actions.JoinNo poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/MembershipExposeFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/MembershipExposeFactory.cs index 217f5188..66eafa9b 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/MembershipExposeFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/MembershipExposeFactory.cs @@ -61,11 +61,9 @@ public Core.POCO.Systems.Views.MembershipExpose Create(Core.DTO.Systems.Views.Me poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - ((Core.POCO.Root.Namespaces.IImport)poco).IsImportAll = ((Core.DTO.Root.Namespaces.IImport)dto).IsImportAll; - ((Core.POCO.Systems.Views.IExpose)poco).IsImportAll = ((Core.DTO.Systems.Views.IExpose)dto).IsImportAll; + poco.IsImportAll = dto.IsImportAll; poco.IsRecursive = dto.IsRecursive; - ((Core.POCO.Root.Namespaces.IImport)poco).Visibility = ((Core.DTO.Root.Namespaces.IImport)dto).Visibility; - ((Core.POCO.Systems.Views.IExpose)poco).Visibility = ((Core.DTO.Systems.Views.IExpose)dto).Visibility; + poco.Visibility = dto.Visibility; return poco; } diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/MergeNodeFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/MergeNodeFactory.cs index ee65410e..4a3968de 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/MergeNodeFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/MergeNodeFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.MergeNode Create(Core.DTO.Systems.Actions.Merge poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/MetadataUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/MetadataUsageFactory.cs index 258cef0b..69eb2e21 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/MetadataUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/MetadataUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Metadata.MetadataUsage Create(Core.DTO.Systems.Metadata poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/NamespaceExposeFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/NamespaceExposeFactory.cs index 150b68ea..c8f14e0d 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/NamespaceExposeFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/NamespaceExposeFactory.cs @@ -61,11 +61,9 @@ public Core.POCO.Systems.Views.NamespaceExpose Create(Core.DTO.Systems.Views.Nam poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - ((Core.POCO.Systems.Views.IExpose)poco).IsImportAll = ((Core.DTO.Systems.Views.IExpose)dto).IsImportAll; - ((Core.POCO.Root.Namespaces.IImport)poco).IsImportAll = ((Core.DTO.Root.Namespaces.IImport)dto).IsImportAll; + poco.IsImportAll = dto.IsImportAll; poco.IsRecursive = dto.IsRecursive; - ((Core.POCO.Systems.Views.IExpose)poco).Visibility = ((Core.DTO.Systems.Views.IExpose)dto).Visibility; - ((Core.POCO.Root.Namespaces.IImport)poco).Visibility = ((Core.DTO.Root.Namespaces.IImport)dto).Visibility; + poco.Visibility = dto.Visibility; return poco; } diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ObjectiveMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ObjectiveMembershipFactory.cs index 1600cb14..f6fbd0a7 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ObjectiveMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ObjectiveMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Systems.Cases.ObjectiveMembership Create(Core.DTO.Systems.Cases poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/OccurrenceUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/OccurrenceUsageFactory.cs index d182e776..f1cc8512 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/OccurrenceUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/OccurrenceUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Occurrences.OccurrenceUsage Create(Core.DTO.Systems.Occ poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/OwningMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/OwningMembershipFactory.cs index e34df956..95e0f117 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/OwningMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/OwningMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Root.Namespaces.OwningMembership Create(Core.DTO.Root.Namespace poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ParameterMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ParameterMembershipFactory.cs index 491c1887..dab6dd40 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ParameterMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ParameterMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Kernel.Behaviors.ParameterMembership Create(Core.DTO.Kernel.Beh poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/PartUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/PartUsageFactory.cs index 97928686..065833e4 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/PartUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/PartUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Parts.PartUsage Create(Core.DTO.Systems.Parts.PartUsage poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/PerformActionUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/PerformActionUsageFactory.cs index 86854198..b550dc51 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/PerformActionUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/PerformActionUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.PerformActionUsage Create(Core.DTO.Systems.Acti poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/PortUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/PortUsageFactory.cs index 5d9fb491..8c119f65 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/PortUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/PortUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Ports.PortUsage Create(Core.DTO.Systems.Ports.PortUsage poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ReferenceUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ReferenceUsageFactory.cs index 7df4a19f..93e412ed 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ReferenceUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ReferenceUsageFactory.cs @@ -70,7 +70,6 @@ public Core.POCO.Systems.DefinitionAndUsage.ReferenceUsage Create(Core.DTO.Syste poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/RenderingUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/RenderingUsageFactory.cs index ceede372..aad7c7e9 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/RenderingUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/RenderingUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Views.RenderingUsage Create(Core.DTO.Systems.Views.Rend poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementConstraintMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementConstraintMembershipFactory.cs index ff8867ed..5d3ddac7 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementConstraintMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementConstraintMembershipFactory.cs @@ -62,8 +62,6 @@ public Core.POCO.Systems.Requirements.RequirementConstraintMembership Create(Cor poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; poco.Kind = dto.Kind; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementDefinitionFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementDefinitionFactory.cs index acb4785f..7594ade6 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementDefinitionFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementDefinitionFactory.cs @@ -57,7 +57,6 @@ public Core.POCO.Systems.Requirements.RequirementDefinition Create(Core.DTO.Syst poco.Id = dto.Id; poco.AliasIds = dto.AliasIds; poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; poco.ElementId = dto.ElementId; poco.IsAbstract = dto.IsAbstract; poco.IsImpliedIncluded = dto.IsImpliedIncluded; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementUsageFactory.cs index 49939bff..2bd2dd51 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementUsageFactory.cs @@ -57,7 +57,6 @@ public Core.POCO.Systems.Requirements.RequirementUsage Create(Core.DTO.Systems.R poco.Id = dto.Id; poco.AliasIds = dto.AliasIds; poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; poco.Direction = dto.Direction; poco.ElementId = dto.ElementId; poco.IsAbstract = dto.IsAbstract; @@ -71,7 +70,6 @@ public Core.POCO.Systems.Requirements.RequirementUsage Create(Core.DTO.Systems.R poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; poco.ReqId = dto.ReqId; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementVerificationMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementVerificationMembershipFactory.cs index 800b1f76..825c21f5 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementVerificationMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/RequirementVerificationMembershipFactory.cs @@ -61,10 +61,7 @@ public Core.POCO.Systems.VerificationCases.RequirementVerificationMembership Cre poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - ((Core.POCO.Systems.VerificationCases.IRequirementVerificationMembership)poco).Kind = ((Core.DTO.Systems.VerificationCases.IRequirementVerificationMembership)dto).Kind; - ((Core.POCO.Systems.Requirements.IRequirementConstraintMembership)poco).Kind = ((Core.DTO.Systems.Requirements.IRequirementConstraintMembership)dto).Kind; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; + poco.Kind = dto.Kind; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ResultExpressionMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ResultExpressionMembershipFactory.cs index f957afac..3c6eb575 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ResultExpressionMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ResultExpressionMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Kernel.Functions.ResultExpressionMembership Create(Core.DTO.Ker poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ReturnParameterMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ReturnParameterMembershipFactory.cs index b192a822..92d8a468 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ReturnParameterMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ReturnParameterMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Kernel.Functions.ReturnParameterMembership Create(Core.DTO.Kern poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/SatisfyRequirementUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/SatisfyRequirementUsageFactory.cs index 9f6d2eba..6cfb3a77 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/SatisfyRequirementUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/SatisfyRequirementUsageFactory.cs @@ -57,7 +57,6 @@ public Core.POCO.Systems.Requirements.SatisfyRequirementUsage Create(Core.DTO.Sy poco.Id = dto.Id; poco.AliasIds = dto.AliasIds; poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; poco.Direction = dto.Direction; poco.ElementId = dto.ElementId; poco.IsAbstract = dto.IsAbstract; @@ -72,7 +71,6 @@ public Core.POCO.Systems.Requirements.SatisfyRequirementUsage Create(Core.DTO.Sy poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; poco.ReqId = dto.ReqId; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/SelectExpressionFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/SelectExpressionFactory.cs index b38a858c..9603de20 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/SelectExpressionFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/SelectExpressionFactory.cs @@ -71,8 +71,7 @@ public Core.POCO.Kernel.Expressions.SelectExpression Create(Core.DTO.Kernel.Expr poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; poco.IsVariable = dto.IsVariable; - ((Core.POCO.Kernel.Expressions.ISelectExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.ISelectExpression)dto).Operator; - ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator; + poco.Operator = dto.Operator; return poco; } diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/SendActionUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/SendActionUsageFactory.cs index 5c194803..1d1c60ce 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/SendActionUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/SendActionUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.SendActionUsage Create(Core.DTO.Systems.Actions poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/StakeholderMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/StakeholderMembershipFactory.cs index bb0fb3e4..4bea22ca 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/StakeholderMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/StakeholderMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Systems.Requirements.StakeholderMembership Create(Core.DTO.Syst poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/StateSubactionMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/StateSubactionMembershipFactory.cs index dc6f3a8f..602ac4c2 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/StateSubactionMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/StateSubactionMembershipFactory.cs @@ -62,8 +62,6 @@ public Core.POCO.Systems.States.StateSubactionMembership Create(Core.DTO.Systems poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; poco.Kind = dto.Kind; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/StateUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/StateUsageFactory.cs index 62cbe00b..7861d295 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/StateUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/StateUsageFactory.cs @@ -72,7 +72,6 @@ public Core.POCO.Systems.States.StateUsage Create(Core.DTO.Systems.States.StateU poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/SubjectMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/SubjectMembershipFactory.cs index 46fbd464..377ac9ee 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/SubjectMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/SubjectMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Systems.Requirements.SubjectMembership Create(Core.DTO.Systems. poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/SuccessionAsUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/SuccessionAsUsageFactory.cs index 2b82fa92..e52c2d70 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/SuccessionAsUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/SuccessionAsUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Connections.SuccessionAsUsage Create(Core.DTO.Systems.C poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/SuccessionFlowUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/SuccessionFlowUsageFactory.cs index ab4d0625..f04e43ba 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/SuccessionFlowUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/SuccessionFlowUsageFactory.cs @@ -72,7 +72,6 @@ public Core.POCO.Systems.Flows.SuccessionFlowUsage Create(Core.DTO.Systems.Flows poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/TerminateActionUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/TerminateActionUsageFactory.cs index 45830861..b1ce3a2a 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/TerminateActionUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/TerminateActionUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.TerminateActionUsage Create(Core.DTO.Systems.Ac poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/TransitionFeatureMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/TransitionFeatureMembershipFactory.cs index 5190acc2..6dc74076 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/TransitionFeatureMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/TransitionFeatureMembershipFactory.cs @@ -62,8 +62,6 @@ public Core.POCO.Systems.States.TransitionFeatureMembership Create(Core.DTO.Syst poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; poco.Kind = dto.Kind; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/TransitionUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/TransitionUsageFactory.cs index 1f158c66..83c63405 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/TransitionUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/TransitionUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.States.TransitionUsage Create(Core.DTO.Systems.States.T poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/UsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/UsageFactory.cs index 48ce4641..5f081bd2 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/UsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/UsageFactory.cs @@ -70,7 +70,6 @@ public Core.POCO.Systems.DefinitionAndUsage.Usage Create(Core.DTO.Systems.Defini poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/UseCaseUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/UseCaseUsageFactory.cs index b818b748..64704257 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/UseCaseUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/UseCaseUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.UseCases.UseCaseUsage Create(Core.DTO.Systems.UseCases. poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/VariantMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/VariantMembershipFactory.cs index 5da54c4b..bdaf6886 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/VariantMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/VariantMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Systems.DefinitionAndUsage.VariantMembership Create(Core.DTO.Sy poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/VerificationCaseUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/VerificationCaseUsageFactory.cs index 1950f478..40fad252 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/VerificationCaseUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/VerificationCaseUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.VerificationCases.VerificationCaseUsage Create(Core.DTO poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewRenderingMembershipFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewRenderingMembershipFactory.cs index abe8b993..642b7660 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewRenderingMembershipFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewRenderingMembershipFactory.cs @@ -61,8 +61,6 @@ public Core.POCO.Systems.Views.ViewRenderingMembership Create(Core.DTO.Systems.V poco.ElementId = dto.ElementId; poco.IsImplied = dto.IsImplied; poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - poco.MemberShortName = dto.MemberShortName; poco.Visibility = dto.Visibility; return poco; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewUsageFactory.cs index 770450e8..876e0c6d 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Views.ViewUsage Create(Core.DTO.Systems.Views.ViewUsage poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewpointDefinitionFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewpointDefinitionFactory.cs index ab1119e9..3d2f38fc 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewpointDefinitionFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewpointDefinitionFactory.cs @@ -57,7 +57,6 @@ public Core.POCO.Systems.Views.ViewpointDefinition Create(Core.DTO.Systems.Views poco.Id = dto.Id; poco.AliasIds = dto.AliasIds; poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; poco.ElementId = dto.ElementId; poco.IsAbstract = dto.IsAbstract; poco.IsImpliedIncluded = dto.IsImpliedIncluded; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewpointUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewpointUsageFactory.cs index 60af4240..fdb77be8 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewpointUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/ViewpointUsageFactory.cs @@ -57,7 +57,6 @@ public Core.POCO.Systems.Views.ViewpointUsage Create(Core.DTO.Systems.Views.View poco.Id = dto.Id; poco.AliasIds = dto.AliasIds; poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; poco.Direction = dto.Direction; poco.ElementId = dto.ElementId; poco.IsAbstract = dto.IsAbstract; @@ -71,7 +70,6 @@ public Core.POCO.Systems.Views.ViewpointUsage Create(Core.DTO.Systems.Views.View poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; poco.ReqId = dto.ReqId; diff --git a/SysML2.NET.Dal/Core/AutoGenElementFactory/WhileLoopActionUsageFactory.cs b/SysML2.NET.Dal/Core/AutoGenElementFactory/WhileLoopActionUsageFactory.cs index bdec50d6..a25d5246 100644 --- a/SysML2.NET.Dal/Core/AutoGenElementFactory/WhileLoopActionUsageFactory.cs +++ b/SysML2.NET.Dal/Core/AutoGenElementFactory/WhileLoopActionUsageFactory.cs @@ -71,7 +71,6 @@ public Core.POCO.Systems.Actions.WhileLoopActionUsage Create(Core.DTO.Systems.Ac poco.IsPortion = dto.IsPortion; poco.IsSufficient = dto.IsSufficient; poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; poco.IsVariation = dto.IsVariation; poco.PortionKind = dto.PortionKind; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AcceptActionUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AcceptActionUsageExtensions.cs index 174da1e8..89b1fdfe 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AcceptActionUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AcceptActionUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.AcceptActionUsage ToDto(this Core.POCO.Sy dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ActionUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ActionUsageExtensions.cs index 8d563db7..f4c24e9c 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ActionUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ActionUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.ActionUsage ToDto(this Core.POCO.Systems. dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ActorMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ActorMembershipExtensions.cs index 2f4f625f..1d031e1e 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ActorMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ActorMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Requirements Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Requirements poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Systems.Requirements.ActorMembership ToDto(this Core.POCO dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AllocationDefinitionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AllocationDefinitionExtensions.cs index b99e4fbd..50752231 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AllocationDefinitionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AllocationDefinitionExtensions.cs @@ -83,9 +83,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsIndividual = dto.IsIndividual; - ((Core.POCO.Systems.Connections.IConnectionDefinition)poco).IsSufficient = ((Core.DTO.Systems.Connections.IConnectionDefinition)dto).IsSufficient; - - ((Core.POCO.Core.Types.IType)poco).IsSufficient = ((Core.DTO.Core.Types.IType)dto).IsSufficient; + poco.IsSufficient = dto.IsSufficient; poco.IsVariation = dto.IsVariation; @@ -107,22 +105,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -199,26 +181,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Allocations. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -243,15 +205,12 @@ public static Core.DTO.Systems.Allocations.AllocationDefinition ToDto(this Core. dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.IsIndividual = poco.IsIndividual; - ((Core.DTO.Systems.Connections.IConnectionDefinition)dto).IsSufficient = ((Core.POCO.Systems.Connections.IConnectionDefinition)poco).IsSufficient; - ((Core.DTO.Core.Types.IType)dto).IsSufficient = ((Core.POCO.Core.Types.IType)poco).IsSufficient; + dto.IsSufficient = poco.IsSufficient; dto.IsVariation = poco.IsVariation; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AllocationUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AllocationUsageExtensions.cs index ce476be1..011b8f24 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AllocationUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AllocationUsageExtensions.cs @@ -101,8 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); @@ -125,22 +123,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.PortionKind = dto.PortionKind; - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -217,26 +199,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Allocations. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -270,15 +232,12 @@ public static Core.DTO.Systems.Allocations.AllocationUsage ToDto(this Core.POCO. dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; dto.PortionKind = poco.PortionKind; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AnalysisCaseUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AnalysisCaseUsageExtensions.cs index a373af54..57169f4c 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AnalysisCaseUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AnalysisCaseUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.AnalysisCases.AnalysisCaseUsage ToDto(this Core.P dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AnnotationExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AnnotationExtensions.cs index d346f0d0..54a7cf06 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AnnotationExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AnnotationExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -198,26 +182,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Annotations.Ann poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -245,8 +209,6 @@ public static Core.DTO.Root.Annotations.Annotation ToDto(this Core.POCO.Root.Ann dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssertConstraintUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssertConstraintUsageExtensions.cs index 75f3b149..ca912f5f 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssertConstraintUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssertConstraintUsageExtensions.cs @@ -101,8 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -206,7 +204,6 @@ public static Core.DTO.Systems.Constraints.AssertConstraintUsage ToDto(this Core dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssignmentActionUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssignmentActionUsageExtensions.cs index 27ba258d..c0b01b1e 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssignmentActionUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssignmentActionUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.AssignmentActionUsage ToDto(this Core.POC dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssociationExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssociationExtensions.cs index 89cf57d7..b3322d3d 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssociationExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssociationExtensions.cs @@ -101,22 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -193,26 +177,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Associations. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -241,8 +205,6 @@ public static Core.DTO.Kernel.Associations.Association ToDto(this Core.POCO.Kern dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssociationStructureExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssociationStructureExtensions.cs index 0f81e08d..375ec967 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssociationStructureExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AssociationStructureExtensions.cs @@ -101,22 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -193,26 +177,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Associations. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -241,8 +205,6 @@ public static Core.DTO.Kernel.Associations.AssociationStructure ToDto(this Core. dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AttributeUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AttributeUsageExtensions.cs index 6d4e3374..6fc8055f 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/AttributeUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/AttributeUsageExtensions.cs @@ -97,8 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -198,7 +196,6 @@ public static Core.DTO.Systems.Attributes.AttributeUsage ToDto(this Core.POCO.Sy dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/BindingConnectorAsUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/BindingConnectorAsUsageExtensions.cs index 759d9360..2f55d2f4 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/BindingConnectorAsUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/BindingConnectorAsUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); @@ -121,22 +119,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -213,26 +195,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Connections. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -265,14 +227,11 @@ public static Core.DTO.Systems.Connections.BindingConnectorAsUsage ToDto(this Co dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/BindingConnectorExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/BindingConnectorExtensions.cs index 04dda530..57e9e1ad 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/BindingConnectorExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/BindingConnectorExtensions.cs @@ -119,22 +119,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -211,26 +195,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Connectors.Bi poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -268,8 +232,6 @@ public static Core.DTO.Kernel.Connectors.BindingConnector ToDto(this Core.POCO.K dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/CalculationUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/CalculationUsageExtensions.cs index 9ef8c8b9..605cf9c9 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/CalculationUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/CalculationUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Calculations.CalculationUsage ToDto(this Core.POC dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/CaseUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/CaseUsageExtensions.cs index 0a4db1aa..77a107e0 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/CaseUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/CaseUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Cases.CaseUsage ToDto(this Core.POCO.Systems.Case dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/CollectExpressionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/CollectExpressionExtensions.cs index 62c2f68b..5d0e07f8 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/CollectExpressionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/CollectExpressionExtensions.cs @@ -99,9 +99,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsVariable = dto.IsVariable; - ((Core.POCO.Kernel.Expressions.ICollectExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.ICollectExpression)dto).Operator; - - ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator; + poco.Operator = dto.Operator; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -201,8 +199,7 @@ public static Core.DTO.Kernel.Expressions.CollectExpression ToDto(this Core.POCO dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; dto.IsVariable = poco.IsVariable; - ((Core.DTO.Kernel.Expressions.ICollectExpression)dto).Operator = ((Core.POCO.Kernel.Expressions.ICollectExpression)poco).Operator; - ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator = ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator; + dto.Operator = poco.Operator; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConcernDefinitionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConcernDefinitionExtensions.cs index 5a5de59d..937a488c 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConcernDefinitionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConcernDefinitionExtensions.cs @@ -71,8 +71,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; - poco.ElementId = dto.ElementId; poco.IsAbstract = dto.IsAbstract; @@ -171,7 +169,6 @@ public static Core.DTO.Systems.Requirements.ConcernDefinition ToDto(this Core.PO dto.Id = poco.Id; dto.AliasIds = poco.AliasIds; dto.DeclaredName = poco.DeclaredName; - dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; dto.IsAbstract = poco.IsAbstract; dto.IsImpliedIncluded = poco.IsImpliedIncluded; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConcernUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConcernUsageExtensions.cs index a46fbce5..5aca4320 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConcernUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConcernUsageExtensions.cs @@ -71,8 +71,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; - poco.Direction = dto.Direction; poco.ElementId = dto.ElementId; @@ -99,8 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -191,7 +187,6 @@ public static Core.DTO.Systems.Requirements.ConcernUsage ToDto(this Core.POCO.Sy dto.Id = poco.Id; dto.AliasIds = poco.AliasIds; dto.DeclaredName = poco.DeclaredName; - dto.DeclaredShortName = poco.DeclaredShortName; dto.Direction = poco.Direction; dto.ElementId = poco.ElementId; dto.IsAbstract = poco.IsAbstract; @@ -205,7 +200,6 @@ public static Core.DTO.Systems.Requirements.ConcernUsage ToDto(this Core.POCO.Sy dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConjugatedPortTypingExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConjugatedPortTypingExtensions.cs index e8e4ca37..08dde542 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConjugatedPortTypingExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConjugatedPortTypingExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -160,15 +144,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Ports.Conjug poco.ConjugatedPortDefinition = null; } - if (cache.TryGetValue(dto.General, out lazyPoco)) - { - poco.General = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.General = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -207,44 +182,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Ports.Conjug poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - if (cache.TryGetValue(dto.Specific, out lazyPoco)) - { - poco.Specific = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.Specific = null; - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - if (cache.TryGetValue(dto.Type, out lazyPoco)) - { - poco.Type = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.Type = null; - } - if (cache.TryGetValue(dto.TypedFeature, out lazyPoco)) { poco.TypedFeature = (Core.POCO.Core.Features.Feature)lazyPoco.Value; @@ -275,17 +212,12 @@ public static Core.DTO.Systems.Ports.ConjugatedPortTyping ToDto(this Core.POCO.S dto.DeclaredName = poco.DeclaredName; dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; - dto.General = poco.General.Id; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Specific = poco.Specific.Id; - dto.Target = poco.Target.Select(x => x.Id).ToList(); - dto.Type = poco.Type.Id; dto.TypedFeature = poco.TypedFeature.Id; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConjugationExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConjugationExtensions.cs index fc4d3a85..1710d9ef 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConjugationExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConjugationExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -207,26 +191,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Types.Conjugati poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -255,8 +219,6 @@ public static Core.DTO.Core.Types.Conjugation ToDto(this Core.POCO.Core.Types.Co dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConnectionDefinitionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConnectionDefinitionExtensions.cs index 5a65c915..d49ccd04 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConnectionDefinitionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConnectionDefinitionExtensions.cs @@ -83,9 +83,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsIndividual = dto.IsIndividual; - ((Core.POCO.Systems.Connections.IConnectionDefinition)poco).IsSufficient = ((Core.DTO.Systems.Connections.IConnectionDefinition)dto).IsSufficient; - - ((Core.POCO.Core.Types.IType)poco).IsSufficient = ((Core.DTO.Core.Types.IType)dto).IsSufficient; + poco.IsSufficient = dto.IsSufficient; poco.IsVariation = dto.IsVariation; @@ -107,22 +105,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -199,26 +181,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Connections. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -243,15 +205,12 @@ public static Core.DTO.Systems.Connections.ConnectionDefinition ToDto(this Core. dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.IsIndividual = poco.IsIndividual; - ((Core.DTO.Systems.Connections.IConnectionDefinition)dto).IsSufficient = ((Core.POCO.Systems.Connections.IConnectionDefinition)poco).IsSufficient; - ((Core.DTO.Core.Types.IType)dto).IsSufficient = ((Core.POCO.Core.Types.IType)poco).IsSufficient; + dto.IsSufficient = poco.IsSufficient; dto.IsVariation = poco.IsVariation; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConnectionUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConnectionUsageExtensions.cs index 14ecffa2..806dd22d 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConnectionUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConnectionUsageExtensions.cs @@ -101,8 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); @@ -125,22 +123,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.PortionKind = dto.PortionKind; - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -217,26 +199,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Connections. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -270,15 +232,12 @@ public static Core.DTO.Systems.Connections.ConnectionUsage ToDto(this Core.POCO. dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; dto.PortionKind = poco.PortionKind; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConnectorExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConnectorExtensions.cs index fb725520..2c9d47e5 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConnectorExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConnectorExtensions.cs @@ -119,22 +119,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -211,26 +195,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Connectors.Co poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -268,8 +232,6 @@ public static Core.DTO.Kernel.Connectors.Connector ToDto(this Core.POCO.Kernel.C dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConstraintUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConstraintUsageExtensions.cs index 36788a15..fd38cba9 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConstraintUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ConstraintUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Constraints.ConstraintUsage ToDto(this Core.POCO. dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/CrossSubsettingExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/CrossSubsettingExtensions.cs index 1c376b8a..aa2d8d37 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/CrossSubsettingExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/CrossSubsettingExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -160,15 +144,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.CrossS poco.CrossedFeature = null; } - if (cache.TryGetValue(dto.General, out lazyPoco)) - { - poco.General = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.General = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -207,53 +182,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.CrossS poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - if (cache.TryGetValue(dto.Specific, out lazyPoco)) - { - poco.Specific = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.Specific = null; - } - - if (cache.TryGetValue(dto.SubsettedFeature, out lazyPoco)) - { - poco.SubsettedFeature = (Core.POCO.Core.Features.Feature)lazyPoco.Value; - } - else - { - poco.SubsettedFeature = null; - } - - if (cache.TryGetValue(dto.SubsettingFeature, out lazyPoco)) - { - poco.SubsettingFeature = (Core.POCO.Core.Features.Feature)lazyPoco.Value; - } - else - { - poco.SubsettingFeature = null; - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -275,18 +203,12 @@ public static Core.DTO.Core.Features.CrossSubsetting ToDto(this Core.POCO.Core.F dto.DeclaredName = poco.DeclaredName; dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; - dto.General = poco.General.Id; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Specific = poco.Specific.Id; - dto.SubsettedFeature = poco.SubsettedFeature.Id; - dto.SubsettingFeature = poco.SubsettingFeature.Id; - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/DecisionNodeExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/DecisionNodeExtensions.cs index 49e8c68a..971406d8 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/DecisionNodeExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/DecisionNodeExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.DecisionNode ToDto(this Core.POCO.Systems dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/DependencyExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/DependencyExtensions.cs index 2ce40690..971bc13c 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/DependencyExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/DependencyExtensions.cs @@ -105,14 +105,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - var supplierToDelete = poco.Supplier.Select(x => x.Id).Except(dto.Supplier); foreach (var identifier in supplierToDelete) @@ -121,14 +113,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t } - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -215,16 +199,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Dependencies.De poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - var supplierToAdd = dto.Supplier.Except(poco.Supplier.Select(x => x.Id)); foreach (var identifier in supplierToAdd) @@ -235,16 +209,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Dependencies.De } } - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -272,9 +236,7 @@ public static Core.DTO.Root.Dependencies.Dependency ToDto(this Core.POCO.Root.De dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); dto.Supplier = poco.Supplier.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/DifferencingExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/DifferencingExtensions.cs index 61ce3c80..6e1cc096 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/DifferencingExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/DifferencingExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -198,26 +182,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Types.Differenc poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -245,8 +209,6 @@ public static Core.DTO.Core.Types.Differencing ToDto(this Core.POCO.Core.Types.D dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/DisjoiningExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/DisjoiningExtensions.cs index 6fd8b52b..02527c1e 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/DisjoiningExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/DisjoiningExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -198,26 +182,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Types.Disjoinin poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - if (cache.TryGetValue(dto.TypeDisjoined, out lazyPoco)) { poco.TypeDisjoined = (Core.POCO.Core.Types.Type)lazyPoco.Value; @@ -254,8 +218,6 @@ public static Core.DTO.Core.Types.Disjoining ToDto(this Core.POCO.Core.Types.Dis dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.TypeDisjoined = poco.TypeDisjoined.Id; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ElementFilterMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ElementFilterMembershipExtensions.cs index a6d7cc8e..01fb1595 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ElementFilterMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ElementFilterMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Packages.Elem Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Packages.Elem poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Kernel.Packages.ElementFilterMembership ToDto(this Core.P dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/EndFeatureMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/EndFeatureMembershipExtensions.cs index 963535cc..71bba258 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/EndFeatureMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/EndFeatureMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.EndFea Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.EndFea poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Core.Features.EndFeatureMembership ToDto(this Core.POCO.C dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/EnumerationDefinitionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/EnumerationDefinitionExtensions.cs index a9e1be22..de2516de 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/EnumerationDefinitionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/EnumerationDefinitionExtensions.cs @@ -81,9 +81,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsSufficient = dto.IsSufficient; - ((Core.POCO.Systems.Enumerations.IEnumerationDefinition)poco).IsVariation = ((Core.DTO.Systems.Enumerations.IEnumerationDefinition)dto).IsVariation; - - ((Core.POCO.Systems.DefinitionAndUsage.IDefinition)poco).IsVariation = ((Core.DTO.Systems.DefinitionAndUsage.IDefinition)dto).IsVariation; + poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -174,8 +172,7 @@ public static Core.DTO.Systems.Enumerations.EnumerationDefinition ToDto(this Cor dto.IsAbstract = poco.IsAbstract; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.IsSufficient = poco.IsSufficient; - ((Core.DTO.Systems.Enumerations.IEnumerationDefinition)dto).IsVariation = ((Core.POCO.Systems.Enumerations.IEnumerationDefinition)poco).IsVariation; - ((Core.DTO.Systems.DefinitionAndUsage.IDefinition)dto).IsVariation = ((Core.POCO.Systems.DefinitionAndUsage.IDefinition)poco).IsVariation; + dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/EnumerationUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/EnumerationUsageExtensions.cs index 170ea392..e89ac1c9 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/EnumerationUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/EnumerationUsageExtensions.cs @@ -97,8 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -198,7 +196,6 @@ public static Core.DTO.Systems.Enumerations.EnumerationUsage ToDto(this Core.POC dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/EventOccurrenceUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/EventOccurrenceUsageExtensions.cs index bfead464..95791785 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/EventOccurrenceUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/EventOccurrenceUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Occurrences.EventOccurrenceUsage ToDto(this Core. dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ExhibitStateUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ExhibitStateUsageExtensions.cs index bac6c7f2..5a54bece 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ExhibitStateUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ExhibitStateUsageExtensions.cs @@ -101,8 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -206,7 +204,6 @@ public static Core.DTO.Systems.States.ExhibitStateUsage ToDto(this Core.POCO.Sys dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureChainExpressionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureChainExpressionExtensions.cs index 612ec92e..fc6ce6c9 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureChainExpressionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureChainExpressionExtensions.cs @@ -99,9 +99,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsVariable = dto.IsVariable; - ((Core.POCO.Kernel.Expressions.IFeatureChainExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IFeatureChainExpression)dto).Operator; - - ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator; + poco.Operator = dto.Operator; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -201,8 +199,7 @@ public static Core.DTO.Kernel.Expressions.FeatureChainExpression ToDto(this Core dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; dto.IsVariable = poco.IsVariable; - ((Core.DTO.Kernel.Expressions.IFeatureChainExpression)dto).Operator = ((Core.POCO.Kernel.Expressions.IFeatureChainExpression)poco).Operator; - ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator = ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator; + dto.Operator = poco.Operator; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureChainingExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureChainingExtensions.cs index cd5b31bc..d46b8bac 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureChainingExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureChainingExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -198,26 +182,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Featur poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -245,8 +209,6 @@ public static Core.DTO.Core.Features.FeatureChaining ToDto(this Core.POCO.Core.F dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureInvertingExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureInvertingExtensions.cs index 348b15f4..52c12318 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureInvertingExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureInvertingExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -207,26 +191,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Featur poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -255,8 +219,6 @@ public static Core.DTO.Core.Features.FeatureInverting ToDto(this Core.POCO.Core. dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureMembershipExtensions.cs index 0216cd03..25cea235 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Types.FeatureMe Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Types.FeatureMe poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Core.Types.FeatureMembership ToDto(this Core.POCO.Core.Ty dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureTypingExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureTypingExtensions.cs index 2a3a9d52..45b4d58b 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureTypingExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureTypingExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -151,15 +135,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Featur Lazy lazyPoco; - if (cache.TryGetValue(dto.General, out lazyPoco)) - { - poco.General = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.General = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -198,35 +173,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Featur poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - if (cache.TryGetValue(dto.Specific, out lazyPoco)) - { - poco.Specific = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.Specific = null; - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - if (cache.TryGetValue(dto.Type, out lazyPoco)) { poco.Type = (Core.POCO.Core.Types.Type)lazyPoco.Value; @@ -265,16 +211,12 @@ public static Core.DTO.Core.Features.FeatureTyping ToDto(this Core.POCO.Core.Fea dto.DeclaredName = poco.DeclaredName; dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; - dto.General = poco.General.Id; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Specific = poco.Specific.Id; - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Type = poco.Type.Id; dto.TypedFeature = poco.TypedFeature.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureValueExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureValueExtensions.cs index bdefa82c..3607f483 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureValueExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FeatureValueExtensions.cs @@ -83,10 +83,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsInitial = dto.IsInitial; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -105,22 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -161,15 +141,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.FeatureValues Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -208,26 +179,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.FeatureValues poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -252,15 +203,10 @@ public static Core.DTO.Kernel.FeatureValues.FeatureValue ToDto(this Core.POCO.Ke dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.IsInitial = poco.IsInitial; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FlowDefinitionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FlowDefinitionExtensions.cs index d7363956..1d689804 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FlowDefinitionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FlowDefinitionExtensions.cs @@ -105,22 +105,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -197,26 +181,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Flows.FlowDe poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -247,8 +211,6 @@ public static Core.DTO.Systems.Flows.FlowDefinition ToDto(this Core.POCO.Systems dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FlowExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FlowExtensions.cs index 41e08951..93d2d21d 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FlowExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FlowExtensions.cs @@ -119,22 +119,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -211,26 +195,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Interactions. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -268,8 +232,6 @@ public static Core.DTO.Kernel.Interactions.Flow ToDto(this Core.POCO.Kernel.Inte dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FlowUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FlowUsageExtensions.cs index aacd7adb..9081c5cc 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FlowUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FlowUsageExtensions.cs @@ -101,8 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); @@ -125,22 +123,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.PortionKind = dto.PortionKind; - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -217,26 +199,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Flows.FlowUs poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -270,15 +232,12 @@ public static Core.DTO.Systems.Flows.FlowUsage ToDto(this Core.POCO.Systems.Flow dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; dto.PortionKind = poco.PortionKind; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ForLoopActionUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ForLoopActionUsageExtensions.cs index 4a7b1144..cdffa0ff 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ForLoopActionUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ForLoopActionUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.ForLoopActionUsage ToDto(this Core.POCO.S dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ForkNodeExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ForkNodeExtensions.cs index c89a7a3c..06e35e9e 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ForkNodeExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ForkNodeExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.ForkNode ToDto(this Core.POCO.Systems.Act dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FramedConcernMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FramedConcernMembershipExtensions.cs index c9a2d960..9f19b619 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/FramedConcernMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/FramedConcernMembershipExtensions.cs @@ -79,13 +79,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - ((Core.POCO.Systems.Requirements.IFramedConcernMembership)poco).Kind = ((Core.DTO.Systems.Requirements.IFramedConcernMembership)dto).Kind; - - ((Core.POCO.Systems.Requirements.IRequirementConstraintMembership)poco).Kind = ((Core.DTO.Systems.Requirements.IRequirementConstraintMembership)dto).Kind; - - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; + poco.Kind = dto.Kind; var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); @@ -105,22 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -161,15 +139,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Requirements Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -208,26 +177,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Requirements poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -250,17 +199,11 @@ public static Core.DTO.Systems.Requirements.FramedConcernMembership ToDto(this C dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - ((Core.DTO.Systems.Requirements.IFramedConcernMembership)dto).Kind = ((Core.POCO.Systems.Requirements.IFramedConcernMembership)poco).Kind; - ((Core.DTO.Systems.Requirements.IRequirementConstraintMembership)dto).Kind = ((Core.POCO.Systems.Requirements.IRequirementConstraintMembership)poco).Kind; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; + dto.Kind = poco.Kind; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/IfActionUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/IfActionUsageExtensions.cs index 2c1b7c0b..94888cfe 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/IfActionUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/IfActionUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.IfActionUsage ToDto(this Core.POCO.System dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/IncludeUseCaseUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/IncludeUseCaseUsageExtensions.cs index 9bd28b07..603818f2 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/IncludeUseCaseUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/IncludeUseCaseUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.UseCases.IncludeUseCaseUsage ToDto(this Core.POCO dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/IndexExpressionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/IndexExpressionExtensions.cs index 8e16eddb..3d65c905 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/IndexExpressionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/IndexExpressionExtensions.cs @@ -99,9 +99,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsVariable = dto.IsVariable; - ((Core.POCO.Kernel.Expressions.IIndexExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IIndexExpression)dto).Operator; - - ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator; + poco.Operator = dto.Operator; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -201,8 +199,7 @@ public static Core.DTO.Kernel.Expressions.IndexExpression ToDto(this Core.POCO.K dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; dto.IsVariable = poco.IsVariable; - ((Core.DTO.Kernel.Expressions.IIndexExpression)dto).Operator = ((Core.POCO.Kernel.Expressions.IIndexExpression)poco).Operator; - ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator = ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator; + dto.Operator = poco.Operator; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/InteractionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/InteractionExtensions.cs index 2c3e707e..8b9f9b94 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/InteractionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/InteractionExtensions.cs @@ -101,22 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -193,26 +177,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Interactions. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -241,8 +205,6 @@ public static Core.DTO.Kernel.Interactions.Interaction ToDto(this Core.POCO.Kern dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/InterfaceDefinitionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/InterfaceDefinitionExtensions.cs index fd279161..13f6fb40 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/InterfaceDefinitionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/InterfaceDefinitionExtensions.cs @@ -83,9 +83,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsIndividual = dto.IsIndividual; - ((Core.POCO.Systems.Connections.IConnectionDefinition)poco).IsSufficient = ((Core.DTO.Systems.Connections.IConnectionDefinition)dto).IsSufficient; - - ((Core.POCO.Core.Types.IType)poco).IsSufficient = ((Core.DTO.Core.Types.IType)dto).IsSufficient; + poco.IsSufficient = dto.IsSufficient; poco.IsVariation = dto.IsVariation; @@ -107,22 +105,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -199,26 +181,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Interfaces.I poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -243,15 +205,12 @@ public static Core.DTO.Systems.Interfaces.InterfaceDefinition ToDto(this Core.PO dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.IsIndividual = poco.IsIndividual; - ((Core.DTO.Systems.Connections.IConnectionDefinition)dto).IsSufficient = ((Core.POCO.Systems.Connections.IConnectionDefinition)poco).IsSufficient; - ((Core.DTO.Core.Types.IType)dto).IsSufficient = ((Core.POCO.Core.Types.IType)poco).IsSufficient; + dto.IsSufficient = poco.IsSufficient; dto.IsVariation = poco.IsVariation; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/InterfaceUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/InterfaceUsageExtensions.cs index 7aaa225b..883f8f04 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/InterfaceUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/InterfaceUsageExtensions.cs @@ -101,8 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); @@ -125,22 +123,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.PortionKind = dto.PortionKind; - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -217,26 +199,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Interfaces.I poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -270,15 +232,12 @@ public static Core.DTO.Systems.Interfaces.InterfaceUsage ToDto(this Core.POCO.Sy dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; dto.PortionKind = poco.PortionKind; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/IntersectingExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/IntersectingExtensions.cs index 4bef3954..b5b6ff7c 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/IntersectingExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/IntersectingExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -198,26 +182,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Types.Intersect poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -245,8 +209,6 @@ public static Core.DTO.Core.Types.Intersecting ToDto(this Core.POCO.Core.Types.I dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ItemUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ItemUsageExtensions.cs index e82dc44c..36eace0c 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ItemUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ItemUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Items.ItemUsage ToDto(this Core.POCO.Systems.Item dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/JoinNodeExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/JoinNodeExtensions.cs index dbe912a1..24e720db 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/JoinNodeExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/JoinNodeExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.JoinNode ToDto(this Core.POCO.Systems.Act dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/MembershipExposeExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/MembershipExposeExtensions.cs index f94ac7bc..da622fd3 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/MembershipExposeExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/MembershipExposeExtensions.cs @@ -79,9 +79,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - ((Core.POCO.Root.Namespaces.IImport)poco).IsImportAll = ((Core.DTO.Root.Namespaces.IImport)dto).IsImportAll; - - ((Core.POCO.Systems.Views.IExpose)poco).IsImportAll = ((Core.DTO.Systems.Views.IExpose)dto).IsImportAll; + poco.IsImportAll = dto.IsImportAll; poco.IsRecursive = dto.IsRecursive; @@ -103,25 +101,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - - ((Core.POCO.Root.Namespaces.IImport)poco).Visibility = ((Core.DTO.Root.Namespaces.IImport)dto).Visibility; - - ((Core.POCO.Systems.Views.IExpose)poco).Visibility = ((Core.DTO.Systems.Views.IExpose)dto).Visibility; + poco.Visibility = dto.Visibility; return identifiersOfObjectsToDelete; @@ -208,26 +188,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Views.Member poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -251,17 +211,13 @@ public static Core.DTO.Systems.Views.MembershipExpose ToDto(this Core.POCO.Syste dto.ImportedMembership = poco.ImportedMembership.Id; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - ((Core.DTO.Root.Namespaces.IImport)dto).IsImportAll = ((Core.POCO.Root.Namespaces.IImport)poco).IsImportAll; - ((Core.DTO.Systems.Views.IExpose)dto).IsImportAll = ((Core.POCO.Systems.Views.IExpose)poco).IsImportAll; + dto.IsImportAll = poco.IsImportAll; dto.IsRecursive = poco.IsRecursive; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); - ((Core.DTO.Root.Namespaces.IImport)dto).Visibility = ((Core.POCO.Root.Namespaces.IImport)poco).Visibility; - ((Core.DTO.Systems.Views.IExpose)dto).Visibility = ((Core.POCO.Systems.Views.IExpose)poco).Visibility; + dto.Visibility = poco.Visibility; return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/MembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/MembershipExtensions.cs index bd688488..9561aa74 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/MembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/MembershipExtensions.cs @@ -101,22 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -204,26 +188,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Namespaces.Memb poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -253,8 +217,6 @@ public static Core.DTO.Root.Namespaces.Membership ToDto(this Core.POCO.Root.Name dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/MembershipImportExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/MembershipImportExtensions.cs index aa675de5..7f432a53 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/MembershipImportExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/MembershipImportExtensions.cs @@ -101,22 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -204,26 +188,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Namespaces.Memb poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -253,8 +217,6 @@ public static Core.DTO.Root.Namespaces.MembershipImport ToDto(this Core.POCO.Roo dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/MergeNodeExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/MergeNodeExtensions.cs index 8313ae60..9b1024a8 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/MergeNodeExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/MergeNodeExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.MergeNode ToDto(this Core.POCO.Systems.Ac dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/MetadataUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/MetadataUsageExtensions.cs index c57463ec..c541a638 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/MetadataUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/MetadataUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Metadata.MetadataUsage ToDto(this Core.POCO.Syste dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/NamespaceExposeExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/NamespaceExposeExtensions.cs index 1efb3f81..59f472e7 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/NamespaceExposeExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/NamespaceExposeExtensions.cs @@ -79,9 +79,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - ((Core.POCO.Systems.Views.IExpose)poco).IsImportAll = ((Core.DTO.Systems.Views.IExpose)dto).IsImportAll; - - ((Core.POCO.Root.Namespaces.IImport)poco).IsImportAll = ((Core.DTO.Root.Namespaces.IImport)dto).IsImportAll; + poco.IsImportAll = dto.IsImportAll; poco.IsRecursive = dto.IsRecursive; @@ -103,25 +101,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - - ((Core.POCO.Systems.Views.IExpose)poco).Visibility = ((Core.DTO.Systems.Views.IExpose)dto).Visibility; - - ((Core.POCO.Root.Namespaces.IImport)poco).Visibility = ((Core.DTO.Root.Namespaces.IImport)dto).Visibility; + poco.Visibility = dto.Visibility; return identifiersOfObjectsToDelete; @@ -208,26 +188,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Views.Namesp poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -251,17 +211,13 @@ public static Core.DTO.Systems.Views.NamespaceExpose ToDto(this Core.POCO.System dto.ImportedNamespace = poco.ImportedNamespace.Id; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - ((Core.DTO.Systems.Views.IExpose)dto).IsImportAll = ((Core.POCO.Systems.Views.IExpose)poco).IsImportAll; - ((Core.DTO.Root.Namespaces.IImport)dto).IsImportAll = ((Core.POCO.Root.Namespaces.IImport)poco).IsImportAll; + dto.IsImportAll = poco.IsImportAll; dto.IsRecursive = poco.IsRecursive; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); - ((Core.DTO.Systems.Views.IExpose)dto).Visibility = ((Core.POCO.Systems.Views.IExpose)poco).Visibility; - ((Core.DTO.Root.Namespaces.IImport)dto).Visibility = ((Core.POCO.Root.Namespaces.IImport)poco).Visibility; + dto.Visibility = poco.Visibility; return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/NamespaceImportExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/NamespaceImportExtensions.cs index 103ba2d4..28d050ef 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/NamespaceImportExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/NamespaceImportExtensions.cs @@ -101,22 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -204,26 +188,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Namespaces.Name poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -253,8 +217,6 @@ public static Core.DTO.Root.Namespaces.NamespaceImport ToDto(this Core.POCO.Root dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ObjectiveMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ObjectiveMembershipExtensions.cs index 1928a570..af2cca05 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ObjectiveMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ObjectiveMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Cases.Object Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Cases.Object poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Systems.Cases.ObjectiveMembership ToDto(this Core.POCO.Sy dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/OccurrenceUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/OccurrenceUsageExtensions.cs index 9280a533..8d94cd9f 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/OccurrenceUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/OccurrenceUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Occurrences.OccurrenceUsage ToDto(this Core.POCO. dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/OwningMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/OwningMembershipExtensions.cs index 2701e6f9..8a9b7046 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/OwningMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/OwningMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Namespaces.Owni Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Root.Namespaces.Owni poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Root.Namespaces.OwningMembership ToDto(this Core.POCO.Roo dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ParameterMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ParameterMembershipExtensions.cs index 8d37fb08..c60df04a 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ParameterMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ParameterMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Behaviors.Par Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Behaviors.Par poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Kernel.Behaviors.ParameterMembership ToDto(this Core.POCO dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/PartUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/PartUsageExtensions.cs index 23265259..624e883b 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/PartUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/PartUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Parts.PartUsage ToDto(this Core.POCO.Systems.Part dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/PerformActionUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/PerformActionUsageExtensions.cs index bed18d41..b81d9503 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/PerformActionUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/PerformActionUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.PerformActionUsage ToDto(this Core.POCO.S dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/PortConjugationExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/PortConjugationExtensions.cs index 431a3561..6124e9c3 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/PortConjugationExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/PortConjugationExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -169,15 +153,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Ports.PortCo poco.OriginalPortDefinition = null; } - if (cache.TryGetValue(dto.OriginalType, out lazyPoco)) - { - poco.OriginalType = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.OriginalType = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -216,26 +191,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Ports.PortCo poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -260,13 +215,10 @@ public static Core.DTO.Systems.Ports.PortConjugation ToDto(this Core.POCO.System dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.OriginalPortDefinition = poco.OriginalPortDefinition.Id; - dto.OriginalType = poco.OriginalType.Id; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/PortUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/PortUsageExtensions.cs index af6c8358..fcbf39ea 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/PortUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/PortUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Ports.PortUsage ToDto(this Core.POCO.Systems.Port dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/RedefinitionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/RedefinitionExtensions.cs index 94d82fc8..18d18de0 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/RedefinitionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/RedefinitionExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -151,15 +135,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Redefi Lazy lazyPoco; - if (cache.TryGetValue(dto.General, out lazyPoco)) - { - poco.General = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.General = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -216,53 +191,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Redefi poco.RedefiningFeature = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - if (cache.TryGetValue(dto.Specific, out lazyPoco)) - { - poco.Specific = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.Specific = null; - } - - if (cache.TryGetValue(dto.SubsettedFeature, out lazyPoco)) - { - poco.SubsettedFeature = (Core.POCO.Core.Features.Feature)lazyPoco.Value; - } - else - { - poco.SubsettedFeature = null; - } - - if (cache.TryGetValue(dto.SubsettingFeature, out lazyPoco)) - { - poco.SubsettingFeature = (Core.POCO.Core.Features.Feature)lazyPoco.Value; - } - else - { - poco.SubsettingFeature = null; - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -283,7 +211,6 @@ public static Core.DTO.Core.Features.Redefinition ToDto(this Core.POCO.Core.Feat dto.DeclaredName = poco.DeclaredName; dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; - dto.General = poco.General.Id; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); @@ -292,11 +219,6 @@ public static Core.DTO.Core.Features.Redefinition ToDto(this Core.POCO.Core.Feat dto.OwningRelationship = poco.OwningRelationship?.Id; dto.RedefinedFeature = poco.RedefinedFeature.Id; dto.RedefiningFeature = poco.RedefiningFeature.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Specific = poco.Specific.Id; - dto.SubsettedFeature = poco.SubsettedFeature.Id; - dto.SubsettingFeature = poco.SubsettingFeature.Id; - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ReferenceSubsettingExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ReferenceSubsettingExtensions.cs index 05ed37dd..ed8a20d9 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ReferenceSubsettingExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ReferenceSubsettingExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -151,15 +135,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Refere Lazy lazyPoco; - if (cache.TryGetValue(dto.General, out lazyPoco)) - { - poco.General = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.General = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -207,53 +182,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Refere poco.ReferencedFeature = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - if (cache.TryGetValue(dto.Specific, out lazyPoco)) - { - poco.Specific = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.Specific = null; - } - - if (cache.TryGetValue(dto.SubsettedFeature, out lazyPoco)) - { - poco.SubsettedFeature = (Core.POCO.Core.Features.Feature)lazyPoco.Value; - } - else - { - poco.SubsettedFeature = null; - } - - if (cache.TryGetValue(dto.SubsettingFeature, out lazyPoco)) - { - poco.SubsettingFeature = (Core.POCO.Core.Features.Feature)lazyPoco.Value; - } - else - { - poco.SubsettingFeature = null; - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -274,7 +202,6 @@ public static Core.DTO.Core.Features.ReferenceSubsetting ToDto(this Core.POCO.Co dto.DeclaredName = poco.DeclaredName; dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; - dto.General = poco.General.Id; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); @@ -282,11 +209,6 @@ public static Core.DTO.Core.Features.ReferenceSubsetting ToDto(this Core.POCO.Co dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; dto.ReferencedFeature = poco.ReferencedFeature.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Specific = poco.Specific.Id; - dto.SubsettedFeature = poco.SubsettedFeature.Id; - dto.SubsettingFeature = poco.SubsettingFeature.Id; - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ReferenceUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ReferenceUsageExtensions.cs index 53ed800f..10ef1f38 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ReferenceUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ReferenceUsageExtensions.cs @@ -97,8 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -198,7 +196,6 @@ public static Core.DTO.Systems.DefinitionAndUsage.ReferenceUsage ToDto(this Core dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/RenderingUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/RenderingUsageExtensions.cs index 7679749d..dc7f3cb8 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/RenderingUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/RenderingUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Views.RenderingUsage ToDto(this Core.POCO.Systems dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementConstraintMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementConstraintMembershipExtensions.cs index 456c74cd..6ba95b2e 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementConstraintMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementConstraintMembershipExtensions.cs @@ -81,10 +81,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.Kind = dto.Kind; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -103,22 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -159,15 +139,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Requirements Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -206,26 +177,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Requirements poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -249,15 +200,10 @@ public static Core.DTO.Systems.Requirements.RequirementConstraintMembership ToDt dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.Kind = poco.Kind; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementDefinitionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementDefinitionExtensions.cs index 929d2d9b..99c8a9e3 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementDefinitionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementDefinitionExtensions.cs @@ -71,8 +71,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; - poco.ElementId = dto.ElementId; poco.IsAbstract = dto.IsAbstract; @@ -171,7 +169,6 @@ public static Core.DTO.Systems.Requirements.RequirementDefinition ToDto(this Cor dto.Id = poco.Id; dto.AliasIds = poco.AliasIds; dto.DeclaredName = poco.DeclaredName; - dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; dto.IsAbstract = poco.IsAbstract; dto.IsImpliedIncluded = poco.IsImpliedIncluded; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementUsageExtensions.cs index 382173d0..8466878b 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementUsageExtensions.cs @@ -71,8 +71,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; - poco.Direction = dto.Direction; poco.ElementId = dto.ElementId; @@ -99,8 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -191,7 +187,6 @@ public static Core.DTO.Systems.Requirements.RequirementUsage ToDto(this Core.POC dto.Id = poco.Id; dto.AliasIds = poco.AliasIds; dto.DeclaredName = poco.DeclaredName; - dto.DeclaredShortName = poco.DeclaredShortName; dto.Direction = poco.Direction; dto.ElementId = poco.ElementId; dto.IsAbstract = poco.IsAbstract; @@ -205,7 +200,6 @@ public static Core.DTO.Systems.Requirements.RequirementUsage ToDto(this Core.POC dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementVerificationMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementVerificationMembershipExtensions.cs index 4c573e1b..2c50da3e 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementVerificationMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/RequirementVerificationMembershipExtensions.cs @@ -79,13 +79,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - ((Core.POCO.Systems.VerificationCases.IRequirementVerificationMembership)poco).Kind = ((Core.DTO.Systems.VerificationCases.IRequirementVerificationMembership)dto).Kind; - - ((Core.POCO.Systems.Requirements.IRequirementConstraintMembership)poco).Kind = ((Core.DTO.Systems.Requirements.IRequirementConstraintMembership)dto).Kind; - - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; + poco.Kind = dto.Kind; var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); @@ -105,22 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -161,15 +139,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Verification Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -208,26 +177,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Verification poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -250,17 +199,11 @@ public static Core.DTO.Systems.VerificationCases.RequirementVerificationMembersh dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - ((Core.DTO.Systems.VerificationCases.IRequirementVerificationMembership)dto).Kind = ((Core.POCO.Systems.VerificationCases.IRequirementVerificationMembership)poco).Kind; - ((Core.DTO.Systems.Requirements.IRequirementConstraintMembership)dto).Kind = ((Core.POCO.Systems.Requirements.IRequirementConstraintMembership)poco).Kind; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; + dto.Kind = poco.Kind; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ResultExpressionMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ResultExpressionMembershipExtensions.cs index 9fc50c72..1dc15049 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ResultExpressionMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ResultExpressionMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Functions.Res Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Functions.Res poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Kernel.Functions.ResultExpressionMembership ToDto(this Co dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ReturnParameterMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ReturnParameterMembershipExtensions.cs index 403638d4..bf239a01 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ReturnParameterMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ReturnParameterMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Functions.Ret Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Functions.Ret poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Kernel.Functions.ReturnParameterMembership ToDto(this Cor dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SatisfyRequirementUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SatisfyRequirementUsageExtensions.cs index ac33c020..b72bcacc 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SatisfyRequirementUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SatisfyRequirementUsageExtensions.cs @@ -71,8 +71,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; - poco.Direction = dto.Direction; poco.ElementId = dto.ElementId; @@ -101,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -193,7 +189,6 @@ public static Core.DTO.Systems.Requirements.SatisfyRequirementUsage ToDto(this C dto.Id = poco.Id; dto.AliasIds = poco.AliasIds; dto.DeclaredName = poco.DeclaredName; - dto.DeclaredShortName = poco.DeclaredShortName; dto.Direction = poco.Direction; dto.ElementId = poco.ElementId; dto.IsAbstract = poco.IsAbstract; @@ -208,7 +203,6 @@ public static Core.DTO.Systems.Requirements.SatisfyRequirementUsage ToDto(this C dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SelectExpressionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SelectExpressionExtensions.cs index 8a8848e1..53e8dd62 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SelectExpressionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SelectExpressionExtensions.cs @@ -99,9 +99,7 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsVariable = dto.IsVariable; - ((Core.POCO.Kernel.Expressions.ISelectExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.ISelectExpression)dto).Operator; - - ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator = ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator; + poco.Operator = dto.Operator; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -201,8 +199,7 @@ public static Core.DTO.Kernel.Expressions.SelectExpression ToDto(this Core.POCO. dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; dto.IsVariable = poco.IsVariable; - ((Core.DTO.Kernel.Expressions.ISelectExpression)dto).Operator = ((Core.POCO.Kernel.Expressions.ISelectExpression)poco).Operator; - ((Core.DTO.Kernel.Expressions.IOperatorExpression)dto).Operator = ((Core.POCO.Kernel.Expressions.IOperatorExpression)poco).Operator; + dto.Operator = poco.Operator; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SendActionUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SendActionUsageExtensions.cs index 33f95b3a..b5810cda 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SendActionUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SendActionUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.SendActionUsage ToDto(this Core.POCO.Syst dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SpecializationExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SpecializationExtensions.cs index 14ef1812..7bc5bf0d 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SpecializationExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SpecializationExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -198,16 +182,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Types.Specializ poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - if (cache.TryGetValue(dto.Specific, out lazyPoco)) { poco.Specific = (Core.POCO.Core.Types.Type)lazyPoco.Value; @@ -217,16 +191,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Types.Specializ poco.Specific = null; } - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -254,9 +218,7 @@ public static Core.DTO.Core.Types.Specialization ToDto(this Core.POCO.Core.Types dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); dto.Specific = poco.Specific.Id; - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/StakeholderMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/StakeholderMembershipExtensions.cs index 5e2bb3cc..cb79cf9d 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/StakeholderMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/StakeholderMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Requirements Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Requirements poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Systems.Requirements.StakeholderMembership ToDto(this Cor dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/StateSubactionMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/StateSubactionMembershipExtensions.cs index 95f7f07e..afdfd515 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/StateSubactionMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/StateSubactionMembershipExtensions.cs @@ -81,10 +81,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.Kind = dto.Kind; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -103,22 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -159,15 +139,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.States.State Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -206,26 +177,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.States.State poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -249,15 +200,10 @@ public static Core.DTO.Systems.States.StateSubactionMembership ToDto(this Core.P dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.Kind = poco.Kind; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/StateUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/StateUsageExtensions.cs index 4a0e7f56..40bf71ca 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/StateUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/StateUsageExtensions.cs @@ -101,8 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -206,7 +204,6 @@ public static Core.DTO.Systems.States.StateUsage ToDto(this Core.POCO.Systems.St dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SubclassificationExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SubclassificationExtensions.cs index 8d2ccff9..63e6d25e 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SubclassificationExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SubclassificationExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -151,15 +135,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Classifiers.Sub Lazy lazyPoco; - if (cache.TryGetValue(dto.General, out lazyPoco)) - { - poco.General = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.General = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -198,25 +173,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Classifiers.Sub poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - if (cache.TryGetValue(dto.Specific, out lazyPoco)) - { - poco.Specific = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.Specific = null; - } - if (cache.TryGetValue(dto.Subclassifier, out lazyPoco)) { poco.Subclassifier = (Core.POCO.Core.Classifiers.Classifier)lazyPoco.Value; @@ -235,16 +191,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Classifiers.Sub poco.Superclassifier = null; } - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -265,18 +211,14 @@ public static Core.DTO.Core.Classifiers.Subclassification ToDto(this Core.POCO.C dto.DeclaredName = poco.DeclaredName; dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; - dto.General = poco.General.Id; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Specific = poco.Specific.Id; dto.Subclassifier = poco.Subclassifier.Id; dto.Superclassifier = poco.Superclassifier.Id; - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SubjectMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SubjectMembershipExtensions.cs index 1b25566f..1651402f 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SubjectMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SubjectMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Requirements Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Requirements poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Systems.Requirements.SubjectMembership ToDto(this Core.PO dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SubsettingExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SubsettingExtensions.cs index a8a02ff0..859da701 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SubsettingExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SubsettingExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -151,15 +135,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Subset Lazy lazyPoco; - if (cache.TryGetValue(dto.General, out lazyPoco)) - { - poco.General = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.General = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -198,25 +173,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Subset poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - if (cache.TryGetValue(dto.Specific, out lazyPoco)) - { - poco.Specific = (Core.POCO.Core.Types.Type)lazyPoco.Value; - } - else - { - poco.Specific = null; - } - if (cache.TryGetValue(dto.SubsettedFeature, out lazyPoco)) { poco.SubsettedFeature = (Core.POCO.Core.Features.Feature)lazyPoco.Value; @@ -235,16 +191,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.Subset poco.SubsettingFeature = null; } - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -265,18 +211,14 @@ public static Core.DTO.Core.Features.Subsetting ToDto(this Core.POCO.Core.Featur dto.DeclaredName = poco.DeclaredName; dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; - dto.General = poco.General.Id; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Specific = poco.Specific.Id; dto.SubsettedFeature = poco.SubsettedFeature.Id; dto.SubsettingFeature = poco.SubsettingFeature.Id; - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionAsUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionAsUsageExtensions.cs index b7b6634d..66718618 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionAsUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionAsUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); @@ -121,22 +119,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -213,26 +195,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Connections. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -265,14 +227,11 @@ public static Core.DTO.Systems.Connections.SuccessionAsUsage ToDto(this Core.POC dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionExtensions.cs index 9088ea5d..9ff77a51 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionExtensions.cs @@ -119,22 +119,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -211,26 +195,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Connectors.Su poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -268,8 +232,6 @@ public static Core.DTO.Kernel.Connectors.Succession ToDto(this Core.POCO.Kernel. dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionFlowExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionFlowExtensions.cs index dc9c368e..f7c0c371 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionFlowExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionFlowExtensions.cs @@ -119,22 +119,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -211,26 +195,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Kernel.Interactions. poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -268,8 +232,6 @@ public static Core.DTO.Kernel.Interactions.SuccessionFlow ToDto(this Core.POCO.K dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionFlowUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionFlowUsageExtensions.cs index fcfc8983..75f18fb6 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionFlowUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/SuccessionFlowUsageExtensions.cs @@ -101,8 +101,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); @@ -125,22 +123,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.PortionKind = dto.PortionKind; - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -217,26 +199,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Flows.Succes poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -270,15 +232,12 @@ public static Core.DTO.Systems.Flows.SuccessionFlowUsage ToDto(this Core.POCO.Sy dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; dto.PortionKind = poco.PortionKind; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/TerminateActionUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/TerminateActionUsageExtensions.cs index fd291db8..ca198ee0 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/TerminateActionUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/TerminateActionUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.TerminateActionUsage ToDto(this Core.POCO dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/TransitionFeatureMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/TransitionFeatureMembershipExtensions.cs index 806f1930..5927a7e2 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/TransitionFeatureMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/TransitionFeatureMembershipExtensions.cs @@ -81,10 +81,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.Kind = dto.Kind; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -103,22 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -159,15 +139,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.States.Trans Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -206,26 +177,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.States.Trans poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -249,15 +200,10 @@ public static Core.DTO.Systems.States.TransitionFeatureMembership ToDto(this Cor dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; dto.Kind = poco.Kind; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/TransitionUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/TransitionUsageExtensions.cs index 69602553..982d0863 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/TransitionUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/TransitionUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.States.TransitionUsage ToDto(this Core.POCO.Syste dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/TypeFeaturingExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/TypeFeaturingExtensions.cs index 1c9e6967..bac2b2b0 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/TypeFeaturingExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/TypeFeaturingExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -207,26 +191,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Features.TypeFe poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -255,8 +219,6 @@ public static Core.DTO.Core.Features.TypeFeaturing ToDto(this Core.POCO.Core.Fea dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); return dto; } diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/UnioningExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/UnioningExtensions.cs index f0086632..01957463 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/UnioningExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/UnioningExtensions.cs @@ -97,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - return identifiersOfObjectsToDelete; } @@ -189,26 +173,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Core.Types.Unioning poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - if (cache.TryGetValue(dto.UnioningType, out lazyPoco)) { poco.UnioningType = (Core.POCO.Core.Types.Type)lazyPoco.Value; @@ -244,8 +208,6 @@ public static Core.DTO.Core.Types.Unioning ToDto(this Core.POCO.Core.Types.Union dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.UnioningType = poco.UnioningType.Id; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/UsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/UsageExtensions.cs index 0ef21c57..70838a20 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/UsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/UsageExtensions.cs @@ -97,8 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -198,7 +196,6 @@ public static Core.DTO.Systems.DefinitionAndUsage.Usage ToDto(this Core.POCO.Sys dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/UseCaseUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/UseCaseUsageExtensions.cs index 0f9bab46..d5d8228c 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/UseCaseUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/UseCaseUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.UseCases.UseCaseUsage ToDto(this Core.POCO.System dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/VariantMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/VariantMembershipExtensions.cs index ec4c0ad0..17da3c31 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/VariantMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/VariantMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.DefinitionAn Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.DefinitionAn poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Systems.DefinitionAndUsage.VariantMembership ToDto(this C dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/VerificationCaseUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/VerificationCaseUsageExtensions.cs index 01aa5b22..77a61eaa 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/VerificationCaseUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/VerificationCaseUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.VerificationCases.VerificationCaseUsage ToDto(thi dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewRenderingMembershipExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewRenderingMembershipExtensions.cs index 3f12eca4..73beb8a6 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewRenderingMembershipExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewRenderingMembershipExtensions.cs @@ -79,10 +79,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsImpliedIncluded = dto.IsImpliedIncluded; - poco.MemberName = dto.MemberName; - - poco.MemberShortName = dto.MemberShortName; - var ownedRelatedElementToDelete = poco.OwnedRelatedElement.Select(x => x.Id).Except(dto.OwnedRelatedElement); foreach (var identifier in ownedRelatedElementToDelete) @@ -101,22 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t identifiersOfObjectsToDelete.AddRange(ownedRelationshipToDelete); - var sourceToDelete = poco.Source.Select(x => x.Id).Except(dto.Source); - - foreach (var identifier in sourceToDelete) - { - poco.Source.Remove(poco.Source.Single(x => x.Id == identifier)); - } - - - var targetToDelete = poco.Target.Select(x => x.Id).Except(dto.Target); - - foreach (var identifier in targetToDelete) - { - poco.Target.Remove(poco.Target.Single(x => x.Id == identifier)); - } - - poco.Visibility = dto.Visibility; @@ -157,15 +137,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Views.ViewRe Lazy lazyPoco; - if (cache.TryGetValue(dto.MemberElement, out lazyPoco)) - { - poco.MemberElement = (Core.POCO.Root.Elements.IElement)lazyPoco.Value; - } - else - { - poco.MemberElement = null; - } - var ownedRelatedElementToAdd = dto.OwnedRelatedElement.Except(poco.OwnedRelatedElement.Select(x => x.Id)); foreach (var identifier in ownedRelatedElementToAdd) @@ -204,26 +175,6 @@ public static void UpdateReferenceProperties(this Core.POCO.Systems.Views.ViewRe poco.OwningRelationship = null; } - var sourceToAdd = dto.Source.Except(poco.Source.Select(x => x.Id)); - - foreach (var identifier in sourceToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Source.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - - var targetToAdd = dto.Target.Except(poco.Target.Select(x => x.Id)); - - foreach (var identifier in targetToAdd) - { - if (cache.TryGetValue(identifier, out lazyPoco)) - { - poco.Target.Add((Core.POCO.Root.Elements.IElement)lazyPoco.Value); - } - } - } /// @@ -246,15 +197,10 @@ public static Core.DTO.Systems.Views.ViewRenderingMembership ToDto(this Core.POC dto.ElementId = poco.ElementId; dto.IsImplied = poco.IsImplied; dto.IsImpliedIncluded = poco.IsImpliedIncluded; - dto.MemberElement = poco.MemberElement.Id; - dto.MemberName = poco.MemberName; - dto.MemberShortName = poco.MemberShortName; dto.OwnedRelatedElement = poco.OwnedRelatedElement.Select(x => x.Id).ToList(); dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelatedElement = poco.OwningRelatedElement?.Id; dto.OwningRelationship = poco.OwningRelationship?.Id; - dto.Source = poco.Source.Select(x => x.Id).ToList(); - dto.Target = poco.Target.Select(x => x.Id).ToList(); dto.Visibility = poco.Visibility; return dto; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewUsageExtensions.cs index 6f34ee21..e4a03971 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Views.ViewUsage ToDto(this Core.POCO.Systems.View dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewpointDefinitionExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewpointDefinitionExtensions.cs index 724330ef..0755b14b 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewpointDefinitionExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewpointDefinitionExtensions.cs @@ -71,8 +71,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; - poco.ElementId = dto.ElementId; poco.IsAbstract = dto.IsAbstract; @@ -171,7 +169,6 @@ public static Core.DTO.Systems.Views.ViewpointDefinition ToDto(this Core.POCO.Sy dto.Id = poco.Id; dto.AliasIds = poco.AliasIds; dto.DeclaredName = poco.DeclaredName; - dto.DeclaredShortName = poco.DeclaredShortName; dto.ElementId = poco.ElementId; dto.IsAbstract = poco.IsAbstract; dto.IsImpliedIncluded = poco.IsImpliedIncluded; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewpointUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewpointUsageExtensions.cs index 451075d8..e88d0b5e 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewpointUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/ViewpointUsageExtensions.cs @@ -71,8 +71,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.DeclaredName = dto.DeclaredName; - poco.DeclaredShortName = dto.DeclaredShortName; - poco.Direction = dto.Direction; poco.ElementId = dto.ElementId; @@ -99,8 +97,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -191,7 +187,6 @@ public static Core.DTO.Systems.Views.ViewpointUsage ToDto(this Core.POCO.Systems dto.Id = poco.Id; dto.AliasIds = poco.AliasIds; dto.DeclaredName = poco.DeclaredName; - dto.DeclaredShortName = poco.DeclaredShortName; dto.Direction = poco.Direction; dto.ElementId = poco.ElementId; dto.IsAbstract = poco.IsAbstract; @@ -205,7 +200,6 @@ public static Core.DTO.Systems.Views.ViewpointUsage ToDto(this Core.POCO.Systems dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Dal/Core/AutoGenPocoExtension/WhileLoopActionUsageExtensions.cs b/SysML2.NET.Dal/Core/AutoGenPocoExtension/WhileLoopActionUsageExtensions.cs index 9e525d2e..06325d26 100644 --- a/SysML2.NET.Dal/Core/AutoGenPocoExtension/WhileLoopActionUsageExtensions.cs +++ b/SysML2.NET.Dal/Core/AutoGenPocoExtension/WhileLoopActionUsageExtensions.cs @@ -99,8 +99,6 @@ public static IEnumerable UpdateValueAndRemoveDeletedReferenceProperties(t poco.IsUnique = dto.IsUnique; - poco.IsVariable = dto.IsVariable; - poco.IsVariation = dto.IsVariation; var ownedRelationshipToDelete = poco.OwnedRelationship.Select(x => x.Id).Except(dto.OwnedRelationship); @@ -203,7 +201,6 @@ public static Core.DTO.Systems.Actions.WhileLoopActionUsage ToDto(this Core.POCO dto.IsPortion = poco.IsPortion; dto.IsSufficient = poco.IsSufficient; dto.IsUnique = poco.IsUnique; - dto.IsVariable = poco.IsVariable; dto.IsVariation = poco.IsVariation; dto.OwnedRelationship = poco.OwnedRelationship.Select(x => x.Id).ToList(); dto.OwningRelationship = poco.OwningRelationship?.Id; diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AcceptActionUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AcceptActionUsageDeSerializer.cs index 376f8e55..762bdce0 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AcceptActionUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AcceptActionUsageDeSerializer.cs @@ -122,26 +122,6 @@ internal static IAcceptActionUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the aliasIds Json property was not found in the AcceptActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the AcceptActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IAcceptActionUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the declaredShortName Json property was not found in the AcceptActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the AcceptActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +204,6 @@ internal static IAcceptActionUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the differencingType Json property was not found in the AcceptActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the AcceptActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -748,18 +688,6 @@ internal static IAcceptActionUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the isUnique Json property was not found in the AcceptActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the AcceptActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1397,26 +1325,6 @@ internal static IAcceptActionUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the nestedViewpoint Json property was not found in the AcceptActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the AcceptActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2241,26 +2149,6 @@ internal static IAcceptActionUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the textualRepresentation Json property was not found in the AcceptActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the AcceptActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ActionDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ActionDefinitionDeSerializer.cs index 159ff1ce..1d2e7d0c 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ActionDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ActionDefinitionDeSerializer.cs @@ -160,26 +160,6 @@ internal static IActionDefinition DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the differencingType Json property was not found in the ActionDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the ActionDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ActionUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ActionUsageDeSerializer.cs index f05cf524..1f2c09d2 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ActionUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ActionUsageDeSerializer.cs @@ -122,26 +122,6 @@ internal static IActionUsage DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the aliasIds Json property was not found in the ActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the ActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IActionUsage DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the declaredShortName Json property was not found in the ActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the ActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +204,6 @@ internal static IActionUsage DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the differencingType Json property was not found in the ActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the ActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -748,18 +688,6 @@ internal static IActionUsage DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the isUnique Json property was not found in the ActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the ActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1397,26 +1325,6 @@ internal static IActionUsage DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the nestedViewpoint Json property was not found in the ActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the ActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2168,26 +2076,6 @@ internal static IActionUsage DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the textualRepresentation Json property was not found in the ActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the ActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ActorMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ActorMembershipDeSerializer.cs index bce9d581..c385e48f 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ActorMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ActorMembershipDeSerializer.cs @@ -190,88 +190,6 @@ internal static IActorMembership DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the isLibraryElement Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the ActorMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the ActorMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -346,31 +264,6 @@ internal static IActorMembership DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the ownedElement Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the ActorMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -385,31 +278,6 @@ internal static IActorMembership DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the ownedMemberElementId Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the ActorMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -419,31 +287,6 @@ internal static IActorMembership DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the ownedMemberName Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberParameter"u8, out var ownedMemberParameterProperty)) - { - if (ownedMemberParameterProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberParameter = Guid.Empty; - logger.LogDebug($"the ActorMembership.ownedMemberParameter property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberParameterProperty.TryGetProperty("@id"u8, out var ownedMemberParameterExternalIdProperty)) - { - var propertyValue = ownedMemberParameterExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberParameter = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberParameter Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberShortName"u8, out var ownedMemberShortNameProperty)) { dtoInstance.ownedMemberShortName = ownedMemberShortNameProperty.GetString(); @@ -676,46 +519,6 @@ internal static IActorMembership DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the shortName Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the ActorMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AllocationDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AllocationDefinitionDeSerializer.cs index 55a60e84..b39600cc 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AllocationDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AllocationDefinitionDeSerializer.cs @@ -122,26 +122,6 @@ internal static IAllocationDefinition DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the allocation Json property was not found in the AllocationDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("associationEnd"u8, out var associationEndProperty)) - { - foreach (var arrayItem in associationEndProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var associationEndExternalIdProperty)) - { - var propertyValue = associationEndExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.associationEnd.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the associationEnd Json property was not found in the AllocationDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("connectionEnd"u8, out var connectionEndProperty)) { foreach (var arrayItem in connectionEndProperty.EnumerateArray()) @@ -274,26 +254,6 @@ internal static IAllocationDefinition DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the elementId Json property was not found in the AllocationDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the AllocationDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("feature"u8, out var featureProperty)) { foreach (var arrayItem in featureProperty.EnumerateArray()) @@ -1636,26 +1596,6 @@ internal static IAllocationDefinition DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the qualifiedName Json property was not found in the AllocationDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the AllocationDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedType"u8, out var relatedTypeProperty)) { foreach (var arrayItem in relatedTypeProperty.EnumerateArray()) @@ -1685,26 +1625,6 @@ internal static IAllocationDefinition DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the shortName Json property was not found in the AllocationDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the AllocationDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceType"u8, out var sourceTypeProperty)) { if (sourceTypeProperty.ValueKind == JsonValueKind.Null) @@ -1729,26 +1649,6 @@ internal static IAllocationDefinition DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the sourceType Json property was not found in the AllocationDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the AllocationDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetType"u8, out var targetTypeProperty)) { foreach (var arrayItem in targetTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AllocationUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AllocationUsageDeSerializer.cs index 3b5f1918..d019efd1 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AllocationUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AllocationUsageDeSerializer.cs @@ -122,26 +122,6 @@ internal static IAllocationUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the allocationDefinition Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("association"u8, out var associationProperty)) - { - foreach (var arrayItem in associationProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var associationExternalIdProperty)) - { - var propertyValue = associationExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.association.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the association Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -162,26 +142,6 @@ internal static IAllocationUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the chainingFeature Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("connectionDefinition"u8, out var connectionDefinitionProperty)) - { - foreach (var arrayItem in connectionDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var connectionDefinitionExternalIdProperty)) - { - var propertyValue = connectionDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.connectionDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the connectionDefinition Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("connectorEnd"u8, out var connectorEndProperty)) { foreach (var arrayItem in connectorEndProperty.EnumerateArray()) @@ -268,26 +228,6 @@ internal static IAllocationUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the defaultFeaturingType Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -391,26 +331,6 @@ internal static IAllocationUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the elementId Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -824,18 +744,6 @@ internal static IAllocationUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the isUnique Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2279,26 +2187,6 @@ internal static IAllocationUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the qualifiedName Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -2328,26 +2216,6 @@ internal static IAllocationUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the shortName Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -2372,26 +2240,6 @@ internal static IAllocationUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the sourceFeature Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -2432,26 +2280,6 @@ internal static IAllocationUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the textualRepresentation Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the AllocationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AnalysisCaseDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AnalysisCaseDefinitionDeSerializer.cs index b20a39f4..b7515a99 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AnalysisCaseDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AnalysisCaseDefinitionDeSerializer.cs @@ -200,26 +200,6 @@ internal static IAnalysisCaseDefinition DeSerialize(JsonElement jsonElement, Ser logger.LogDebug("the differencingType Json property was not found in the AnalysisCaseDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the AnalysisCaseDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AnalysisCaseUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AnalysisCaseUsageDeSerializer.cs index c8348026..df3ce09f 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AnalysisCaseUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AnalysisCaseUsageDeSerializer.cs @@ -85,26 +85,6 @@ internal static IAnalysisCaseUsage DeSerialize(JsonElement jsonElement, Serializ } } - if (jsonElement.TryGetProperty("actionDefinition"u8, out var actionDefinitionProperty)) - { - foreach (var arrayItem in actionDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var actionDefinitionExternalIdProperty)) - { - var propertyValue = actionDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.actionDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the actionDefinition Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("actorParameter"u8, out var actorParameterProperty)) { foreach (var arrayItem in actorParameterProperty.EnumerateArray()) @@ -166,74 +146,6 @@ internal static IAnalysisCaseUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the analysisCaseDefinition Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("calculationDefinition"u8, out var calculationDefinitionProperty)) - { - if (calculationDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.calculationDefinition = null; - } - else - { - if (calculationDefinitionProperty.TryGetProperty("@id"u8, out var calculationDefinitionExternalIdProperty)) - { - var propertyValue = calculationDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.calculationDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the calculationDefinition Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("caseDefinition"u8, out var caseDefinitionProperty)) - { - if (caseDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.caseDefinition = null; - } - else - { - if (caseDefinitionProperty.TryGetProperty("@id"u8, out var caseDefinitionExternalIdProperty)) - { - var propertyValue = caseDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.caseDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the caseDefinition Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -296,26 +208,6 @@ internal static IAnalysisCaseUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the declaredShortName Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -336,26 +228,6 @@ internal static IAnalysisCaseUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the differencingType Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -548,30 +420,6 @@ internal static IAnalysisCaseUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the featuringType Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -876,18 +724,6 @@ internal static IAnalysisCaseUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the isUnique Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1549,26 +1385,6 @@ internal static IAnalysisCaseUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the objectiveRequirement Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2394,26 +2210,6 @@ internal static IAnalysisCaseUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the textualRepresentation Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the AnalysisCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AnnotationDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AnnotationDeSerializer.cs index 62a55c04..ad732032 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AnnotationDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AnnotationDeSerializer.cs @@ -559,46 +559,6 @@ internal static IAnnotation DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the shortName Json property was not found in the Annotation: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Annotation: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Annotation: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssertConstraintUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssertConstraintUsageDeSerializer.cs index 47adf6f1..bfc01ecb 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssertConstraintUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssertConstraintUsageDeSerializer.cs @@ -127,26 +127,6 @@ internal static IAssertConstraintUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the assertedConstraint Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -233,26 +213,6 @@ internal static IAssertConstraintUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the declaredShortName Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -273,26 +233,6 @@ internal static IAssertConstraintUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the differencingType Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -485,30 +425,6 @@ internal static IAssertConstraintUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the featuringType Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -825,18 +741,6 @@ internal static IAssertConstraintUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the isUnique Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2207,30 +2111,6 @@ internal static IAssertConstraintUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the portionKind Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("predicate"u8, out var predicateProperty)) - { - if (predicateProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.predicate = null; - } - else - { - if (predicateProperty.TryGetProperty("@id"u8, out var predicateExternalIdProperty)) - { - var propertyValue = predicateExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.predicate = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the predicate Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -2294,26 +2174,6 @@ internal static IAssertConstraintUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the textualRepresentation Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the AssertConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssignmentActionUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssignmentActionUsageDeSerializer.cs index b8a2848a..03b56d19 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssignmentActionUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssignmentActionUsageDeSerializer.cs @@ -122,26 +122,6 @@ internal static IAssignmentActionUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the aliasIds Json property was not found in the AssignmentActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the AssignmentActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IAssignmentActionUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the declaredShortName Json property was not found in the AssignmentActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the AssignmentActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +204,6 @@ internal static IAssignmentActionUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the differencingType Json property was not found in the AssignmentActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the AssignmentActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -748,18 +688,6 @@ internal static IAssignmentActionUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the isUnique Json property was not found in the AssignmentActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the AssignmentActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1397,26 +1325,6 @@ internal static IAssignmentActionUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the nestedViewpoint Json property was not found in the AssignmentActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the AssignmentActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2217,26 +2125,6 @@ internal static IAssignmentActionUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the textualRepresentation Json property was not found in the AssignmentActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the AssignmentActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssociationDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssociationDeSerializer.cs index c58bfc55..b52440a7 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssociationDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssociationDeSerializer.cs @@ -214,26 +214,6 @@ internal static IAssociation DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the elementId Json property was not found in the Association: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the Association: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("feature"u8, out var featureProperty)) { foreach (var arrayItem in featureProperty.EnumerateArray()) @@ -1012,26 +992,6 @@ internal static IAssociation DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the qualifiedName Json property was not found in the Association: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the Association: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedType"u8, out var relatedTypeProperty)) { foreach (var arrayItem in relatedTypeProperty.EnumerateArray()) @@ -1061,26 +1021,6 @@ internal static IAssociation DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the shortName Json property was not found in the Association: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Association: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceType"u8, out var sourceTypeProperty)) { if (sourceTypeProperty.ValueKind == JsonValueKind.Null) @@ -1105,26 +1045,6 @@ internal static IAssociation DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the sourceType Json property was not found in the Association: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Association: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetType"u8, out var targetTypeProperty)) { foreach (var arrayItem in targetTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssociationStructureDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssociationStructureDeSerializer.cs index 3cacc360..8e1c40c0 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssociationStructureDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AssociationStructureDeSerializer.cs @@ -214,26 +214,6 @@ internal static IAssociationStructure DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the elementId Json property was not found in the AssociationStructure: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the AssociationStructure: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("feature"u8, out var featureProperty)) { foreach (var arrayItem in featureProperty.EnumerateArray()) @@ -1012,26 +992,6 @@ internal static IAssociationStructure DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the qualifiedName Json property was not found in the AssociationStructure: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the AssociationStructure: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedType"u8, out var relatedTypeProperty)) { foreach (var arrayItem in relatedTypeProperty.EnumerateArray()) @@ -1061,26 +1021,6 @@ internal static IAssociationStructure DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the shortName Json property was not found in the AssociationStructure: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the AssociationStructure: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceType"u8, out var sourceTypeProperty)) { if (sourceTypeProperty.ValueKind == JsonValueKind.Null) @@ -1105,26 +1045,6 @@ internal static IAssociationStructure DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the sourceType Json property was not found in the AssociationStructure: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the AssociationStructure: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetType"u8, out var targetTypeProperty)) { foreach (var arrayItem in targetTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AttributeUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AttributeUsageDeSerializer.cs index 50c43d6e..0e56bc6c 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AttributeUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/AttributeUsageDeSerializer.cs @@ -184,26 +184,6 @@ internal static IAttributeUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the declaredShortName Json property was not found in the AttributeUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the AttributeUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -692,18 +672,6 @@ internal static IAttributeUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the isUnique Json property was not found in the AttributeUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the AttributeUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2063,26 +2031,6 @@ internal static IAttributeUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the textualRepresentation Json property was not found in the AttributeUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the AttributeUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BehaviorDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BehaviorDeSerializer.cs index 78a35389..5db87685 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BehaviorDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BehaviorDeSerializer.cs @@ -140,26 +140,6 @@ internal static IBehavior DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the differencingType Json property was not found in the Behavior: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the Behavior: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("documentation"u8, out var documentationProperty)) { foreach (var arrayItem in documentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BindingConnectorAsUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BindingConnectorAsUsageDeSerializer.cs index 9f883a3b..3811d985 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BindingConnectorAsUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BindingConnectorAsUsageDeSerializer.cs @@ -351,26 +351,6 @@ internal static IBindingConnectorAsUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the elementId Json property was not found in the BindingConnectorAsUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the BindingConnectorAsUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -748,18 +728,6 @@ internal static IBindingConnectorAsUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the isUnique Json property was not found in the BindingConnectorAsUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the BindingConnectorAsUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2134,26 +2102,6 @@ internal static IBindingConnectorAsUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the qualifiedName Json property was not found in the BindingConnectorAsUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the BindingConnectorAsUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -2183,26 +2131,6 @@ internal static IBindingConnectorAsUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the shortName Json property was not found in the BindingConnectorAsUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the BindingConnectorAsUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -2227,26 +2155,6 @@ internal static IBindingConnectorAsUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the sourceFeature Json property was not found in the BindingConnectorAsUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the BindingConnectorAsUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -2287,26 +2195,6 @@ internal static IBindingConnectorAsUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the textualRepresentation Json property was not found in the BindingConnectorAsUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the BindingConnectorAsUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BindingConnectorDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BindingConnectorDeSerializer.cs index 873080fc..a498bd3a 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BindingConnectorDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BindingConnectorDeSerializer.cs @@ -311,26 +311,6 @@ internal static IBindingConnector DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the elementId Json property was not found in the BindingConnector: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the BindingConnector: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -1470,26 +1450,6 @@ internal static IBindingConnector DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the qualifiedName Json property was not found in the BindingConnector: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the BindingConnector: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -1519,26 +1479,6 @@ internal static IBindingConnector DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the shortName Json property was not found in the BindingConnector: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the BindingConnector: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -1563,26 +1503,6 @@ internal static IBindingConnector DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the sourceFeature Json property was not found in the BindingConnector: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the BindingConnector: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -1623,26 +1543,6 @@ internal static IBindingConnector DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the textualRepresentation Json property was not found in the BindingConnector: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the BindingConnector: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BooleanExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BooleanExpressionDeSerializer.cs index 781633af..1602d18c 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BooleanExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/BooleanExpressionDeSerializer.cs @@ -102,26 +102,6 @@ internal static IBooleanExpression DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the aliasIds Json property was not found in the BooleanExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the BooleanExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IBooleanExpression DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the differencingType Json property was not found in the BooleanExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the BooleanExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); @@ -396,30 +356,6 @@ internal static IBooleanExpression DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the featuringType Json property was not found in the BooleanExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the BooleanExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CalculationDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CalculationDefinitionDeSerializer.cs index b0dc8628..dab0c3c6 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CalculationDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CalculationDefinitionDeSerializer.cs @@ -180,26 +180,6 @@ internal static ICalculationDefinition DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the differencingType Json property was not found in the CalculationDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the CalculationDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CalculationUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CalculationUsageDeSerializer.cs index 15f281a9..57ce28e3 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CalculationUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CalculationUsageDeSerializer.cs @@ -85,26 +85,6 @@ internal static ICalculationUsage DeSerialize(JsonElement jsonElement, Serializa } } - if (jsonElement.TryGetProperty("actionDefinition"u8, out var actionDefinitionProperty)) - { - foreach (var arrayItem in actionDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var actionDefinitionExternalIdProperty)) - { - var propertyValue = actionDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.actionDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the actionDefinition Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("aliasIds"u8, out var aliasIdsProperty)) { foreach (var arrayItem in aliasIdsProperty.EnumerateArray()) @@ -122,26 +102,6 @@ internal static ICalculationUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the aliasIds Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("calculationDefinition"u8, out var calculationDefinitionProperty)) { if (calculationDefinitionProperty.ValueKind == JsonValueKind.Null) @@ -228,26 +188,6 @@ internal static ICalculationUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the declaredShortName Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -268,26 +208,6 @@ internal static ICalculationUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the differencingType Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -480,30 +400,6 @@ internal static ICalculationUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the featuringType Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -808,18 +704,6 @@ internal static ICalculationUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the isUnique Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1457,26 +1341,6 @@ internal static ICalculationUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the nestedViewpoint Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2253,26 +2117,6 @@ internal static ICalculationUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the textualRepresentation Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the CalculationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CaseDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CaseDefinitionDeSerializer.cs index 8982f9ec..416380db 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CaseDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CaseDefinitionDeSerializer.cs @@ -200,26 +200,6 @@ internal static ICaseDefinition DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the differencingType Json property was not found in the CaseDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the CaseDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CaseUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CaseUsageDeSerializer.cs index e1b553fb..08487765 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CaseUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CaseUsageDeSerializer.cs @@ -85,26 +85,6 @@ internal static ICaseUsage DeSerialize(JsonElement jsonElement, SerializationMod } } - if (jsonElement.TryGetProperty("actionDefinition"u8, out var actionDefinitionProperty)) - { - foreach (var arrayItem in actionDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var actionDefinitionExternalIdProperty)) - { - var propertyValue = actionDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.actionDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the actionDefinition Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("actorParameter"u8, out var actorParameterProperty)) { foreach (var arrayItem in actorParameterProperty.EnumerateArray()) @@ -142,50 +122,6 @@ internal static ICaseUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the aliasIds Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("calculationDefinition"u8, out var calculationDefinitionProperty)) - { - if (calculationDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.calculationDefinition = null; - } - else - { - if (calculationDefinitionProperty.TryGetProperty("@id"u8, out var calculationDefinitionExternalIdProperty)) - { - var propertyValue = calculationDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.calculationDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the calculationDefinition Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("caseDefinition"u8, out var caseDefinitionProperty)) { if (caseDefinitionProperty.ValueKind == JsonValueKind.Null) @@ -272,26 +208,6 @@ internal static ICaseUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the declaredShortName Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -312,26 +228,6 @@ internal static ICaseUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the differencingType Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -524,30 +420,6 @@ internal static ICaseUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the featuringType Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -852,18 +724,6 @@ internal static ICaseUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the isUnique Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1525,26 +1385,6 @@ internal static ICaseUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the objectiveRequirement Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2346,26 +2186,6 @@ internal static ICaseUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the textualRepresentation Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the CaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CollectExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CollectExpressionDeSerializer.cs index 14dea642..47ae1d67 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CollectExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CollectExpressionDeSerializer.cs @@ -122,26 +122,6 @@ internal static ICollectExpression DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the argument Json property was not found in the CollectExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the CollectExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -224,26 +204,6 @@ internal static ICollectExpression DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the differencingType Json property was not found in the CollectExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the CollectExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConcernDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConcernDefinitionDeSerializer.cs index ace54bac..2ee8ad75 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConcernDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConcernDefinitionDeSerializer.cs @@ -151,15 +151,6 @@ internal static IConcernDefinition DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the declaredName Json property was not found in the ConcernDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("declaredShortName"u8, out var declaredShortNameProperty)) - { - dtoInstance.DeclaredShortName = declaredShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the declaredShortName Json property was not found in the ConcernDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -180,26 +171,6 @@ internal static IConcernDefinition DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the differencingType Json property was not found in the ConcernDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the ConcernDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConcernUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConcernUsageDeSerializer.cs index fc2630a1..e8a9e3c5 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConcernUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConcernUsageDeSerializer.cs @@ -142,26 +142,6 @@ internal static IConcernUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the assumedConstraint Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -206,30 +186,6 @@ internal static IConcernUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the concernDefinition Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("constraintDefinition"u8, out var constraintDefinitionProperty)) - { - if (constraintDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.constraintDefinition = null; - } - else - { - if (constraintDefinitionProperty.TryGetProperty("@id"u8, out var constraintDefinitionExternalIdProperty)) - { - var propertyValue = constraintDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.constraintDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the constraintDefinition Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("crossFeature"u8, out var crossFeatureProperty)) { if (crossFeatureProperty.ValueKind == JsonValueKind.Null) @@ -263,35 +219,6 @@ internal static IConcernUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the declaredName Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("declaredShortName"u8, out var declaredShortNameProperty)) - { - dtoInstance.DeclaredShortName = declaredShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the declaredShortName Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -312,26 +239,6 @@ internal static IConcernUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the differencingType Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -544,30 +451,6 @@ internal static IConcernUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the framedConcern Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -872,18 +755,6 @@ internal static IConcernUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the isUnique Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2254,30 +2125,6 @@ internal static IConcernUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the portionKind Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("predicate"u8, out var predicateProperty)) - { - if (predicateProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.predicate = null; - } - else - { - if (predicateProperty.TryGetProperty("@id"u8, out var predicateExternalIdProperty)) - { - var propertyValue = predicateExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.predicate = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the predicate Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -2316,30 +2163,6 @@ internal static IConcernUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the requiredConstraint Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("requirementDefinition"u8, out var requirementDefinitionProperty)) - { - if (requirementDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.requirementDefinition = null; - } - else - { - if (requirementDefinitionProperty.TryGetProperty("@id"u8, out var requirementDefinitionExternalIdProperty)) - { - var propertyValue = requirementDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.requirementDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the requirementDefinition Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("result"u8, out var resultProperty)) { if (resultProperty.ValueKind == JsonValueKind.Null) @@ -2456,26 +2279,6 @@ internal static IConcernUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the textualRepresentation Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the ConcernUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConjugatedPortDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConjugatedPortDefinitionDeSerializer.cs index fb3cacf0..7a3aa968 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConjugatedPortDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConjugatedPortDefinitionDeSerializer.cs @@ -760,30 +760,6 @@ internal static IConjugatedPortDefinition DeSerialize(JsonElement jsonElement, S logger.LogDebug("the ownedConcern Json property was not found in the ConjugatedPortDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedConjugator"u8, out var ownedConjugatorProperty)) - { - if (ownedConjugatorProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedConjugator = null; - } - else - { - if (ownedConjugatorProperty.TryGetProperty("@id"u8, out var ownedConjugatorExternalIdProperty)) - { - var propertyValue = ownedConjugatorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedConjugator = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedConjugator Json property was not found in the ConjugatedPortDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedConnection"u8, out var ownedConnectionProperty)) { foreach (var arrayItem in ownedConnectionProperty.EnumerateArray()) @@ -1537,30 +1513,6 @@ internal static IConjugatedPortDefinition DeSerialize(JsonElement jsonElement, S logger.LogDebug("the owningMembership Json property was not found in the ConjugatedPortDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningNamespace"u8, out var owningNamespaceProperty)) - { - if (owningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningNamespace = null; - } - else - { - if (owningNamespaceProperty.TryGetProperty("@id"u8, out var owningNamespaceExternalIdProperty)) - { - var propertyValue = owningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningNamespace Json property was not found in the ConjugatedPortDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("owningRelationship"u8, out var owningRelationshipProperty)) { if (owningRelationshipProperty.ValueKind == JsonValueKind.Null) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConjugatedPortTypingDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConjugatedPortTypingDeSerializer.cs index c1a42249..6ddcf4d6 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConjugatedPortTypingDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConjugatedPortTypingDeSerializer.cs @@ -179,31 +179,6 @@ internal static IConjugatedPortTyping DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the elementId Json property was not found in the ConjugatedPortTyping: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("general"u8, out var generalProperty)) - { - if (generalProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.General = Guid.Empty; - logger.LogDebug($"the ConjugatedPortTyping.General property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (generalProperty.TryGetProperty("@id"u8, out var generalExternalIdProperty)) - { - var propertyValue = generalExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.General = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the general Json property was not found in the ConjugatedPortTyping: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isImplied"u8, out var isImpliedProperty)) { if (isImpliedProperty.ValueKind != JsonValueKind.Null) @@ -473,30 +448,6 @@ internal static IConjugatedPortTyping DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the owningRelationship Json property was not found in the ConjugatedPortTyping: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningType"u8, out var owningTypeProperty)) - { - if (owningTypeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningType = null; - } - else - { - if (owningTypeProperty.TryGetProperty("@id"u8, out var owningTypeExternalIdProperty)) - { - var propertyValue = owningTypeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningType = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningType Json property was not found in the ConjugatedPortTyping: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("portDefinition"u8, out var portDefinitionProperty)) { if (portDefinitionProperty.ValueKind == JsonValueKind.Null) @@ -560,71 +511,6 @@ internal static IConjugatedPortTyping DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the shortName Json property was not found in the ConjugatedPortTyping: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the ConjugatedPortTyping: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("specific"u8, out var specificProperty)) - { - if (specificProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.Specific = Guid.Empty; - logger.LogDebug($"the ConjugatedPortTyping.Specific property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (specificProperty.TryGetProperty("@id"u8, out var specificExternalIdProperty)) - { - var propertyValue = specificExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Specific = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the specific Json property was not found in the ConjugatedPortTyping: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the ConjugatedPortTyping: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) @@ -645,31 +531,6 @@ internal static IConjugatedPortTyping DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the textualRepresentation Json property was not found in the ConjugatedPortTyping: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - if (typeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.Type = Guid.Empty; - logger.LogDebug($"the ConjugatedPortTyping.Type property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (typeProperty.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Type = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the ConjugatedPortTyping: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("typedFeature"u8, out var typedFeatureProperty)) { if (typedFeatureProperty.ValueKind == JsonValueKind.Null) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConjugationDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConjugationDeSerializer.cs index 6a50baaf..8c67f66e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConjugationDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConjugationDeSerializer.cs @@ -511,46 +511,6 @@ internal static IConjugation DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the shortName Json property was not found in the Conjugation: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Conjugation: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Conjugation: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConnectionDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConnectionDefinitionDeSerializer.cs index 987dc335..81a9b347 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConnectionDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConnectionDefinitionDeSerializer.cs @@ -102,26 +102,6 @@ internal static IConnectionDefinition DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the aliasIds Json property was not found in the ConnectionDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("associationEnd"u8, out var associationEndProperty)) - { - foreach (var arrayItem in associationEndProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var associationEndExternalIdProperty)) - { - var propertyValue = associationEndExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.associationEnd.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the associationEnd Json property was not found in the ConnectionDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("connectionEnd"u8, out var connectionEndProperty)) { foreach (var arrayItem in connectionEndProperty.EnumerateArray()) @@ -254,26 +234,6 @@ internal static IConnectionDefinition DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the elementId Json property was not found in the ConnectionDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the ConnectionDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("feature"u8, out var featureProperty)) { foreach (var arrayItem in featureProperty.EnumerateArray()) @@ -1616,26 +1576,6 @@ internal static IConnectionDefinition DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the qualifiedName Json property was not found in the ConnectionDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the ConnectionDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedType"u8, out var relatedTypeProperty)) { foreach (var arrayItem in relatedTypeProperty.EnumerateArray()) @@ -1665,26 +1605,6 @@ internal static IConnectionDefinition DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the shortName Json property was not found in the ConnectionDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the ConnectionDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceType"u8, out var sourceTypeProperty)) { if (sourceTypeProperty.ValueKind == JsonValueKind.Null) @@ -1709,26 +1629,6 @@ internal static IConnectionDefinition DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the sourceType Json property was not found in the ConnectionDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the ConnectionDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetType"u8, out var targetTypeProperty)) { foreach (var arrayItem in targetTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConnectionUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConnectionUsageDeSerializer.cs index 7f01feb1..bc1601c8 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConnectionUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConnectionUsageDeSerializer.cs @@ -102,26 +102,6 @@ internal static IConnectionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the aliasIds Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("association"u8, out var associationProperty)) - { - foreach (var arrayItem in associationProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var associationExternalIdProperty)) - { - var propertyValue = associationExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.association.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the association Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -248,26 +228,6 @@ internal static IConnectionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the defaultFeaturingType Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -371,26 +331,6 @@ internal static IConnectionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the elementId Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -804,18 +744,6 @@ internal static IConnectionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the isUnique Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2259,26 +2187,6 @@ internal static IConnectionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the qualifiedName Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -2308,26 +2216,6 @@ internal static IConnectionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the shortName Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -2352,26 +2240,6 @@ internal static IConnectionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the sourceFeature Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -2412,26 +2280,6 @@ internal static IConnectionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the textualRepresentation Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the ConnectionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConnectorDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConnectorDeSerializer.cs index 7804189e..9972c691 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConnectorDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConnectorDeSerializer.cs @@ -311,26 +311,6 @@ internal static IConnector DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the elementId Json property was not found in the Connector: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the Connector: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -1470,26 +1450,6 @@ internal static IConnector DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the qualifiedName Json property was not found in the Connector: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the Connector: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -1519,26 +1479,6 @@ internal static IConnector DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the shortName Json property was not found in the Connector: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Connector: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -1563,26 +1503,6 @@ internal static IConnector DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the sourceFeature Json property was not found in the Connector: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Connector: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -1623,26 +1543,6 @@ internal static IConnector DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the textualRepresentation Json property was not found in the Connector: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the Connector: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConstraintDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConstraintDefinitionDeSerializer.cs index 41e4ed89..f15cd625 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConstraintDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConstraintDefinitionDeSerializer.cs @@ -140,26 +140,6 @@ internal static IConstraintDefinition DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the differencingType Json property was not found in the ConstraintDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the ConstraintDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConstraintUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConstraintUsageDeSerializer.cs index 057588a2..139fe675 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConstraintUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConstraintUsageDeSerializer.cs @@ -102,26 +102,6 @@ internal static IConstraintUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the aliasIds Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -208,26 +188,6 @@ internal static IConstraintUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the declaredShortName Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -248,26 +208,6 @@ internal static IConstraintUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the differencingType Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -460,30 +400,6 @@ internal static IConstraintUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the featuringType Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -788,18 +704,6 @@ internal static IConstraintUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the isUnique Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2170,30 +2074,6 @@ internal static IConstraintUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the portionKind Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("predicate"u8, out var predicateProperty)) - { - if (predicateProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.predicate = null; - } - else - { - if (predicateProperty.TryGetProperty("@id"u8, out var predicateExternalIdProperty)) - { - var propertyValue = predicateExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.predicate = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the predicate Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -2257,26 +2137,6 @@ internal static IConstraintUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the textualRepresentation Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the ConstraintUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConstructorExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConstructorExpressionDeSerializer.cs index 026c328f..5175885d 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConstructorExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ConstructorExpressionDeSerializer.cs @@ -122,26 +122,6 @@ internal static IConstructorExpression DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the argument Json property was not found in the ConstructorExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the ConstructorExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -224,26 +204,6 @@ internal static IConstructorExpression DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the differencingType Json property was not found in the ConstructorExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the ConstructorExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CrossSubsettingDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CrossSubsettingDeSerializer.cs index 34fd09f6..31358403 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CrossSubsettingDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/CrossSubsettingDeSerializer.cs @@ -204,31 +204,6 @@ internal static ICrossSubsetting DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the elementId Json property was not found in the CrossSubsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("general"u8, out var generalProperty)) - { - if (generalProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.General = Guid.Empty; - logger.LogDebug($"the CrossSubsetting.General property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (generalProperty.TryGetProperty("@id"u8, out var generalExternalIdProperty)) - { - var propertyValue = generalExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.General = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the general Json property was not found in the CrossSubsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isImplied"u8, out var isImpliedProperty)) { if (isImpliedProperty.ValueKind != JsonValueKind.Null) @@ -378,30 +353,6 @@ internal static ICrossSubsetting DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the owner Json property was not found in the CrossSubsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningFeature"u8, out var owningFeatureProperty)) - { - if (owningFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningFeature = null; - } - else - { - if (owningFeatureProperty.TryGetProperty("@id"u8, out var owningFeatureExternalIdProperty)) - { - var propertyValue = owningFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningFeature Json property was not found in the CrossSubsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("owningMembership"u8, out var owningMembershipProperty)) { if (owningMembershipProperty.ValueKind == JsonValueKind.Null) @@ -498,30 +449,6 @@ internal static ICrossSubsetting DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the owningRelationship Json property was not found in the CrossSubsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningType"u8, out var owningTypeProperty)) - { - if (owningTypeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningType = null; - } - else - { - if (owningTypeProperty.TryGetProperty("@id"u8, out var owningTypeExternalIdProperty)) - { - var propertyValue = owningTypeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningType = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningType Json property was not found in the CrossSubsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -560,121 +487,6 @@ internal static ICrossSubsetting DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the shortName Json property was not found in the CrossSubsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the CrossSubsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("specific"u8, out var specificProperty)) - { - if (specificProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.Specific = Guid.Empty; - logger.LogDebug($"the CrossSubsetting.Specific property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (specificProperty.TryGetProperty("@id"u8, out var specificExternalIdProperty)) - { - var propertyValue = specificExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Specific = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the specific Json property was not found in the CrossSubsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("subsettedFeature"u8, out var subsettedFeatureProperty)) - { - if (subsettedFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.SubsettedFeature = Guid.Empty; - logger.LogDebug($"the CrossSubsetting.SubsettedFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (subsettedFeatureProperty.TryGetProperty("@id"u8, out var subsettedFeatureExternalIdProperty)) - { - var propertyValue = subsettedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.SubsettedFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the subsettedFeature Json property was not found in the CrossSubsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("subsettingFeature"u8, out var subsettingFeatureProperty)) - { - if (subsettingFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.SubsettingFeature = Guid.Empty; - logger.LogDebug($"the CrossSubsetting.SubsettingFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (subsettingFeatureProperty.TryGetProperty("@id"u8, out var subsettingFeatureExternalIdProperty)) - { - var propertyValue = subsettingFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.SubsettingFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the subsettingFeature Json property was not found in the CrossSubsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the CrossSubsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DecisionNodeDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DecisionNodeDeSerializer.cs index ec1839e2..7c0ce12d 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DecisionNodeDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DecisionNodeDeSerializer.cs @@ -122,26 +122,6 @@ internal static IDecisionNode DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the aliasIds Json property was not found in the DecisionNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the DecisionNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IDecisionNode DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the declaredShortName Json property was not found in the DecisionNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the DecisionNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +204,6 @@ internal static IDecisionNode DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the differencingType Json property was not found in the DecisionNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the DecisionNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -748,18 +688,6 @@ internal static IDecisionNode DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the isUnique Json property was not found in the DecisionNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the DecisionNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1397,26 +1325,6 @@ internal static IDecisionNode DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the nestedViewpoint Json property was not found in the DecisionNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the DecisionNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2168,26 +2076,6 @@ internal static IDecisionNode DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the textualRepresentation Json property was not found in the DecisionNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the DecisionNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DependencyDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DependencyDeSerializer.cs index 2aca80a1..2b067afa 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DependencyDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DependencyDeSerializer.cs @@ -457,26 +457,6 @@ internal static IDependency DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the shortName Json property was not found in the Dependency: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Dependency: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("supplier"u8, out var supplierProperty)) { foreach (var arrayItem in supplierProperty.EnumerateArray()) @@ -497,26 +477,6 @@ internal static IDependency DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the supplier Json property was not found in the Dependency: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Dependency: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DifferencingDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DifferencingDeSerializer.cs index 10821b97..a68ae10b 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DifferencingDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DifferencingDeSerializer.cs @@ -462,46 +462,6 @@ internal static IDifferencing DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the shortName Json property was not found in the Differencing: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Differencing: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Differencing: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DisjoiningDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DisjoiningDeSerializer.cs index 8d81e238..52ac9195 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DisjoiningDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DisjoiningDeSerializer.cs @@ -486,46 +486,6 @@ internal static IDisjoining DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the shortName Json property was not found in the Disjoining: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Disjoining: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Disjoining: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DocumentationDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DocumentationDeSerializer.cs index 7d79f648..ef2474fb 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DocumentationDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/DocumentationDeSerializer.cs @@ -102,26 +102,6 @@ internal static IDocumentation DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the aliasIds Json property was not found in the Documentation: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("annotatedElement"u8, out var annotatedElementProperty)) - { - foreach (var arrayItem in annotatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var annotatedElementExternalIdProperty)) - { - var propertyValue = annotatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.annotatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the annotatedElement Json property was not found in the Documentation: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("annotation"u8, out var annotationProperty)) { foreach (var arrayItem in annotationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ElementFilterMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ElementFilterMembershipDeSerializer.cs index c26a749c..03238716 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ElementFilterMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ElementFilterMembershipDeSerializer.cs @@ -215,54 +215,6 @@ internal static IElementFilterMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the isLibraryElement Json property was not found in the ElementFilterMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the ElementFilterMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the ElementFilterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the ElementFilterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the ElementFilterMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) { if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) @@ -288,15 +240,6 @@ internal static IElementFilterMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the membershipOwningNamespace Json property was not found in the ElementFilterMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the ElementFilterMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -346,31 +289,6 @@ internal static IElementFilterMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the ownedElement Json property was not found in the ElementFilterMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the ElementFilterMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the ElementFilterMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -601,46 +519,6 @@ internal static IElementFilterMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the shortName Json property was not found in the ElementFilterMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the ElementFilterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the ElementFilterMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EndFeatureMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EndFeatureMembershipDeSerializer.cs index ce3ecb6a..253686a4 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EndFeatureMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EndFeatureMembershipDeSerializer.cs @@ -190,88 +190,6 @@ internal static IEndFeatureMembership DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the isLibraryElement Json property was not found in the EndFeatureMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the EndFeatureMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the EndFeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the EndFeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the EndFeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the EndFeatureMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the EndFeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the EndFeatureMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -321,31 +239,6 @@ internal static IEndFeatureMembership DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the ownedElement Json property was not found in the EndFeatureMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the EndFeatureMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the EndFeatureMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -626,46 +519,6 @@ internal static IEndFeatureMembership DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the shortName Json property was not found in the EndFeatureMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the EndFeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the EndFeatureMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EnumerationDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EnumerationDefinitionDeSerializer.cs index b671b297..5f6b5ecd 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EnumerationDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EnumerationDefinitionDeSerializer.cs @@ -1597,26 +1597,6 @@ internal static IEnumerationDefinition DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the usage Json property was not found in the EnumerationDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("variant"u8, out var variantProperty)) - { - foreach (var arrayItem in variantProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var variantExternalIdProperty)) - { - var propertyValue = variantExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.variant.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the variant Json property was not found in the EnumerationDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("variantMembership"u8, out var variantMembershipProperty)) { foreach (var arrayItem in variantMembershipProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EnumerationUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EnumerationUsageDeSerializer.cs index 2f8060b9..5ab6f0b1 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EnumerationUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EnumerationUsageDeSerializer.cs @@ -102,26 +102,6 @@ internal static IEnumerationUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the aliasIds Json property was not found in the EnumerationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("attributeDefinition"u8, out var attributeDefinitionProperty)) - { - foreach (var arrayItem in attributeDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var attributeDefinitionExternalIdProperty)) - { - var propertyValue = attributeDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.attributeDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the attributeDefinition Json property was not found in the EnumerationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -184,26 +164,6 @@ internal static IEnumerationUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the declaredShortName Json property was not found in the EnumerationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the EnumerationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -717,18 +677,6 @@ internal static IEnumerationUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the isUnique Json property was not found in the EnumerationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the EnumerationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2088,26 +2036,6 @@ internal static IEnumerationUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the textualRepresentation Json property was not found in the EnumerationUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the EnumerationUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EventOccurrenceUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EventOccurrenceUsageDeSerializer.cs index d7b505c8..1423c109 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EventOccurrenceUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/EventOccurrenceUsageDeSerializer.cs @@ -164,26 +164,6 @@ internal static IEventOccurrenceUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the declaredShortName Json property was not found in the EventOccurrenceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the EventOccurrenceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -733,18 +713,6 @@ internal static IEventOccurrenceUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the isUnique Json property was not found in the EventOccurrenceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the EventOccurrenceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2133,26 +2101,6 @@ internal static IEventOccurrenceUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the textualRepresentation Json property was not found in the EventOccurrenceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the EventOccurrenceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ExhibitStateUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ExhibitStateUsageDeSerializer.cs index f609ce22..80e06e7d 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ExhibitStateUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ExhibitStateUsageDeSerializer.cs @@ -85,26 +85,6 @@ internal static IExhibitStateUsage DeSerialize(JsonElement jsonElement, Serializ } } - if (jsonElement.TryGetProperty("actionDefinition"u8, out var actionDefinitionProperty)) - { - foreach (var arrayItem in actionDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var actionDefinitionExternalIdProperty)) - { - var propertyValue = actionDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.actionDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the actionDefinition Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("aliasIds"u8, out var aliasIdsProperty)) { foreach (var arrayItem in aliasIdsProperty.EnumerateArray()) @@ -122,26 +102,6 @@ internal static IExhibitStateUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the aliasIds Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +164,6 @@ internal static IExhibitStateUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the declaredShortName Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +184,6 @@ internal static IExhibitStateUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the differencingType Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -419,31 +339,6 @@ internal static IExhibitStateUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the entryAction Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("eventOccurrence"u8, out var eventOccurrenceProperty)) - { - if (eventOccurrenceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.eventOccurrence = Guid.Empty; - logger.LogDebug($"the ExhibitStateUsage.eventOccurrence property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (eventOccurrenceProperty.TryGetProperty("@id"u8, out var eventOccurrenceExternalIdProperty)) - { - var propertyValue = eventOccurrenceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.eventOccurrence = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the eventOccurrence Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("exhibitedState"u8, out var exhibitedStateProperty)) { if (exhibitedStateProperty.ValueKind == JsonValueKind.Null) @@ -882,18 +777,6 @@ internal static IExhibitStateUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the isUnique Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1531,26 +1414,6 @@ internal static IExhibitStateUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the nestedViewpoint Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2255,31 +2118,6 @@ internal static IExhibitStateUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the parameter Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("performedAction"u8, out var performedActionProperty)) - { - if (performedActionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.performedAction = Guid.Empty; - logger.LogDebug($"the ExhibitStateUsage.performedAction property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (performedActionProperty.TryGetProperty("@id"u8, out var performedActionExternalIdProperty)) - { - var propertyValue = performedActionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.performedAction = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the performedAction Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("portionKind"u8, out var portionKindProperty)) { dtoInstance.PortionKind = PortionKindDeSerializer.DeserializeNullable(portionKindProperty.GetString()); @@ -2347,26 +2185,6 @@ internal static IExhibitStateUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the textualRepresentation Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the ExhibitStateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ExpressionDeSerializer.cs index eb0ea257..36c568c9 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ExpressionDeSerializer.cs @@ -102,26 +102,6 @@ internal static IExpression DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the aliasIds Json property was not found in the Expression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the Expression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IExpression DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the differencingType Json property was not found in the Expression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the Expression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureChainExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureChainExpressionDeSerializer.cs index 03f2b0b8..649acd65 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureChainExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureChainExpressionDeSerializer.cs @@ -122,26 +122,6 @@ internal static IFeatureChainExpression DeSerialize(JsonElement jsonElement, Ser logger.LogDebug("the argument Json property was not found in the FeatureChainExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the FeatureChainExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -224,26 +204,6 @@ internal static IFeatureChainExpression DeSerialize(JsonElement jsonElement, Ser logger.LogDebug("the differencingType Json property was not found in the FeatureChainExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the FeatureChainExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureChainingDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureChainingDeSerializer.cs index e4212843..aaf37104 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureChainingDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureChainingDeSerializer.cs @@ -487,46 +487,6 @@ internal static IFeatureChaining DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the shortName Json property was not found in the FeatureChaining: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the FeatureChaining: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the FeatureChaining: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureInvertingDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureInvertingDeSerializer.cs index 9daca1de..a429798b 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureInvertingDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureInvertingDeSerializer.cs @@ -511,46 +511,6 @@ internal static IFeatureInverting DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the shortName Json property was not found in the FeatureInverting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the FeatureInverting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the FeatureInverting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureMembershipDeSerializer.cs index 34fc3a90..de7b5275 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureMembershipDeSerializer.cs @@ -190,88 +190,6 @@ internal static IFeatureMembership DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the isLibraryElement Json property was not found in the FeatureMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the FeatureMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the FeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the FeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the FeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the FeatureMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the FeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the FeatureMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -321,31 +239,6 @@ internal static IFeatureMembership DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the ownedElement Json property was not found in the FeatureMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the FeatureMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the FeatureMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -626,46 +519,6 @@ internal static IFeatureMembership DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the shortName Json property was not found in the FeatureMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the FeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the FeatureMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureReferenceExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureReferenceExpressionDeSerializer.cs index 2c304184..168524fe 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureReferenceExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureReferenceExpressionDeSerializer.cs @@ -102,26 +102,6 @@ internal static IFeatureReferenceExpression DeSerialize(JsonElement jsonElement, logger.LogDebug("the aliasIds Json property was not found in the FeatureReferenceExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the FeatureReferenceExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IFeatureReferenceExpression DeSerialize(JsonElement jsonElement, logger.LogDebug("the differencingType Json property was not found in the FeatureReferenceExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the FeatureReferenceExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureTypingDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureTypingDeSerializer.cs index 9a2071fc..9b59656a 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureTypingDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureTypingDeSerializer.cs @@ -154,31 +154,6 @@ internal static IFeatureTyping DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the elementId Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("general"u8, out var generalProperty)) - { - if (generalProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.General = Guid.Empty; - logger.LogDebug($"the FeatureTyping.General property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (generalProperty.TryGetProperty("@id"u8, out var generalExternalIdProperty)) - { - var propertyValue = generalExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.General = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the general Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isImplied"u8, out var isImpliedProperty)) { if (isImpliedProperty.ValueKind != JsonValueKind.Null) @@ -448,30 +423,6 @@ internal static IFeatureTyping DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the owningRelationship Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningType"u8, out var owningTypeProperty)) - { - if (owningTypeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningType = null; - } - else - { - if (owningTypeProperty.TryGetProperty("@id"u8, out var owningTypeExternalIdProperty)) - { - var propertyValue = owningTypeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningType = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningType Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -510,71 +461,6 @@ internal static IFeatureTyping DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the shortName Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("specific"u8, out var specificProperty)) - { - if (specificProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.Specific = Guid.Empty; - logger.LogDebug($"the FeatureTyping.Specific property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (specificProperty.TryGetProperty("@id"u8, out var specificExternalIdProperty)) - { - var propertyValue = specificExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Specific = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the specific Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the FeatureTyping: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureValueDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureValueDeSerializer.cs index af247494..eaf01ab5 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureValueDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FeatureValueDeSerializer.cs @@ -239,54 +239,6 @@ internal static IFeatureValue DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the isLibraryElement Json property was not found in the FeatureValue: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the FeatureValue.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the FeatureValue: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the FeatureValue: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the FeatureValue: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) { if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) @@ -312,15 +264,6 @@ internal static IFeatureValue DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the membershipOwningNamespace Json property was not found in the FeatureValue: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the FeatureValue: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -370,31 +313,6 @@ internal static IFeatureValue DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the ownedElement Json property was not found in the FeatureValue: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the FeatureValue.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the FeatureValue: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -625,46 +543,6 @@ internal static IFeatureValue DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the shortName Json property was not found in the FeatureValue: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the FeatureValue: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the FeatureValue: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FlowDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FlowDeSerializer.cs index 7d28ee1d..18274448 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FlowDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FlowDeSerializer.cs @@ -102,46 +102,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the aliasIds Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("association"u8, out var associationProperty)) - { - foreach (var arrayItem in associationProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var associationExternalIdProperty)) - { - var propertyValue = associationExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.association.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the association Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -268,26 +228,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the differencingType Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); @@ -331,26 +271,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the elementId Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -1594,26 +1514,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the qualifiedName Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -1643,26 +1543,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the shortName Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -1711,26 +1591,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the sourceOutputFeature Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -1795,26 +1655,6 @@ internal static IFlow DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the textualRepresentation Json property was not found in the Flow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the Flow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FlowDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FlowDefinitionDeSerializer.cs index 5bc71ebb..ea2a84f9 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FlowDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FlowDefinitionDeSerializer.cs @@ -122,26 +122,6 @@ internal static IFlowDefinition DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the aliasIds Json property was not found in the FlowDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("associationEnd"u8, out var associationEndProperty)) - { - foreach (var arrayItem in associationEndProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var associationEndExternalIdProperty)) - { - var propertyValue = associationEndExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.associationEnd.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the associationEnd Json property was not found in the FlowDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("declaredName"u8, out var declaredNameProperty)) { dtoInstance.DeclaredName = declaredNameProperty.GetString(); @@ -180,26 +160,6 @@ internal static IFlowDefinition DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the differencingType Json property was not found in the FlowDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the FlowDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -254,26 +214,6 @@ internal static IFlowDefinition DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the elementId Json property was not found in the FlowDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the FlowDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("feature"u8, out var featureProperty)) { foreach (var arrayItem in featureProperty.EnumerateArray()) @@ -1656,26 +1596,6 @@ internal static IFlowDefinition DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the qualifiedName Json property was not found in the FlowDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the FlowDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedType"u8, out var relatedTypeProperty)) { foreach (var arrayItem in relatedTypeProperty.EnumerateArray()) @@ -1705,26 +1625,6 @@ internal static IFlowDefinition DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the shortName Json property was not found in the FlowDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the FlowDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceType"u8, out var sourceTypeProperty)) { if (sourceTypeProperty.ValueKind == JsonValueKind.Null) @@ -1769,26 +1669,6 @@ internal static IFlowDefinition DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the step Json property was not found in the FlowDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the FlowDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetType"u8, out var targetTypeProperty)) { foreach (var arrayItem in targetTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FlowUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FlowUsageDeSerializer.cs index 78be2d4a..df6aa098 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FlowUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FlowUsageDeSerializer.cs @@ -85,26 +85,6 @@ internal static IFlowUsage DeSerialize(JsonElement jsonElement, SerializationMod } } - if (jsonElement.TryGetProperty("actionDefinition"u8, out var actionDefinitionProperty)) - { - foreach (var arrayItem in actionDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var actionDefinitionExternalIdProperty)) - { - var propertyValue = actionDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.actionDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the actionDefinition Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("aliasIds"u8, out var aliasIdsProperty)) { foreach (var arrayItem in aliasIdsProperty.EnumerateArray()) @@ -122,46 +102,6 @@ internal static IFlowUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the aliasIds Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("association"u8, out var associationProperty)) - { - foreach (var arrayItem in associationProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var associationExternalIdProperty)) - { - var propertyValue = associationExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.association.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the association Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -268,26 +208,6 @@ internal static IFlowUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the defaultFeaturingType Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -308,26 +228,6 @@ internal static IFlowUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the differencingType Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -391,26 +291,6 @@ internal static IFlowUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the elementId Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -664,26 +544,6 @@ internal static IFlowUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the input Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("interaction"u8, out var interactionProperty)) - { - foreach (var arrayItem in interactionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var interactionExternalIdProperty)) - { - var propertyValue = interactionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.interaction.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the interaction Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("intersectingType"u8, out var intersectingTypeProperty)) { foreach (var arrayItem in intersectingTypeProperty.EnumerateArray()) @@ -884,18 +744,6 @@ internal static IFlowUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the isUnique Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1533,26 +1381,6 @@ internal static IFlowUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the nestedViewpoint Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2363,26 +2191,6 @@ internal static IFlowUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the qualifiedName Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -2412,26 +2220,6 @@ internal static IFlowUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the shortName Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -2480,26 +2268,6 @@ internal static IFlowUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the sourceOutputFeature Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -2564,26 +2332,6 @@ internal static IFlowUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the textualRepresentation Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the FlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ForLoopActionUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ForLoopActionUsageDeSerializer.cs index 51a8995f..45c80aa8 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ForLoopActionUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ForLoopActionUsageDeSerializer.cs @@ -122,26 +122,6 @@ internal static IForLoopActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the aliasIds Json property was not found in the ForLoopActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the ForLoopActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("bodyAction"u8, out var bodyActionProperty)) { if (bodyActionProperty.ValueKind == JsonValueKind.Null) @@ -229,26 +209,6 @@ internal static IForLoopActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the declaredShortName Json property was not found in the ForLoopActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the ForLoopActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -269,26 +229,6 @@ internal static IForLoopActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the differencingType Json property was not found in the ForLoopActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the ForLoopActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -773,18 +713,6 @@ internal static IForLoopActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the isUnique Json property was not found in the ForLoopActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the ForLoopActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1447,26 +1375,6 @@ internal static IForLoopActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the nestedViewpoint Json property was not found in the ForLoopActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the ForLoopActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2243,26 +2151,6 @@ internal static IForLoopActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the textualRepresentation Json property was not found in the ForLoopActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the ForLoopActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ForkNodeDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ForkNodeDeSerializer.cs index f602ffd1..ff52253f 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ForkNodeDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ForkNodeDeSerializer.cs @@ -122,26 +122,6 @@ internal static IForkNode DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the aliasIds Json property was not found in the ForkNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the ForkNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IForkNode DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the declaredShortName Json property was not found in the ForkNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the ForkNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +204,6 @@ internal static IForkNode DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the differencingType Json property was not found in the ForkNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the ForkNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -748,18 +688,6 @@ internal static IForkNode DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the isUnique Json property was not found in the ForkNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the ForkNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1397,26 +1325,6 @@ internal static IForkNode DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the nestedViewpoint Json property was not found in the ForkNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the ForkNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2168,26 +2076,6 @@ internal static IForkNode DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the textualRepresentation Json property was not found in the ForkNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the ForkNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FramedConcernMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FramedConcernMembershipDeSerializer.cs index 87b92642..5ca7e477 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FramedConcernMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FramedConcernMembershipDeSerializer.cs @@ -199,88 +199,6 @@ internal static IFramedConcernMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the kind Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the FramedConcernMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the FramedConcernMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -335,31 +253,6 @@ internal static IFramedConcernMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the ownedConcern Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedConstraint"u8, out var ownedConstraintProperty)) - { - if (ownedConstraintProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedConstraint = Guid.Empty; - logger.LogDebug($"the FramedConcernMembership.ownedConstraint property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedConstraintProperty.TryGetProperty("@id"u8, out var ownedConstraintExternalIdProperty)) - { - var propertyValue = ownedConstraintExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedConstraint = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedConstraint Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedElement"u8, out var ownedElementProperty)) { foreach (var arrayItem in ownedElementProperty.EnumerateArray()) @@ -380,31 +273,6 @@ internal static IFramedConcernMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the ownedElement Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the FramedConcernMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -419,31 +287,6 @@ internal static IFramedConcernMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the ownedMemberElementId Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the FramedConcernMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -681,31 +524,6 @@ internal static IFramedConcernMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the referencedConcern Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("referencedConstraint"u8, out var referencedConstraintProperty)) - { - if (referencedConstraintProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.referencedConstraint = Guid.Empty; - logger.LogDebug($"the FramedConcernMembership.referencedConstraint property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (referencedConstraintProperty.TryGetProperty("@id"u8, out var referencedConstraintExternalIdProperty)) - { - var propertyValue = referencedConstraintExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.referencedConstraint = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the referencedConstraint Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) { foreach (var arrayItem in relatedElementProperty.EnumerateArray()) @@ -735,46 +553,6 @@ internal static IFramedConcernMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the shortName Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the FramedConcernMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FunctionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FunctionDeSerializer.cs index 2a015b15..ed962798 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FunctionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/FunctionDeSerializer.cs @@ -140,26 +140,6 @@ internal static IFunction DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the differencingType Json property was not found in the Function: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the Function: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("documentation"u8, out var documentationProperty)) { foreach (var arrayItem in documentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IfActionUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IfActionUsageDeSerializer.cs index 52ba8569..dfe0dcca 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IfActionUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IfActionUsageDeSerializer.cs @@ -122,26 +122,6 @@ internal static IIfActionUsage DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the aliasIds Json property was not found in the IfActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the IfActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IIfActionUsage DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the declaredShortName Json property was not found in the IfActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the IfActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +204,6 @@ internal static IIfActionUsage DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the differencingType Json property was not found in the IfActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the IfActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -797,18 +737,6 @@ internal static IIfActionUsage DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the isUnique Json property was not found in the IfActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the IfActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1446,26 +1374,6 @@ internal static IIfActionUsage DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the nestedViewpoint Json property was not found in the IfActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the IfActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2242,26 +2150,6 @@ internal static IIfActionUsage DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the thenAction Json property was not found in the IfActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the IfActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IncludeUseCaseUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IncludeUseCaseUsageDeSerializer.cs index bf837900..855e1ed6 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IncludeUseCaseUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IncludeUseCaseUsageDeSerializer.cs @@ -85,26 +85,6 @@ internal static IIncludeUseCaseUsage DeSerialize(JsonElement jsonElement, Serial } } - if (jsonElement.TryGetProperty("actionDefinition"u8, out var actionDefinitionProperty)) - { - foreach (var arrayItem in actionDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var actionDefinitionExternalIdProperty)) - { - var propertyValue = actionDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.actionDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the actionDefinition Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("actorParameter"u8, out var actorParameterProperty)) { foreach (var arrayItem in actorParameterProperty.EnumerateArray()) @@ -142,74 +122,6 @@ internal static IIncludeUseCaseUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the aliasIds Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("calculationDefinition"u8, out var calculationDefinitionProperty)) - { - if (calculationDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.calculationDefinition = null; - } - else - { - if (calculationDefinitionProperty.TryGetProperty("@id"u8, out var calculationDefinitionExternalIdProperty)) - { - var propertyValue = calculationDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.calculationDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the calculationDefinition Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("caseDefinition"u8, out var caseDefinitionProperty)) - { - if (caseDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.caseDefinition = null; - } - else - { - if (caseDefinitionProperty.TryGetProperty("@id"u8, out var caseDefinitionExternalIdProperty)) - { - var propertyValue = caseDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.caseDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the caseDefinition Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -272,26 +184,6 @@ internal static IIncludeUseCaseUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the declaredShortName Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -312,26 +204,6 @@ internal static IIncludeUseCaseUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the differencingType Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -439,31 +311,6 @@ internal static IIncludeUseCaseUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the endOwningType Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("eventOccurrence"u8, out var eventOccurrenceProperty)) - { - if (eventOccurrenceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.eventOccurrence = Guid.Empty; - logger.LogDebug($"the IncludeUseCaseUsage.eventOccurrence property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (eventOccurrenceProperty.TryGetProperty("@id"u8, out var eventOccurrenceExternalIdProperty)) - { - var propertyValue = eventOccurrenceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.eventOccurrence = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the eventOccurrence Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("feature"u8, out var featureProperty)) { foreach (var arrayItem in featureProperty.EnumerateArray()) @@ -549,30 +396,6 @@ internal static IIncludeUseCaseUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the featuringType Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -897,18 +720,6 @@ internal static IIncludeUseCaseUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the isUnique Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1570,26 +1381,6 @@ internal static IIncludeUseCaseUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the objectiveRequirement Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2294,31 +2085,6 @@ internal static IIncludeUseCaseUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the parameter Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("performedAction"u8, out var performedActionProperty)) - { - if (performedActionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.performedAction = Guid.Empty; - logger.LogDebug($"the IncludeUseCaseUsage.performedAction property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (performedActionProperty.TryGetProperty("@id"u8, out var performedActionExternalIdProperty)) - { - var propertyValue = performedActionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.performedAction = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the performedAction Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("portionKind"u8, out var portionKindProperty)) { dtoInstance.PortionKind = PortionKindDeSerializer.DeserializeNullable(portionKindProperty.GetString()); @@ -2416,26 +2182,6 @@ internal static IIncludeUseCaseUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the textualRepresentation Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the IncludeUseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IndexExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IndexExpressionDeSerializer.cs index 4c0786ff..dd1bedcd 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IndexExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IndexExpressionDeSerializer.cs @@ -122,26 +122,6 @@ internal static IIndexExpression DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the argument Json property was not found in the IndexExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the IndexExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -224,26 +204,6 @@ internal static IIndexExpression DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the differencingType Json property was not found in the IndexExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the IndexExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InteractionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InteractionDeSerializer.cs index f108ff28..6154990d 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InteractionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InteractionDeSerializer.cs @@ -160,26 +160,6 @@ internal static IInteraction DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the differencingType Json property was not found in the Interaction: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the Interaction: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("documentation"u8, out var documentationProperty)) { foreach (var arrayItem in documentationProperty.EnumerateArray()) @@ -214,26 +194,6 @@ internal static IInteraction DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the elementId Json property was not found in the Interaction: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the Interaction: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("feature"u8, out var featureProperty)) { foreach (var arrayItem in featureProperty.EnumerateArray()) @@ -1032,26 +992,6 @@ internal static IInteraction DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the qualifiedName Json property was not found in the Interaction: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the Interaction: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedType"u8, out var relatedTypeProperty)) { foreach (var arrayItem in relatedTypeProperty.EnumerateArray()) @@ -1081,26 +1021,6 @@ internal static IInteraction DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the shortName Json property was not found in the Interaction: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Interaction: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceType"u8, out var sourceTypeProperty)) { if (sourceTypeProperty.ValueKind == JsonValueKind.Null) @@ -1145,26 +1065,6 @@ internal static IInteraction DeSerialize(JsonElement jsonElement, SerializationM logger.LogDebug("the step Json property was not found in the Interaction: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Interaction: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetType"u8, out var targetTypeProperty)) { foreach (var arrayItem in targetTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InterfaceDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InterfaceDefinitionDeSerializer.cs index cf8f045d..3f423c5e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InterfaceDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InterfaceDefinitionDeSerializer.cs @@ -102,46 +102,6 @@ internal static IInterfaceDefinition DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the aliasIds Json property was not found in the InterfaceDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("associationEnd"u8, out var associationEndProperty)) - { - foreach (var arrayItem in associationEndProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var associationEndExternalIdProperty)) - { - var propertyValue = associationEndExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.associationEnd.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the associationEnd Json property was not found in the InterfaceDefinition: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("connectionEnd"u8, out var connectionEndProperty)) - { - foreach (var arrayItem in connectionEndProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var connectionEndExternalIdProperty)) - { - var propertyValue = connectionEndExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.connectionEnd.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the connectionEnd Json property was not found in the InterfaceDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("declaredName"u8, out var declaredNameProperty)) { dtoInstance.DeclaredName = declaredNameProperty.GetString(); @@ -254,26 +214,6 @@ internal static IInterfaceDefinition DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the elementId Json property was not found in the InterfaceDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the InterfaceDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("feature"u8, out var featureProperty)) { foreach (var arrayItem in featureProperty.EnumerateArray()) @@ -1636,26 +1576,6 @@ internal static IInterfaceDefinition DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the qualifiedName Json property was not found in the InterfaceDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the InterfaceDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedType"u8, out var relatedTypeProperty)) { foreach (var arrayItem in relatedTypeProperty.EnumerateArray()) @@ -1685,26 +1605,6 @@ internal static IInterfaceDefinition DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the shortName Json property was not found in the InterfaceDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the InterfaceDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceType"u8, out var sourceTypeProperty)) { if (sourceTypeProperty.ValueKind == JsonValueKind.Null) @@ -1729,26 +1629,6 @@ internal static IInterfaceDefinition DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the sourceType Json property was not found in the InterfaceDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the InterfaceDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetType"u8, out var targetTypeProperty)) { foreach (var arrayItem in targetTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InterfaceUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InterfaceUsageDeSerializer.cs index 569c14b8..6b5935f4 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InterfaceUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InterfaceUsageDeSerializer.cs @@ -102,26 +102,6 @@ internal static IInterfaceUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the aliasIds Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("association"u8, out var associationProperty)) - { - foreach (var arrayItem in associationProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var associationExternalIdProperty)) - { - var propertyValue = associationExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.association.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the association Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -142,26 +122,6 @@ internal static IInterfaceUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the chainingFeature Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("connectionDefinition"u8, out var connectionDefinitionProperty)) - { - foreach (var arrayItem in connectionDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var connectionDefinitionExternalIdProperty)) - { - var propertyValue = connectionDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.connectionDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the connectionDefinition Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("connectorEnd"u8, out var connectorEndProperty)) { foreach (var arrayItem in connectorEndProperty.EnumerateArray()) @@ -248,26 +208,6 @@ internal static IInterfaceUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the defaultFeaturingType Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -371,26 +311,6 @@ internal static IInterfaceUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the elementId Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -824,18 +744,6 @@ internal static IInterfaceUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the isUnique Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2279,26 +2187,6 @@ internal static IInterfaceUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the qualifiedName Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -2328,26 +2216,6 @@ internal static IInterfaceUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the shortName Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -2372,26 +2240,6 @@ internal static IInterfaceUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the sourceFeature Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -2432,26 +2280,6 @@ internal static IInterfaceUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the textualRepresentation Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the InterfaceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IntersectingDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IntersectingDeSerializer.cs index ba480234..548c74a1 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IntersectingDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/IntersectingDeSerializer.cs @@ -462,46 +462,6 @@ internal static IIntersecting DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the shortName Json property was not found in the Intersecting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Intersecting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Intersecting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InvariantDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InvariantDeSerializer.cs index 260495f8..a0b1b176 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InvariantDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InvariantDeSerializer.cs @@ -102,26 +102,6 @@ internal static IInvariant DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the aliasIds Json property was not found in the Invariant: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the Invariant: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IInvariant DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the differencingType Json property was not found in the Invariant: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the Invariant: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); @@ -396,30 +356,6 @@ internal static IInvariant DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the featuringType Json property was not found in the Invariant: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the Invariant: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InvocationExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InvocationExpressionDeSerializer.cs index de39b65e..36b3e026 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InvocationExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/InvocationExpressionDeSerializer.cs @@ -122,26 +122,6 @@ internal static IInvocationExpression DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the argument Json property was not found in the InvocationExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the InvocationExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -224,26 +204,6 @@ internal static IInvocationExpression DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the differencingType Json property was not found in the InvocationExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the InvocationExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ItemUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ItemUsageDeSerializer.cs index e32c2120..167e8def 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ItemUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ItemUsageDeSerializer.cs @@ -164,26 +164,6 @@ internal static IItemUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the declaredShortName Json property was not found in the ItemUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the ItemUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -708,18 +688,6 @@ internal static IItemUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the isUnique Json property was not found in the ItemUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the ItemUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2128,26 +2096,6 @@ internal static IItemUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the textualRepresentation Json property was not found in the ItemUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the ItemUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/JoinNodeDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/JoinNodeDeSerializer.cs index 210c3af5..f347d8ab 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/JoinNodeDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/JoinNodeDeSerializer.cs @@ -122,26 +122,6 @@ internal static IJoinNode DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the aliasIds Json property was not found in the JoinNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the JoinNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IJoinNode DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the declaredShortName Json property was not found in the JoinNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the JoinNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +204,6 @@ internal static IJoinNode DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the differencingType Json property was not found in the JoinNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the JoinNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -748,18 +688,6 @@ internal static IJoinNode DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the isUnique Json property was not found in the JoinNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the JoinNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1397,26 +1325,6 @@ internal static IJoinNode DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the nestedViewpoint Json property was not found in the JoinNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the JoinNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2168,26 +2076,6 @@ internal static IJoinNode DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the textualRepresentation Json property was not found in the JoinNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the JoinNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralBooleanDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralBooleanDeSerializer.cs index ac06d9cc..3c6697d6 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralBooleanDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralBooleanDeSerializer.cs @@ -102,26 +102,6 @@ internal static ILiteralBoolean DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the aliasIds Json property was not found in the LiteralBoolean: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the LiteralBoolean: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static ILiteralBoolean DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the differencingType Json property was not found in the LiteralBoolean: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the LiteralBoolean: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralExpressionDeSerializer.cs index 4bf1cd28..51ab2a76 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralExpressionDeSerializer.cs @@ -102,26 +102,6 @@ internal static ILiteralExpression DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the aliasIds Json property was not found in the LiteralExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the LiteralExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static ILiteralExpression DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the differencingType Json property was not found in the LiteralExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the LiteralExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralInfinityDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralInfinityDeSerializer.cs index eaa8e2b6..9a08669a 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralInfinityDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralInfinityDeSerializer.cs @@ -102,26 +102,6 @@ internal static ILiteralInfinity DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the aliasIds Json property was not found in the LiteralInfinity: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the LiteralInfinity: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static ILiteralInfinity DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the differencingType Json property was not found in the LiteralInfinity: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the LiteralInfinity: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralIntegerDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralIntegerDeSerializer.cs index 4dd76ec8..517fdfb8 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralIntegerDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralIntegerDeSerializer.cs @@ -102,26 +102,6 @@ internal static ILiteralInteger DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the aliasIds Json property was not found in the LiteralInteger: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the LiteralInteger: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static ILiteralInteger DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the differencingType Json property was not found in the LiteralInteger: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the LiteralInteger: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralRationalDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralRationalDeSerializer.cs index ce5eeea5..9215456a 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralRationalDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralRationalDeSerializer.cs @@ -102,26 +102,6 @@ internal static ILiteralRational DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the aliasIds Json property was not found in the LiteralRational: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the LiteralRational: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static ILiteralRational DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the differencingType Json property was not found in the LiteralRational: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the LiteralRational: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralStringDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralStringDeSerializer.cs index eee40a43..2feba9e8 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralStringDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/LiteralStringDeSerializer.cs @@ -102,26 +102,6 @@ internal static ILiteralString DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the aliasIds Json property was not found in the LiteralString: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the LiteralString: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static ILiteralString DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the differencingType Json property was not found in the LiteralString: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the LiteralString: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MembershipDeSerializer.cs index 003829e8..dc72c218 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MembershipDeSerializer.cs @@ -519,46 +519,6 @@ internal static IMembership DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the shortName Json property was not found in the Membership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Membership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Membership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MembershipExposeDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MembershipExposeDeSerializer.cs index eb8a7d14..30ab3e5d 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MembershipExposeDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MembershipExposeDeSerializer.cs @@ -536,46 +536,6 @@ internal static IMembershipExpose DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the shortName Json property was not found in the MembershipExpose: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the MembershipExpose: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the MembershipExpose: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MembershipImportDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MembershipImportDeSerializer.cs index 2881c825..cc114a08 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MembershipImportDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MembershipImportDeSerializer.cs @@ -536,46 +536,6 @@ internal static IMembershipImport DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the shortName Json property was not found in the MembershipImport: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the MembershipImport: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the MembershipImport: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MergeNodeDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MergeNodeDeSerializer.cs index 1df54944..e188ae32 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MergeNodeDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MergeNodeDeSerializer.cs @@ -122,26 +122,6 @@ internal static IMergeNode DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the aliasIds Json property was not found in the MergeNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the MergeNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IMergeNode DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the declaredShortName Json property was not found in the MergeNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the MergeNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +204,6 @@ internal static IMergeNode DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the differencingType Json property was not found in the MergeNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the MergeNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -748,18 +688,6 @@ internal static IMergeNode DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the isUnique Json property was not found in the MergeNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the MergeNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1397,26 +1325,6 @@ internal static IMergeNode DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the nestedViewpoint Json property was not found in the MergeNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the MergeNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2168,26 +2076,6 @@ internal static IMergeNode DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the textualRepresentation Json property was not found in the MergeNode: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the MergeNode: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MetadataAccessExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MetadataAccessExpressionDeSerializer.cs index ca2b4d31..28825206 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MetadataAccessExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MetadataAccessExpressionDeSerializer.cs @@ -102,26 +102,6 @@ internal static IMetadataAccessExpression DeSerialize(JsonElement jsonElement, S logger.LogDebug("the aliasIds Json property was not found in the MetadataAccessExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the MetadataAccessExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IMetadataAccessExpression DeSerialize(JsonElement jsonElement, S logger.LogDebug("the differencingType Json property was not found in the MetadataAccessExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the MetadataAccessExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MetadataUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MetadataUsageDeSerializer.cs index 93811eed..78239bdb 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MetadataUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/MetadataUsageDeSerializer.cs @@ -204,26 +204,6 @@ internal static IMetadataUsage DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the declaredShortName Json property was not found in the MetadataUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the MetadataUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -748,18 +728,6 @@ internal static IMetadataUsage DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the isUnique Json property was not found in the MetadataUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the MetadataUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -772,26 +740,6 @@ internal static IMetadataUsage DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the isVariation Json property was not found in the MetadataUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("itemDefinition"u8, out var itemDefinitionProperty)) - { - foreach (var arrayItem in itemDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var itemDefinitionExternalIdProperty)) - { - var propertyValue = itemDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.itemDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the itemDefinition Json property was not found in the MetadataUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("mayTimeVary"u8, out var mayTimeVaryProperty)) { if (mayTimeVaryProperty.ValueKind != JsonValueKind.Null) @@ -844,30 +792,6 @@ internal static IMetadataUsage DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the membership Json property was not found in the MetadataUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("metaclass"u8, out var metaclassProperty)) - { - if (metaclassProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.metaclass = null; - } - else - { - if (metaclassProperty.TryGetProperty("@id"u8, out var metaclassExternalIdProperty)) - { - var propertyValue = metaclassExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.metaclass = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the metaclass Json property was not found in the MetadataUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("metadataDefinition"u8, out var metadataDefinitionProperty)) { if (metadataDefinitionProperty.ValueKind == JsonValueKind.Null) @@ -2260,26 +2184,6 @@ internal static IMetadataUsage DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the textualRepresentation Json property was not found in the MetadataUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the MetadataUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/NamespaceExposeDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/NamespaceExposeDeSerializer.cs index d2a342e5..ed475220 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/NamespaceExposeDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/NamespaceExposeDeSerializer.cs @@ -536,46 +536,6 @@ internal static INamespaceExpose DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the shortName Json property was not found in the NamespaceExpose: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the NamespaceExpose: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the NamespaceExpose: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/NamespaceImportDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/NamespaceImportDeSerializer.cs index 03c358eb..43ba727a 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/NamespaceImportDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/NamespaceImportDeSerializer.cs @@ -536,46 +536,6 @@ internal static INamespaceImport DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the shortName Json property was not found in the NamespaceImport: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the NamespaceImport: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the NamespaceImport: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/NullExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/NullExpressionDeSerializer.cs index f4363f9e..4028dd4c 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/NullExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/NullExpressionDeSerializer.cs @@ -102,26 +102,6 @@ internal static INullExpression DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the aliasIds Json property was not found in the NullExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the NullExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static INullExpression DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the differencingType Json property was not found in the NullExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the NullExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ObjectiveMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ObjectiveMembershipDeSerializer.cs index 021d4bcd..431d1e3b 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ObjectiveMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ObjectiveMembershipDeSerializer.cs @@ -190,88 +190,6 @@ internal static IObjectiveMembership DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the isLibraryElement Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the ObjectiveMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the ObjectiveMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -321,31 +239,6 @@ internal static IObjectiveMembership DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the ownedElement Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the ObjectiveMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -360,31 +253,6 @@ internal static IObjectiveMembership DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the ownedMemberElementId Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the ObjectiveMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -651,46 +519,6 @@ internal static IObjectiveMembership DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the shortName Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the ObjectiveMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/OccurrenceUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/OccurrenceUsageDeSerializer.cs index d17de40d..3e5a8f33 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/OccurrenceUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/OccurrenceUsageDeSerializer.cs @@ -164,26 +164,6 @@ internal static IOccurrenceUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the declaredShortName Json property was not found in the OccurrenceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the OccurrenceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -708,18 +688,6 @@ internal static IOccurrenceUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the isUnique Json property was not found in the OccurrenceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the OccurrenceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2108,26 +2076,6 @@ internal static IOccurrenceUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the textualRepresentation Json property was not found in the OccurrenceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the OccurrenceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/OperatorExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/OperatorExpressionDeSerializer.cs index 407e8a16..5264146b 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/OperatorExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/OperatorExpressionDeSerializer.cs @@ -122,26 +122,6 @@ internal static IOperatorExpression DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the argument Json property was not found in the OperatorExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the OperatorExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -224,26 +204,6 @@ internal static IOperatorExpression DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the differencingType Json property was not found in the OperatorExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the OperatorExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/OwningMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/OwningMembershipDeSerializer.cs index c56d9d3e..b8b123b8 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/OwningMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/OwningMembershipDeSerializer.cs @@ -190,54 +190,6 @@ internal static IOwningMembership DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the isLibraryElement Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the OwningMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) { if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) @@ -263,15 +215,6 @@ internal static IOwningMembership DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the membershipOwningNamespace Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -576,46 +519,6 @@ internal static IOwningMembership DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the shortName Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the OwningMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ParameterMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ParameterMembershipDeSerializer.cs index ca25990b..1cc4d534 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ParameterMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ParameterMembershipDeSerializer.cs @@ -190,88 +190,6 @@ internal static IParameterMembership DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the isLibraryElement Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the ParameterMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the ParameterMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -321,31 +239,6 @@ internal static IParameterMembership DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the ownedElement Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the ParameterMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -360,31 +253,6 @@ internal static IParameterMembership DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the ownedMemberElementId Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the ParameterMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -651,46 +519,6 @@ internal static IParameterMembership DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the shortName Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the ParameterMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PartUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PartUsageDeSerializer.cs index b3700bab..c57f954b 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PartUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PartUsageDeSerializer.cs @@ -164,26 +164,6 @@ internal static IPartUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the declaredShortName Json property was not found in the PartUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the PartUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -708,18 +688,6 @@ internal static IPartUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the isUnique Json property was not found in the PartUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the PartUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2148,26 +2116,6 @@ internal static IPartUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the textualRepresentation Json property was not found in the PartUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the PartUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PerformActionUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PerformActionUsageDeSerializer.cs index 2b976b72..e9cecde9 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PerformActionUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PerformActionUsageDeSerializer.cs @@ -122,26 +122,6 @@ internal static IPerformActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the aliasIds Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static IPerformActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the declaredShortName Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +204,6 @@ internal static IPerformActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the differencingType Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -371,31 +311,6 @@ internal static IPerformActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the endOwningType Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("eventOccurrence"u8, out var eventOccurrenceProperty)) - { - if (eventOccurrenceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.eventOccurrence = Guid.Empty; - logger.LogDebug($"the PerformActionUsage.eventOccurrence property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (eventOccurrenceProperty.TryGetProperty("@id"u8, out var eventOccurrenceExternalIdProperty)) - { - var propertyValue = eventOccurrenceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.eventOccurrence = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the eventOccurrence Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("feature"u8, out var featureProperty)) { foreach (var arrayItem in featureProperty.EnumerateArray()) @@ -773,18 +688,6 @@ internal static IPerformActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the isUnique Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1422,26 +1325,6 @@ internal static IPerformActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the nestedViewpoint Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2218,26 +2101,6 @@ internal static IPerformActionUsage DeSerialize(JsonElement jsonElement, Seriali logger.LogDebug("the textualRepresentation Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the PerformActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PortConjugationDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PortConjugationDeSerializer.cs index 48b53fc7..475f7fc6 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PortConjugationDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PortConjugationDeSerializer.cs @@ -274,31 +274,6 @@ internal static IPortConjugation DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the originalPortDefinition Json property was not found in the PortConjugation: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("originalType"u8, out var originalTypeProperty)) - { - if (originalTypeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.OriginalType = Guid.Empty; - logger.LogDebug($"the PortConjugation.OriginalType property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (originalTypeProperty.TryGetProperty("@id"u8, out var originalTypeExternalIdProperty)) - { - var propertyValue = originalTypeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.OriginalType = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the originalType Json property was not found in the PortConjugation: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedAnnotation"u8, out var ownedAnnotationProperty)) { foreach (var arrayItem in ownedAnnotationProperty.EnumerateArray()) @@ -499,30 +474,6 @@ internal static IPortConjugation DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the owningRelationship Json property was not found in the PortConjugation: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningType"u8, out var owningTypeProperty)) - { - if (owningTypeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningType = null; - } - else - { - if (owningTypeProperty.TryGetProperty("@id"u8, out var owningTypeExternalIdProperty)) - { - var propertyValue = owningTypeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningType = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningType Json property was not found in the PortConjugation: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -561,46 +512,6 @@ internal static IPortConjugation DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the shortName Json property was not found in the PortConjugation: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the PortConjugation: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the PortConjugation: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PortUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PortUsageDeSerializer.cs index 1ce2d822..c5a10e72 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PortUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PortUsageDeSerializer.cs @@ -164,26 +164,6 @@ internal static IPortUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the declaredShortName Json property was not found in the PortUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the PortUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -708,18 +688,6 @@ internal static IPortUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the isUnique Json property was not found in the PortUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the PortUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1357,26 +1325,6 @@ internal static IPortUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the nestedViewpoint Json property was not found in the PortUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the PortUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2128,26 +2076,6 @@ internal static IPortUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the textualRepresentation Json property was not found in the PortUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the PortUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PredicateDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PredicateDeSerializer.cs index 03773a2b..6b7a37b2 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PredicateDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/PredicateDeSerializer.cs @@ -140,26 +140,6 @@ internal static IPredicate DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the differencingType Json property was not found in the Predicate: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the Predicate: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("documentation"u8, out var documentationProperty)) { foreach (var arrayItem in documentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RedefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RedefinitionDeSerializer.cs index e46ab1e6..22e070e6 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RedefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RedefinitionDeSerializer.cs @@ -154,31 +154,6 @@ internal static IRedefinition DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the elementId Json property was not found in the Redefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("general"u8, out var generalProperty)) - { - if (generalProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.General = Guid.Empty; - logger.LogDebug($"the Redefinition.General property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (generalProperty.TryGetProperty("@id"u8, out var generalExternalIdProperty)) - { - var propertyValue = generalExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.General = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the general Json property was not found in the Redefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isImplied"u8, out var isImpliedProperty)) { if (isImpliedProperty.ValueKind != JsonValueKind.Null) @@ -448,30 +423,6 @@ internal static IRedefinition DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the owningRelationship Json property was not found in the Redefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningType"u8, out var owningTypeProperty)) - { - if (owningTypeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningType = null; - } - else - { - if (owningTypeProperty.TryGetProperty("@id"u8, out var owningTypeExternalIdProperty)) - { - var propertyValue = owningTypeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningType = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningType Json property was not found in the Redefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -560,121 +511,6 @@ internal static IRedefinition DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the shortName Json property was not found in the Redefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Redefinition: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("specific"u8, out var specificProperty)) - { - if (specificProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.Specific = Guid.Empty; - logger.LogDebug($"the Redefinition.Specific property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (specificProperty.TryGetProperty("@id"u8, out var specificExternalIdProperty)) - { - var propertyValue = specificExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Specific = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the specific Json property was not found in the Redefinition: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("subsettedFeature"u8, out var subsettedFeatureProperty)) - { - if (subsettedFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.SubsettedFeature = Guid.Empty; - logger.LogDebug($"the Redefinition.SubsettedFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (subsettedFeatureProperty.TryGetProperty("@id"u8, out var subsettedFeatureExternalIdProperty)) - { - var propertyValue = subsettedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.SubsettedFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the subsettedFeature Json property was not found in the Redefinition: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("subsettingFeature"u8, out var subsettingFeatureProperty)) - { - if (subsettingFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.SubsettingFeature = Guid.Empty; - logger.LogDebug($"the Redefinition.SubsettingFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (subsettingFeatureProperty.TryGetProperty("@id"u8, out var subsettingFeatureExternalIdProperty)) - { - var propertyValue = subsettingFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.SubsettingFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the subsettingFeature Json property was not found in the Redefinition: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Redefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ReferenceSubsettingDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ReferenceSubsettingDeSerializer.cs index 1c177095..270fd317 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ReferenceSubsettingDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ReferenceSubsettingDeSerializer.cs @@ -154,31 +154,6 @@ internal static IReferenceSubsetting DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the elementId Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("general"u8, out var generalProperty)) - { - if (generalProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.General = Guid.Empty; - logger.LogDebug($"the ReferenceSubsetting.General property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (generalProperty.TryGetProperty("@id"u8, out var generalExternalIdProperty)) - { - var propertyValue = generalExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.General = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the general Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isImplied"u8, out var isImpliedProperty)) { if (isImpliedProperty.ValueKind != JsonValueKind.Null) @@ -328,30 +303,6 @@ internal static IReferenceSubsetting DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the owner Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningFeature"u8, out var owningFeatureProperty)) - { - if (owningFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningFeature = null; - } - else - { - if (owningFeatureProperty.TryGetProperty("@id"u8, out var owningFeatureExternalIdProperty)) - { - var propertyValue = owningFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningFeature Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("owningMembership"u8, out var owningMembershipProperty)) { if (owningMembershipProperty.ValueKind == JsonValueKind.Null) @@ -448,30 +399,6 @@ internal static IReferenceSubsetting DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the owningRelationship Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningType"u8, out var owningTypeProperty)) - { - if (owningTypeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningType = null; - } - else - { - if (owningTypeProperty.TryGetProperty("@id"u8, out var owningTypeExternalIdProperty)) - { - var propertyValue = owningTypeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningType = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningType Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -560,121 +487,6 @@ internal static IReferenceSubsetting DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the shortName Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("specific"u8, out var specificProperty)) - { - if (specificProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.Specific = Guid.Empty; - logger.LogDebug($"the ReferenceSubsetting.Specific property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (specificProperty.TryGetProperty("@id"u8, out var specificExternalIdProperty)) - { - var propertyValue = specificExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Specific = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the specific Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("subsettedFeature"u8, out var subsettedFeatureProperty)) - { - if (subsettedFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.SubsettedFeature = Guid.Empty; - logger.LogDebug($"the ReferenceSubsetting.SubsettedFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (subsettedFeatureProperty.TryGetProperty("@id"u8, out var subsettedFeatureExternalIdProperty)) - { - var propertyValue = subsettedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.SubsettedFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the subsettedFeature Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("subsettingFeature"u8, out var subsettingFeatureProperty)) - { - if (subsettingFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.SubsettingFeature = Guid.Empty; - logger.LogDebug($"the ReferenceSubsetting.SubsettingFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (subsettingFeatureProperty.TryGetProperty("@id"u8, out var subsettingFeatureExternalIdProperty)) - { - var propertyValue = subsettingFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.SubsettingFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the subsettingFeature Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the ReferenceSubsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ReferenceUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ReferenceUsageDeSerializer.cs index 38d1ca30..404bbd2c 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ReferenceUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ReferenceUsageDeSerializer.cs @@ -672,18 +672,6 @@ internal static IReferenceUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the isUnique Json property was not found in the ReferenceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the ReferenceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2043,26 +2031,6 @@ internal static IReferenceUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the textualRepresentation Json property was not found in the ReferenceUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the ReferenceUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RenderingUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RenderingUsageDeSerializer.cs index ab78a79b..7ab5accd 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RenderingUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RenderingUsageDeSerializer.cs @@ -164,26 +164,6 @@ internal static IRenderingUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the declaredShortName Json property was not found in the RenderingUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the RenderingUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -708,18 +688,6 @@ internal static IRenderingUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the isUnique Json property was not found in the RenderingUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the RenderingUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2081,26 +2049,6 @@ internal static IRenderingUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the owningUsage Json property was not found in the RenderingUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("partDefinition"u8, out var partDefinitionProperty)) - { - foreach (var arrayItem in partDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var partDefinitionExternalIdProperty)) - { - var propertyValue = partDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.partDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the partDefinition Json property was not found in the RenderingUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("portionKind"u8, out var portionKindProperty)) { dtoInstance.PortionKind = PortionKindDeSerializer.DeserializeNullable(portionKindProperty.GetString()); @@ -2172,26 +2120,6 @@ internal static IRenderingUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the textualRepresentation Json property was not found in the RenderingUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the RenderingUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementConstraintMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementConstraintMembershipDeSerializer.cs index b65ae7f3..5d3811ca 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementConstraintMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementConstraintMembershipDeSerializer.cs @@ -199,88 +199,6 @@ internal static IRequirementConstraintMembership DeSerialize(JsonElement jsonEle logger.LogDebug("the kind Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the RequirementConstraintMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the RequirementConstraintMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -355,31 +273,6 @@ internal static IRequirementConstraintMembership DeSerialize(JsonElement jsonEle logger.LogDebug("the ownedElement Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the RequirementConstraintMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -394,31 +287,6 @@ internal static IRequirementConstraintMembership DeSerialize(JsonElement jsonEle logger.LogDebug("the ownedMemberElementId Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the RequirementConstraintMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -685,46 +553,6 @@ internal static IRequirementConstraintMembership DeSerialize(JsonElement jsonEle logger.LogDebug("the shortName Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the RequirementConstraintMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementDefinitionDeSerializer.cs index 63bc6365..c6770de7 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementDefinitionDeSerializer.cs @@ -151,15 +151,6 @@ internal static IRequirementDefinition DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the declaredName Json property was not found in the RequirementDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("declaredShortName"u8, out var declaredShortNameProperty)) - { - dtoInstance.DeclaredShortName = declaredShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the declaredShortName Json property was not found in the RequirementDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -180,26 +171,6 @@ internal static IRequirementDefinition DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the differencingType Json property was not found in the RequirementDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the RequirementDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementUsageDeSerializer.cs index c14e6a73..f5bfccd7 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementUsageDeSerializer.cs @@ -142,26 +142,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the assumedConstraint Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -182,30 +162,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the chainingFeature Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("constraintDefinition"u8, out var constraintDefinitionProperty)) - { - if (constraintDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.constraintDefinition = null; - } - else - { - if (constraintDefinitionProperty.TryGetProperty("@id"u8, out var constraintDefinitionExternalIdProperty)) - { - var propertyValue = constraintDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.constraintDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the constraintDefinition Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("crossFeature"u8, out var crossFeatureProperty)) { if (crossFeatureProperty.ValueKind == JsonValueKind.Null) @@ -239,35 +195,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the declaredName Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("declaredShortName"u8, out var declaredShortNameProperty)) - { - dtoInstance.DeclaredShortName = declaredShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the declaredShortName Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -288,26 +215,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the differencingType Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -520,30 +427,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the framedConcern Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -848,18 +731,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the isUnique Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2230,30 +2101,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the portionKind Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("predicate"u8, out var predicateProperty)) - { - if (predicateProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.predicate = null; - } - else - { - if (predicateProperty.TryGetProperty("@id"u8, out var predicateExternalIdProperty)) - { - var propertyValue = predicateExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.predicate = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the predicate Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -2432,26 +2279,6 @@ internal static IRequirementUsage DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the textualRepresentation Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the RequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementVerificationMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementVerificationMembershipDeSerializer.cs index 359dbd85..1f479ae4 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementVerificationMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/RequirementVerificationMembershipDeSerializer.cs @@ -199,88 +199,6 @@ internal static IRequirementVerificationMembership DeSerialize(JsonElement jsonE logger.LogDebug("the kind Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the RequirementVerificationMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the RequirementVerificationMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -310,31 +228,6 @@ internal static IRequirementVerificationMembership DeSerialize(JsonElement jsonE logger.LogDebug("the ownedAnnotation Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedConstraint"u8, out var ownedConstraintProperty)) - { - if (ownedConstraintProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedConstraint = Guid.Empty; - logger.LogDebug($"the RequirementVerificationMembership.ownedConstraint property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedConstraintProperty.TryGetProperty("@id"u8, out var ownedConstraintExternalIdProperty)) - { - var propertyValue = ownedConstraintExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedConstraint = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedConstraint Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedElement"u8, out var ownedElementProperty)) { foreach (var arrayItem in ownedElementProperty.EnumerateArray()) @@ -355,31 +248,6 @@ internal static IRequirementVerificationMembership DeSerialize(JsonElement jsonE logger.LogDebug("the ownedElement Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the RequirementVerificationMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -394,31 +262,6 @@ internal static IRequirementVerificationMembership DeSerialize(JsonElement jsonE logger.LogDebug("the ownedMemberElementId Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the RequirementVerificationMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -656,31 +499,6 @@ internal static IRequirementVerificationMembership DeSerialize(JsonElement jsonE logger.LogDebug("the qualifiedName Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("referencedConstraint"u8, out var referencedConstraintProperty)) - { - if (referencedConstraintProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.referencedConstraint = Guid.Empty; - logger.LogDebug($"the RequirementVerificationMembership.referencedConstraint property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (referencedConstraintProperty.TryGetProperty("@id"u8, out var referencedConstraintExternalIdProperty)) - { - var propertyValue = referencedConstraintExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.referencedConstraint = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the referencedConstraint Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) { foreach (var arrayItem in relatedElementProperty.EnumerateArray()) @@ -710,46 +528,6 @@ internal static IRequirementVerificationMembership DeSerialize(JsonElement jsonE logger.LogDebug("the shortName Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the RequirementVerificationMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ResultExpressionMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ResultExpressionMembershipDeSerializer.cs index 89706c57..5a8b579a 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ResultExpressionMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ResultExpressionMembershipDeSerializer.cs @@ -190,88 +190,6 @@ internal static IResultExpressionMembership DeSerialize(JsonElement jsonElement, logger.LogDebug("the isLibraryElement Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the ResultExpressionMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the ResultExpressionMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -321,31 +239,6 @@ internal static IResultExpressionMembership DeSerialize(JsonElement jsonElement, logger.LogDebug("the ownedElement Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the ResultExpressionMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -360,31 +253,6 @@ internal static IResultExpressionMembership DeSerialize(JsonElement jsonElement, logger.LogDebug("the ownedMemberElementId Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the ResultExpressionMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -651,46 +519,6 @@ internal static IResultExpressionMembership DeSerialize(JsonElement jsonElement, logger.LogDebug("the shortName Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the ResultExpressionMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ReturnParameterMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ReturnParameterMembershipDeSerializer.cs index fa8b3468..684a3382 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ReturnParameterMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ReturnParameterMembershipDeSerializer.cs @@ -190,88 +190,6 @@ internal static IReturnParameterMembership DeSerialize(JsonElement jsonElement, logger.LogDebug("the isLibraryElement Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the ReturnParameterMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the ReturnParameterMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -321,31 +239,6 @@ internal static IReturnParameterMembership DeSerialize(JsonElement jsonElement, logger.LogDebug("the ownedElement Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the ReturnParameterMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -360,31 +253,6 @@ internal static IReturnParameterMembership DeSerialize(JsonElement jsonElement, logger.LogDebug("the ownedMemberElementId Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the ReturnParameterMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -651,46 +519,6 @@ internal static IReturnParameterMembership DeSerialize(JsonElement jsonElement, logger.LogDebug("the shortName Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the ReturnParameterMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SatisfyRequirementUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SatisfyRequirementUsageDeSerializer.cs index eeac4bca..ecfa3fd1 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SatisfyRequirementUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SatisfyRequirementUsageDeSerializer.cs @@ -122,31 +122,6 @@ internal static ISatisfyRequirementUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the aliasIds Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("assertedConstraint"u8, out var assertedConstraintProperty)) - { - if (assertedConstraintProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.assertedConstraint = Guid.Empty; - logger.LogDebug($"the SatisfyRequirementUsage.assertedConstraint property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (assertedConstraintProperty.TryGetProperty("@id"u8, out var assertedConstraintExternalIdProperty)) - { - var propertyValue = assertedConstraintExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.assertedConstraint = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the assertedConstraint Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("assumedConstraint"u8, out var assumedConstraintProperty)) { foreach (var arrayItem in assumedConstraintProperty.EnumerateArray()) @@ -167,26 +142,6 @@ internal static ISatisfyRequirementUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the assumedConstraint Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -207,30 +162,6 @@ internal static ISatisfyRequirementUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the chainingFeature Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("constraintDefinition"u8, out var constraintDefinitionProperty)) - { - if (constraintDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.constraintDefinition = null; - } - else - { - if (constraintDefinitionProperty.TryGetProperty("@id"u8, out var constraintDefinitionExternalIdProperty)) - { - var propertyValue = constraintDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.constraintDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the constraintDefinition Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("crossFeature"u8, out var crossFeatureProperty)) { if (crossFeatureProperty.ValueKind == JsonValueKind.Null) @@ -264,35 +195,6 @@ internal static ISatisfyRequirementUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the declaredName Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("declaredShortName"u8, out var declaredShortNameProperty)) - { - dtoInstance.DeclaredShortName = declaredShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the declaredShortName Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -313,26 +215,6 @@ internal static ISatisfyRequirementUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the differencingType Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -545,30 +427,6 @@ internal static ISatisfyRequirementUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the framedConcern Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -885,18 +743,6 @@ internal static ISatisfyRequirementUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the isUnique Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2267,30 +2113,6 @@ internal static ISatisfyRequirementUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the portionKind Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("predicate"u8, out var predicateProperty)) - { - if (predicateProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.predicate = null; - } - else - { - if (predicateProperty.TryGetProperty("@id"u8, out var predicateExternalIdProperty)) - { - var propertyValue = predicateExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.predicate = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the predicate Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -2519,26 +2341,6 @@ internal static ISatisfyRequirementUsage DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the textualRepresentation Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the SatisfyRequirementUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SelectExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SelectExpressionDeSerializer.cs index 8aa22179..e45512bf 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SelectExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SelectExpressionDeSerializer.cs @@ -122,26 +122,6 @@ internal static ISelectExpression DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the argument Json property was not found in the SelectExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the SelectExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -224,26 +204,6 @@ internal static ISelectExpression DeSerialize(JsonElement jsonElement, Serializa logger.LogDebug("the differencingType Json property was not found in the SelectExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the SelectExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SendActionUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SendActionUsageDeSerializer.cs index e03647c3..6198c2cf 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SendActionUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SendActionUsageDeSerializer.cs @@ -122,26 +122,6 @@ internal static ISendActionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the aliasIds Json property was not found in the SendActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the SendActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static ISendActionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the declaredShortName Json property was not found in the SendActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the SendActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +204,6 @@ internal static ISendActionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the differencingType Json property was not found in the SendActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the SendActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -748,18 +688,6 @@ internal static ISendActionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the isUnique Json property was not found in the SendActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the SendActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1397,26 +1325,6 @@ internal static ISendActionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the nestedViewpoint Json property was not found in the SendActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the SendActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2241,26 +2149,6 @@ internal static ISendActionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the textualRepresentation Json property was not found in the SendActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the SendActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SpecializationDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SpecializationDeSerializer.cs index 67a6ce0a..0ac1e8b7 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SpecializationDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SpecializationDeSerializer.cs @@ -486,26 +486,6 @@ internal static ISpecialization DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the shortName Json property was not found in the Specialization: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Specialization: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("specific"u8, out var specificProperty)) { if (specificProperty.ValueKind == JsonValueKind.Null) @@ -531,26 +511,6 @@ internal static ISpecialization DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the specific Json property was not found in the Specialization: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Specialization: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StakeholderMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StakeholderMembershipDeSerializer.cs index 9e152946..4287c5b3 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StakeholderMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StakeholderMembershipDeSerializer.cs @@ -190,88 +190,6 @@ internal static IStakeholderMembership DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the isLibraryElement Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the StakeholderMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the StakeholderMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -321,31 +239,6 @@ internal static IStakeholderMembership DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the ownedElement Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the StakeholderMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -360,31 +253,6 @@ internal static IStakeholderMembership DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the ownedMemberElementId Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the StakeholderMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -394,31 +262,6 @@ internal static IStakeholderMembership DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the ownedMemberName Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberParameter"u8, out var ownedMemberParameterProperty)) - { - if (ownedMemberParameterProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberParameter = Guid.Empty; - logger.LogDebug($"the StakeholderMembership.ownedMemberParameter property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberParameterProperty.TryGetProperty("@id"u8, out var ownedMemberParameterExternalIdProperty)) - { - var propertyValue = ownedMemberParameterExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberParameter = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberParameter Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberShortName"u8, out var ownedMemberShortNameProperty)) { dtoInstance.ownedMemberShortName = ownedMemberShortNameProperty.GetString(); @@ -676,46 +519,6 @@ internal static IStakeholderMembership DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the shortName Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the StakeholderMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StateDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StateDefinitionDeSerializer.cs index b579ed0f..4a7315db 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StateDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StateDefinitionDeSerializer.cs @@ -160,26 +160,6 @@ internal static IStateDefinition DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the differencingType Json property was not found in the StateDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the StateDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StateSubactionMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StateSubactionMembershipDeSerializer.cs index eda93d91..ee0dda47 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StateSubactionMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StateSubactionMembershipDeSerializer.cs @@ -224,88 +224,6 @@ internal static IStateSubactionMembership DeSerialize(JsonElement jsonElement, S logger.LogDebug("the kind Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the StateSubactionMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the StateSubactionMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -355,31 +273,6 @@ internal static IStateSubactionMembership DeSerialize(JsonElement jsonElement, S logger.LogDebug("the ownedElement Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the StateSubactionMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -394,31 +287,6 @@ internal static IStateSubactionMembership DeSerialize(JsonElement jsonElement, S logger.LogDebug("the ownedMemberElementId Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the StateSubactionMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -660,46 +528,6 @@ internal static IStateSubactionMembership DeSerialize(JsonElement jsonElement, S logger.LogDebug("the shortName Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the StateSubactionMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StateUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StateUsageDeSerializer.cs index a33757d0..1be5e6c5 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StateUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StateUsageDeSerializer.cs @@ -85,26 +85,6 @@ internal static IStateUsage DeSerialize(JsonElement jsonElement, SerializationMo } } - if (jsonElement.TryGetProperty("actionDefinition"u8, out var actionDefinitionProperty)) - { - foreach (var arrayItem in actionDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var actionDefinitionExternalIdProperty)) - { - var propertyValue = actionDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.actionDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the actionDefinition Json property was not found in the StateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("aliasIds"u8, out var aliasIdsProperty)) { foreach (var arrayItem in aliasIdsProperty.EnumerateArray()) @@ -122,26 +102,6 @@ internal static IStateUsage DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the aliasIds Json property was not found in the StateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the StateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +164,6 @@ internal static IStateUsage DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the declaredShortName Json property was not found in the StateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the StateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +184,6 @@ internal static IStateUsage DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the differencingType Json property was not found in the StateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the StateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -832,18 +752,6 @@ internal static IStateUsage DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the isUnique Json property was not found in the StateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the StateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1481,26 +1389,6 @@ internal static IStateUsage DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the nestedViewpoint Json property was not found in the StateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the StateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2272,26 +2160,6 @@ internal static IStateUsage DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the textualRepresentation Json property was not found in the StateUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the StateUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StepDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StepDeSerializer.cs index 787c6f8a..5dc28564 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StepDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/StepDeSerializer.cs @@ -204,26 +204,6 @@ internal static IStep DeSerialize(JsonElement jsonElement, SerializationModeKind logger.LogDebug("the differencingType Json property was not found in the Step: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the Step: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SubclassificationDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SubclassificationDeSerializer.cs index d3b6c859..76f5ed37 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SubclassificationDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SubclassificationDeSerializer.cs @@ -154,31 +154,6 @@ internal static ISubclassification DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the elementId Json property was not found in the Subclassification: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("general"u8, out var generalProperty)) - { - if (generalProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.General = Guid.Empty; - logger.LogDebug($"the Subclassification.General property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (generalProperty.TryGetProperty("@id"u8, out var generalExternalIdProperty)) - { - var propertyValue = generalExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.General = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the general Json property was not found in the Subclassification: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isImplied"u8, out var isImpliedProperty)) { if (isImpliedProperty.ValueKind != JsonValueKind.Null) @@ -448,30 +423,6 @@ internal static ISubclassification DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the owningRelationship Json property was not found in the Subclassification: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningType"u8, out var owningTypeProperty)) - { - if (owningTypeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningType = null; - } - else - { - if (owningTypeProperty.TryGetProperty("@id"u8, out var owningTypeExternalIdProperty)) - { - var propertyValue = owningTypeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningType = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningType Json property was not found in the Subclassification: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -510,51 +461,6 @@ internal static ISubclassification DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the shortName Json property was not found in the Subclassification: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Subclassification: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("specific"u8, out var specificProperty)) - { - if (specificProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.Specific = Guid.Empty; - logger.LogDebug($"the Subclassification.Specific property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (specificProperty.TryGetProperty("@id"u8, out var specificExternalIdProperty)) - { - var propertyValue = specificExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Specific = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the specific Json property was not found in the Subclassification: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("subclassifier"u8, out var subclassifierProperty)) { if (subclassifierProperty.ValueKind == JsonValueKind.Null) @@ -605,26 +511,6 @@ internal static ISubclassification DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the superclassifier Json property was not found in the Subclassification: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Subclassification: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SubjectMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SubjectMembershipDeSerializer.cs index 28a41746..d4717f93 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SubjectMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SubjectMembershipDeSerializer.cs @@ -190,88 +190,6 @@ internal static ISubjectMembership DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the isLibraryElement Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the SubjectMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the SubjectMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -321,31 +239,6 @@ internal static ISubjectMembership DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the ownedElement Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the SubjectMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -360,31 +253,6 @@ internal static ISubjectMembership DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the ownedMemberElementId Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the SubjectMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -394,31 +262,6 @@ internal static ISubjectMembership DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the ownedMemberName Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberParameter"u8, out var ownedMemberParameterProperty)) - { - if (ownedMemberParameterProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberParameter = Guid.Empty; - logger.LogDebug($"the SubjectMembership.ownedMemberParameter property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberParameterProperty.TryGetProperty("@id"u8, out var ownedMemberParameterExternalIdProperty)) - { - var propertyValue = ownedMemberParameterExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberParameter = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberParameter Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberShortName"u8, out var ownedMemberShortNameProperty)) { dtoInstance.ownedMemberShortName = ownedMemberShortNameProperty.GetString(); @@ -676,46 +519,6 @@ internal static ISubjectMembership DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the shortName Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the SubjectMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SubsettingDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SubsettingDeSerializer.cs index 7fc7dda6..813d9ed8 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SubsettingDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SubsettingDeSerializer.cs @@ -154,31 +154,6 @@ internal static ISubsetting DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the elementId Json property was not found in the Subsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("general"u8, out var generalProperty)) - { - if (generalProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.General = Guid.Empty; - logger.LogDebug($"the Subsetting.General property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (generalProperty.TryGetProperty("@id"u8, out var generalExternalIdProperty)) - { - var propertyValue = generalExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.General = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the general Json property was not found in the Subsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isImplied"u8, out var isImpliedProperty)) { if (isImpliedProperty.ValueKind != JsonValueKind.Null) @@ -448,30 +423,6 @@ internal static ISubsetting DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the owningRelationship Json property was not found in the Subsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("owningType"u8, out var owningTypeProperty)) - { - if (owningTypeProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.owningType = null; - } - else - { - if (owningTypeProperty.TryGetProperty("@id"u8, out var owningTypeExternalIdProperty)) - { - var propertyValue = owningTypeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.owningType = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the owningType Json property was not found in the Subsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -510,51 +461,6 @@ internal static ISubsetting DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the shortName Json property was not found in the Subsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Subsetting: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("specific"u8, out var specificProperty)) - { - if (specificProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.Specific = Guid.Empty; - logger.LogDebug($"the Subsetting.Specific property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (specificProperty.TryGetProperty("@id"u8, out var specificExternalIdProperty)) - { - var propertyValue = specificExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Specific = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the specific Json property was not found in the Subsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("subsettedFeature"u8, out var subsettedFeatureProperty)) { if (subsettedFeatureProperty.ValueKind == JsonValueKind.Null) @@ -605,26 +511,6 @@ internal static ISubsetting DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the subsettingFeature Json property was not found in the Subsetting: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Subsetting: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionAsUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionAsUsageDeSerializer.cs index 53ad5600..6722dc40 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionAsUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionAsUsageDeSerializer.cs @@ -351,26 +351,6 @@ internal static ISuccessionAsUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the elementId Json property was not found in the SuccessionAsUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the SuccessionAsUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -748,18 +728,6 @@ internal static ISuccessionAsUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the isUnique Json property was not found in the SuccessionAsUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the SuccessionAsUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2134,26 +2102,6 @@ internal static ISuccessionAsUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the qualifiedName Json property was not found in the SuccessionAsUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the SuccessionAsUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -2183,26 +2131,6 @@ internal static ISuccessionAsUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the shortName Json property was not found in the SuccessionAsUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the SuccessionAsUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -2227,26 +2155,6 @@ internal static ISuccessionAsUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the sourceFeature Json property was not found in the SuccessionAsUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the SuccessionAsUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -2287,26 +2195,6 @@ internal static ISuccessionAsUsage DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the textualRepresentation Json property was not found in the SuccessionAsUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the SuccessionAsUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionDeSerializer.cs index ba0e122e..058b7899 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionDeSerializer.cs @@ -311,26 +311,6 @@ internal static ISuccession DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the elementId Json property was not found in the Succession: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the Succession: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -1470,26 +1450,6 @@ internal static ISuccession DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the qualifiedName Json property was not found in the Succession: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the Succession: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -1519,26 +1479,6 @@ internal static ISuccession DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the shortName Json property was not found in the Succession: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Succession: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -1563,26 +1503,6 @@ internal static ISuccession DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the sourceFeature Json property was not found in the Succession: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Succession: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -1623,26 +1543,6 @@ internal static ISuccession DeSerialize(JsonElement jsonElement, SerializationMo logger.LogDebug("the textualRepresentation Json property was not found in the Succession: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the Succession: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionFlowDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionFlowDeSerializer.cs index 2d157640..1a275b78 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionFlowDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionFlowDeSerializer.cs @@ -102,46 +102,6 @@ internal static ISuccessionFlow DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the aliasIds Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("association"u8, out var associationProperty)) - { - foreach (var arrayItem in associationProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var associationExternalIdProperty)) - { - var propertyValue = associationExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.association.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the association Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -268,26 +228,6 @@ internal static ISuccessionFlow DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the differencingType Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); @@ -331,26 +271,6 @@ internal static ISuccessionFlow DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the elementId Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -1594,26 +1514,6 @@ internal static ISuccessionFlow DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the qualifiedName Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -1643,26 +1543,6 @@ internal static ISuccessionFlow DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the shortName Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -1711,26 +1591,6 @@ internal static ISuccessionFlow DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the sourceOutputFeature Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -1795,26 +1655,6 @@ internal static ISuccessionFlow DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the textualRepresentation Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the SuccessionFlow: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionFlowUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionFlowUsageDeSerializer.cs index 15172562..ee81280b 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionFlowUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/SuccessionFlowUsageDeSerializer.cs @@ -85,26 +85,6 @@ internal static ISuccessionFlowUsage DeSerialize(JsonElement jsonElement, Serial } } - if (jsonElement.TryGetProperty("actionDefinition"u8, out var actionDefinitionProperty)) - { - foreach (var arrayItem in actionDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var actionDefinitionExternalIdProperty)) - { - var propertyValue = actionDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.actionDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the actionDefinition Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("aliasIds"u8, out var aliasIdsProperty)) { foreach (var arrayItem in aliasIdsProperty.EnumerateArray()) @@ -122,46 +102,6 @@ internal static ISuccessionFlowUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the aliasIds Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("association"u8, out var associationProperty)) - { - foreach (var arrayItem in associationProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var associationExternalIdProperty)) - { - var propertyValue = associationExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.association.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the association Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -268,26 +208,6 @@ internal static ISuccessionFlowUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the defaultFeaturingType Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -308,26 +228,6 @@ internal static ISuccessionFlowUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the differencingType Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -391,26 +291,6 @@ internal static ISuccessionFlowUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the elementId Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("endFeature"u8, out var endFeatureProperty)) - { - foreach (var arrayItem in endFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var endFeatureExternalIdProperty)) - { - var propertyValue = endFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.endFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the endFeature Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("endOwningType"u8, out var endOwningTypeProperty)) { if (endOwningTypeProperty.ValueKind == JsonValueKind.Null) @@ -664,26 +544,6 @@ internal static ISuccessionFlowUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the input Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("interaction"u8, out var interactionProperty)) - { - foreach (var arrayItem in interactionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var interactionExternalIdProperty)) - { - var propertyValue = interactionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.interaction.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the interaction Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("intersectingType"u8, out var intersectingTypeProperty)) { foreach (var arrayItem in intersectingTypeProperty.EnumerateArray()) @@ -884,18 +744,6 @@ internal static ISuccessionFlowUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the isUnique Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1533,26 +1381,6 @@ internal static ISuccessionFlowUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the nestedViewpoint Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2363,26 +2191,6 @@ internal static ISuccessionFlowUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the qualifiedName Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("relatedElement"u8, out var relatedElementProperty)) - { - foreach (var arrayItem in relatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var relatedElementExternalIdProperty)) - { - var propertyValue = relatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.relatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the relatedElement Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("relatedFeature"u8, out var relatedFeatureProperty)) { foreach (var arrayItem in relatedFeatureProperty.EnumerateArray()) @@ -2412,26 +2220,6 @@ internal static ISuccessionFlowUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the shortName Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("sourceFeature"u8, out var sourceFeatureProperty)) { if (sourceFeatureProperty.ValueKind == JsonValueKind.Null) @@ -2480,26 +2268,6 @@ internal static ISuccessionFlowUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the sourceOutputFeature Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("targetFeature"u8, out var targetFeatureProperty)) { foreach (var arrayItem in targetFeatureProperty.EnumerateArray()) @@ -2564,26 +2332,6 @@ internal static ISuccessionFlowUsage DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the textualRepresentation Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the SuccessionFlowUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TerminateActionUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TerminateActionUsageDeSerializer.cs index f01fbf7f..06fde9ed 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TerminateActionUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TerminateActionUsageDeSerializer.cs @@ -122,26 +122,6 @@ internal static ITerminateActionUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the aliasIds Json property was not found in the TerminateActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the TerminateActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static ITerminateActionUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the declaredShortName Json property was not found in the TerminateActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the TerminateActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +204,6 @@ internal static ITerminateActionUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the differencingType Json property was not found in the TerminateActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the TerminateActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -748,18 +688,6 @@ internal static ITerminateActionUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the isUnique Json property was not found in the TerminateActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the TerminateActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1397,26 +1325,6 @@ internal static ITerminateActionUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the nestedViewpoint Json property was not found in the TerminateActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the TerminateActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2192,26 +2100,6 @@ internal static ITerminateActionUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the textualRepresentation Json property was not found in the TerminateActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the TerminateActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TextualRepresentationDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TextualRepresentationDeSerializer.cs index c2e0f2eb..1925ce76 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TextualRepresentationDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TextualRepresentationDeSerializer.cs @@ -102,26 +102,6 @@ internal static ITextualRepresentation DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the aliasIds Json property was not found in the TextualRepresentation: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("annotatedElement"u8, out var annotatedElementProperty)) - { - foreach (var arrayItem in annotatedElementProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var annotatedElementExternalIdProperty)) - { - var propertyValue = annotatedElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.annotatedElement.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the annotatedElement Json property was not found in the TextualRepresentation: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("annotation"u8, out var annotationProperty)) { foreach (var arrayItem in annotationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TransitionFeatureMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TransitionFeatureMembershipDeSerializer.cs index f497f356..91f13556 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TransitionFeatureMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TransitionFeatureMembershipDeSerializer.cs @@ -199,88 +199,6 @@ internal static ITransitionFeatureMembership DeSerialize(JsonElement jsonElement logger.LogDebug("the kind Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the TransitionFeatureMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the TransitionFeatureMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -330,31 +248,6 @@ internal static ITransitionFeatureMembership DeSerialize(JsonElement jsonElement logger.LogDebug("the ownedElement Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the TransitionFeatureMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -369,31 +262,6 @@ internal static ITransitionFeatureMembership DeSerialize(JsonElement jsonElement logger.LogDebug("the ownedMemberElementId Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the TransitionFeatureMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -635,46 +503,6 @@ internal static ITransitionFeatureMembership DeSerialize(JsonElement jsonElement logger.LogDebug("the shortName Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the TransitionFeatureMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TransitionUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TransitionUsageDeSerializer.cs index b86ba495..e945b2d8 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TransitionUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TransitionUsageDeSerializer.cs @@ -122,26 +122,6 @@ internal static ITransitionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the aliasIds Json property was not found in the TransitionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the TransitionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -204,26 +184,6 @@ internal static ITransitionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the declaredShortName Json property was not found in the TransitionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the TransitionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -244,26 +204,6 @@ internal static ITransitionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the differencingType Json property was not found in the TransitionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the TransitionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -788,18 +728,6 @@ internal static ITransitionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the isUnique Json property was not found in the TransitionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the TransitionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1437,26 +1365,6 @@ internal static ITransitionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the nestedViewpoint Json property was not found in the TransitionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the TransitionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2303,26 +2211,6 @@ internal static ITransitionUsage DeSerialize(JsonElement jsonElement, Serializat logger.LogDebug("the triggerAction Json property was not found in the TransitionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the TransitionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TriggerInvocationExpressionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TriggerInvocationExpressionDeSerializer.cs index fef85e24..b2b2f174 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TriggerInvocationExpressionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TriggerInvocationExpressionDeSerializer.cs @@ -122,26 +122,6 @@ internal static ITriggerInvocationExpression DeSerialize(JsonElement jsonElement logger.LogDebug("the argument Json property was not found in the TriggerInvocationExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the TriggerInvocationExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -224,26 +204,6 @@ internal static ITriggerInvocationExpression DeSerialize(JsonElement jsonElement logger.LogDebug("the differencingType Json property was not found in the TriggerInvocationExpression: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the TriggerInvocationExpression: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("direction"u8, out var directionProperty)) { dtoInstance.Direction = FeatureDirectionKindDeSerializer.DeserializeNullable(directionProperty.GetString()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TypeFeaturingDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TypeFeaturingDeSerializer.cs index 4f244b7e..e30c12df 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TypeFeaturingDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/TypeFeaturingDeSerializer.cs @@ -511,46 +511,6 @@ internal static ITypeFeaturing DeSerialize(JsonElement jsonElement, Serializatio logger.LogDebug("the shortName Json property was not found in the TypeFeaturing: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the TypeFeaturing: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the TypeFeaturing: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UnioningDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UnioningDeSerializer.cs index dbabcc14..18ee981b 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UnioningDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UnioningDeSerializer.cs @@ -437,46 +437,6 @@ internal static IUnioning DeSerialize(JsonElement jsonElement, SerializationMode logger.LogDebug("the shortName Json property was not found in the Unioning: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the Unioning: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the Unioning: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UsageDeSerializer.cs index 0704bcbc..5deaec1c 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UsageDeSerializer.cs @@ -672,18 +672,6 @@ internal static IUsage DeSerialize(JsonElement jsonElement, SerializationModeKin logger.LogDebug("the isUnique Json property was not found in the Usage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the Usage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2043,26 +2031,6 @@ internal static IUsage DeSerialize(JsonElement jsonElement, SerializationModeKin logger.LogDebug("the textualRepresentation Json property was not found in the Usage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the Usage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UseCaseDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UseCaseDefinitionDeSerializer.cs index 700ca6d4..bab006b7 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UseCaseDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UseCaseDefinitionDeSerializer.cs @@ -200,26 +200,6 @@ internal static IUseCaseDefinition DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the differencingType Json property was not found in the UseCaseDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the UseCaseDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UseCaseUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UseCaseUsageDeSerializer.cs index 1d3665e6..f0bca3b3 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UseCaseUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/UseCaseUsageDeSerializer.cs @@ -85,26 +85,6 @@ internal static IUseCaseUsage DeSerialize(JsonElement jsonElement, Serialization } } - if (jsonElement.TryGetProperty("actionDefinition"u8, out var actionDefinitionProperty)) - { - foreach (var arrayItem in actionDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var actionDefinitionExternalIdProperty)) - { - var propertyValue = actionDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.actionDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the actionDefinition Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("actorParameter"u8, out var actorParameterProperty)) { foreach (var arrayItem in actorParameterProperty.EnumerateArray()) @@ -142,74 +122,6 @@ internal static IUseCaseUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the aliasIds Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("calculationDefinition"u8, out var calculationDefinitionProperty)) - { - if (calculationDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.calculationDefinition = null; - } - else - { - if (calculationDefinitionProperty.TryGetProperty("@id"u8, out var calculationDefinitionExternalIdProperty)) - { - var propertyValue = calculationDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.calculationDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the calculationDefinition Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("caseDefinition"u8, out var caseDefinitionProperty)) - { - if (caseDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.caseDefinition = null; - } - else - { - if (caseDefinitionProperty.TryGetProperty("@id"u8, out var caseDefinitionExternalIdProperty)) - { - var propertyValue = caseDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.caseDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the caseDefinition Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -272,26 +184,6 @@ internal static IUseCaseUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the declaredShortName Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -312,26 +204,6 @@ internal static IUseCaseUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the differencingType Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -524,30 +396,6 @@ internal static IUseCaseUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the featuringType Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -872,18 +720,6 @@ internal static IUseCaseUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the isUnique Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1545,26 +1381,6 @@ internal static IUseCaseUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the objectiveRequirement Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2366,26 +2182,6 @@ internal static IUseCaseUsage DeSerialize(JsonElement jsonElement, Serialization logger.LogDebug("the textualRepresentation Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the UseCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/VariantMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/VariantMembershipDeSerializer.cs index 171df3be..0d7119f0 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/VariantMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/VariantMembershipDeSerializer.cs @@ -190,54 +190,6 @@ internal static IVariantMembership DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the isLibraryElement Json property was not found in the VariantMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the VariantMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the VariantMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the VariantMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the VariantMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) { if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) @@ -263,15 +215,6 @@ internal static IVariantMembership DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the membershipOwningNamespace Json property was not found in the VariantMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the VariantMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -321,31 +264,6 @@ internal static IVariantMembership DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the ownedElement Json property was not found in the VariantMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the VariantMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the VariantMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -601,46 +519,6 @@ internal static IVariantMembership DeSerialize(JsonElement jsonElement, Serializ logger.LogDebug("the shortName Json property was not found in the VariantMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the VariantMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the VariantMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/VerificationCaseDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/VerificationCaseDefinitionDeSerializer.cs index 1bed35eb..b68a900c 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/VerificationCaseDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/VerificationCaseDefinitionDeSerializer.cs @@ -200,26 +200,6 @@ internal static IVerificationCaseDefinition DeSerialize(JsonElement jsonElement, logger.LogDebug("the differencingType Json property was not found in the VerificationCaseDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the VerificationCaseDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/VerificationCaseUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/VerificationCaseUsageDeSerializer.cs index ea87d72d..3a0d89f8 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/VerificationCaseUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/VerificationCaseUsageDeSerializer.cs @@ -85,26 +85,6 @@ internal static IVerificationCaseUsage DeSerialize(JsonElement jsonElement, Seri } } - if (jsonElement.TryGetProperty("actionDefinition"u8, out var actionDefinitionProperty)) - { - foreach (var arrayItem in actionDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var actionDefinitionExternalIdProperty)) - { - var propertyValue = actionDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.actionDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the actionDefinition Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("actorParameter"u8, out var actorParameterProperty)) { foreach (var arrayItem in actorParameterProperty.EnumerateArray()) @@ -142,50 +122,6 @@ internal static IVerificationCaseUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the aliasIds Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("calculationDefinition"u8, out var calculationDefinitionProperty)) - { - if (calculationDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.calculationDefinition = null; - } - else - { - if (calculationDefinitionProperty.TryGetProperty("@id"u8, out var calculationDefinitionExternalIdProperty)) - { - var propertyValue = calculationDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.calculationDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the calculationDefinition Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("caseDefinition"u8, out var caseDefinitionProperty)) { if (caseDefinitionProperty.ValueKind == JsonValueKind.Null) @@ -272,26 +208,6 @@ internal static IVerificationCaseUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the declaredShortName Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -312,26 +228,6 @@ internal static IVerificationCaseUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the differencingType Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -524,30 +420,6 @@ internal static IVerificationCaseUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the featuringType Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -852,18 +724,6 @@ internal static IVerificationCaseUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the isUnique Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1525,26 +1385,6 @@ internal static IVerificationCaseUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the objectiveRequirement Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2346,26 +2186,6 @@ internal static IVerificationCaseUsage DeSerialize(JsonElement jsonElement, Seri logger.LogDebug("the textualRepresentation Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the VerificationCaseUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewRenderingMembershipDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewRenderingMembershipDeSerializer.cs index e943f7ed..c29fdb66 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewRenderingMembershipDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewRenderingMembershipDeSerializer.cs @@ -190,88 +190,6 @@ internal static IViewRenderingMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the isLibraryElement Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("memberElement"u8, out var memberElementProperty)) - { - if (memberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.MemberElement = Guid.Empty; - logger.LogDebug($"the ViewRenderingMembership.MemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (memberElementProperty.TryGetProperty("@id"u8, out var memberElementExternalIdProperty)) - { - var propertyValue = memberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.MemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the memberElement Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberElementId"u8, out var memberElementIdProperty)) - { - var propertyValue = memberElementIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.memberElementId = propertyValue; - } - } - else - { - logger.LogDebug("the memberElementId Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberName"u8, out var memberNameProperty)) - { - dtoInstance.MemberName = memberNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberName Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("membershipOwningNamespace"u8, out var membershipOwningNamespaceProperty)) - { - if (membershipOwningNamespaceProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.membershipOwningNamespace = Guid.Empty; - logger.LogDebug($"the ViewRenderingMembership.membershipOwningNamespace property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (membershipOwningNamespaceProperty.TryGetProperty("@id"u8, out var membershipOwningNamespaceExternalIdProperty)) - { - var propertyValue = membershipOwningNamespaceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.membershipOwningNamespace = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the membershipOwningNamespace Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("memberShortName"u8, out var memberShortNameProperty)) - { - dtoInstance.MemberShortName = memberShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the memberShortName Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("name"u8, out var nameProperty)) { dtoInstance.name = nameProperty.GetString(); @@ -321,31 +239,6 @@ internal static IViewRenderingMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the ownedElement Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberElement"u8, out var ownedMemberElementProperty)) - { - if (ownedMemberElementProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberElement = Guid.Empty; - logger.LogDebug($"the ViewRenderingMembership.ownedMemberElement property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberElementProperty.TryGetProperty("@id"u8, out var ownedMemberElementExternalIdProperty)) - { - var propertyValue = ownedMemberElementExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberElement = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberElement Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberElementId"u8, out var ownedMemberElementIdProperty)) { var propertyValue = ownedMemberElementIdProperty.GetString(); @@ -360,31 +253,6 @@ internal static IViewRenderingMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the ownedMemberElementId Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("ownedMemberFeature"u8, out var ownedMemberFeatureProperty)) - { - if (ownedMemberFeatureProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.ownedMemberFeature = Guid.Empty; - logger.LogDebug($"the ViewRenderingMembership.ownedMemberFeature property was not found in the Json. The value is set to Guid.Empty"); - } - else - { - if (ownedMemberFeatureProperty.TryGetProperty("@id"u8, out var ownedMemberFeatureExternalIdProperty)) - { - var propertyValue = ownedMemberFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.ownedMemberFeature = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the ownedMemberFeature Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("ownedMemberName"u8, out var ownedMemberNameProperty)) { dtoInstance.ownedMemberName = ownedMemberNameProperty.GetString(); @@ -676,46 +544,6 @@ internal static IViewRenderingMembership DeSerialize(JsonElement jsonElement, Se logger.LogDebug("the shortName Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("source"u8, out var sourceProperty)) - { - foreach (var arrayItem in sourceProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var sourceExternalIdProperty)) - { - var propertyValue = sourceExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Source.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the source Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("target"u8, out var targetProperty)) - { - foreach (var arrayItem in targetProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var targetExternalIdProperty)) - { - var propertyValue = targetExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.Target.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the target Json property was not found in the ViewRenderingMembership: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("textualRepresentation"u8, out var textualRepresentationProperty)) { foreach (var arrayItem in textualRepresentationProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewUsageDeSerializer.cs index 1a2c9957..5e4a2407 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewUsageDeSerializer.cs @@ -164,26 +164,6 @@ internal static IViewUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the declaredShortName Json property was not found in the ViewUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the ViewUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -728,18 +708,6 @@ internal static IViewUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the isUnique Json property was not found in the ViewUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the ViewUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2101,26 +2069,6 @@ internal static IViewUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the owningUsage Json property was not found in the ViewUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("partDefinition"u8, out var partDefinitionProperty)) - { - foreach (var arrayItem in partDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var partDefinitionExternalIdProperty)) - { - var propertyValue = partDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.partDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the partDefinition Json property was not found in the ViewUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("portionKind"u8, out var portionKindProperty)) { dtoInstance.PortionKind = PortionKindDeSerializer.DeserializeNullable(portionKindProperty.GetString()); @@ -2188,26 +2136,6 @@ internal static IViewUsage DeSerialize(JsonElement jsonElement, SerializationMod logger.LogDebug("the textualRepresentation Json property was not found in the ViewUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the ViewUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewpointDefinitionDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewpointDefinitionDeSerializer.cs index 03291984..3035dfbb 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewpointDefinitionDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewpointDefinitionDeSerializer.cs @@ -151,15 +151,6 @@ internal static IViewpointDefinition DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the declaredName Json property was not found in the ViewpointDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("declaredShortName"u8, out var declaredShortNameProperty)) - { - dtoInstance.DeclaredShortName = declaredShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the declaredShortName Json property was not found in the ViewpointDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -180,26 +171,6 @@ internal static IViewpointDefinition DeSerialize(JsonElement jsonElement, Serial logger.LogDebug("the differencingType Json property was not found in the ViewpointDefinition: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the ViewpointDefinition: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewpointUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewpointUsageDeSerializer.cs index edbd8f2f..3a92734e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewpointUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/ViewpointUsageDeSerializer.cs @@ -142,26 +142,6 @@ internal static IViewpointUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the assumedConstraint Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("chainingFeature"u8, out var chainingFeatureProperty)) { foreach (var arrayItem in chainingFeatureProperty.EnumerateArray()) @@ -182,30 +162,6 @@ internal static IViewpointUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the chainingFeature Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("constraintDefinition"u8, out var constraintDefinitionProperty)) - { - if (constraintDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.constraintDefinition = null; - } - else - { - if (constraintDefinitionProperty.TryGetProperty("@id"u8, out var constraintDefinitionExternalIdProperty)) - { - var propertyValue = constraintDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.constraintDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the constraintDefinition Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("crossFeature"u8, out var crossFeatureProperty)) { if (crossFeatureProperty.ValueKind == JsonValueKind.Null) @@ -239,35 +195,6 @@ internal static IViewpointUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the declaredName Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("declaredShortName"u8, out var declaredShortNameProperty)) - { - dtoInstance.DeclaredShortName = declaredShortNameProperty.GetString(); - } - else - { - logger.LogDebug("the declaredShortName Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); - } - - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -288,26 +215,6 @@ internal static IViewpointUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the differencingType Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -520,30 +427,6 @@ internal static IViewpointUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the framedConcern Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("function"u8, out var functionProperty)) - { - if (functionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.function = null; - } - else - { - if (functionProperty.TryGetProperty("@id"u8, out var functionExternalIdProperty)) - { - var propertyValue = functionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.function = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the function Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("importedMembership"u8, out var importedMembershipProperty)) { foreach (var arrayItem in importedMembershipProperty.EnumerateArray()) @@ -848,18 +731,6 @@ internal static IViewpointUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the isUnique Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -2230,30 +2101,6 @@ internal static IViewpointUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the portionKind Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("predicate"u8, out var predicateProperty)) - { - if (predicateProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.predicate = null; - } - else - { - if (predicateProperty.TryGetProperty("@id"u8, out var predicateExternalIdProperty)) - { - var propertyValue = predicateExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.predicate = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the predicate Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("qualifiedName"u8, out var qualifiedNameProperty)) { dtoInstance.qualifiedName = qualifiedNameProperty.GetString(); @@ -2292,30 +2139,6 @@ internal static IViewpointUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the requiredConstraint Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("requirementDefinition"u8, out var requirementDefinitionProperty)) - { - if (requirementDefinitionProperty.ValueKind == JsonValueKind.Null) - { - dtoInstance.requirementDefinition = null; - } - else - { - if (requirementDefinitionProperty.TryGetProperty("@id"u8, out var requirementDefinitionExternalIdProperty)) - { - var propertyValue = requirementDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.requirementDefinition = Guid.Parse(propertyValue); - } - } - } - } - else - { - logger.LogDebug("the requirementDefinition Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("result"u8, out var resultProperty)) { if (resultProperty.ValueKind == JsonValueKind.Null) @@ -2432,26 +2255,6 @@ internal static IViewpointUsage DeSerialize(JsonElement jsonElement, Serializati logger.LogDebug("the textualRepresentation Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the ViewpointUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/WhileLoopActionUsageDeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/WhileLoopActionUsageDeSerializer.cs index a0752a0f..1d076c81 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/WhileLoopActionUsageDeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenDeSerializer/WhileLoopActionUsageDeSerializer.cs @@ -122,26 +122,6 @@ internal static IWhileLoopActionUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the aliasIds Json property was not found in the WhileLoopActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("behavior"u8, out var behaviorProperty)) - { - foreach (var arrayItem in behaviorProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var behaviorExternalIdProperty)) - { - var propertyValue = behaviorExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.behavior.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the behavior Json property was not found in the WhileLoopActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("bodyAction"u8, out var bodyActionProperty)) { if (bodyActionProperty.ValueKind == JsonValueKind.Null) @@ -229,26 +209,6 @@ internal static IWhileLoopActionUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the declaredShortName Json property was not found in the WhileLoopActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("definition"u8, out var definitionProperty)) - { - foreach (var arrayItem in definitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var definitionExternalIdProperty)) - { - var propertyValue = definitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.definition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the definition Json property was not found in the WhileLoopActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("differencingType"u8, out var differencingTypeProperty)) { foreach (var arrayItem in differencingTypeProperty.EnumerateArray()) @@ -269,26 +229,6 @@ internal static IWhileLoopActionUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the differencingType Json property was not found in the WhileLoopActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("directedFeature"u8, out var directedFeatureProperty)) - { - foreach (var arrayItem in directedFeatureProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var directedFeatureExternalIdProperty)) - { - var propertyValue = directedFeatureExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.directedFeature.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the directedFeature Json property was not found in the WhileLoopActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("directedUsage"u8, out var directedUsageProperty)) { foreach (var arrayItem in directedUsageProperty.EnumerateArray()) @@ -773,18 +713,6 @@ internal static IWhileLoopActionUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the isUnique Json property was not found in the WhileLoopActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("isVariable"u8, out var isVariableProperty)) - { - if (isVariableProperty.ValueKind != JsonValueKind.Null) - { - dtoInstance.IsVariable = isVariableProperty.GetBoolean(); - } - } - else - { - logger.LogDebug("the isVariable Json property was not found in the WhileLoopActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("isVariation"u8, out var isVariationProperty)) { if (isVariationProperty.ValueKind != JsonValueKind.Null) @@ -1422,26 +1350,6 @@ internal static IWhileLoopActionUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the nestedViewpoint Json property was not found in the WhileLoopActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("occurrenceDefinition"u8, out var occurrenceDefinitionProperty)) - { - foreach (var arrayItem in occurrenceDefinitionProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var occurrenceDefinitionExternalIdProperty)) - { - var propertyValue = occurrenceDefinitionExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.occurrenceDefinition.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the occurrenceDefinition Json property was not found in the WhileLoopActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("output"u8, out var outputProperty)) { foreach (var arrayItem in outputProperty.EnumerateArray()) @@ -2193,26 +2101,6 @@ internal static IWhileLoopActionUsage DeSerialize(JsonElement jsonElement, Seria logger.LogDebug("the textualRepresentation Json property was not found in the WhileLoopActionUsage: { Id }", dtoInstance.Id); } - if (jsonElement.TryGetProperty("type"u8, out var typeProperty)) - { - foreach (var arrayItem in typeProperty.EnumerateArray()) - { - if (arrayItem.TryGetProperty("@id"u8, out var typeExternalIdProperty)) - { - var propertyValue = typeExternalIdProperty.GetString(); - - if (propertyValue != null) - { - dtoInstance.type.Add(Guid.Parse(propertyValue)); - } - } - } - } - else - { - logger.LogDebug("the type Json property was not found in the WhileLoopActionUsage: { Id }", dtoInstance.Id); - } - if (jsonElement.TryGetProperty("unioningType"u8, out var unioningTypeProperty)) { foreach (var arrayItem in unioningTypeProperty.EnumerateArray()) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AcceptActionUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AcceptActionUsageSerializer.cs index a8749e83..f648a754 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AcceptActionUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AcceptActionUsageSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAcceptActionUsage iAcc writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iAcceptActionUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iAcceptActionUsage.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAcceptActionUsage iAcc writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iAcceptActionUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iAcceptActionUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iAcceptActionUsage.differencingType) @@ -179,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAcceptActionUsage iAcc writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iAcceptActionUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iAcceptActionUsage.directedUsage) @@ -413,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAcceptActionUsage iAcc writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iAcceptActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iAcceptActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iAcceptActionUsage.IsVariation); @@ -787,18 +748,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAcceptActionUsage iAcc writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iAcceptActionUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iAcceptActionUsage.output) @@ -1280,18 +1229,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAcceptActionUsage iAcc writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iAcceptActionUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iAcceptActionUsage.unioningType) @@ -1415,9 +1352,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IAcceptActionUsage i writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iAcceptActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iAcceptActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iAcceptActionUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ActionDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ActionDefinitionSerializer.cs index 8e56c9e4..221da9f6 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ActionDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ActionDefinitionSerializer.cs @@ -129,18 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IActionDefinition iActi writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iActionDefinition.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iActionDefinition.directedUsage) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ActionUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ActionUsageSerializer.cs index 0e6897c9..27fc0394 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ActionUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ActionUsageSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IActionUsage iActionUsa writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iActionUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iActionUsage.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IActionUsage iActionUsa writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iActionUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iActionUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iActionUsage.differencingType) @@ -179,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IActionUsage iActionUsa writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iActionUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iActionUsage.directedUsage) @@ -413,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IActionUsage iActionUsa writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iActionUsage.IsVariation); @@ -787,18 +748,6 @@ private static void SerializeAsJsonWithDerivedProperties(IActionUsage iActionUsa writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iActionUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iActionUsage.output) @@ -1246,18 +1195,6 @@ private static void SerializeAsJsonWithDerivedProperties(IActionUsage iActionUsa writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iActionUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iActionUsage.unioningType) @@ -1381,9 +1318,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IActionUsage iAction writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iActionUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ActorMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ActorMembershipSerializer.cs index f25a12ed..fad73c2f 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ActorMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ActorMembershipSerializer.cs @@ -129,27 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IActorMembership iActor writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iActorMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iActorMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iActorMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iActorMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iActorMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iActorMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iActorMembership.name); @@ -183,30 +162,12 @@ private static void SerializeAsJsonWithDerivedProperties(IActorMembership iActor writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iActorMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iActorMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iActorMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iActorMembership.ownedMemberName); - writer.WritePropertyName("ownedMemberParameter"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iActorMembership.ownedMemberParameter); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberShortName"u8); writer.WriteStringValue(iActorMembership.ownedMemberShortName); @@ -328,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IActorMembership iActor writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iActorMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iActorMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iActorMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iActorMembership.textualRepresentation) @@ -404,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IActorMembership iAc writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iActorMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iActorMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iActorMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iActorMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iActorMembership.OwnedRelatedElement) @@ -468,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IActorMembership iAc writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iActorMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iActorMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iActorMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AllocationDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AllocationDefinitionSerializer.cs index 2d3ab961..7cc8b57f 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AllocationDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AllocationDefinitionSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationDefinition i writer.WriteEndArray(); - writer.WriteStartArray("associationEnd"u8); - - foreach (var item in iAllocationDefinition.associationEnd) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("connectionEnd"u8); foreach (var item in iAllocationDefinition.connectionEnd) @@ -192,18 +180,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationDefinition i writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iAllocationDefinition.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iAllocationDefinition.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("feature"u8); foreach (var item in iAllocationDefinition.feature) @@ -968,18 +944,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationDefinition i writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iAllocationDefinition.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iAllocationDefinition.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedType"u8); foreach (var item in iAllocationDefinition.relatedType) @@ -995,18 +959,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationDefinition i writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iAllocationDefinition.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iAllocationDefinition.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceType"u8); if (iAllocationDefinition.sourceType.HasValue) @@ -1021,18 +973,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationDefinition i writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iAllocationDefinition.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetType"u8); foreach (var item in iAllocationDefinition.targetType) @@ -1206,30 +1146,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IAllocationDefinitio writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iAllocationDefinition.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iAllocationDefinition.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AllocationUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AllocationUsageSerializer.cs index 37021417..11b72e5d 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AllocationUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AllocationUsageSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationUsage iAlloc writer.WriteEndArray(); - writer.WriteStartArray("association"u8); - - foreach (var item in iAllocationUsage.association) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iAllocationUsage.chainingFeature) @@ -135,18 +123,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationUsage iAlloc writer.WriteEndArray(); - writer.WriteStartArray("connectionDefinition"u8); - - foreach (var item in iAllocationUsage.connectionDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("connectorEnd"u8); foreach (var item in iAllocationUsage.connectorEnd) @@ -193,18 +169,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationUsage iAlloc writer.WriteNullValue(); } - writer.WriteStartArray("definition"u8); - - foreach (var item in iAllocationUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iAllocationUsage.differencingType) @@ -267,18 +231,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationUsage iAlloc writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iAllocationUsage.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iAllocationUsage.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iAllocationUsage.endOwningType.HasValue) @@ -454,9 +406,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationUsage iAlloc writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iAllocationUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iAllocationUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iAllocationUsage.IsVariation); @@ -1310,18 +1259,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationUsage iAlloc writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iAllocationUsage.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iAllocationUsage.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iAllocationUsage.relatedFeature) @@ -1337,18 +1274,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationUsage iAlloc writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iAllocationUsage.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iAllocationUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iAllocationUsage.sourceFeature.HasValue) @@ -1363,18 +1288,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationUsage iAlloc writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iAllocationUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iAllocationUsage.targetFeature) @@ -1399,18 +1312,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAllocationUsage iAlloc writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iAllocationUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iAllocationUsage.unioningType) @@ -1537,9 +1438,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IAllocationUsage iAl writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iAllocationUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iAllocationUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iAllocationUsage.IsVariation); @@ -1606,30 +1504,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IAllocationUsage iAl writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iAllocationUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iAllocationUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AnalysisCaseDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AnalysisCaseDefinitionSerializer.cs index f742dd3f..87947cec 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AnalysisCaseDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AnalysisCaseDefinitionSerializer.cs @@ -153,18 +153,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAnalysisCaseDefinition writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iAnalysisCaseDefinition.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iAnalysisCaseDefinition.directedUsage) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AnalysisCaseUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AnalysisCaseUsageSerializer.cs index 012b2702..2a4434a0 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AnalysisCaseUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AnalysisCaseUsageSerializer.cs @@ -90,18 +90,6 @@ internal static void Serialize(object obj, Utf8JsonWriter writer, SerializationM /// private static void SerializeAsJsonWithDerivedProperties(IAnalysisCaseUsage iAnalysisCaseUsage, Utf8JsonWriter writer) { - writer.WriteStartArray("actionDefinition"u8); - - foreach (var item in iAnalysisCaseUsage.actionDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("actorParameter"u8); foreach (var item in iAnalysisCaseUsage.actorParameter) @@ -137,46 +125,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAnalysisCaseUsage iAna writer.WriteNullValue(); } - writer.WriteStartArray("behavior"u8); - - foreach (var item in iAnalysisCaseUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("calculationDefinition"u8); - - if (iAnalysisCaseUsage.calculationDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iAnalysisCaseUsage.calculationDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - - writer.WritePropertyName("caseDefinition"u8); - - if (iAnalysisCaseUsage.caseDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iAnalysisCaseUsage.caseDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iAnalysisCaseUsage.chainingFeature) @@ -209,18 +157,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAnalysisCaseUsage iAna writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iAnalysisCaseUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iAnalysisCaseUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iAnalysisCaseUsage.differencingType) @@ -233,18 +169,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAnalysisCaseUsage iAna writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iAnalysisCaseUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iAnalysisCaseUsage.directedUsage) @@ -351,20 +275,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAnalysisCaseUsage iAna writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iAnalysisCaseUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iAnalysisCaseUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iAnalysisCaseUsage.importedMembership) @@ -484,9 +394,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAnalysisCaseUsage iAna writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iAnalysisCaseUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iAnalysisCaseUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iAnalysisCaseUsage.IsVariation); @@ -872,18 +779,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAnalysisCaseUsage iAna writer.WriteNullValue(); } - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iAnalysisCaseUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iAnalysisCaseUsage.output) @@ -1357,18 +1252,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAnalysisCaseUsage iAna writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iAnalysisCaseUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iAnalysisCaseUsage.unioningType) @@ -1492,9 +1375,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IAnalysisCaseUsage i writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iAnalysisCaseUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iAnalysisCaseUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iAnalysisCaseUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AnnotationSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AnnotationSerializer.cs index 87e741a6..280cc158 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AnnotationSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AnnotationSerializer.cs @@ -322,30 +322,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAnnotation iAnnotation writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iAnnotation.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iAnnotation.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iAnnotation.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iAnnotation.textualRepresentation) @@ -453,30 +429,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IAnnotation iAnnotat writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iAnnotation.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iAnnotation.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssertConstraintUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssertConstraintUsageSerializer.cs index ced1492c..b150b6f5 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssertConstraintUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssertConstraintUsageSerializer.cs @@ -105,18 +105,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssertConstraintUsage writer.WriteStringValue(iAssertConstraintUsage.assertedConstraint); writer.WriteEndObject(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iAssertConstraintUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iAssertConstraintUsage.chainingFeature) @@ -163,18 +151,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssertConstraintUsage writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iAssertConstraintUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iAssertConstraintUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iAssertConstraintUsage.differencingType) @@ -187,18 +163,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssertConstraintUsage writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iAssertConstraintUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iAssertConstraintUsage.directedUsage) @@ -305,20 +269,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssertConstraintUsage writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iAssertConstraintUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iAssertConstraintUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iAssertConstraintUsage.importedMembership) @@ -441,9 +391,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssertConstraintUsage writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iAssertConstraintUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iAssertConstraintUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iAssertConstraintUsage.IsVariation); @@ -1256,20 +1203,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssertConstraintUsage writer.WriteNullValue(); } - writer.WritePropertyName("predicate"u8); - - if (iAssertConstraintUsage.predicate.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iAssertConstraintUsage.predicate.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iAssertConstraintUsage.qualifiedName); @@ -1294,18 +1227,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssertConstraintUsage writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iAssertConstraintUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iAssertConstraintUsage.unioningType) @@ -1432,9 +1353,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IAssertConstraintUsa writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iAssertConstraintUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iAssertConstraintUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iAssertConstraintUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssignmentActionUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssignmentActionUsageSerializer.cs index 934f374a..22787040 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssignmentActionUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssignmentActionUsageSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssignmentActionUsage writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iAssignmentActionUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iAssignmentActionUsage.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssignmentActionUsage writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iAssignmentActionUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iAssignmentActionUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iAssignmentActionUsage.differencingType) @@ -179,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssignmentActionUsage writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iAssignmentActionUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iAssignmentActionUsage.directedUsage) @@ -413,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssignmentActionUsage writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iAssignmentActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iAssignmentActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iAssignmentActionUsage.IsVariation); @@ -787,18 +748,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssignmentActionUsage writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iAssignmentActionUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iAssignmentActionUsage.output) @@ -1266,18 +1215,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssignmentActionUsage writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iAssignmentActionUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iAssignmentActionUsage.unioningType) @@ -1415,9 +1352,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IAssignmentActionUsa writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iAssignmentActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iAssignmentActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iAssignmentActionUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssociationSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssociationSerializer.cs index e44811c1..58b929d5 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssociationSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssociationSerializer.cs @@ -156,18 +156,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssociation iAssociati writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iAssociation.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iAssociation.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("feature"u8); foreach (var item in iAssociation.feature) @@ -602,18 +590,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssociation iAssociati writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iAssociation.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iAssociation.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedType"u8); foreach (var item in iAssociation.relatedType) @@ -629,18 +605,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssociation iAssociati writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iAssociation.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iAssociation.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceType"u8); if (iAssociation.sourceType.HasValue) @@ -655,18 +619,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssociation iAssociati writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iAssociation.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetType"u8); foreach (var item in iAssociation.targetType) @@ -798,30 +750,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IAssociation iAssoci writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iAssociation.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iAssociation.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssociationStructureSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssociationStructureSerializer.cs index e8567da8..129f1acc 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssociationStructureSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AssociationStructureSerializer.cs @@ -156,18 +156,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssociationStructure i writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iAssociationStructure.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iAssociationStructure.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("feature"u8); foreach (var item in iAssociationStructure.feature) @@ -602,18 +590,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssociationStructure i writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iAssociationStructure.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iAssociationStructure.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedType"u8); foreach (var item in iAssociationStructure.relatedType) @@ -629,18 +605,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssociationStructure i writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iAssociationStructure.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iAssociationStructure.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceType"u8); if (iAssociationStructure.sourceType.HasValue) @@ -655,18 +619,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAssociationStructure i writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iAssociationStructure.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetType"u8); foreach (var item in iAssociationStructure.targetType) @@ -798,30 +750,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IAssociationStructur writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iAssociationStructure.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iAssociationStructure.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AttributeUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AttributeUsageSerializer.cs index 96b58296..9ee6c0a9 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AttributeUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/AttributeUsageSerializer.cs @@ -143,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAttributeUsage iAttrib writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iAttributeUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iAttributeUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iAttributeUsage.differencingType) @@ -384,9 +372,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAttributeUsage iAttrib writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iAttributeUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iAttributeUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iAttributeUsage.IsVariation); @@ -1182,18 +1167,6 @@ private static void SerializeAsJsonWithDerivedProperties(IAttributeUsage iAttrib writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iAttributeUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iAttributeUsage.unioningType) @@ -1314,9 +1287,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IAttributeUsage iAtt writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iAttributeUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iAttributeUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iAttributeUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BehaviorSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BehaviorSerializer.cs index e58666eb..f955de77 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BehaviorSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BehaviorSerializer.cs @@ -117,18 +117,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBehavior iBehavior, Ut writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iBehavior.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("documentation"u8); foreach (var item in iBehavior.documentation) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BindingConnectorAsUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BindingConnectorAsUsageSerializer.cs index 5e253705..1386ef0c 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BindingConnectorAsUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BindingConnectorAsUsageSerializer.cs @@ -243,18 +243,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBindingConnectorAsUsag writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iBindingConnectorAsUsage.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iBindingConnectorAsUsage.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iBindingConnectorAsUsage.endOwningType.HasValue) @@ -413,9 +401,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBindingConnectorAsUsag writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iBindingConnectorAsUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iBindingConnectorAsUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iBindingConnectorAsUsage.IsVariation); @@ -1222,18 +1207,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBindingConnectorAsUsag writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iBindingConnectorAsUsage.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iBindingConnectorAsUsage.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iBindingConnectorAsUsage.relatedFeature) @@ -1249,18 +1222,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBindingConnectorAsUsag writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iBindingConnectorAsUsage.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iBindingConnectorAsUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iBindingConnectorAsUsage.sourceFeature.HasValue) @@ -1275,18 +1236,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBindingConnectorAsUsag writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iBindingConnectorAsUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iBindingConnectorAsUsage.targetFeature) @@ -1311,18 +1260,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBindingConnectorAsUsag writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iBindingConnectorAsUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iBindingConnectorAsUsage.unioningType) @@ -1446,9 +1383,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IBindingConnectorAsU writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iBindingConnectorAsUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iBindingConnectorAsUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iBindingConnectorAsUsage.IsVariation); @@ -1504,30 +1438,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IBindingConnectorAsU writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iBindingConnectorAsUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iBindingConnectorAsUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BindingConnectorSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BindingConnectorSerializer.cs index 03d73ea5..cf5ba5a6 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BindingConnectorSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BindingConnectorSerializer.cs @@ -219,18 +219,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBindingConnector iBind writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iBindingConnector.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iBindingConnector.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iBindingConnector.endOwningType.HasValue) @@ -837,18 +825,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBindingConnector iBind writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iBindingConnector.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iBindingConnector.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iBindingConnector.relatedFeature) @@ -864,18 +840,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBindingConnector iBind writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iBindingConnector.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iBindingConnector.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iBindingConnector.sourceFeature.HasValue) @@ -890,18 +854,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBindingConnector iBind writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iBindingConnector.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iBindingConnector.targetFeature) @@ -926,18 +878,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBindingConnector iBind writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iBindingConnector.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iBindingConnector.unioningType) @@ -1080,30 +1020,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IBindingConnector iB writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iBindingConnector.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iBindingConnector.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BooleanExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BooleanExpressionSerializer.cs index 12e369a9..c9f8d255 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BooleanExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/BooleanExpressionSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBooleanExpression iBoo writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iBooleanExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iBooleanExpression.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBooleanExpression iBoo writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iBooleanExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iBooleanExpression.Direction.HasValue) @@ -261,20 +237,6 @@ private static void SerializeAsJsonWithDerivedProperties(IBooleanExpression iBoo writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iBooleanExpression.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iBooleanExpression.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iBooleanExpression.importedMembership) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CalculationDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CalculationDefinitionSerializer.cs index 5ca4fbc1..f675895d 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CalculationDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CalculationDefinitionSerializer.cs @@ -141,18 +141,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICalculationDefinition writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iCalculationDefinition.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iCalculationDefinition.directedUsage) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CalculationUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CalculationUsageSerializer.cs index d02ff2e1..02e9b53d 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CalculationUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CalculationUsageSerializer.cs @@ -90,18 +90,6 @@ internal static void Serialize(object obj, Utf8JsonWriter writer, SerializationM /// private static void SerializeAsJsonWithDerivedProperties(ICalculationUsage iCalculationUsage, Utf8JsonWriter writer) { - writer.WriteStartArray("actionDefinition"u8); - - foreach (var item in iCalculationUsage.actionDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("aliasIds"u8); foreach (var item in iCalculationUsage.AliasIds) @@ -111,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICalculationUsage iCalc writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iCalculationUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("calculationDefinition"u8); if (iCalculationUsage.calculationDefinition.HasValue) @@ -169,18 +145,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICalculationUsage iCalc writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iCalculationUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iCalculationUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iCalculationUsage.differencingType) @@ -193,18 +157,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICalculationUsage iCalc writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iCalculationUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iCalculationUsage.directedUsage) @@ -311,20 +263,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICalculationUsage iCalc writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iCalculationUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCalculationUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iCalculationUsage.importedMembership) @@ -444,9 +382,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICalculationUsage iCalc writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iCalculationUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iCalculationUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iCalculationUsage.IsVariation); @@ -818,18 +753,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICalculationUsage iCalc writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iCalculationUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iCalculationUsage.output) @@ -1283,18 +1206,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICalculationUsage iCalc writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iCalculationUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iCalculationUsage.unioningType) @@ -1418,9 +1329,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ICalculationUsage iC writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iCalculationUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iCalculationUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iCalculationUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CaseDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CaseDefinitionSerializer.cs index 4990f287..78c23aca 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CaseDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CaseDefinitionSerializer.cs @@ -153,18 +153,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICaseDefinition iCaseDe writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iCaseDefinition.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iCaseDefinition.directedUsage) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CaseUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CaseUsageSerializer.cs index 765d122c..0421fb3e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CaseUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CaseUsageSerializer.cs @@ -90,18 +90,6 @@ internal static void Serialize(object obj, Utf8JsonWriter writer, SerializationM /// private static void SerializeAsJsonWithDerivedProperties(ICaseUsage iCaseUsage, Utf8JsonWriter writer) { - writer.WriteStartArray("actionDefinition"u8); - - foreach (var item in iCaseUsage.actionDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("actorParameter"u8); foreach (var item in iCaseUsage.actorParameter) @@ -123,32 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICaseUsage iCaseUsage, writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iCaseUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("calculationDefinition"u8); - - if (iCaseUsage.calculationDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCaseUsage.calculationDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("caseDefinition"u8); if (iCaseUsage.caseDefinition.HasValue) @@ -195,18 +157,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICaseUsage iCaseUsage, writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iCaseUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iCaseUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iCaseUsage.differencingType) @@ -219,18 +169,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICaseUsage iCaseUsage, writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iCaseUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iCaseUsage.directedUsage) @@ -337,20 +275,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICaseUsage iCaseUsage, writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iCaseUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCaseUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iCaseUsage.importedMembership) @@ -470,9 +394,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICaseUsage iCaseUsage, writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iCaseUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iCaseUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iCaseUsage.IsVariation); @@ -858,18 +779,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICaseUsage iCaseUsage, writer.WriteNullValue(); } - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iCaseUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iCaseUsage.output) @@ -1329,18 +1238,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICaseUsage iCaseUsage, writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iCaseUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iCaseUsage.unioningType) @@ -1464,9 +1361,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ICaseUsage iCaseUsag writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iCaseUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iCaseUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iCaseUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CollectExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CollectExpressionSerializer.cs index 9c70e056..19d587cf 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CollectExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CollectExpressionSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICollectExpression iCol writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iCollectExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iCollectExpression.chainingFeature) @@ -167,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICollectExpression iCol writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iCollectExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iCollectExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConcernDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConcernDefinitionSerializer.cs index 7d9eb8a3..52630725 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConcernDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConcernDefinitionSerializer.cs @@ -126,9 +126,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConcernDefinition iCon writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iConcernDefinition.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iConcernDefinition.DeclaredShortName); - writer.WriteStartArray("differencingType"u8); foreach (var item in iConcernDefinition.differencingType) @@ -141,18 +138,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConcernDefinition iCon writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iConcernDefinition.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iConcernDefinition.directedUsage) @@ -1114,9 +1099,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IConcernDefinition i writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iConcernDefinition.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iConcernDefinition.DeclaredShortName); - writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iConcernDefinition.ElementId); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConcernUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConcernUsageSerializer.cs index d1fbe9be..b8e2a006 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConcernUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConcernUsageSerializer.cs @@ -123,18 +123,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConcernUsage iConcernU writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iConcernUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iConcernUsage.chainingFeature) @@ -161,20 +149,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConcernUsage iConcernU writer.WriteNullValue(); } - writer.WritePropertyName("constraintDefinition"u8); - - if (iConcernUsage.constraintDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConcernUsage.constraintDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("crossFeature"u8); if (iConcernUsage.crossFeature.HasValue) @@ -192,21 +166,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConcernUsage iConcernU writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iConcernUsage.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iConcernUsage.DeclaredShortName); - - writer.WriteStartArray("definition"u8); - - foreach (var item in iConcernUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iConcernUsage.differencingType) @@ -219,18 +178,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConcernUsage iConcernU writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iConcernUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iConcernUsage.directedUsage) @@ -349,20 +296,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConcernUsage iConcernU writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iConcernUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConcernUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iConcernUsage.importedMembership) @@ -482,9 +415,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConcernUsage iConcernU writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iConcernUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iConcernUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iConcernUsage.IsVariation); @@ -1297,20 +1227,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConcernUsage iConcernU writer.WriteNullValue(); } - writer.WritePropertyName("predicate"u8); - - if (iConcernUsage.predicate.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConcernUsage.predicate.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iConcernUsage.qualifiedName); @@ -1329,20 +1245,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConcernUsage iConcernU writer.WriteEndArray(); - writer.WritePropertyName("requirementDefinition"u8); - - if (iConcernUsage.requirementDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConcernUsage.requirementDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("result"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -1391,18 +1293,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConcernUsage iConcernU writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iConcernUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iConcernUsage.unioningType) @@ -1476,9 +1366,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IConcernUsage iConce writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iConcernUsage.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iConcernUsage.DeclaredShortName); - writer.WritePropertyName("direction"u8); if (iConcernUsage.Direction.HasValue) @@ -1526,9 +1413,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IConcernUsage iConce writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iConcernUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iConcernUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iConcernUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConjugatedPortDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConjugatedPortDefinitionSerializer.cs index 9d0308bb..be51892a 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConjugatedPortDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConjugatedPortDefinitionSerializer.cs @@ -442,20 +442,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConjugatedPortDefiniti writer.WriteEndArray(); - writer.WritePropertyName("ownedConjugator"u8); - - if (iConjugatedPortDefinition.ownedConjugator.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConjugatedPortDefinition.ownedConjugator.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("ownedConnection"u8); foreach (var item in iConjugatedPortDefinition.ownedConnection) @@ -898,20 +884,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConjugatedPortDefiniti writer.WriteNullValue(); } - writer.WritePropertyName("owningNamespace"u8); - - if (iConjugatedPortDefinition.owningNamespace.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConjugatedPortDefinition.owningNamespace.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("owningRelationship"u8); if (iConjugatedPortDefinition.OwningRelationship.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConjugatedPortTypingSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConjugatedPortTypingSerializer.cs index 0c4c135f..0540fa4c 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConjugatedPortTypingSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConjugatedPortTypingSerializer.cs @@ -126,12 +126,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConjugatedPortTyping i writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iConjugatedPortTyping.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConjugatedPortTyping.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iConjugatedPortTyping.IsImplied); @@ -276,20 +270,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConjugatedPortTyping i writer.WriteNullValue(); } - writer.WritePropertyName("owningType"u8); - - if (iConjugatedPortTyping.owningType.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConjugatedPortTyping.owningType.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("portDefinition"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -314,36 +294,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConjugatedPortTyping i writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iConjugatedPortTyping.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iConjugatedPortTyping.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConjugatedPortTyping.Specific); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iConjugatedPortTyping.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iConjugatedPortTyping.textualRepresentation) @@ -356,12 +306,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConjugatedPortTyping i writer.WriteEndArray(); - writer.WritePropertyName("type"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConjugatedPortTyping.Type); - writer.WriteEndObject(); - writer.WritePropertyName("typedFeature"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -405,12 +349,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IConjugatedPortTypin writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iConjugatedPortTyping.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConjugatedPortTyping.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iConjugatedPortTyping.IsImplied); @@ -469,42 +407,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IConjugatedPortTypin writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iConjugatedPortTyping.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConjugatedPortTyping.Specific); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iConjugatedPortTyping.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("type"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConjugatedPortTyping.Type); - writer.WriteEndObject(); - writer.WritePropertyName("typedFeature"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConjugationSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConjugationSerializer.cs index 42c98f24..6048338c 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConjugationSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConjugationSerializer.cs @@ -294,30 +294,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConjugation iConjugati writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iConjugation.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iConjugation.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iConjugation.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iConjugation.textualRepresentation) @@ -431,30 +407,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IConjugation iConjug writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iConjugation.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iConjugation.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConnectionDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConnectionDefinitionSerializer.cs index 45b9881b..4a5fe947 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConnectionDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConnectionDefinitionSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionDefinition i writer.WriteEndArray(); - writer.WriteStartArray("associationEnd"u8); - - foreach (var item in iConnectionDefinition.associationEnd) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("connectionEnd"u8); foreach (var item in iConnectionDefinition.connectionEnd) @@ -180,18 +168,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionDefinition i writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iConnectionDefinition.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iConnectionDefinition.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("feature"u8); foreach (var item in iConnectionDefinition.feature) @@ -956,18 +932,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionDefinition i writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iConnectionDefinition.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iConnectionDefinition.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedType"u8); foreach (var item in iConnectionDefinition.relatedType) @@ -983,18 +947,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionDefinition i writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iConnectionDefinition.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iConnectionDefinition.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceType"u8); if (iConnectionDefinition.sourceType.HasValue) @@ -1009,18 +961,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionDefinition i writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iConnectionDefinition.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetType"u8); foreach (var item in iConnectionDefinition.targetType) @@ -1194,30 +1134,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IConnectionDefinitio writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iConnectionDefinition.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iConnectionDefinition.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConnectionUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConnectionUsageSerializer.cs index 50abf1f1..0e4217b9 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConnectionUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConnectionUsageSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionUsage iConne writer.WriteEndArray(); - writer.WriteStartArray("association"u8); - - foreach (var item in iConnectionUsage.association) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iConnectionUsage.chainingFeature) @@ -181,18 +169,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionUsage iConne writer.WriteNullValue(); } - writer.WriteStartArray("definition"u8); - - foreach (var item in iConnectionUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iConnectionUsage.differencingType) @@ -255,18 +231,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionUsage iConne writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iConnectionUsage.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iConnectionUsage.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iConnectionUsage.endOwningType.HasValue) @@ -442,9 +406,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionUsage iConne writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iConnectionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iConnectionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iConnectionUsage.IsVariation); @@ -1298,18 +1259,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionUsage iConne writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iConnectionUsage.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iConnectionUsage.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iConnectionUsage.relatedFeature) @@ -1325,18 +1274,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionUsage iConne writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iConnectionUsage.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iConnectionUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iConnectionUsage.sourceFeature.HasValue) @@ -1351,18 +1288,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionUsage iConne writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iConnectionUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iConnectionUsage.targetFeature) @@ -1387,18 +1312,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnectionUsage iConne writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iConnectionUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iConnectionUsage.unioningType) @@ -1525,9 +1438,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IConnectionUsage iCo writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iConnectionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iConnectionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iConnectionUsage.IsVariation); @@ -1594,30 +1504,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IConnectionUsage iCo writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iConnectionUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iConnectionUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConnectorSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConnectorSerializer.cs index 8b5bfd56..1958cdb9 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConnectorSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConnectorSerializer.cs @@ -219,18 +219,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnector iConnector, writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iConnector.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iConnector.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iConnector.endOwningType.HasValue) @@ -837,18 +825,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnector iConnector, writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iConnector.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iConnector.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iConnector.relatedFeature) @@ -864,18 +840,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnector iConnector, writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iConnector.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iConnector.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iConnector.sourceFeature.HasValue) @@ -890,18 +854,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnector iConnector, writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iConnector.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iConnector.targetFeature) @@ -926,18 +878,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConnector iConnector, writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iConnector.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iConnector.unioningType) @@ -1080,30 +1020,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IConnector iConnecto writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iConnector.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iConnector.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConstraintDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConstraintDefinitionSerializer.cs index 734cfa69..f88cfa78 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConstraintDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConstraintDefinitionSerializer.cs @@ -117,18 +117,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConstraintDefinition i writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iConstraintDefinition.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iConstraintDefinition.directedUsage) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConstraintUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConstraintUsageSerializer.cs index adc7cc8d..6d927e69 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConstraintUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConstraintUsageSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConstraintUsage iConst writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iConstraintUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iConstraintUsage.chainingFeature) @@ -157,18 +145,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConstraintUsage iConst writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iConstraintUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iConstraintUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iConstraintUsage.differencingType) @@ -181,18 +157,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConstraintUsage iConst writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iConstraintUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iConstraintUsage.directedUsage) @@ -299,20 +263,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConstraintUsage iConst writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iConstraintUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConstraintUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iConstraintUsage.importedMembership) @@ -432,9 +382,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConstraintUsage iConst writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iConstraintUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iConstraintUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iConstraintUsage.IsVariation); @@ -1247,20 +1194,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConstraintUsage iConst writer.WriteNullValue(); } - writer.WritePropertyName("predicate"u8); - - if (iConstraintUsage.predicate.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iConstraintUsage.predicate.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iConstraintUsage.qualifiedName); @@ -1285,18 +1218,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConstraintUsage iConst writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iConstraintUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iConstraintUsage.unioningType) @@ -1420,9 +1341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IConstraintUsage iCo writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iConstraintUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iConstraintUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iConstraintUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConstructorExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConstructorExpressionSerializer.cs index 2eb7f9b6..85fa1ac0 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConstructorExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ConstructorExpressionSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConstructorExpression writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iConstructorExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iConstructorExpression.chainingFeature) @@ -167,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IConstructorExpression writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iConstructorExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iConstructorExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CrossSubsettingSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CrossSubsettingSerializer.cs index a1bb15fa..22e3f7c1 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CrossSubsettingSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/CrossSubsettingSerializer.cs @@ -132,12 +132,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICrossSubsetting iCross writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iCrossSubsetting.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCrossSubsetting.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iCrossSubsetting.IsImplied); @@ -212,20 +206,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICrossSubsetting iCross writer.WriteNullValue(); } - writer.WritePropertyName("owningFeature"u8); - - if (iCrossSubsetting.owningFeature.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCrossSubsetting.owningFeature.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("owningMembership"u8); if (iCrossSubsetting.owningMembership.HasValue) @@ -282,20 +262,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICrossSubsetting iCross writer.WriteNullValue(); } - writer.WritePropertyName("owningType"u8); - - if (iCrossSubsetting.owningType.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCrossSubsetting.owningType.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iCrossSubsetting.qualifiedName); @@ -314,48 +280,6 @@ private static void SerializeAsJsonWithDerivedProperties(ICrossSubsetting iCross writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iCrossSubsetting.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iCrossSubsetting.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCrossSubsetting.Specific); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettedFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCrossSubsetting.SubsettedFeature); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettingFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCrossSubsetting.SubsettingFeature); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iCrossSubsetting.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iCrossSubsetting.textualRepresentation) @@ -405,12 +329,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ICrossSubsetting iCr writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iCrossSubsetting.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCrossSubsetting.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iCrossSubsetting.IsImplied); @@ -469,48 +387,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ICrossSubsetting iCr writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iCrossSubsetting.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCrossSubsetting.Specific); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettedFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCrossSubsetting.SubsettedFeature); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettingFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iCrossSubsetting.SubsettingFeature); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iCrossSubsetting.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DecisionNodeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DecisionNodeSerializer.cs index 991935cc..327589ef 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DecisionNodeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DecisionNodeSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDecisionNode iDecision writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iDecisionNode.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iDecisionNode.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDecisionNode iDecision writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iDecisionNode.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iDecisionNode.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iDecisionNode.differencingType) @@ -179,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDecisionNode iDecision writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iDecisionNode.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iDecisionNode.directedUsage) @@ -413,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDecisionNode iDecision writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iDecisionNode.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iDecisionNode.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iDecisionNode.IsVariation); @@ -787,18 +748,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDecisionNode iDecision writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iDecisionNode.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iDecisionNode.output) @@ -1246,18 +1195,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDecisionNode iDecision writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iDecisionNode.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iDecisionNode.unioningType) @@ -1381,9 +1318,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IDecisionNode iDecis writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iDecisionNode.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iDecisionNode.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iDecisionNode.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DependencySerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DependencySerializer.cs index 1a08b3d3..3106b838 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DependencySerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DependencySerializer.cs @@ -280,18 +280,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDependency iDependency writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iDependency.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iDependency.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("supplier"u8); foreach (var item in iDependency.Supplier) @@ -304,18 +292,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDependency iDependency writer.WriteEndArray(); - writer.WriteStartArray("target"u8); - - foreach (var item in iDependency.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iDependency.textualRepresentation) @@ -429,18 +405,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IDependency iDepende writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iDependency.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("supplier"u8); foreach (var item in iDependency.Supplier) @@ -453,18 +417,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IDependency iDepende writer.WriteEndArray(); - writer.WriteStartArray("target"u8); - - foreach (var item in iDependency.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DifferencingSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DifferencingSerializer.cs index 7817b067..b6a67767 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DifferencingSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DifferencingSerializer.cs @@ -274,30 +274,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDifferencing iDifferen writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iDifferencing.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iDifferencing.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iDifferencing.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iDifferencing.textualRepresentation) @@ -411,30 +387,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IDifferencing iDiffe writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iDifferencing.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iDifferencing.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DisjoiningSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DisjoiningSerializer.cs index b5430030..b6d60047 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DisjoiningSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DisjoiningSerializer.cs @@ -288,30 +288,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDisjoining iDisjoining writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iDisjoining.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iDisjoining.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iDisjoining.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iDisjoining.textualRepresentation) @@ -425,30 +401,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IDisjoining iDisjoin writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iDisjoining.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iDisjoining.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("typeDisjoined"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DocumentationSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DocumentationSerializer.cs index 7f80fd83..f9b96f30 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DocumentationSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/DocumentationSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IDocumentation iDocumen writer.WriteEndArray(); - writer.WriteStartArray("annotatedElement"u8); - - foreach (var item in iDocumentation.annotatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("annotation"u8); foreach (var item in iDocumentation.annotation) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ElementFilterMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ElementFilterMembershipSerializer.cs index 8c0f4738..1be196b0 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ElementFilterMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ElementFilterMembershipSerializer.cs @@ -135,27 +135,12 @@ private static void SerializeAsJsonWithDerivedProperties(IElementFilterMembershi writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iElementFilterMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iElementFilterMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iElementFilterMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iElementFilterMembership.MemberName); - writer.WritePropertyName("membershipOwningNamespace"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); writer.WriteStringValue(iElementFilterMembership.membershipOwningNamespace); writer.WriteEndObject(); - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iElementFilterMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iElementFilterMembership.name); @@ -183,12 +168,6 @@ private static void SerializeAsJsonWithDerivedProperties(IElementFilterMembershi writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iElementFilterMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iElementFilterMembership.ownedMemberElementId); @@ -310,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IElementFilterMembershi writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iElementFilterMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iElementFilterMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iElementFilterMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iElementFilterMembership.textualRepresentation) @@ -386,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IElementFilterMember writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iElementFilterMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iElementFilterMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iElementFilterMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iElementFilterMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iElementFilterMembership.OwnedRelatedElement) @@ -450,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IElementFilterMember writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iElementFilterMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iElementFilterMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iElementFilterMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EndFeatureMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EndFeatureMembershipSerializer.cs index a202f425..b6c6302c 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EndFeatureMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EndFeatureMembershipSerializer.cs @@ -129,27 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IEndFeatureMembership i writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iEndFeatureMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iEndFeatureMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iEndFeatureMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iEndFeatureMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iEndFeatureMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iEndFeatureMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iEndFeatureMembership.name); @@ -177,12 +156,6 @@ private static void SerializeAsJsonWithDerivedProperties(IEndFeatureMembership i writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iEndFeatureMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iEndFeatureMembership.ownedMemberElementId); @@ -316,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IEndFeatureMembership i writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iEndFeatureMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iEndFeatureMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iEndFeatureMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iEndFeatureMembership.textualRepresentation) @@ -392,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IEndFeatureMembershi writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iEndFeatureMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iEndFeatureMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iEndFeatureMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iEndFeatureMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iEndFeatureMembership.OwnedRelatedElement) @@ -456,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IEndFeatureMembershi writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iEndFeatureMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iEndFeatureMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iEndFeatureMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EnumerationDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EnumerationDefinitionSerializer.cs index 3aacc384..3de4215f 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EnumerationDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EnumerationDefinitionSerializer.cs @@ -951,18 +951,6 @@ private static void SerializeAsJsonWithDerivedProperties(IEnumerationDefinition writer.WriteEndArray(); - writer.WriteStartArray("variant"u8); - - foreach (var item in iEnumerationDefinition.variant) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("variantMembership"u8); foreach (var item in iEnumerationDefinition.variantMembership) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EnumerationUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EnumerationUsageSerializer.cs index 1092b629..e7be5006 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EnumerationUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EnumerationUsageSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IEnumerationUsage iEnum writer.WriteEndArray(); - writer.WriteStartArray("attributeDefinition"u8); - - foreach (var item in iEnumerationUsage.attributeDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iEnumerationUsage.chainingFeature) @@ -143,18 +131,6 @@ private static void SerializeAsJsonWithDerivedProperties(IEnumerationUsage iEnum writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iEnumerationUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iEnumerationUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iEnumerationUsage.differencingType) @@ -390,9 +366,6 @@ private static void SerializeAsJsonWithDerivedProperties(IEnumerationUsage iEnum writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iEnumerationUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iEnumerationUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iEnumerationUsage.IsVariation); @@ -1188,18 +1161,6 @@ private static void SerializeAsJsonWithDerivedProperties(IEnumerationUsage iEnum writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iEnumerationUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iEnumerationUsage.unioningType) @@ -1320,9 +1281,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IEnumerationUsage iE writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iEnumerationUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iEnumerationUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iEnumerationUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EventOccurrenceUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EventOccurrenceUsageSerializer.cs index 4a4eac4b..4fa2e204 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EventOccurrenceUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/EventOccurrenceUsageSerializer.cs @@ -131,18 +131,6 @@ private static void SerializeAsJsonWithDerivedProperties(IEventOccurrenceUsage i writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iEventOccurrenceUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iEventOccurrenceUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iEventOccurrenceUsage.differencingType) @@ -395,9 +383,6 @@ private static void SerializeAsJsonWithDerivedProperties(IEventOccurrenceUsage i writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iEventOccurrenceUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iEventOccurrenceUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iEventOccurrenceUsage.IsVariation); @@ -1216,18 +1201,6 @@ private static void SerializeAsJsonWithDerivedProperties(IEventOccurrenceUsage i writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iEventOccurrenceUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iEventOccurrenceUsage.unioningType) @@ -1351,9 +1324,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IEventOccurrenceUsag writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iEventOccurrenceUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iEventOccurrenceUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iEventOccurrenceUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ExhibitStateUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ExhibitStateUsageSerializer.cs index a45d265f..1c0f12f0 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ExhibitStateUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ExhibitStateUsageSerializer.cs @@ -90,18 +90,6 @@ internal static void Serialize(object obj, Utf8JsonWriter writer, SerializationM /// private static void SerializeAsJsonWithDerivedProperties(IExhibitStateUsage iExhibitStateUsage, Utf8JsonWriter writer) { - writer.WriteStartArray("actionDefinition"u8); - - foreach (var item in iExhibitStateUsage.actionDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("aliasIds"u8); foreach (var item in iExhibitStateUsage.AliasIds) @@ -111,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IExhibitStateUsage iExh writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iExhibitStateUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iExhibitStateUsage.chainingFeature) @@ -155,18 +131,6 @@ private static void SerializeAsJsonWithDerivedProperties(IExhibitStateUsage iExh writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iExhibitStateUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iExhibitStateUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iExhibitStateUsage.differencingType) @@ -179,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IExhibitStateUsage iExh writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iExhibitStateUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iExhibitStateUsage.directedUsage) @@ -283,12 +235,6 @@ private static void SerializeAsJsonWithDerivedProperties(IExhibitStateUsage iExh writer.WriteNullValue(); } - writer.WritePropertyName("eventOccurrence"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iExhibitStateUsage.eventOccurrence); - writer.WriteEndObject(); - writer.WritePropertyName("exhibitedState"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -470,9 +416,6 @@ private static void SerializeAsJsonWithDerivedProperties(IExhibitStateUsage iExh writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iExhibitStateUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iExhibitStateUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iExhibitStateUsage.IsVariation); @@ -844,18 +787,6 @@ private static void SerializeAsJsonWithDerivedProperties(IExhibitStateUsage iExh writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iExhibitStateUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iExhibitStateUsage.output) @@ -1274,12 +1205,6 @@ private static void SerializeAsJsonWithDerivedProperties(IExhibitStateUsage iExh writer.WriteEndArray(); - writer.WritePropertyName("performedAction"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iExhibitStateUsage.performedAction); - writer.WriteEndObject(); - writer.WritePropertyName("portionKind"u8); if (iExhibitStateUsage.PortionKind.HasValue) @@ -1321,18 +1246,6 @@ private static void SerializeAsJsonWithDerivedProperties(IExhibitStateUsage iExh writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iExhibitStateUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iExhibitStateUsage.unioningType) @@ -1459,9 +1372,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IExhibitStateUsage i writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iExhibitStateUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iExhibitStateUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iExhibitStateUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ExpressionSerializer.cs index e01b64ff..9a3c195f 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ExpressionSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IExpression iExpression writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iExpression.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IExpression iExpression writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureChainExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureChainExpressionSerializer.cs index 6969680c..94b567a1 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureChainExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureChainExpressionSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureChainExpression writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iFeatureChainExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iFeatureChainExpression.chainingFeature) @@ -167,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureChainExpression writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iFeatureChainExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iFeatureChainExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureChainingSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureChainingSerializer.cs index 9f6ac232..fc28688e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureChainingSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureChainingSerializer.cs @@ -280,30 +280,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureChaining iFeatu writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iFeatureChaining.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iFeatureChaining.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFeatureChaining.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iFeatureChaining.textualRepresentation) @@ -411,30 +387,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFeatureChaining iFe writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iFeatureChaining.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFeatureChaining.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureInvertingSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureInvertingSerializer.cs index 52287485..8a843957 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureInvertingSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureInvertingSerializer.cs @@ -294,30 +294,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureInverting iFeat writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iFeatureInverting.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iFeatureInverting.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFeatureInverting.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iFeatureInverting.textualRepresentation) @@ -431,30 +407,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFeatureInverting iF writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iFeatureInverting.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFeatureInverting.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureMembershipSerializer.cs index 220065d6..8f8139e7 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureMembershipSerializer.cs @@ -129,27 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureMembership iFea writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iFeatureMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iFeatureMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iFeatureMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iFeatureMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iFeatureMembership.name); @@ -177,12 +156,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureMembership iFea writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iFeatureMembership.ownedMemberElementId); @@ -316,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureMembership iFea writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iFeatureMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iFeatureMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFeatureMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iFeatureMembership.textualRepresentation) @@ -392,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFeatureMembership i writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iFeatureMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iFeatureMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iFeatureMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iFeatureMembership.OwnedRelatedElement) @@ -456,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFeatureMembership i writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iFeatureMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFeatureMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iFeatureMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureReferenceExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureReferenceExpressionSerializer.cs index 983a1fd2..a9da01de 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureReferenceExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureReferenceExpressionSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureReferenceExpres writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iFeatureReferenceExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iFeatureReferenceExpression.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureReferenceExpres writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iFeatureReferenceExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iFeatureReferenceExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureTypingSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureTypingSerializer.cs index 873c27be..118362af 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureTypingSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureTypingSerializer.cs @@ -120,12 +120,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureTyping iFeature writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iFeatureTyping.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureTyping.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iFeatureTyping.IsImplied); @@ -270,20 +264,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureTyping iFeature writer.WriteNullValue(); } - writer.WritePropertyName("owningType"u8); - - if (iFeatureTyping.owningType.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureTyping.owningType.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iFeatureTyping.qualifiedName); @@ -302,36 +282,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureTyping iFeature writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iFeatureTyping.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iFeatureTyping.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureTyping.Specific); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFeatureTyping.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iFeatureTyping.textualRepresentation) @@ -387,12 +337,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFeatureTyping iFeat writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iFeatureTyping.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureTyping.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iFeatureTyping.IsImplied); @@ -451,36 +395,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFeatureTyping iFeat writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iFeatureTyping.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureTyping.Specific); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFeatureTyping.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("type"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureValueSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureValueSerializer.cs index a04266da..921568b1 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureValueSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FeatureValueSerializer.cs @@ -141,27 +141,12 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureValue iFeatureV writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iFeatureValue.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureValue.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iFeatureValue.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iFeatureValue.MemberName); - writer.WritePropertyName("membershipOwningNamespace"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); writer.WriteStringValue(iFeatureValue.membershipOwningNamespace); writer.WriteEndObject(); - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iFeatureValue.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iFeatureValue.name); @@ -189,12 +174,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureValue iFeatureV writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureValue.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iFeatureValue.ownedMemberElementId); @@ -316,30 +295,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFeatureValue iFeatureV writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iFeatureValue.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iFeatureValue.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFeatureValue.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iFeatureValue.textualRepresentation) @@ -404,18 +359,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFeatureValue iFeatu writer.WritePropertyName("isInitial"u8); writer.WriteBooleanValue(iFeatureValue.IsInitial); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFeatureValue.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iFeatureValue.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iFeatureValue.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iFeatureValue.OwnedRelatedElement) @@ -468,30 +411,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFeatureValue iFeatu writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iFeatureValue.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFeatureValue.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iFeatureValue.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FlowDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FlowDefinitionSerializer.cs index 10afd769..faf42f18 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FlowDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FlowDefinitionSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowDefinition iFlowDe writer.WriteEndArray(); - writer.WriteStartArray("associationEnd"u8); - - foreach (var item in iFlowDefinition.associationEnd) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iFlowDefinition.DeclaredName); @@ -141,18 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowDefinition iFlowDe writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iFlowDefinition.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iFlowDefinition.directedUsage) @@ -180,18 +156,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowDefinition iFlowDe writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iFlowDefinition.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iFlowDefinition.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("feature"u8); foreach (var item in iFlowDefinition.feature) @@ -980,18 +944,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowDefinition iFlowDe writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iFlowDefinition.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iFlowDefinition.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedType"u8); foreach (var item in iFlowDefinition.relatedType) @@ -1007,18 +959,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowDefinition iFlowDe writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iFlowDefinition.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iFlowDefinition.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceType"u8); if (iFlowDefinition.sourceType.HasValue) @@ -1045,18 +985,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowDefinition iFlowDe writer.WriteEndArray(); - writer.WriteStartArray("target"u8); - - foreach (var item in iFlowDefinition.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetType"u8); foreach (var item in iFlowDefinition.targetType) @@ -1230,30 +1158,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFlowDefinition iFlo writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iFlowDefinition.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFlowDefinition.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FlowSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FlowSerializer.cs index 348f2753..37d58e0a 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FlowSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FlowSerializer.cs @@ -99,30 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WriteEndArray(); - writer.WriteStartArray("association"u8); - - foreach (var item in iFlow.association) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("behavior"u8); - - foreach (var item in iFlow.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iFlow.chainingFeature) @@ -193,18 +169,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iFlow.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iFlow.Direction.HasValue) @@ -231,18 +195,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iFlow.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iFlow.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iFlow.endOwningType.HasValue) @@ -911,18 +863,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iFlow.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iFlow.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iFlow.relatedFeature) @@ -938,18 +878,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iFlow.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iFlow.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iFlow.sourceFeature.HasValue) @@ -978,18 +906,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iFlow.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iFlow.targetFeature) @@ -1028,18 +944,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlow iFlow, Utf8JsonWr writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iFlow.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iFlow.unioningType) @@ -1182,30 +1086,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFlow iFlow, Utf8Jso writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iFlow.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFlow.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FlowUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FlowUsageSerializer.cs index 5fc2e8b7..1fdc628d 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FlowUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FlowUsageSerializer.cs @@ -90,18 +90,6 @@ internal static void Serialize(object obj, Utf8JsonWriter writer, SerializationM /// private static void SerializeAsJsonWithDerivedProperties(IFlowUsage iFlowUsage, Utf8JsonWriter writer) { - writer.WriteStartArray("actionDefinition"u8); - - foreach (var item in iFlowUsage.actionDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("aliasIds"u8); foreach (var item in iFlowUsage.AliasIds) @@ -111,30 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowUsage iFlowUsage, writer.WriteEndArray(); - writer.WriteStartArray("association"u8); - - foreach (var item in iFlowUsage.association) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("behavior"u8); - - foreach (var item in iFlowUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iFlowUsage.chainingFeature) @@ -193,18 +157,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowUsage iFlowUsage, writer.WriteNullValue(); } - writer.WriteStartArray("definition"u8); - - foreach (var item in iFlowUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iFlowUsage.differencingType) @@ -217,18 +169,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowUsage iFlowUsage, writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iFlowUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iFlowUsage.directedUsage) @@ -267,18 +207,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowUsage iFlowUsage, writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iFlowUsage.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iFlowUsage.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iFlowUsage.endOwningType.HasValue) @@ -421,18 +349,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowUsage iFlowUsage, writer.WriteEndArray(); - writer.WriteStartArray("interaction"u8); - - foreach (var item in iFlowUsage.interaction) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("intersectingType"u8); foreach (var item in iFlowUsage.intersectingType) @@ -490,9 +406,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowUsage iFlowUsage, writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iFlowUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iFlowUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iFlowUsage.IsVariation); @@ -864,18 +777,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowUsage iFlowUsage, writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iFlowUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iFlowUsage.output) @@ -1360,18 +1261,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowUsage iFlowUsage, writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iFlowUsage.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iFlowUsage.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iFlowUsage.relatedFeature) @@ -1387,18 +1276,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowUsage iFlowUsage, writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iFlowUsage.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iFlowUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iFlowUsage.sourceFeature.HasValue) @@ -1427,18 +1304,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowUsage iFlowUsage, writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iFlowUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iFlowUsage.targetFeature) @@ -1477,18 +1342,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFlowUsage iFlowUsage, writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iFlowUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iFlowUsage.unioningType) @@ -1615,9 +1468,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFlowUsage iFlowUsag writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iFlowUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iFlowUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iFlowUsage.IsVariation); @@ -1684,30 +1534,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFlowUsage iFlowUsag writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iFlowUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFlowUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ForLoopActionUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ForLoopActionUsageSerializer.cs index 8f81fd3c..42b27498 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ForLoopActionUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ForLoopActionUsageSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IForLoopActionUsage iFo writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iForLoopActionUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("bodyAction"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -161,18 +149,6 @@ private static void SerializeAsJsonWithDerivedProperties(IForLoopActionUsage iFo writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iForLoopActionUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iForLoopActionUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iForLoopActionUsage.differencingType) @@ -185,18 +161,6 @@ private static void SerializeAsJsonWithDerivedProperties(IForLoopActionUsage iFo writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iForLoopActionUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iForLoopActionUsage.directedUsage) @@ -419,9 +383,6 @@ private static void SerializeAsJsonWithDerivedProperties(IForLoopActionUsage iFo writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iForLoopActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iForLoopActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iForLoopActionUsage.IsVariation); @@ -799,18 +760,6 @@ private static void SerializeAsJsonWithDerivedProperties(IForLoopActionUsage iFo writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iForLoopActionUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iForLoopActionUsage.output) @@ -1264,18 +1213,6 @@ private static void SerializeAsJsonWithDerivedProperties(IForLoopActionUsage iFo writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iForLoopActionUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iForLoopActionUsage.unioningType) @@ -1399,9 +1336,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IForLoopActionUsage writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iForLoopActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iForLoopActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iForLoopActionUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ForkNodeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ForkNodeSerializer.cs index 1edb675d..5b187da0 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ForkNodeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ForkNodeSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IForkNode iForkNode, Ut writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iForkNode.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iForkNode.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IForkNode iForkNode, Ut writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iForkNode.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iForkNode.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iForkNode.differencingType) @@ -179,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IForkNode iForkNode, Ut writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iForkNode.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iForkNode.directedUsage) @@ -413,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IForkNode iForkNode, Ut writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iForkNode.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iForkNode.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iForkNode.IsVariation); @@ -787,18 +748,6 @@ private static void SerializeAsJsonWithDerivedProperties(IForkNode iForkNode, Ut writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iForkNode.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iForkNode.output) @@ -1246,18 +1195,6 @@ private static void SerializeAsJsonWithDerivedProperties(IForkNode iForkNode, Ut writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iForkNode.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iForkNode.unioningType) @@ -1381,9 +1318,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IForkNode iForkNode, writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iForkNode.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iForkNode.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iForkNode.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FramedConcernMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FramedConcernMembershipSerializer.cs index fdf04e9f..58590c35 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FramedConcernMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FramedConcernMembershipSerializer.cs @@ -132,27 +132,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFramedConcernMembershi writer.WritePropertyName("kind"u8); writer.WriteStringValue(iFramedConcernMembership.Kind.ToString().ToLower()); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iFramedConcernMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iFramedConcernMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iFramedConcernMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iFramedConcernMembership.name); @@ -174,12 +153,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFramedConcernMembershi writer.WriteStringValue(iFramedConcernMembership.ownedConcern); writer.WriteEndObject(); - writer.WritePropertyName("ownedConstraint"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.ownedConstraint); - writer.WriteEndObject(); - writer.WriteStartArray("ownedElement"u8); foreach (var item in iFramedConcernMembership.ownedElement) @@ -192,21 +165,9 @@ private static void SerializeAsJsonWithDerivedProperties(IFramedConcernMembershi writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iFramedConcernMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iFramedConcernMembership.ownedMemberName); @@ -322,12 +283,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFramedConcernMembershi writer.WriteStringValue(iFramedConcernMembership.referencedConcern); writer.WriteEndObject(); - writer.WritePropertyName("referencedConstraint"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.referencedConstraint); - writer.WriteEndObject(); - writer.WriteStartArray("relatedElement"u8); foreach (var item in iFramedConcernMembership.relatedElement) @@ -343,30 +298,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFramedConcernMembershi writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iFramedConcernMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iFramedConcernMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFramedConcernMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iFramedConcernMembership.textualRepresentation) @@ -422,18 +353,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFramedConcernMember writer.WritePropertyName("kind"u8); writer.WriteStringValue(iFramedConcernMembership.Kind.ToString().ToLower()); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iFramedConcernMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iFramedConcernMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iFramedConcernMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iFramedConcernMembership.OwnedRelatedElement) @@ -486,30 +405,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IFramedConcernMember writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iFramedConcernMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iFramedConcernMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iFramedConcernMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FunctionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FunctionSerializer.cs index efcb94e0..be342ec9 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FunctionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/FunctionSerializer.cs @@ -117,18 +117,6 @@ private static void SerializeAsJsonWithDerivedProperties(IFunction iFunction, Ut writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iFunction.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("documentation"u8); foreach (var item in iFunction.documentation) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IfActionUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IfActionUsageSerializer.cs index 16693470..ea6b02df 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IfActionUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IfActionUsageSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIfActionUsage iIfActio writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iIfActionUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iIfActionUsage.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIfActionUsage iIfActio writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iIfActionUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iIfActionUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iIfActionUsage.differencingType) @@ -179,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIfActionUsage iIfActio writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iIfActionUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iIfActionUsage.directedUsage) @@ -433,9 +397,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIfActionUsage iIfActio writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iIfActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iIfActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iIfActionUsage.IsVariation); @@ -807,18 +768,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIfActionUsage iIfActio writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iIfActionUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iIfActionUsage.output) @@ -1272,18 +1221,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIfActionUsage iIfActio writer.WriteStringValue(iIfActionUsage.thenAction); writer.WriteEndObject(); - writer.WriteStartArray("type"u8); - - foreach (var item in iIfActionUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iIfActionUsage.unioningType) @@ -1407,9 +1344,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IIfActionUsage iIfAc writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iIfActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iIfActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iIfActionUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IncludeUseCaseUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IncludeUseCaseUsageSerializer.cs index 4452ea20..02c2cf69 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IncludeUseCaseUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IncludeUseCaseUsageSerializer.cs @@ -90,18 +90,6 @@ internal static void Serialize(object obj, Utf8JsonWriter writer, SerializationM /// private static void SerializeAsJsonWithDerivedProperties(IIncludeUseCaseUsage iIncludeUseCaseUsage, Utf8JsonWriter writer) { - writer.WriteStartArray("actionDefinition"u8); - - foreach (var item in iIncludeUseCaseUsage.actionDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("actorParameter"u8); foreach (var item in iIncludeUseCaseUsage.actorParameter) @@ -123,46 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIncludeUseCaseUsage iI writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iIncludeUseCaseUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("calculationDefinition"u8); - - if (iIncludeUseCaseUsage.calculationDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iIncludeUseCaseUsage.calculationDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - - writer.WritePropertyName("caseDefinition"u8); - - if (iIncludeUseCaseUsage.caseDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iIncludeUseCaseUsage.caseDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iIncludeUseCaseUsage.chainingFeature) @@ -195,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIncludeUseCaseUsage iI writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iIncludeUseCaseUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iIncludeUseCaseUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iIncludeUseCaseUsage.differencingType) @@ -219,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIncludeUseCaseUsage iI writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iIncludeUseCaseUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iIncludeUseCaseUsage.directedUsage) @@ -295,12 +219,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIncludeUseCaseUsage iI writer.WriteNullValue(); } - writer.WritePropertyName("eventOccurrence"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iIncludeUseCaseUsage.eventOccurrence); - writer.WriteEndObject(); - writer.WriteStartArray("feature"u8); foreach (var item in iIncludeUseCaseUsage.feature) @@ -343,20 +261,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIncludeUseCaseUsage iI writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iIncludeUseCaseUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iIncludeUseCaseUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iIncludeUseCaseUsage.importedMembership) @@ -488,9 +392,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIncludeUseCaseUsage iI writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iIncludeUseCaseUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iIncludeUseCaseUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iIncludeUseCaseUsage.IsVariation); @@ -876,18 +777,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIncludeUseCaseUsage iI writer.WriteNullValue(); } - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iIncludeUseCaseUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iIncludeUseCaseUsage.output) @@ -1306,12 +1195,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIncludeUseCaseUsage iI writer.WriteEndArray(); - writer.WritePropertyName("performedAction"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iIncludeUseCaseUsage.performedAction); - writer.WriteEndObject(); - writer.WritePropertyName("portionKind"u8); if (iIncludeUseCaseUsage.PortionKind.HasValue) @@ -1353,18 +1236,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIncludeUseCaseUsage iI writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iIncludeUseCaseUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iIncludeUseCaseUsage.unioningType) @@ -1508,9 +1379,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IIncludeUseCaseUsage writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iIncludeUseCaseUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iIncludeUseCaseUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iIncludeUseCaseUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IndexExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IndexExpressionSerializer.cs index 1826106b..1e93fe38 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IndexExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IndexExpressionSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIndexExpression iIndex writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iIndexExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iIndexExpression.chainingFeature) @@ -167,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIndexExpression iIndex writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iIndexExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iIndexExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InteractionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InteractionSerializer.cs index 9f5316bb..bcaba6ae 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InteractionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InteractionSerializer.cs @@ -129,18 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInteraction iInteracti writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iInteraction.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("documentation"u8); foreach (var item in iInteraction.documentation) @@ -156,18 +144,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInteraction iInteracti writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iInteraction.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iInteraction.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("feature"u8); foreach (var item in iInteraction.feature) @@ -614,18 +590,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInteraction iInteracti writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iInteraction.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iInteraction.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedType"u8); foreach (var item in iInteraction.relatedType) @@ -641,18 +605,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInteraction iInteracti writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iInteraction.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iInteraction.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceType"u8); if (iInteraction.sourceType.HasValue) @@ -679,18 +631,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInteraction iInteracti writer.WriteEndArray(); - writer.WriteStartArray("target"u8); - - foreach (var item in iInteraction.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetType"u8); foreach (var item in iInteraction.targetType) @@ -822,30 +762,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IInteraction iIntera writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iInteraction.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iInteraction.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InterfaceDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InterfaceDefinitionSerializer.cs index f7b68da9..fcff6321 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InterfaceDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InterfaceDefinitionSerializer.cs @@ -99,30 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceDefinition iI writer.WriteEndArray(); - writer.WriteStartArray("associationEnd"u8); - - foreach (var item in iInterfaceDefinition.associationEnd) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("connectionEnd"u8); - - foreach (var item in iInterfaceDefinition.connectionEnd) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iInterfaceDefinition.DeclaredName); @@ -180,18 +156,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceDefinition iI writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iInterfaceDefinition.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iInterfaceDefinition.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("feature"u8); foreach (var item in iInterfaceDefinition.feature) @@ -968,18 +932,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceDefinition iI writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iInterfaceDefinition.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iInterfaceDefinition.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedType"u8); foreach (var item in iInterfaceDefinition.relatedType) @@ -995,18 +947,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceDefinition iI writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iInterfaceDefinition.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iInterfaceDefinition.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceType"u8); if (iInterfaceDefinition.sourceType.HasValue) @@ -1021,18 +961,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceDefinition iI writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iInterfaceDefinition.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetType"u8); foreach (var item in iInterfaceDefinition.targetType) @@ -1206,30 +1134,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IInterfaceDefinition writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iInterfaceDefinition.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iInterfaceDefinition.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InterfaceUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InterfaceUsageSerializer.cs index 7f4c43b4..2ece7f6f 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InterfaceUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InterfaceUsageSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceUsage iInterf writer.WriteEndArray(); - writer.WriteStartArray("association"u8); - - foreach (var item in iInterfaceUsage.association) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iInterfaceUsage.chainingFeature) @@ -123,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceUsage iInterf writer.WriteEndArray(); - writer.WriteStartArray("connectionDefinition"u8); - - foreach (var item in iInterfaceUsage.connectionDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("connectorEnd"u8); foreach (var item in iInterfaceUsage.connectorEnd) @@ -181,18 +157,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceUsage iInterf writer.WriteNullValue(); } - writer.WriteStartArray("definition"u8); - - foreach (var item in iInterfaceUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iInterfaceUsage.differencingType) @@ -255,18 +219,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceUsage iInterf writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iInterfaceUsage.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iInterfaceUsage.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iInterfaceUsage.endOwningType.HasValue) @@ -454,9 +406,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceUsage iInterf writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iInterfaceUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iInterfaceUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iInterfaceUsage.IsVariation); @@ -1310,18 +1259,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceUsage iInterf writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iInterfaceUsage.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iInterfaceUsage.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iInterfaceUsage.relatedFeature) @@ -1337,18 +1274,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceUsage iInterf writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iInterfaceUsage.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iInterfaceUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iInterfaceUsage.sourceFeature.HasValue) @@ -1363,18 +1288,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceUsage iInterf writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iInterfaceUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iInterfaceUsage.targetFeature) @@ -1399,18 +1312,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInterfaceUsage iInterf writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iInterfaceUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iInterfaceUsage.unioningType) @@ -1537,9 +1438,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IInterfaceUsage iInt writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iInterfaceUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iInterfaceUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iInterfaceUsage.IsVariation); @@ -1606,30 +1504,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IInterfaceUsage iInt writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iInterfaceUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iInterfaceUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IntersectingSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IntersectingSerializer.cs index 8b6ed17f..00850268 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IntersectingSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/IntersectingSerializer.cs @@ -274,30 +274,6 @@ private static void SerializeAsJsonWithDerivedProperties(IIntersecting iIntersec writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iIntersecting.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iIntersecting.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iIntersecting.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iIntersecting.textualRepresentation) @@ -411,30 +387,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IIntersecting iInter writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iIntersecting.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iIntersecting.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InvariantSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InvariantSerializer.cs index 4ec041e1..14ea396e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InvariantSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InvariantSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInvariant iInvariant, writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iInvariant.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iInvariant.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInvariant iInvariant, writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iInvariant.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iInvariant.Direction.HasValue) @@ -261,20 +237,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInvariant iInvariant, writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iInvariant.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iInvariant.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iInvariant.importedMembership) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InvocationExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InvocationExpressionSerializer.cs index e6881d8d..1a2386df 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InvocationExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/InvocationExpressionSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInvocationExpression i writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iInvocationExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iInvocationExpression.chainingFeature) @@ -167,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IInvocationExpression i writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iInvocationExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iInvocationExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ItemUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ItemUsageSerializer.cs index bb530128..bde5e9b9 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ItemUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ItemUsageSerializer.cs @@ -131,18 +131,6 @@ private static void SerializeAsJsonWithDerivedProperties(IItemUsage iItemUsage, writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iItemUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iItemUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iItemUsage.differencingType) @@ -389,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IItemUsage iItemUsage, writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iItemUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iItemUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iItemUsage.IsVariation); @@ -1222,18 +1207,6 @@ private static void SerializeAsJsonWithDerivedProperties(IItemUsage iItemUsage, writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iItemUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iItemUsage.unioningType) @@ -1357,9 +1330,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IItemUsage iItemUsag writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iItemUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iItemUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iItemUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/JoinNodeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/JoinNodeSerializer.cs index 6cb90c1c..89c5b62e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/JoinNodeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/JoinNodeSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IJoinNode iJoinNode, Ut writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iJoinNode.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iJoinNode.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IJoinNode iJoinNode, Ut writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iJoinNode.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iJoinNode.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iJoinNode.differencingType) @@ -179,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IJoinNode iJoinNode, Ut writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iJoinNode.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iJoinNode.directedUsage) @@ -413,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IJoinNode iJoinNode, Ut writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iJoinNode.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iJoinNode.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iJoinNode.IsVariation); @@ -787,18 +748,6 @@ private static void SerializeAsJsonWithDerivedProperties(IJoinNode iJoinNode, Ut writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iJoinNode.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iJoinNode.output) @@ -1246,18 +1195,6 @@ private static void SerializeAsJsonWithDerivedProperties(IJoinNode iJoinNode, Ut writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iJoinNode.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iJoinNode.unioningType) @@ -1381,9 +1318,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IJoinNode iJoinNode, writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iJoinNode.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iJoinNode.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iJoinNode.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralBooleanSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralBooleanSerializer.cs index 9c7b6edc..2d03380b 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralBooleanSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralBooleanSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralBoolean iLitera writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iLiteralBoolean.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iLiteralBoolean.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralBoolean iLitera writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iLiteralBoolean.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iLiteralBoolean.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralExpressionSerializer.cs index 29ae6e75..e31dcaef 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralExpressionSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralExpression iLit writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iLiteralExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iLiteralExpression.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralExpression iLit writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iLiteralExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iLiteralExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralInfinitySerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralInfinitySerializer.cs index fef42a5f..87316176 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralInfinitySerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralInfinitySerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralInfinity iLiter writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iLiteralInfinity.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iLiteralInfinity.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralInfinity iLiter writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iLiteralInfinity.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iLiteralInfinity.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralIntegerSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralIntegerSerializer.cs index 8d33deb7..c18bd1ef 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralIntegerSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralIntegerSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralInteger iLitera writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iLiteralInteger.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iLiteralInteger.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralInteger iLitera writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iLiteralInteger.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iLiteralInteger.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralRationalSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralRationalSerializer.cs index cb68b6d8..4a846a88 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralRationalSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralRationalSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralRational iLiter writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iLiteralRational.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iLiteralRational.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralRational iLiter writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iLiteralRational.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iLiteralRational.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralStringSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralStringSerializer.cs index 5bb72543..89ddecf8 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralStringSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/LiteralStringSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralString iLiteral writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iLiteralString.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iLiteralString.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(ILiteralString iLiteral writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iLiteralString.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iLiteralString.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MembershipExposeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MembershipExposeSerializer.cs index 513455c3..6115b5a1 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MembershipExposeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MembershipExposeSerializer.cs @@ -292,30 +292,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMembershipExpose iMemb writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iMembershipExpose.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iMembershipExpose.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iMembershipExpose.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iMembershipExpose.textualRepresentation) @@ -432,30 +408,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IMembershipExpose iM writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iMembershipExpose.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iMembershipExpose.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iMembershipExpose.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MembershipImportSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MembershipImportSerializer.cs index f40156e2..1fdcefc2 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MembershipImportSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MembershipImportSerializer.cs @@ -292,30 +292,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMembershipImport iMemb writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iMembershipImport.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iMembershipImport.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iMembershipImport.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iMembershipImport.textualRepresentation) @@ -432,30 +408,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IMembershipImport iM writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iMembershipImport.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iMembershipImport.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iMembershipImport.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MembershipSerializer.cs index c5c24186..364b3992 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MembershipSerializer.cs @@ -289,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMembership iMembership writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iMembership.textualRepresentation) @@ -429,30 +405,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IMembership iMembers writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MergeNodeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MergeNodeSerializer.cs index a2917311..b2ece18b 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MergeNodeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MergeNodeSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMergeNode iMergeNode, writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iMergeNode.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iMergeNode.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMergeNode iMergeNode, writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iMergeNode.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iMergeNode.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iMergeNode.differencingType) @@ -179,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMergeNode iMergeNode, writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iMergeNode.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iMergeNode.directedUsage) @@ -413,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMergeNode iMergeNode, writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iMergeNode.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iMergeNode.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iMergeNode.IsVariation); @@ -787,18 +748,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMergeNode iMergeNode, writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iMergeNode.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iMergeNode.output) @@ -1246,18 +1195,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMergeNode iMergeNode, writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iMergeNode.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iMergeNode.unioningType) @@ -1381,9 +1318,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IMergeNode iMergeNod writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iMergeNode.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iMergeNode.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iMergeNode.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MetadataAccessExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MetadataAccessExpressionSerializer.cs index 5d7952c1..358cda8e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MetadataAccessExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MetadataAccessExpressionSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMetadataAccessExpressi writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iMetadataAccessExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iMetadataAccessExpression.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMetadataAccessExpressi writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iMetadataAccessExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iMetadataAccessExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MetadataUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MetadataUsageSerializer.cs index 1a10098f..41ae0b5a 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MetadataUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/MetadataUsageSerializer.cs @@ -155,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMetadataUsage iMetadat writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iMetadataUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iMetadataUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iMetadataUsage.differencingType) @@ -413,24 +401,9 @@ private static void SerializeAsJsonWithDerivedProperties(IMetadataUsage iMetadat writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iMetadataUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iMetadataUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iMetadataUsage.IsVariation); - writer.WriteStartArray("itemDefinition"u8); - - foreach (var item in iMetadataUsage.itemDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("mayTimeVary"u8); writer.WriteBooleanValue(iMetadataUsage.mayTimeVary); @@ -458,20 +431,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMetadataUsage iMetadat writer.WriteEndArray(); - writer.WritePropertyName("metaclass"u8); - - if (iMetadataUsage.metaclass.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iMetadataUsage.metaclass.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("metadataDefinition"u8); if (iMetadataUsage.metadataDefinition.HasValue) @@ -1300,18 +1259,6 @@ private static void SerializeAsJsonWithDerivedProperties(IMetadataUsage iMetadat writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iMetadataUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iMetadataUsage.unioningType) @@ -1435,9 +1382,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IMetadataUsage iMeta writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iMetadataUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iMetadataUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iMetadataUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/NamespaceExposeSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/NamespaceExposeSerializer.cs index 81ff12ce..ede6b885 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/NamespaceExposeSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/NamespaceExposeSerializer.cs @@ -292,30 +292,6 @@ private static void SerializeAsJsonWithDerivedProperties(INamespaceExpose iNames writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iNamespaceExpose.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iNamespaceExpose.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iNamespaceExpose.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iNamespaceExpose.textualRepresentation) @@ -432,30 +408,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(INamespaceExpose iNa writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iNamespaceExpose.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iNamespaceExpose.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iNamespaceExpose.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/NamespaceImportSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/NamespaceImportSerializer.cs index 416a1104..f522294e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/NamespaceImportSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/NamespaceImportSerializer.cs @@ -292,30 +292,6 @@ private static void SerializeAsJsonWithDerivedProperties(INamespaceImport iNames writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iNamespaceImport.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iNamespaceImport.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iNamespaceImport.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iNamespaceImport.textualRepresentation) @@ -432,30 +408,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(INamespaceImport iNa writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iNamespaceImport.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iNamespaceImport.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iNamespaceImport.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/NullExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/NullExpressionSerializer.cs index e1506118..a00109d9 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/NullExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/NullExpressionSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(INullExpression iNullEx writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iNullExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iNullExpression.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(INullExpression iNullEx writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iNullExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iNullExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ObjectiveMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ObjectiveMembershipSerializer.cs index 2286bca8..e29721ba 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ObjectiveMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ObjectiveMembershipSerializer.cs @@ -129,27 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IObjectiveMembership iO writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iObjectiveMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iObjectiveMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iObjectiveMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iObjectiveMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iObjectiveMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iObjectiveMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iObjectiveMembership.name); @@ -177,21 +156,9 @@ private static void SerializeAsJsonWithDerivedProperties(IObjectiveMembership iO writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iObjectiveMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iObjectiveMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iObjectiveMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iObjectiveMembership.ownedMemberName); @@ -322,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IObjectiveMembership iO writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iObjectiveMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iObjectiveMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iObjectiveMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iObjectiveMembership.textualRepresentation) @@ -398,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IObjectiveMembership writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iObjectiveMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iObjectiveMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iObjectiveMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iObjectiveMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iObjectiveMembership.OwnedRelatedElement) @@ -462,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IObjectiveMembership writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iObjectiveMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iObjectiveMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iObjectiveMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/OccurrenceUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/OccurrenceUsageSerializer.cs index 5c374b43..4886f480 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/OccurrenceUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/OccurrenceUsageSerializer.cs @@ -131,18 +131,6 @@ private static void SerializeAsJsonWithDerivedProperties(IOccurrenceUsage iOccur writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iOccurrenceUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iOccurrenceUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iOccurrenceUsage.differencingType) @@ -389,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IOccurrenceUsage iOccur writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iOccurrenceUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iOccurrenceUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iOccurrenceUsage.IsVariation); @@ -1210,18 +1195,6 @@ private static void SerializeAsJsonWithDerivedProperties(IOccurrenceUsage iOccur writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iOccurrenceUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iOccurrenceUsage.unioningType) @@ -1345,9 +1318,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IOccurrenceUsage iOc writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iOccurrenceUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iOccurrenceUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iOccurrenceUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/OperatorExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/OperatorExpressionSerializer.cs index ffb80ee7..f326dfc3 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/OperatorExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/OperatorExpressionSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IOperatorExpression iOp writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iOperatorExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iOperatorExpression.chainingFeature) @@ -167,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IOperatorExpression iOp writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iOperatorExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iOperatorExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/OwningMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/OwningMembershipSerializer.cs index 826c6e20..b791fcdb 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/OwningMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/OwningMembershipSerializer.cs @@ -129,27 +129,12 @@ private static void SerializeAsJsonWithDerivedProperties(IOwningMembership iOwni writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iOwningMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iOwningMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iOwningMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iOwningMembership.MemberName); - writer.WritePropertyName("membershipOwningNamespace"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); writer.WriteStringValue(iOwningMembership.membershipOwningNamespace); writer.WriteEndObject(); - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iOwningMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iOwningMembership.name); @@ -304,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IOwningMembership iOwni writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iOwningMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iOwningMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iOwningMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iOwningMembership.textualRepresentation) @@ -380,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IOwningMembership iO writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iOwningMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iOwningMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iOwningMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iOwningMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iOwningMembership.OwnedRelatedElement) @@ -444,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IOwningMembership iO writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iOwningMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iOwningMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iOwningMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ParameterMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ParameterMembershipSerializer.cs index efc6b050..94ecce41 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ParameterMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ParameterMembershipSerializer.cs @@ -129,27 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IParameterMembership iP writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iParameterMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iParameterMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iParameterMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iParameterMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iParameterMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iParameterMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iParameterMembership.name); @@ -177,21 +156,9 @@ private static void SerializeAsJsonWithDerivedProperties(IParameterMembership iP writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iParameterMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iParameterMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iParameterMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iParameterMembership.ownedMemberName); @@ -322,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IParameterMembership iP writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iParameterMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iParameterMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iParameterMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iParameterMembership.textualRepresentation) @@ -398,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IParameterMembership writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iParameterMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iParameterMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iParameterMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iParameterMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iParameterMembership.OwnedRelatedElement) @@ -462,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IParameterMembership writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iParameterMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iParameterMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iParameterMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PartUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PartUsageSerializer.cs index 433e6293..a63a10d7 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PartUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PartUsageSerializer.cs @@ -131,18 +131,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPartUsage iPartUsage, writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iPartUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iPartUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iPartUsage.differencingType) @@ -389,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPartUsage iPartUsage, writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iPartUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iPartUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iPartUsage.IsVariation); @@ -1234,18 +1219,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPartUsage iPartUsage, writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iPartUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iPartUsage.unioningType) @@ -1369,9 +1342,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IPartUsage iPartUsag writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iPartUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iPartUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iPartUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PerformActionUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PerformActionUsageSerializer.cs index 820b123d..6ef126d7 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PerformActionUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PerformActionUsageSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPerformActionUsage iPe writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iPerformActionUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iPerformActionUsage.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPerformActionUsage iPe writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iPerformActionUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iPerformActionUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iPerformActionUsage.differencingType) @@ -179,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPerformActionUsage iPe writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iPerformActionUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iPerformActionUsage.directedUsage) @@ -255,12 +219,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPerformActionUsage iPe writer.WriteNullValue(); } - writer.WritePropertyName("eventOccurrence"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iPerformActionUsage.eventOccurrence); - writer.WriteEndObject(); - writer.WriteStartArray("feature"u8); foreach (var item in iPerformActionUsage.feature) @@ -419,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPerformActionUsage iPe writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iPerformActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iPerformActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iPerformActionUsage.IsVariation); @@ -793,18 +748,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPerformActionUsage iPe writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iPerformActionUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iPerformActionUsage.output) @@ -1258,18 +1201,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPerformActionUsage iPe writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iPerformActionUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iPerformActionUsage.unioningType) @@ -1393,9 +1324,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IPerformActionUsage writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iPerformActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iPerformActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iPerformActionUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PortConjugationSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PortConjugationSerializer.cs index 0c50afab..430bbf60 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PortConjugationSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PortConjugationSerializer.cs @@ -150,12 +150,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPortConjugation iPortC writer.WriteStringValue(iPortConjugation.OriginalPortDefinition); writer.WriteEndObject(); - writer.WritePropertyName("originalType"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iPortConjugation.OriginalType); - writer.WriteEndObject(); - writer.WriteStartArray("ownedAnnotation"u8); foreach (var item in iPortConjugation.ownedAnnotation) @@ -274,20 +268,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPortConjugation iPortC writer.WriteNullValue(); } - writer.WritePropertyName("owningType"u8); - - if (iPortConjugation.owningType.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iPortConjugation.owningType.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iPortConjugation.qualifiedName); @@ -306,30 +286,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPortConjugation iPortC writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iPortConjugation.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iPortConjugation.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iPortConjugation.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iPortConjugation.textualRepresentation) @@ -391,12 +347,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IPortConjugation iPo writer.WriteStringValue(iPortConjugation.OriginalPortDefinition); writer.WriteEndObject(); - writer.WritePropertyName("originalType"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iPortConjugation.OriginalType); - writer.WriteEndObject(); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iPortConjugation.OwnedRelatedElement) @@ -449,30 +399,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IPortConjugation iPo writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iPortConjugation.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iPortConjugation.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PortUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PortUsageSerializer.cs index 76a3e336..5170f501 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PortUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PortUsageSerializer.cs @@ -131,18 +131,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPortUsage iPortUsage, writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iPortUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iPortUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iPortUsage.differencingType) @@ -389,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPortUsage iPortUsage, writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iPortUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iPortUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iPortUsage.IsVariation); @@ -763,18 +748,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPortUsage iPortUsage, writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iPortUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iPortUsage.output) @@ -1222,18 +1195,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPortUsage iPortUsage, writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iPortUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iPortUsage.unioningType) @@ -1357,9 +1318,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IPortUsage iPortUsag writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iPortUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iPortUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iPortUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PredicateSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PredicateSerializer.cs index 168b210b..c4336bd9 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PredicateSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/PredicateSerializer.cs @@ -117,18 +117,6 @@ private static void SerializeAsJsonWithDerivedProperties(IPredicate iPredicate, writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iPredicate.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("documentation"u8); foreach (var item in iPredicate.documentation) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RedefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RedefinitionSerializer.cs index f72a3336..ea80bd33 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RedefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RedefinitionSerializer.cs @@ -120,12 +120,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRedefinition iRedefini writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iRedefinition.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRedefinition.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iRedefinition.IsImplied); @@ -270,20 +264,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRedefinition iRedefini writer.WriteNullValue(); } - writer.WritePropertyName("owningType"u8); - - if (iRedefinition.owningType.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRedefinition.owningType.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iRedefinition.qualifiedName); @@ -314,48 +294,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRedefinition iRedefini writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iRedefinition.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iRedefinition.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRedefinition.Specific); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettedFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRedefinition.SubsettedFeature); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettingFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRedefinition.SubsettingFeature); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iRedefinition.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iRedefinition.textualRepresentation) @@ -399,12 +337,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IRedefinition iRedef writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iRedefinition.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRedefinition.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iRedefinition.IsImplied); @@ -475,48 +407,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IRedefinition iRedef writer.WriteStringValue(iRedefinition.RedefiningFeature); writer.WriteEndObject(); - writer.WriteStartArray("source"u8); - - foreach (var item in iRedefinition.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRedefinition.Specific); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettedFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRedefinition.SubsettedFeature); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettingFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRedefinition.SubsettingFeature); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iRedefinition.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ReferenceSubsettingSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ReferenceSubsettingSerializer.cs index 9472218f..da2ac9e2 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ReferenceSubsettingSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ReferenceSubsettingSerializer.cs @@ -120,12 +120,6 @@ private static void SerializeAsJsonWithDerivedProperties(IReferenceSubsetting iR writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iReferenceSubsetting.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iReferenceSubsetting.IsImplied); @@ -200,20 +194,6 @@ private static void SerializeAsJsonWithDerivedProperties(IReferenceSubsetting iR writer.WriteNullValue(); } - writer.WritePropertyName("owningFeature"u8); - - if (iReferenceSubsetting.owningFeature.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.owningFeature.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("owningMembership"u8); if (iReferenceSubsetting.owningMembership.HasValue) @@ -270,20 +250,6 @@ private static void SerializeAsJsonWithDerivedProperties(IReferenceSubsetting iR writer.WriteNullValue(); } - writer.WritePropertyName("owningType"u8); - - if (iReferenceSubsetting.owningType.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.owningType.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iReferenceSubsetting.qualifiedName); @@ -314,48 +280,6 @@ private static void SerializeAsJsonWithDerivedProperties(IReferenceSubsetting iR writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iReferenceSubsetting.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iReferenceSubsetting.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.Specific); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettedFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.SubsettedFeature); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettingFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.SubsettingFeature); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iReferenceSubsetting.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iReferenceSubsetting.textualRepresentation) @@ -399,12 +323,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IReferenceSubsetting writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iReferenceSubsetting.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iReferenceSubsetting.IsImplied); @@ -469,48 +387,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IReferenceSubsetting writer.WriteStringValue(iReferenceSubsetting.ReferencedFeature); writer.WriteEndObject(); - writer.WriteStartArray("source"u8); - - foreach (var item in iReferenceSubsetting.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.Specific); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettedFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.SubsettedFeature); - writer.WriteEndObject(); - - writer.WritePropertyName("subsettingFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReferenceSubsetting.SubsettingFeature); - writer.WriteEndObject(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iReferenceSubsetting.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ReferenceUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ReferenceUsageSerializer.cs index 215b1142..04065163 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ReferenceUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ReferenceUsageSerializer.cs @@ -372,9 +372,6 @@ private static void SerializeAsJsonWithDerivedProperties(IReferenceUsage iRefere writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iReferenceUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iReferenceUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iReferenceUsage.IsVariation); @@ -1170,18 +1167,6 @@ private static void SerializeAsJsonWithDerivedProperties(IReferenceUsage iRefere writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iReferenceUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iReferenceUsage.unioningType) @@ -1302,9 +1287,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IReferenceUsage iRef writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iReferenceUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iReferenceUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iReferenceUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RenderingUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RenderingUsageSerializer.cs index 058a23b3..f9288226 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RenderingUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RenderingUsageSerializer.cs @@ -131,18 +131,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRenderingUsage iRender writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iRenderingUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iRenderingUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iRenderingUsage.differencingType) @@ -389,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRenderingUsage iRender writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iRenderingUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iRenderingUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iRenderingUsage.IsVariation); @@ -1193,18 +1178,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRenderingUsage iRender writer.WriteNullValue(); } - writer.WriteStartArray("partDefinition"u8); - - foreach (var item in iRenderingUsage.partDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("portionKind"u8); if (iRenderingUsage.PortionKind.HasValue) @@ -1248,18 +1221,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRenderingUsage iRender writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iRenderingUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iRenderingUsage.unioningType) @@ -1383,9 +1344,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IRenderingUsage iRen writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iRenderingUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iRenderingUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iRenderingUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementConstraintMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementConstraintMembershipSerializer.cs index 1436df69..f190c29e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementConstraintMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementConstraintMembershipSerializer.cs @@ -132,27 +132,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementConstraintM writer.WritePropertyName("kind"u8); writer.WriteStringValue(iRequirementConstraintMembership.Kind.ToString().ToLower()); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementConstraintMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iRequirementConstraintMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iRequirementConstraintMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementConstraintMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iRequirementConstraintMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iRequirementConstraintMembership.name); @@ -186,21 +165,9 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementConstraintM writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementConstraintMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iRequirementConstraintMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementConstraintMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iRequirementConstraintMembership.ownedMemberName); @@ -331,30 +298,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementConstraintM writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iRequirementConstraintMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iRequirementConstraintMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iRequirementConstraintMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iRequirementConstraintMembership.textualRepresentation) @@ -410,18 +353,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IRequirementConstrai writer.WritePropertyName("kind"u8); writer.WriteStringValue(iRequirementConstraintMembership.Kind.ToString().ToLower()); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementConstraintMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iRequirementConstraintMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iRequirementConstraintMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iRequirementConstraintMembership.OwnedRelatedElement) @@ -474,30 +405,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IRequirementConstrai writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iRequirementConstraintMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iRequirementConstraintMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iRequirementConstraintMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementDefinitionSerializer.cs index 7757bd62..dc42b906 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementDefinitionSerializer.cs @@ -126,9 +126,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementDefinition writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iRequirementDefinition.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iRequirementDefinition.DeclaredShortName); - writer.WriteStartArray("differencingType"u8); foreach (var item in iRequirementDefinition.differencingType) @@ -141,18 +138,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementDefinition writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iRequirementDefinition.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iRequirementDefinition.directedUsage) @@ -1114,9 +1099,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IRequirementDefiniti writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iRequirementDefinition.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iRequirementDefinition.DeclaredShortName); - writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iRequirementDefinition.ElementId); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementUsageSerializer.cs index d540eaab..6a8372a2 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementUsageSerializer.cs @@ -123,18 +123,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iRequirementUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iRequirementUsage.chainingFeature) @@ -147,20 +135,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WriteEndArray(); - writer.WritePropertyName("constraintDefinition"u8); - - if (iRequirementUsage.constraintDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementUsage.constraintDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("crossFeature"u8); if (iRequirementUsage.crossFeature.HasValue) @@ -178,21 +152,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iRequirementUsage.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iRequirementUsage.DeclaredShortName); - - writer.WriteStartArray("definition"u8); - - foreach (var item in iRequirementUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iRequirementUsage.differencingType) @@ -205,18 +164,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iRequirementUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iRequirementUsage.directedUsage) @@ -335,20 +282,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iRequirementUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iRequirementUsage.importedMembership) @@ -468,9 +401,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iRequirementUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iRequirementUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iRequirementUsage.IsVariation); @@ -1283,20 +1213,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WriteNullValue(); } - writer.WritePropertyName("predicate"u8); - - if (iRequirementUsage.predicate.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementUsage.predicate.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iRequirementUsage.qualifiedName); @@ -1377,18 +1293,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementUsage iRequ writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iRequirementUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iRequirementUsage.unioningType) @@ -1462,9 +1366,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IRequirementUsage iR writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iRequirementUsage.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iRequirementUsage.DeclaredShortName); - writer.WritePropertyName("direction"u8); if (iRequirementUsage.Direction.HasValue) @@ -1512,9 +1413,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IRequirementUsage iR writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iRequirementUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iRequirementUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iRequirementUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementVerificationMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementVerificationMembershipSerializer.cs index e68ed91d..0d06e953 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementVerificationMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/RequirementVerificationMembershipSerializer.cs @@ -132,27 +132,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementVerificatio writer.WritePropertyName("kind"u8); writer.WriteStringValue(iRequirementVerificationMembership.Kind.ToString().ToLower()); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementVerificationMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iRequirementVerificationMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iRequirementVerificationMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementVerificationMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iRequirementVerificationMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iRequirementVerificationMembership.name); @@ -168,12 +147,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementVerificatio writer.WriteEndArray(); - writer.WritePropertyName("ownedConstraint"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementVerificationMembership.ownedConstraint); - writer.WriteEndObject(); - writer.WriteStartArray("ownedElement"u8); foreach (var item in iRequirementVerificationMembership.ownedElement) @@ -186,21 +159,9 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementVerificatio writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementVerificationMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iRequirementVerificationMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementVerificationMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iRequirementVerificationMembership.ownedMemberName); @@ -316,12 +277,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementVerificatio writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iRequirementVerificationMembership.qualifiedName); - writer.WritePropertyName("referencedConstraint"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementVerificationMembership.referencedConstraint); - writer.WriteEndObject(); - writer.WriteStartArray("relatedElement"u8); foreach (var item in iRequirementVerificationMembership.relatedElement) @@ -337,30 +292,6 @@ private static void SerializeAsJsonWithDerivedProperties(IRequirementVerificatio writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iRequirementVerificationMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iRequirementVerificationMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iRequirementVerificationMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iRequirementVerificationMembership.textualRepresentation) @@ -422,18 +353,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IRequirementVerifica writer.WritePropertyName("kind"u8); writer.WriteStringValue(iRequirementVerificationMembership.Kind.ToString().ToLower()); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iRequirementVerificationMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iRequirementVerificationMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iRequirementVerificationMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iRequirementVerificationMembership.OwnedRelatedElement) @@ -486,30 +405,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IRequirementVerifica writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iRequirementVerificationMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iRequirementVerificationMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iRequirementVerificationMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ResultExpressionMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ResultExpressionMembershipSerializer.cs index e6ec5ea9..abe4dfd2 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ResultExpressionMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ResultExpressionMembershipSerializer.cs @@ -129,27 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IResultExpressionMember writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iResultExpressionMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iResultExpressionMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iResultExpressionMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iResultExpressionMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iResultExpressionMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iResultExpressionMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iResultExpressionMembership.name); @@ -177,21 +156,9 @@ private static void SerializeAsJsonWithDerivedProperties(IResultExpressionMember writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iResultExpressionMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iResultExpressionMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iResultExpressionMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iResultExpressionMembership.ownedMemberName); @@ -322,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IResultExpressionMember writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iResultExpressionMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iResultExpressionMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iResultExpressionMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iResultExpressionMembership.textualRepresentation) @@ -398,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IResultExpressionMem writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iResultExpressionMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iResultExpressionMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iResultExpressionMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iResultExpressionMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iResultExpressionMembership.OwnedRelatedElement) @@ -462,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IResultExpressionMem writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iResultExpressionMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iResultExpressionMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iResultExpressionMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ReturnParameterMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ReturnParameterMembershipSerializer.cs index 5d7a2f91..7f9fc21f 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ReturnParameterMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ReturnParameterMembershipSerializer.cs @@ -129,27 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IReturnParameterMembers writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iReturnParameterMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReturnParameterMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iReturnParameterMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iReturnParameterMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReturnParameterMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iReturnParameterMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iReturnParameterMembership.name); @@ -177,21 +156,9 @@ private static void SerializeAsJsonWithDerivedProperties(IReturnParameterMembers writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReturnParameterMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iReturnParameterMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReturnParameterMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iReturnParameterMembership.ownedMemberName); @@ -322,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IReturnParameterMembers writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iReturnParameterMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iReturnParameterMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iReturnParameterMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iReturnParameterMembership.textualRepresentation) @@ -398,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IReturnParameterMemb writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iReturnParameterMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iReturnParameterMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iReturnParameterMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iReturnParameterMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iReturnParameterMembership.OwnedRelatedElement) @@ -462,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IReturnParameterMemb writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iReturnParameterMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iReturnParameterMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iReturnParameterMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SatisfyRequirementUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SatisfyRequirementUsageSerializer.cs index c3a1e7e0..0cc61369 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SatisfyRequirementUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SatisfyRequirementUsageSerializer.cs @@ -111,12 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISatisfyRequirementUsag writer.WriteEndArray(); - writer.WritePropertyName("assertedConstraint"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSatisfyRequirementUsage.assertedConstraint); - writer.WriteEndObject(); - writer.WriteStartArray("assumedConstraint"u8); foreach (var item in iSatisfyRequirementUsage.assumedConstraint) @@ -129,18 +123,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISatisfyRequirementUsag writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iSatisfyRequirementUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iSatisfyRequirementUsage.chainingFeature) @@ -153,20 +135,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISatisfyRequirementUsag writer.WriteEndArray(); - writer.WritePropertyName("constraintDefinition"u8); - - if (iSatisfyRequirementUsage.constraintDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSatisfyRequirementUsage.constraintDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("crossFeature"u8); if (iSatisfyRequirementUsage.crossFeature.HasValue) @@ -184,21 +152,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISatisfyRequirementUsag writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iSatisfyRequirementUsage.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iSatisfyRequirementUsage.DeclaredShortName); - - writer.WriteStartArray("definition"u8); - - foreach (var item in iSatisfyRequirementUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iSatisfyRequirementUsage.differencingType) @@ -211,18 +164,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISatisfyRequirementUsag writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iSatisfyRequirementUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iSatisfyRequirementUsage.directedUsage) @@ -341,20 +282,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISatisfyRequirementUsag writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iSatisfyRequirementUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSatisfyRequirementUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iSatisfyRequirementUsage.importedMembership) @@ -477,9 +404,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISatisfyRequirementUsag writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iSatisfyRequirementUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iSatisfyRequirementUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iSatisfyRequirementUsage.IsVariation); @@ -1292,20 +1216,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISatisfyRequirementUsag writer.WriteNullValue(); } - writer.WritePropertyName("predicate"u8); - - if (iSatisfyRequirementUsage.predicate.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSatisfyRequirementUsage.predicate.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iSatisfyRequirementUsage.qualifiedName); @@ -1398,18 +1308,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISatisfyRequirementUsag writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iSatisfyRequirementUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iSatisfyRequirementUsage.unioningType) @@ -1483,9 +1381,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISatisfyRequirementU writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iSatisfyRequirementUsage.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iSatisfyRequirementUsage.DeclaredShortName); - writer.WritePropertyName("direction"u8); if (iSatisfyRequirementUsage.Direction.HasValue) @@ -1536,9 +1431,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISatisfyRequirementU writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iSatisfyRequirementUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iSatisfyRequirementUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iSatisfyRequirementUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SelectExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SelectExpressionSerializer.cs index 7628ed59..94de8a17 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SelectExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SelectExpressionSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISelectExpression iSele writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iSelectExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iSelectExpression.chainingFeature) @@ -167,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISelectExpression iSele writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iSelectExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iSelectExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SendActionUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SendActionUsageSerializer.cs index 37fa218f..d284cc8f 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SendActionUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SendActionUsageSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISendActionUsage iSendA writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iSendActionUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iSendActionUsage.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISendActionUsage iSendA writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iSendActionUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iSendActionUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iSendActionUsage.differencingType) @@ -179,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISendActionUsage iSendA writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iSendActionUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iSendActionUsage.directedUsage) @@ -413,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISendActionUsage iSendA writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iSendActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iSendActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iSendActionUsage.IsVariation); @@ -787,18 +748,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISendActionUsage iSendA writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iSendActionUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iSendActionUsage.output) @@ -1280,18 +1229,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISendActionUsage iSendA writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iSendActionUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iSendActionUsage.unioningType) @@ -1415,9 +1352,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISendActionUsage iSe writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iSendActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iSendActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iSendActionUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SpecializationSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SpecializationSerializer.cs index 70a5df00..be53421b 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SpecializationSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SpecializationSerializer.cs @@ -288,36 +288,12 @@ private static void SerializeAsJsonWithDerivedProperties(ISpecialization iSpecia writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iSpecialization.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iSpecialization.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("specific"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); writer.WriteStringValue(iSpecialization.Specific); writer.WriteEndObject(); - writer.WriteStartArray("target"u8); - - foreach (var item in iSpecialization.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iSpecialization.textualRepresentation) @@ -425,36 +401,12 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISpecialization iSpe writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iSpecialization.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("specific"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); writer.WriteStringValue(iSpecialization.Specific); writer.WriteEndObject(); - writer.WriteStartArray("target"u8); - - foreach (var item in iSpecialization.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StakeholderMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StakeholderMembershipSerializer.cs index 2d756998..930a5dd9 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StakeholderMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StakeholderMembershipSerializer.cs @@ -129,27 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IStakeholderMembership writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iStakeholderMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iStakeholderMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iStakeholderMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iStakeholderMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iStakeholderMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iStakeholderMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iStakeholderMembership.name); @@ -177,30 +156,12 @@ private static void SerializeAsJsonWithDerivedProperties(IStakeholderMembership writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iStakeholderMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iStakeholderMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iStakeholderMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iStakeholderMembership.ownedMemberName); - writer.WritePropertyName("ownedMemberParameter"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iStakeholderMembership.ownedMemberParameter); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberShortName"u8); writer.WriteStringValue(iStakeholderMembership.ownedMemberShortName); @@ -328,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IStakeholderMembership writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iStakeholderMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iStakeholderMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iStakeholderMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iStakeholderMembership.textualRepresentation) @@ -404,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IStakeholderMembersh writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iStakeholderMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iStakeholderMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iStakeholderMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iStakeholderMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iStakeholderMembership.OwnedRelatedElement) @@ -468,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IStakeholderMembersh writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iStakeholderMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iStakeholderMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iStakeholderMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StateDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StateDefinitionSerializer.cs index 37c97add..7cfbf66f 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StateDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StateDefinitionSerializer.cs @@ -129,18 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IStateDefinition iState writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iStateDefinition.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iStateDefinition.directedUsage) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StateSubactionMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StateSubactionMembershipSerializer.cs index d22eb983..95c61efa 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StateSubactionMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StateSubactionMembershipSerializer.cs @@ -138,27 +138,6 @@ private static void SerializeAsJsonWithDerivedProperties(IStateSubactionMembersh writer.WritePropertyName("kind"u8); writer.WriteStringValue(iStateSubactionMembership.Kind.ToString().ToLower()); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iStateSubactionMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iStateSubactionMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iStateSubactionMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iStateSubactionMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iStateSubactionMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iStateSubactionMembership.name); @@ -186,21 +165,9 @@ private static void SerializeAsJsonWithDerivedProperties(IStateSubactionMembersh writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iStateSubactionMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iStateSubactionMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iStateSubactionMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iStateSubactionMembership.ownedMemberName); @@ -325,30 +292,6 @@ private static void SerializeAsJsonWithDerivedProperties(IStateSubactionMembersh writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iStateSubactionMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iStateSubactionMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iStateSubactionMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iStateSubactionMembership.textualRepresentation) @@ -404,18 +347,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IStateSubactionMembe writer.WritePropertyName("kind"u8); writer.WriteStringValue(iStateSubactionMembership.Kind.ToString().ToLower()); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iStateSubactionMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iStateSubactionMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iStateSubactionMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iStateSubactionMembership.OwnedRelatedElement) @@ -468,30 +399,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IStateSubactionMembe writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iStateSubactionMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iStateSubactionMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iStateSubactionMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StateUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StateUsageSerializer.cs index 68a9e645..0077ce51 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StateUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StateUsageSerializer.cs @@ -90,18 +90,6 @@ internal static void Serialize(object obj, Utf8JsonWriter writer, SerializationM /// private static void SerializeAsJsonWithDerivedProperties(IStateUsage iStateUsage, Utf8JsonWriter writer) { - writer.WriteStartArray("actionDefinition"u8); - - foreach (var item in iStateUsage.actionDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("aliasIds"u8); foreach (var item in iStateUsage.AliasIds) @@ -111,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(IStateUsage iStateUsage writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iStateUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iStateUsage.chainingFeature) @@ -155,18 +131,6 @@ private static void SerializeAsJsonWithDerivedProperties(IStateUsage iStateUsage writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iStateUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iStateUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iStateUsage.differencingType) @@ -179,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IStateUsage iStateUsage writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iStateUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iStateUsage.directedUsage) @@ -458,9 +410,6 @@ private static void SerializeAsJsonWithDerivedProperties(IStateUsage iStateUsage writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iStateUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iStateUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iStateUsage.IsVariation); @@ -832,18 +781,6 @@ private static void SerializeAsJsonWithDerivedProperties(IStateUsage iStateUsage writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iStateUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iStateUsage.output) @@ -1303,18 +1240,6 @@ private static void SerializeAsJsonWithDerivedProperties(IStateUsage iStateUsage writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iStateUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iStateUsage.unioningType) @@ -1441,9 +1366,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IStateUsage iStateUs writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iStateUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iStateUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iStateUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StepSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StepSerializer.cs index a26af894..f85c94b7 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StepSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/StepSerializer.cs @@ -155,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IStep iStep, Utf8JsonWr writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iStep.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iStep.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SubclassificationSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SubclassificationSerializer.cs index f7d0327f..3c0bdb8e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SubclassificationSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SubclassificationSerializer.cs @@ -120,12 +120,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubclassification iSub writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iSubclassification.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubclassification.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iSubclassification.IsImplied); @@ -270,20 +264,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubclassification iSub writer.WriteNullValue(); } - writer.WritePropertyName("owningType"u8); - - if (iSubclassification.owningType.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubclassification.owningType.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iSubclassification.qualifiedName); @@ -302,24 +282,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubclassification iSub writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iSubclassification.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iSubclassification.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubclassification.Specific); - writer.WriteEndObject(); - writer.WritePropertyName("subclassifier"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -332,18 +294,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubclassification iSub writer.WriteStringValue(iSubclassification.Superclassifier); writer.WriteEndObject(); - writer.WriteStartArray("target"u8); - - foreach (var item in iSubclassification.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iSubclassification.textualRepresentation) @@ -387,12 +337,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISubclassification i writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iSubclassification.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubclassification.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iSubclassification.IsImplied); @@ -451,24 +395,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISubclassification i writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iSubclassification.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubclassification.Specific); - writer.WriteEndObject(); - writer.WritePropertyName("subclassifier"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -481,18 +407,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISubclassification i writer.WriteStringValue(iSubclassification.Superclassifier); writer.WriteEndObject(); - writer.WriteStartArray("target"u8); - - foreach (var item in iSubclassification.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SubjectMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SubjectMembershipSerializer.cs index 99dacad0..4d5926a2 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SubjectMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SubjectMembershipSerializer.cs @@ -129,27 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubjectMembership iSub writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iSubjectMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubjectMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iSubjectMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iSubjectMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubjectMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iSubjectMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iSubjectMembership.name); @@ -177,30 +156,12 @@ private static void SerializeAsJsonWithDerivedProperties(ISubjectMembership iSub writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubjectMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iSubjectMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubjectMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iSubjectMembership.ownedMemberName); - writer.WritePropertyName("ownedMemberParameter"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubjectMembership.ownedMemberParameter); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberShortName"u8); writer.WriteStringValue(iSubjectMembership.ownedMemberShortName); @@ -328,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubjectMembership iSub writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iSubjectMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iSubjectMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iSubjectMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iSubjectMembership.textualRepresentation) @@ -404,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISubjectMembership i writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iSubjectMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubjectMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iSubjectMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iSubjectMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iSubjectMembership.OwnedRelatedElement) @@ -468,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISubjectMembership i writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iSubjectMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iSubjectMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iSubjectMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SubsettingSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SubsettingSerializer.cs index 9f19296f..53902ed2 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SubsettingSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SubsettingSerializer.cs @@ -120,12 +120,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubsetting iSubsetting writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iSubsetting.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubsetting.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iSubsetting.IsImplied); @@ -270,20 +264,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubsetting iSubsetting writer.WriteNullValue(); } - writer.WritePropertyName("owningType"u8); - - if (iSubsetting.owningType.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubsetting.owningType.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iSubsetting.qualifiedName); @@ -302,24 +282,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubsetting iSubsetting writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iSubsetting.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iSubsetting.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubsetting.Specific); - writer.WriteEndObject(); - writer.WritePropertyName("subsettedFeature"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -332,18 +294,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISubsetting iSubsetting writer.WriteStringValue(iSubsetting.SubsettingFeature); writer.WriteEndObject(); - writer.WriteStartArray("target"u8); - - foreach (var item in iSubsetting.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iSubsetting.textualRepresentation) @@ -387,12 +337,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISubsetting iSubsett writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iSubsetting.ElementId); - writer.WritePropertyName("general"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubsetting.General); - writer.WriteEndObject(); - writer.WritePropertyName("isImplied"u8); writer.WriteBooleanValue(iSubsetting.IsImplied); @@ -451,24 +395,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISubsetting iSubsett writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iSubsetting.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("specific"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iSubsetting.Specific); - writer.WriteEndObject(); - writer.WritePropertyName("subsettedFeature"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -481,18 +407,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISubsetting iSubsett writer.WriteStringValue(iSubsetting.SubsettingFeature); writer.WriteEndObject(); - writer.WriteStartArray("target"u8); - - foreach (var item in iSubsetting.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionAsUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionAsUsageSerializer.cs index e9b6ebb5..4f3460ef 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionAsUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionAsUsageSerializer.cs @@ -243,18 +243,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionAsUsage iSuc writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iSuccessionAsUsage.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iSuccessionAsUsage.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iSuccessionAsUsage.endOwningType.HasValue) @@ -413,9 +401,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionAsUsage iSuc writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iSuccessionAsUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iSuccessionAsUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iSuccessionAsUsage.IsVariation); @@ -1222,18 +1207,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionAsUsage iSuc writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iSuccessionAsUsage.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iSuccessionAsUsage.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iSuccessionAsUsage.relatedFeature) @@ -1249,18 +1222,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionAsUsage iSuc writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iSuccessionAsUsage.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iSuccessionAsUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iSuccessionAsUsage.sourceFeature.HasValue) @@ -1275,18 +1236,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionAsUsage iSuc writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iSuccessionAsUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iSuccessionAsUsage.targetFeature) @@ -1311,18 +1260,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionAsUsage iSuc writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iSuccessionAsUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iSuccessionAsUsage.unioningType) @@ -1446,9 +1383,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISuccessionAsUsage i writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iSuccessionAsUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iSuccessionAsUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iSuccessionAsUsage.IsVariation); @@ -1504,30 +1438,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISuccessionAsUsage i writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iSuccessionAsUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iSuccessionAsUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionFlowSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionFlowSerializer.cs index 87b1f338..0c37d91e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionFlowSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionFlowSerializer.cs @@ -99,30 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlow iSucces writer.WriteEndArray(); - writer.WriteStartArray("association"u8); - - foreach (var item in iSuccessionFlow.association) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("behavior"u8); - - foreach (var item in iSuccessionFlow.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iSuccessionFlow.chainingFeature) @@ -193,18 +169,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlow iSucces writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iSuccessionFlow.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iSuccessionFlow.Direction.HasValue) @@ -231,18 +195,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlow iSucces writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iSuccessionFlow.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iSuccessionFlow.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iSuccessionFlow.endOwningType.HasValue) @@ -911,18 +863,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlow iSucces writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iSuccessionFlow.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iSuccessionFlow.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iSuccessionFlow.relatedFeature) @@ -938,18 +878,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlow iSucces writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iSuccessionFlow.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iSuccessionFlow.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iSuccessionFlow.sourceFeature.HasValue) @@ -978,18 +906,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlow iSucces writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iSuccessionFlow.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iSuccessionFlow.targetFeature) @@ -1028,18 +944,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlow iSucces writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iSuccessionFlow.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iSuccessionFlow.unioningType) @@ -1182,30 +1086,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISuccessionFlow iSuc writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iSuccessionFlow.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iSuccessionFlow.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionFlowUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionFlowUsageSerializer.cs index c8a5a2c1..863b631d 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionFlowUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionFlowUsageSerializer.cs @@ -90,18 +90,6 @@ internal static void Serialize(object obj, Utf8JsonWriter writer, SerializationM /// private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlowUsage iSuccessionFlowUsage, Utf8JsonWriter writer) { - writer.WriteStartArray("actionDefinition"u8); - - foreach (var item in iSuccessionFlowUsage.actionDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("aliasIds"u8); foreach (var item in iSuccessionFlowUsage.AliasIds) @@ -111,30 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlowUsage iS writer.WriteEndArray(); - writer.WriteStartArray("association"u8); - - foreach (var item in iSuccessionFlowUsage.association) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("behavior"u8); - - foreach (var item in iSuccessionFlowUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iSuccessionFlowUsage.chainingFeature) @@ -193,18 +157,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlowUsage iS writer.WriteNullValue(); } - writer.WriteStartArray("definition"u8); - - foreach (var item in iSuccessionFlowUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iSuccessionFlowUsage.differencingType) @@ -217,18 +169,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlowUsage iS writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iSuccessionFlowUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iSuccessionFlowUsage.directedUsage) @@ -267,18 +207,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlowUsage iS writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iSuccessionFlowUsage.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iSuccessionFlowUsage.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iSuccessionFlowUsage.endOwningType.HasValue) @@ -421,18 +349,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlowUsage iS writer.WriteEndArray(); - writer.WriteStartArray("interaction"u8); - - foreach (var item in iSuccessionFlowUsage.interaction) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("intersectingType"u8); foreach (var item in iSuccessionFlowUsage.intersectingType) @@ -490,9 +406,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlowUsage iS writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iSuccessionFlowUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iSuccessionFlowUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iSuccessionFlowUsage.IsVariation); @@ -864,18 +777,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlowUsage iS writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iSuccessionFlowUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iSuccessionFlowUsage.output) @@ -1360,18 +1261,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlowUsage iS writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iSuccessionFlowUsage.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iSuccessionFlowUsage.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iSuccessionFlowUsage.relatedFeature) @@ -1387,18 +1276,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlowUsage iS writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iSuccessionFlowUsage.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iSuccessionFlowUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iSuccessionFlowUsage.sourceFeature.HasValue) @@ -1427,18 +1304,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlowUsage iS writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iSuccessionFlowUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iSuccessionFlowUsage.targetFeature) @@ -1477,18 +1342,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccessionFlowUsage iS writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iSuccessionFlowUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iSuccessionFlowUsage.unioningType) @@ -1615,9 +1468,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISuccessionFlowUsage writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iSuccessionFlowUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iSuccessionFlowUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iSuccessionFlowUsage.IsVariation); @@ -1684,30 +1534,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISuccessionFlowUsage writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iSuccessionFlowUsage.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iSuccessionFlowUsage.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionSerializer.cs index bcabcd1d..0feb7953 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/SuccessionSerializer.cs @@ -219,18 +219,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccession iSuccession writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iSuccession.ElementId); - writer.WriteStartArray("endFeature"u8); - - foreach (var item in iSuccession.endFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("endOwningType"u8); if (iSuccession.endOwningType.HasValue) @@ -837,18 +825,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccession iSuccession writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iSuccession.qualifiedName); - writer.WriteStartArray("relatedElement"u8); - - foreach (var item in iSuccession.relatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("relatedFeature"u8); foreach (var item in iSuccession.relatedFeature) @@ -864,18 +840,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccession iSuccession writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iSuccession.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iSuccession.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("sourceFeature"u8); if (iSuccession.sourceFeature.HasValue) @@ -890,18 +854,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccession iSuccession writer.WriteNullValue(); } - writer.WriteStartArray("target"u8); - - foreach (var item in iSuccession.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("targetFeature"u8); foreach (var item in iSuccession.targetFeature) @@ -926,18 +878,6 @@ private static void SerializeAsJsonWithDerivedProperties(ISuccession iSuccession writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iSuccession.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iSuccession.unioningType) @@ -1080,30 +1020,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ISuccession iSuccess writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iSuccession.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iSuccession.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TerminateActionUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TerminateActionUsageSerializer.cs index 40bfa6ea..81ef1975 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TerminateActionUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TerminateActionUsageSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITerminateActionUsage i writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iTerminateActionUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iTerminateActionUsage.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITerminateActionUsage i writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iTerminateActionUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iTerminateActionUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iTerminateActionUsage.differencingType) @@ -179,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITerminateActionUsage i writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iTerminateActionUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iTerminateActionUsage.directedUsage) @@ -413,9 +377,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITerminateActionUsage i writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iTerminateActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iTerminateActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iTerminateActionUsage.IsVariation); @@ -787,18 +748,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITerminateActionUsage i writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iTerminateActionUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iTerminateActionUsage.output) @@ -1260,18 +1209,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITerminateActionUsage i writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iTerminateActionUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iTerminateActionUsage.unioningType) @@ -1395,9 +1332,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ITerminateActionUsag writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iTerminateActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iTerminateActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iTerminateActionUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TextualRepresentationSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TextualRepresentationSerializer.cs index b91f8728..4ace894e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TextualRepresentationSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TextualRepresentationSerializer.cs @@ -99,18 +99,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITextualRepresentation writer.WriteEndArray(); - writer.WriteStartArray("annotatedElement"u8); - - foreach (var item in iTextualRepresentation.annotatedElement) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("annotation"u8); foreach (var item in iTextualRepresentation.annotation) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TransitionFeatureMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TransitionFeatureMembershipSerializer.cs index ab97c610..2ddfdc7e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TransitionFeatureMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TransitionFeatureMembershipSerializer.cs @@ -132,27 +132,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITransitionFeatureMembe writer.WritePropertyName("kind"u8); writer.WriteStringValue(iTransitionFeatureMembership.Kind.ToString().ToLower()); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iTransitionFeatureMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iTransitionFeatureMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iTransitionFeatureMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iTransitionFeatureMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iTransitionFeatureMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iTransitionFeatureMembership.name); @@ -180,21 +159,9 @@ private static void SerializeAsJsonWithDerivedProperties(ITransitionFeatureMembe writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iTransitionFeatureMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iTransitionFeatureMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iTransitionFeatureMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iTransitionFeatureMembership.ownedMemberName); @@ -319,30 +286,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITransitionFeatureMembe writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iTransitionFeatureMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iTransitionFeatureMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iTransitionFeatureMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iTransitionFeatureMembership.textualRepresentation) @@ -404,18 +347,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ITransitionFeatureMe writer.WritePropertyName("kind"u8); writer.WriteStringValue(iTransitionFeatureMembership.Kind.ToString().ToLower()); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iTransitionFeatureMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iTransitionFeatureMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iTransitionFeatureMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iTransitionFeatureMembership.OwnedRelatedElement) @@ -468,30 +399,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ITransitionFeatureMe writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iTransitionFeatureMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iTransitionFeatureMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iTransitionFeatureMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TransitionUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TransitionUsageSerializer.cs index b6f4d8bf..ab61ac93 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TransitionUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TransitionUsageSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITransitionUsage iTrans writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iTransitionUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iTransitionUsage.chainingFeature) @@ -155,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITransitionUsage iTrans writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iTransitionUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iTransitionUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iTransitionUsage.differencingType) @@ -179,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITransitionUsage iTrans writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iTransitionUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iTransitionUsage.directedUsage) @@ -437,9 +401,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITransitionUsage iTrans writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iTransitionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iTransitionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iTransitionUsage.IsVariation); @@ -811,18 +772,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITransitionUsage iTrans writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iTransitionUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iTransitionUsage.output) @@ -1300,18 +1249,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITransitionUsage iTrans writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iTransitionUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iTransitionUsage.unioningType) @@ -1435,9 +1372,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ITransitionUsage iTr writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iTransitionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iTransitionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iTransitionUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TriggerInvocationExpressionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TriggerInvocationExpressionSerializer.cs index 18a8ee81..6fbdef8d 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TriggerInvocationExpressionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TriggerInvocationExpressionSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITriggerInvocationExpre writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iTriggerInvocationExpression.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iTriggerInvocationExpression.chainingFeature) @@ -167,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITriggerInvocationExpre writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iTriggerInvocationExpression.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("direction"u8); if (iTriggerInvocationExpression.Direction.HasValue) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TypeFeaturingSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TypeFeaturingSerializer.cs index ce6e1ed2..f3ea460b 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TypeFeaturingSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/TypeFeaturingSerializer.cs @@ -294,30 +294,6 @@ private static void SerializeAsJsonWithDerivedProperties(ITypeFeaturing iTypeFea writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iTypeFeaturing.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iTypeFeaturing.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iTypeFeaturing.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iTypeFeaturing.textualRepresentation) @@ -431,30 +407,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(ITypeFeaturing iType writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iTypeFeaturing.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iTypeFeaturing.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - } } } diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UnioningSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UnioningSerializer.cs index fe29b36e..2df7426e 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UnioningSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UnioningSerializer.cs @@ -268,30 +268,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUnioning iUnioning, Ut writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iUnioning.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iUnioning.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iUnioning.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iUnioning.textualRepresentation) @@ -405,30 +381,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IUnioning iUnioning, writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iUnioning.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iUnioning.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("unioningType"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UsageSerializer.cs index 8fc211db..5be79da8 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UsageSerializer.cs @@ -372,9 +372,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUsage iUsage, Utf8Json writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iUsage.IsVariation); @@ -1170,18 +1167,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUsage iUsage, Utf8Json writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iUsage.unioningType) @@ -1302,9 +1287,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IUsage iUsage, Utf8J writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UseCaseDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UseCaseDefinitionSerializer.cs index 19ee6a0b..a3954c49 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UseCaseDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UseCaseDefinitionSerializer.cs @@ -153,18 +153,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUseCaseDefinition iUse writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iUseCaseDefinition.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iUseCaseDefinition.directedUsage) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UseCaseUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UseCaseUsageSerializer.cs index 8849f113..71f0672a 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UseCaseUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/UseCaseUsageSerializer.cs @@ -90,18 +90,6 @@ internal static void Serialize(object obj, Utf8JsonWriter writer, SerializationM /// private static void SerializeAsJsonWithDerivedProperties(IUseCaseUsage iUseCaseUsage, Utf8JsonWriter writer) { - writer.WriteStartArray("actionDefinition"u8); - - foreach (var item in iUseCaseUsage.actionDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("actorParameter"u8); foreach (var item in iUseCaseUsage.actorParameter) @@ -123,46 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUseCaseUsage iUseCaseU writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iUseCaseUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("calculationDefinition"u8); - - if (iUseCaseUsage.calculationDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iUseCaseUsage.calculationDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - - writer.WritePropertyName("caseDefinition"u8); - - if (iUseCaseUsage.caseDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iUseCaseUsage.caseDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iUseCaseUsage.chainingFeature) @@ -195,18 +143,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUseCaseUsage iUseCaseU writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iUseCaseUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iUseCaseUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iUseCaseUsage.differencingType) @@ -219,18 +155,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUseCaseUsage iUseCaseU writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iUseCaseUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iUseCaseUsage.directedUsage) @@ -337,20 +261,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUseCaseUsage iUseCaseU writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iUseCaseUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iUseCaseUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iUseCaseUsage.importedMembership) @@ -482,9 +392,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUseCaseUsage iUseCaseU writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iUseCaseUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iUseCaseUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iUseCaseUsage.IsVariation); @@ -870,18 +777,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUseCaseUsage iUseCaseU writer.WriteNullValue(); } - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iUseCaseUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iUseCaseUsage.output) @@ -1341,18 +1236,6 @@ private static void SerializeAsJsonWithDerivedProperties(IUseCaseUsage iUseCaseU writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iUseCaseUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iUseCaseUsage.unioningType) @@ -1490,9 +1373,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IUseCaseUsage iUseCa writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iUseCaseUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iUseCaseUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iUseCaseUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/VariantMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/VariantMembershipSerializer.cs index abc69a91..3c37fba7 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/VariantMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/VariantMembershipSerializer.cs @@ -129,27 +129,12 @@ private static void SerializeAsJsonWithDerivedProperties(IVariantMembership iVar writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iVariantMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iVariantMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iVariantMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iVariantMembership.MemberName); - writer.WritePropertyName("membershipOwningNamespace"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); writer.WriteStringValue(iVariantMembership.membershipOwningNamespace); writer.WriteEndObject(); - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iVariantMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iVariantMembership.name); @@ -177,12 +162,6 @@ private static void SerializeAsJsonWithDerivedProperties(IVariantMembership iVar writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iVariantMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iVariantMembership.ownedMemberElementId); @@ -310,30 +289,6 @@ private static void SerializeAsJsonWithDerivedProperties(IVariantMembership iVar writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iVariantMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iVariantMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iVariantMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iVariantMembership.textualRepresentation) @@ -386,18 +341,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IVariantMembership i writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iVariantMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iVariantMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iVariantMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iVariantMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iVariantMembership.OwnedRelatedElement) @@ -450,30 +393,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IVariantMembership i writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iVariantMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iVariantMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iVariantMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/VerificationCaseDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/VerificationCaseDefinitionSerializer.cs index d82e55a7..1ff8f0ad 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/VerificationCaseDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/VerificationCaseDefinitionSerializer.cs @@ -153,18 +153,6 @@ private static void SerializeAsJsonWithDerivedProperties(IVerificationCaseDefini writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iVerificationCaseDefinition.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iVerificationCaseDefinition.directedUsage) diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/VerificationCaseUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/VerificationCaseUsageSerializer.cs index 566e060f..332c4f98 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/VerificationCaseUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/VerificationCaseUsageSerializer.cs @@ -90,18 +90,6 @@ internal static void Serialize(object obj, Utf8JsonWriter writer, SerializationM /// private static void SerializeAsJsonWithDerivedProperties(IVerificationCaseUsage iVerificationCaseUsage, Utf8JsonWriter writer) { - writer.WriteStartArray("actionDefinition"u8); - - foreach (var item in iVerificationCaseUsage.actionDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("actorParameter"u8); foreach (var item in iVerificationCaseUsage.actorParameter) @@ -123,32 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IVerificationCaseUsage writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iVerificationCaseUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WritePropertyName("calculationDefinition"u8); - - if (iVerificationCaseUsage.calculationDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iVerificationCaseUsage.calculationDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("caseDefinition"u8); if (iVerificationCaseUsage.caseDefinition.HasValue) @@ -195,18 +157,6 @@ private static void SerializeAsJsonWithDerivedProperties(IVerificationCaseUsage writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iVerificationCaseUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iVerificationCaseUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iVerificationCaseUsage.differencingType) @@ -219,18 +169,6 @@ private static void SerializeAsJsonWithDerivedProperties(IVerificationCaseUsage writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iVerificationCaseUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iVerificationCaseUsage.directedUsage) @@ -337,20 +275,6 @@ private static void SerializeAsJsonWithDerivedProperties(IVerificationCaseUsage writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iVerificationCaseUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iVerificationCaseUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iVerificationCaseUsage.importedMembership) @@ -470,9 +394,6 @@ private static void SerializeAsJsonWithDerivedProperties(IVerificationCaseUsage writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iVerificationCaseUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iVerificationCaseUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iVerificationCaseUsage.IsVariation); @@ -858,18 +779,6 @@ private static void SerializeAsJsonWithDerivedProperties(IVerificationCaseUsage writer.WriteNullValue(); } - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iVerificationCaseUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iVerificationCaseUsage.output) @@ -1329,18 +1238,6 @@ private static void SerializeAsJsonWithDerivedProperties(IVerificationCaseUsage writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iVerificationCaseUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iVerificationCaseUsage.unioningType) @@ -1490,9 +1387,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IVerificationCaseUsa writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iVerificationCaseUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iVerificationCaseUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iVerificationCaseUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewRenderingMembershipSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewRenderingMembershipSerializer.cs index a3d446a4..9afc1354 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewRenderingMembershipSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewRenderingMembershipSerializer.cs @@ -129,27 +129,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewRenderingMembershi writer.WritePropertyName("isLibraryElement"u8); writer.WriteBooleanValue(iViewRenderingMembership.isLibraryElement); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iViewRenderingMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberElementId"u8); - writer.WriteStringValue(iViewRenderingMembership.memberElementId); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iViewRenderingMembership.MemberName); - - writer.WritePropertyName("membershipOwningNamespace"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iViewRenderingMembership.membershipOwningNamespace); - writer.WriteEndObject(); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iViewRenderingMembership.MemberShortName); - writer.WritePropertyName("name"u8); writer.WriteStringValue(iViewRenderingMembership.name); @@ -177,21 +156,9 @@ private static void SerializeAsJsonWithDerivedProperties(IViewRenderingMembershi writer.WriteEndArray(); - writer.WritePropertyName("ownedMemberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iViewRenderingMembership.ownedMemberElement); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberElementId"u8); writer.WriteStringValue(iViewRenderingMembership.ownedMemberElementId); - writer.WritePropertyName("ownedMemberFeature"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iViewRenderingMembership.ownedMemberFeature); - writer.WriteEndObject(); - writer.WritePropertyName("ownedMemberName"u8); writer.WriteStringValue(iViewRenderingMembership.ownedMemberName); @@ -328,30 +295,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewRenderingMembershi writer.WritePropertyName("shortName"u8); writer.WriteStringValue(iViewRenderingMembership.shortName); - writer.WriteStartArray("source"u8); - - foreach (var item in iViewRenderingMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iViewRenderingMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("textualRepresentation"u8); foreach (var item in iViewRenderingMembership.textualRepresentation) @@ -404,18 +347,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IViewRenderingMember writer.WritePropertyName("isImpliedIncluded"u8); writer.WriteBooleanValue(iViewRenderingMembership.IsImpliedIncluded); - writer.WritePropertyName("memberElement"u8); - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iViewRenderingMembership.MemberElement); - writer.WriteEndObject(); - - writer.WritePropertyName("memberName"u8); - writer.WriteStringValue(iViewRenderingMembership.MemberName); - - writer.WritePropertyName("memberShortName"u8); - writer.WriteStringValue(iViewRenderingMembership.MemberShortName); - writer.WriteStartArray("ownedRelatedElement"u8); foreach (var item in iViewRenderingMembership.OwnedRelatedElement) @@ -468,30 +399,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IViewRenderingMember writer.WriteNullValue(); } - writer.WriteStartArray("source"u8); - - foreach (var item in iViewRenderingMembership.Source) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - - writer.WriteStartArray("target"u8); - - foreach (var item in iViewRenderingMembership.Target) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("visibility"u8); writer.WriteStringValue(iViewRenderingMembership.Visibility.ToString().ToLower()); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewUsageSerializer.cs index a561a7bb..d8111a81 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewUsageSerializer.cs @@ -131,18 +131,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewUsage iViewUsage, writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iViewUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iViewUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iViewUsage.differencingType) @@ -401,9 +389,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewUsage iViewUsage, writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iViewUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iViewUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iViewUsage.IsVariation); @@ -1205,18 +1190,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewUsage iViewUsage, writer.WriteNullValue(); } - writer.WriteStartArray("partDefinition"u8); - - foreach (var item in iViewUsage.partDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("portionKind"u8); if (iViewUsage.PortionKind.HasValue) @@ -1258,18 +1231,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewUsage iViewUsage, writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iViewUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iViewUsage.unioningType) @@ -1433,9 +1394,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IViewUsage iViewUsag writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iViewUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iViewUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iViewUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewpointDefinitionSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewpointDefinitionSerializer.cs index d5d617e0..05a16d5d 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewpointDefinitionSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewpointDefinitionSerializer.cs @@ -126,9 +126,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewpointDefinition iV writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iViewpointDefinition.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iViewpointDefinition.DeclaredShortName); - writer.WriteStartArray("differencingType"u8); foreach (var item in iViewpointDefinition.differencingType) @@ -141,18 +138,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewpointDefinition iV writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iViewpointDefinition.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iViewpointDefinition.directedUsage) @@ -1126,9 +1111,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IViewpointDefinition writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iViewpointDefinition.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iViewpointDefinition.DeclaredShortName); - writer.WritePropertyName("elementId"u8); writer.WriteStringValue(iViewpointDefinition.ElementId); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewpointUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewpointUsageSerializer.cs index f2b23fb3..745254e3 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewpointUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/ViewpointUsageSerializer.cs @@ -123,18 +123,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewpointUsage iViewpo writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iViewpointUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("chainingFeature"u8); foreach (var item in iViewpointUsage.chainingFeature) @@ -147,20 +135,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewpointUsage iViewpo writer.WriteEndArray(); - writer.WritePropertyName("constraintDefinition"u8); - - if (iViewpointUsage.constraintDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iViewpointUsage.constraintDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("crossFeature"u8); if (iViewpointUsage.crossFeature.HasValue) @@ -178,21 +152,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewpointUsage iViewpo writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iViewpointUsage.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iViewpointUsage.DeclaredShortName); - - writer.WriteStartArray("definition"u8); - - foreach (var item in iViewpointUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iViewpointUsage.differencingType) @@ -205,18 +164,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewpointUsage iViewpo writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iViewpointUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iViewpointUsage.directedUsage) @@ -335,20 +282,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewpointUsage iViewpo writer.WriteEndArray(); - writer.WritePropertyName("function"u8); - - if (iViewpointUsage.function.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iViewpointUsage.function.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WriteStartArray("importedMembership"u8); foreach (var item in iViewpointUsage.importedMembership) @@ -468,9 +401,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewpointUsage iViewpo writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iViewpointUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iViewpointUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iViewpointUsage.IsVariation); @@ -1283,20 +1213,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewpointUsage iViewpo writer.WriteNullValue(); } - writer.WritePropertyName("predicate"u8); - - if (iViewpointUsage.predicate.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iViewpointUsage.predicate.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("qualifiedName"u8); writer.WriteStringValue(iViewpointUsage.qualifiedName); @@ -1315,20 +1231,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewpointUsage iViewpo writer.WriteEndArray(); - writer.WritePropertyName("requirementDefinition"u8); - - if (iViewpointUsage.requirementDefinition.HasValue) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(iViewpointUsage.requirementDefinition.Value); - writer.WriteEndObject(); - } - else - { - writer.WriteNullValue(); - } - writer.WritePropertyName("result"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -1377,18 +1279,6 @@ private static void SerializeAsJsonWithDerivedProperties(IViewpointUsage iViewpo writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iViewpointUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iViewpointUsage.unioningType) @@ -1488,9 +1378,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IViewpointUsage iVie writer.WritePropertyName("declaredName"u8); writer.WriteStringValue(iViewpointUsage.DeclaredName); - writer.WritePropertyName("declaredShortName"u8); - writer.WriteStringValue(iViewpointUsage.DeclaredShortName); - writer.WritePropertyName("direction"u8); if (iViewpointUsage.Direction.HasValue) @@ -1538,9 +1425,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IViewpointUsage iVie writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iViewpointUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iViewpointUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iViewpointUsage.IsVariation); diff --git a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/WhileLoopActionUsageSerializer.cs b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/WhileLoopActionUsageSerializer.cs index 2978bff4..3d30a8d1 100644 --- a/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/WhileLoopActionUsageSerializer.cs +++ b/SysML2.NET.Serializer.Json/Core/AutoGenSerializer/WhileLoopActionUsageSerializer.cs @@ -111,18 +111,6 @@ private static void SerializeAsJsonWithDerivedProperties(IWhileLoopActionUsage i writer.WriteEndArray(); - writer.WriteStartArray("behavior"u8); - - foreach (var item in iWhileLoopActionUsage.behavior) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WritePropertyName("bodyAction"u8); writer.WriteStartObject(); writer.WritePropertyName("@id"u8); @@ -161,18 +149,6 @@ private static void SerializeAsJsonWithDerivedProperties(IWhileLoopActionUsage i writer.WritePropertyName("declaredShortName"u8); writer.WriteStringValue(iWhileLoopActionUsage.DeclaredShortName); - writer.WriteStartArray("definition"u8); - - foreach (var item in iWhileLoopActionUsage.definition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("differencingType"u8); foreach (var item in iWhileLoopActionUsage.differencingType) @@ -185,18 +161,6 @@ private static void SerializeAsJsonWithDerivedProperties(IWhileLoopActionUsage i writer.WriteEndArray(); - writer.WriteStartArray("directedFeature"u8); - - foreach (var item in iWhileLoopActionUsage.directedFeature) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("directedUsage"u8); foreach (var item in iWhileLoopActionUsage.directedUsage) @@ -419,9 +383,6 @@ private static void SerializeAsJsonWithDerivedProperties(IWhileLoopActionUsage i writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iWhileLoopActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iWhileLoopActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iWhileLoopActionUsage.IsVariation); @@ -793,18 +754,6 @@ private static void SerializeAsJsonWithDerivedProperties(IWhileLoopActionUsage i writer.WriteEndArray(); - writer.WriteStartArray("occurrenceDefinition"u8); - - foreach (var item in iWhileLoopActionUsage.occurrenceDefinition) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("output"u8); foreach (var item in iWhileLoopActionUsage.output) @@ -1252,18 +1201,6 @@ private static void SerializeAsJsonWithDerivedProperties(IWhileLoopActionUsage i writer.WriteEndArray(); - writer.WriteStartArray("type"u8); - - foreach (var item in iWhileLoopActionUsage.type) - { - writer.WriteStartObject(); - writer.WritePropertyName("@id"u8); - writer.WriteStringValue(item); - writer.WriteEndObject(); - } - - writer.WriteEndArray(); - writer.WriteStartArray("unioningType"u8); foreach (var item in iWhileLoopActionUsage.unioningType) @@ -1407,9 +1344,6 @@ private static void SerializeAsJsonWithoutDerivedProperties(IWhileLoopActionUsag writer.WritePropertyName("isUnique"u8); writer.WriteBooleanValue(iWhileLoopActionUsage.IsUnique); - writer.WritePropertyName("isVariable"u8); - writer.WriteBooleanValue(iWhileLoopActionUsage.IsVariable); - writer.WritePropertyName("isVariation"u8); writer.WriteBooleanValue(iWhileLoopActionUsage.IsVariation); diff --git a/SysML2.NET/Core/AutoGenDto/AcceptActionUsage.cs b/SysML2.NET/Core/AutoGenDto/AcceptActionUsage.cs index 24c54540..76418548 100644 --- a/SysML2.NET/Core/AutoGenDto/AcceptActionUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/AcceptActionUsage.cs @@ -75,7 +75,7 @@ public partial class AcceptActionUsage : IAcceptActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -125,7 +125,7 @@ public partial class AcceptActionUsage : IAcceptActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -147,7 +147,7 @@ public partial class AcceptActionUsage : IAcceptActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -416,7 +416,11 @@ public partial class AcceptActionUsage : IAcceptActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -703,7 +707,7 @@ public partial class AcceptActionUsage : IAcceptActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1082,7 +1086,7 @@ public partial class AcceptActionUsage : IAcceptActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/ActionDefinition.cs b/SysML2.NET/Core/AutoGenDto/ActionDefinition.cs index 1912add7..2c3520ac 100644 --- a/SysML2.NET/Core/AutoGenDto/ActionDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/ActionDefinition.cs @@ -101,7 +101,7 @@ public partial class ActionDefinition : IActionDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenDto/ActionUsage.cs b/SysML2.NET/Core/AutoGenDto/ActionUsage.cs index c5c92f6c..844262be 100644 --- a/SysML2.NET/Core/AutoGenDto/ActionUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/ActionUsage.cs @@ -76,7 +76,7 @@ public partial class ActionUsage : IActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -126,7 +126,7 @@ public partial class ActionUsage : IActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -148,7 +148,7 @@ public partial class ActionUsage : IActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -417,7 +417,11 @@ public partial class ActionUsage : IActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -704,7 +708,7 @@ public partial class ActionUsage : IActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1058,7 +1062,7 @@ public partial class ActionUsage : IActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/ActorMembership.cs b/SysML2.NET/Core/AutoGenDto/ActorMembership.cs index 0e61a0cd..9cf0359c 100644 --- a/SysML2.NET/Core/AutoGenDto/ActorMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/ActorMembership.cs @@ -122,7 +122,11 @@ public partial class ActorMembership : IActorMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -130,7 +134,7 @@ public partial class ActorMembership : IActorMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -138,7 +142,11 @@ public partial class ActorMembership : IActorMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -149,7 +157,7 @@ public partial class ActorMembership : IActorMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -157,7 +165,11 @@ public partial class ActorMembership : IActorMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -204,7 +216,7 @@ public partial class ActorMembership : IActorMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -222,7 +234,7 @@ public partial class ActorMembership : IActorMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IParameterMembership.OwnedMemberParameter")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => ((SysML2.NET.Core.DTO.Kernel.Behaviors.IParameterMembership)this).ownedMemberParameter; /// /// The name of the ownedMemberElement. @@ -239,7 +251,7 @@ public partial class ActorMembership : IActorMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674993_898044_43344")] [RedefinedByProperty("IActorMembership.OwnedActorParameter")] [Implements(implementation: "IParameterMembership.OwnedMemberParameter")] - public Guid ownedMemberParameter { get; internal set; } + Guid Kernel.Behaviors.IParameterMembership.ownedMemberParameter => this.ownedActorParameter; /// /// The shortName of the ownedMemberElement. @@ -353,7 +365,11 @@ public partial class ActorMembership : IActorMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -362,7 +378,18 @@ public partial class ActorMembership : IActorMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/AllocationDefinition.cs b/SysML2.NET/Core/AutoGenDto/AllocationDefinition.cs index a8dbec30..8a3a66af 100644 --- a/SysML2.NET/Core/AutoGenDto/AllocationDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/AllocationDefinition.cs @@ -74,7 +74,7 @@ public partial class AllocationDefinition : IAllocationDefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1562476168385_824569_22106")] [RedefinedByProperty("IConnectionDefinition.ConnectionEnd")] [Implements(implementation: "IAssociation.AssociationEnd")] - public List associationEnd { get; internal set; } = []; + List Kernel.Associations.IAssociation.associationEnd => this.connectionEnd; /// /// The Usages that define the things related by the ConnectionDefinition. @@ -155,7 +155,7 @@ public partial class AllocationDefinition : IAllocationDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => ((SysML2.NET.Core.DTO.Kernel.Associations.IAssociation)this).associationEnd; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -287,7 +287,14 @@ public partial class AllocationDefinition : IAllocationDefinition [Property(xmiId: "_18_5_3_b9102da_1564072709069_937523_30797", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IConnectionDefinition.IsSufficient")] [Implements(implementation: "IType.IsSufficient")] - bool Core.Types.IType.IsSufficient { get; set; } + bool Core.Types.IType.IsSufficient + { + get => this.IsSufficient; + set + { + this.IsSufficient = value; + } + } /// /// Whether this Definition is for a variation point or not. If true, then all the memberships of the @@ -778,7 +785,7 @@ public partial class AllocationDefinition : IAllocationDefinition [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedType; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -806,7 +813,11 @@ public partial class AllocationDefinition : IAllocationDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType.HasValue ? [this.sourceType.Value] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -824,7 +835,11 @@ public partial class AllocationDefinition : IAllocationDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetType; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenDto/AllocationUsage.cs b/SysML2.NET/Core/AutoGenDto/AllocationUsage.cs index d261026e..07e18454 100644 --- a/SysML2.NET/Core/AutoGenDto/AllocationUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/AllocationUsage.cs @@ -70,7 +70,7 @@ public partial class AllocationUsage : IAllocationUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IConnectionUsage.ConnectionDefinition")] [Implements(implementation: "IConnector.Association")] - public List association { get; internal set; } = []; + List Kernel.Connectors.IConnector.association => ((SysML2.NET.Core.DTO.Systems.Connections.IConnectionUsage)this).connectionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -94,7 +94,7 @@ public partial class AllocationUsage : IAllocationUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674983_471497_43284")] [RedefinedByProperty("IAllocationUsage.AllocationDefinition")] [Implements(implementation: "IConnectionUsage.ConnectionDefinition")] - public List connectionDefinition { get; internal set; } = []; + List Systems.Connections.IConnectionUsage.connectionDefinition => this.allocationDefinition; /// /// The endFeatures of a Connector, which redefine the endFeatures of the associations of the Connector. @@ -151,7 +151,7 @@ public partial class AllocationUsage : IAllocationUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -215,7 +215,7 @@ public partial class AllocationUsage : IAllocationUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -450,7 +450,11 @@ public partial class AllocationUsage : IAllocationUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1094,7 +1098,7 @@ public partial class AllocationUsage : IAllocationUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1122,7 +1126,11 @@ public partial class AllocationUsage : IAllocationUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1140,7 +1148,11 @@ public partial class AllocationUsage : IAllocationUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1170,7 +1182,7 @@ public partial class AllocationUsage : IAllocationUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/AnalysisCaseDefinition.cs b/SysML2.NET/Core/AutoGenDto/AnalysisCaseDefinition.cs index 6e4e9a54..9aab7bef 100644 --- a/SysML2.NET/Core/AutoGenDto/AnalysisCaseDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/AnalysisCaseDefinition.cs @@ -117,7 +117,7 @@ public partial class AnalysisCaseDefinition : IAnalysisCaseDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenDto/AnalysisCaseUsage.cs b/SysML2.NET/Core/AutoGenDto/AnalysisCaseUsage.cs index 971a4783..17e67e5b 100644 --- a/SysML2.NET/Core/AutoGenDto/AnalysisCaseUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/AnalysisCaseUsage.cs @@ -57,7 +57,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition { get; internal set; } = []; + List Systems.Actions.IActionUsage.actionDefinition => ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.HasValue ? [((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.Value] : []; /// /// The parameters of this CaseUsage that represent actors involved in the case. @@ -90,7 +90,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Function that is the type of this CalculationUsage. Nominally, this would be a @@ -102,7 +102,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1565500905804_589845_30779")] [RedefinedByProperty("ICaseUsage.CaseDefinition")] [Implements(implementation: "ICalculationUsage.CalculationDefinition")] - public Guid? calculationDefinition { get; internal set; } + Guid? Systems.Calculations.ICalculationUsage.calculationDefinition => ((SysML2.NET.Core.DTO.Systems.Cases.ICaseUsage)this).caseDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Cases.ICaseUsage)this).caseDefinition.Value : Guid.Empty; /// /// The CaseDefinition that is the type of this CaseUsage. @@ -111,7 +111,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1588213526305_899324_302")] [RedefinedByProperty("IAnalysisCaseUsage.AnalysisCaseDefinition")] [Implements(implementation: "ICaseUsage.CaseDefinition")] - public Guid? caseDefinition { get; internal set; } + Guid? Systems.Cases.ICaseUsage.caseDefinition => this.analysisCaseDefinition.HasValue ? this.analysisCaseDefinition.Value : Guid.Empty; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -161,7 +161,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -183,7 +183,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -278,7 +278,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -469,7 +469,11 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -764,7 +768,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => ((SysML2.NET.Core.DTO.Systems.Actions.IActionUsage)this).actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1147,7 +1151,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/Annotation.cs b/SysML2.NET/Core/AutoGenDto/Annotation.cs index 930d819e..9fff5f95 100644 --- a/SysML2.NET/Core/AutoGenDto/Annotation.cs +++ b/SysML2.NET/Core/AutoGenDto/Annotation.cs @@ -280,7 +280,11 @@ public partial class Annotation : IAnnotation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAnnotation.AnnotatingElement")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.annotatingElement]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -289,7 +293,18 @@ public partial class Annotation : IAnnotation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAnnotation.AnnotatedElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.AnnotatedElement]; + set + { + if (value.Count != 0) + { + this.AnnotatedElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/AssertConstraintUsage.cs b/SysML2.NET/Core/AutoGenDto/AssertConstraintUsage.cs index 609c6460..a9f42e68 100644 --- a/SysML2.NET/Core/AutoGenDto/AssertConstraintUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/AssertConstraintUsage.cs @@ -72,7 +72,7 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -132,7 +132,7 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -154,7 +154,7 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -249,7 +249,7 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.HasValue ? ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -447,7 +447,11 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1054,7 +1058,7 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public Guid? predicate { get; internal set; } + Guid? Kernel.Functions.IBooleanExpression.predicate => this.constraintDefinition.HasValue ? this.constraintDefinition.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1107,7 +1111,7 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/AssignmentActionUsage.cs b/SysML2.NET/Core/AutoGenDto/AssignmentActionUsage.cs index a3413584..924fcc24 100644 --- a/SysML2.NET/Core/AutoGenDto/AssignmentActionUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/AssignmentActionUsage.cs @@ -74,7 +74,7 @@ public partial class AssignmentActionUsage : IAssignmentActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -124,7 +124,7 @@ public partial class AssignmentActionUsage : IAssignmentActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -146,7 +146,7 @@ public partial class AssignmentActionUsage : IAssignmentActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -415,7 +415,11 @@ public partial class AssignmentActionUsage : IAssignmentActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -702,7 +706,7 @@ public partial class AssignmentActionUsage : IAssignmentActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1073,7 +1077,7 @@ public partial class AssignmentActionUsage : IAssignmentActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/Association.cs b/SysML2.NET/Core/AutoGenDto/Association.cs index a273194c..08a98204 100644 --- a/SysML2.NET/Core/AutoGenDto/Association.cs +++ b/SysML2.NET/Core/AutoGenDto/Association.cs @@ -127,7 +127,7 @@ public partial class Association : IAssociation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.associationEnd; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -507,7 +507,7 @@ public partial class Association : IAssociation [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedType; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -535,7 +535,11 @@ public partial class Association : IAssociation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType.HasValue ? [this.sourceType.Value] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -553,7 +557,11 @@ public partial class Association : IAssociation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetType; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenDto/AssociationStructure.cs b/SysML2.NET/Core/AutoGenDto/AssociationStructure.cs index 16d92521..8702684e 100644 --- a/SysML2.NET/Core/AutoGenDto/AssociationStructure.cs +++ b/SysML2.NET/Core/AutoGenDto/AssociationStructure.cs @@ -127,7 +127,7 @@ public partial class AssociationStructure : IAssociationStructure [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.associationEnd; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -507,7 +507,7 @@ public partial class AssociationStructure : IAssociationStructure [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedType; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -535,7 +535,11 @@ public partial class AssociationStructure : IAssociationStructure [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType.HasValue ? [this.sourceType.Value] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -553,7 +557,11 @@ public partial class AssociationStructure : IAssociationStructure [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetType; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenDto/AttributeUsage.cs b/SysML2.NET/Core/AutoGenDto/AttributeUsage.cs index 295f7a73..02c83b9c 100644 --- a/SysML2.NET/Core/AutoGenDto/AttributeUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/AttributeUsage.cs @@ -116,7 +116,7 @@ public partial class AttributeUsage : IAttributeUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IAttributeUsage.AttributeDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.attributeDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -371,7 +371,7 @@ public partial class AttributeUsage : IAttributeUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IAttributeUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool Systems.DefinitionAndUsage.IUsage.isReference { get; } + bool Systems.DefinitionAndUsage.IUsage.isReference => this.isReference; /// /// Whether all things that meet the classification conditions of this Type must be classified by the @@ -399,7 +399,11 @@ public partial class AttributeUsage : IAttributeUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1011,7 +1015,7 @@ public partial class AttributeUsage : IAttributeUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/Behavior.cs b/SysML2.NET/Core/AutoGenDto/Behavior.cs index 82db7598..65d11f91 100644 --- a/SysML2.NET/Core/AutoGenDto/Behavior.cs +++ b/SysML2.NET/Core/AutoGenDto/Behavior.cs @@ -90,7 +90,7 @@ public partial class Behavior : IBehavior [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The Documentation owned by this Element. diff --git a/SysML2.NET/Core/AutoGenDto/BindingConnector.cs b/SysML2.NET/Core/AutoGenDto/BindingConnector.cs index d8a63e56..7adc99e7 100644 --- a/SysML2.NET/Core/AutoGenDto/BindingConnector.cs +++ b/SysML2.NET/Core/AutoGenDto/BindingConnector.cs @@ -172,7 +172,7 @@ public partial class BindingConnector : IBindingConnector [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -733,7 +733,7 @@ public partial class BindingConnector : IBindingConnector [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -761,7 +761,11 @@ public partial class BindingConnector : IBindingConnector [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -779,7 +783,11 @@ public partial class BindingConnector : IBindingConnector [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -809,7 +817,7 @@ public partial class BindingConnector : IBindingConnector [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => this.association; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/BindingConnectorAsUsage.cs b/SysML2.NET/Core/AutoGenDto/BindingConnectorAsUsage.cs index 924c8452..977b0ae5 100644 --- a/SysML2.NET/Core/AutoGenDto/BindingConnectorAsUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/BindingConnectorAsUsage.cs @@ -191,7 +191,7 @@ public partial class BindingConnectorAsUsage : IBindingConnectorAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -410,7 +410,11 @@ public partial class BindingConnectorAsUsage : IBindingConnectorAsUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1017,7 +1021,7 @@ public partial class BindingConnectorAsUsage : IBindingConnectorAsUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1045,7 +1049,11 @@ public partial class BindingConnectorAsUsage : IBindingConnectorAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1063,7 +1071,11 @@ public partial class BindingConnectorAsUsage : IBindingConnectorAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1093,7 +1105,7 @@ public partial class BindingConnectorAsUsage : IBindingConnectorAsUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => this.association; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/BooleanExpression.cs b/SysML2.NET/Core/AutoGenDto/BooleanExpression.cs index 38cc5622..9a73a13e 100644 --- a/SysML2.NET/Core/AutoGenDto/BooleanExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/BooleanExpression.cs @@ -60,7 +60,7 @@ public partial class BooleanExpression : IBooleanExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -121,7 +121,7 @@ public partial class BooleanExpression : IBooleanExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -207,7 +207,7 @@ public partial class BooleanExpression : IBooleanExpression [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? IExpression.function => this.predicate.HasValue ? this.predicate.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. diff --git a/SysML2.NET/Core/AutoGenDto/CalculationDefinition.cs b/SysML2.NET/Core/AutoGenDto/CalculationDefinition.cs index ece4682d..f6521667 100644 --- a/SysML2.NET/Core/AutoGenDto/CalculationDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/CalculationDefinition.cs @@ -110,7 +110,7 @@ public partial class CalculationDefinition : ICalculationDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenDto/CalculationUsage.cs b/SysML2.NET/Core/AutoGenDto/CalculationUsage.cs index 4a6fb444..0993fed4 100644 --- a/SysML2.NET/Core/AutoGenDto/CalculationUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/CalculationUsage.cs @@ -61,7 +61,7 @@ public partial class CalculationUsage : ICalculationUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition { get; internal set; } = []; + List Systems.Actions.IActionUsage.actionDefinition => this.calculationDefinition.HasValue ? [this.calculationDefinition.Value] : []; /// /// Various alternative identifiers for this Element. Generally, these will be set by tools. @@ -77,7 +77,7 @@ public partial class CalculationUsage : ICalculationUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Function that is the type of this CalculationUsage. Nominally, this would be a @@ -138,7 +138,7 @@ public partial class CalculationUsage : ICalculationUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -160,7 +160,7 @@ public partial class CalculationUsage : ICalculationUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -255,7 +255,7 @@ public partial class CalculationUsage : ICalculationUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => this.calculationDefinition.HasValue ? this.calculationDefinition.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -446,7 +446,11 @@ public partial class CalculationUsage : ICalculationUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -733,7 +737,7 @@ public partial class CalculationUsage : ICalculationUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => ((SysML2.NET.Core.DTO.Systems.Actions.IActionUsage)this).actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1098,7 +1102,7 @@ public partial class CalculationUsage : ICalculationUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/CaseDefinition.cs b/SysML2.NET/Core/AutoGenDto/CaseDefinition.cs index ead008ce..12469b10 100644 --- a/SysML2.NET/Core/AutoGenDto/CaseDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/CaseDefinition.cs @@ -119,7 +119,7 @@ public partial class CaseDefinition : ICaseDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenDto/CaseUsage.cs b/SysML2.NET/Core/AutoGenDto/CaseUsage.cs index 7bfa1666..feb4e0e6 100644 --- a/SysML2.NET/Core/AutoGenDto/CaseUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/CaseUsage.cs @@ -57,7 +57,7 @@ public partial class CaseUsage : ICaseUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition { get; internal set; } = []; + List Systems.Actions.IActionUsage.actionDefinition => ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.HasValue ? [((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.Value] : []; /// /// The parameters of this CaseUsage that represent actors involved in the case. @@ -82,7 +82,7 @@ public partial class CaseUsage : ICaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Function that is the type of this CalculationUsage. Nominally, this would be a @@ -94,7 +94,7 @@ public partial class CaseUsage : ICaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1565500905804_589845_30779")] [RedefinedByProperty("ICaseUsage.CaseDefinition")] [Implements(implementation: "ICalculationUsage.CalculationDefinition")] - public Guid? calculationDefinition { get; internal set; } + Guid? Systems.Calculations.ICalculationUsage.calculationDefinition => this.caseDefinition.HasValue ? this.caseDefinition.Value : Guid.Empty; /// /// The CaseDefinition that is the type of this CaseUsage. @@ -152,7 +152,7 @@ public partial class CaseUsage : ICaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -174,7 +174,7 @@ public partial class CaseUsage : ICaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -269,7 +269,7 @@ public partial class CaseUsage : ICaseUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -460,7 +460,11 @@ public partial class CaseUsage : ICaseUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -755,7 +759,7 @@ public partial class CaseUsage : ICaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => ((SysML2.NET.Core.DTO.Systems.Actions.IActionUsage)this).actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1129,7 +1133,7 @@ public partial class CaseUsage : ICaseUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/CollectExpression.cs b/SysML2.NET/Core/AutoGenDto/CollectExpression.cs index 37ca36a8..ed77c376 100644 --- a/SysML2.NET/Core/AutoGenDto/CollectExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/CollectExpression.cs @@ -70,7 +70,7 @@ public partial class CollectExpression : ICollectExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -131,7 +131,7 @@ public partial class CollectExpression : ICollectExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -443,7 +443,14 @@ public partial class CollectExpression : ICollectExpression [Property(xmiId: "_18_5_3_12e503d9_1557528808100_646606_111674", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("ICollectExpression.Operator")] [Implements(implementation: "IOperatorExpression.Operator")] - string IOperatorExpression.Operator { get; set; } + string IOperatorExpression.Operator + { + get => this.Operator; + set + { + this.Operator = value; + } + } /// /// All features related to this Type by FeatureMemberships that have direction out or inout. diff --git a/SysML2.NET/Core/AutoGenDto/ConcernDefinition.cs b/SysML2.NET/Core/AutoGenDto/ConcernDefinition.cs index b46f0d1c..f7cf3be0 100644 --- a/SysML2.NET/Core/AutoGenDto/ConcernDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/ConcernDefinition.cs @@ -88,7 +88,14 @@ public partial class ConcernDefinition : IConcernDefinition [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementDefinition.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -110,7 +117,7 @@ public partial class ConcernDefinition : IConcernDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenDto/ConcernUsage.cs b/SysML2.NET/Core/AutoGenDto/ConcernUsage.cs index aa602bb6..7ea8d561 100644 --- a/SysML2.NET/Core/AutoGenDto/ConcernUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/ConcernUsage.cs @@ -82,7 +82,7 @@ public partial class ConcernUsage : IConcernUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -113,7 +113,7 @@ public partial class ConcernUsage : IConcernUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578025035149_386_969")] [RedefinedByProperty("IRequirementUsage.RequirementDefinition")] [Implements(implementation: "IConstraintUsage.ConstraintDefinition")] - public Guid? constraintDefinition { get; internal set; } + Guid? Systems.Constraints.IConstraintUsage.constraintDefinition => ((SysML2.NET.Core.DTO.Systems.Requirements.IRequirementUsage)this).requirementDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Requirements.IRequirementUsage)this).requirementDefinition.Value : Guid.Empty; /// /// The second chainingFeature of the crossedFeature of the ownedCrossSubsetting of this Feature, if it @@ -141,7 +141,14 @@ public partial class ConcernUsage : IConcernUsage [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementUsage.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The Classifiers that are the types of this Usage. Nominally, these are Definitions, but other kinds @@ -152,7 +159,7 @@ public partial class ConcernUsage : IConcernUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -174,7 +181,7 @@ public partial class ConcernUsage : IConcernUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -278,7 +285,7 @@ public partial class ConcernUsage : IConcernUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.HasValue ? ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -469,7 +476,11 @@ public partial class ConcernUsage : IConcernUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1076,7 +1087,7 @@ public partial class ConcernUsage : IConcernUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public Guid? predicate { get; internal set; } + Guid? Kernel.Functions.IBooleanExpression.predicate => ((SysML2.NET.Core.DTO.Systems.Constraints.IConstraintUsage)this).constraintDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Constraints.IConstraintUsage)this).constraintDefinition.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1117,7 +1128,7 @@ public partial class ConcernUsage : IConcernUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578067546711_751168_1745")] [RedefinedByProperty("IConcernUsage.ConcernDefinition")] [Implements(implementation: "IRequirementUsage.RequirementDefinition")] - public Guid? requirementDefinition { get; internal set; } + Guid? IRequirementUsage.requirementDefinition => this.concernDefinition.HasValue ? this.concernDefinition.Value : Guid.Empty; /// /// An output parameter of the Expression whose value is the result of the Expression. The result of an @@ -1184,7 +1195,7 @@ public partial class ConcernUsage : IConcernUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/ConjugatedPortDefinition.cs b/SysML2.NET/Core/AutoGenDto/ConjugatedPortDefinition.cs index b49c7a79..8b57f405 100644 --- a/SysML2.NET/Core/AutoGenDto/ConjugatedPortDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/ConjugatedPortDefinition.cs @@ -387,7 +387,7 @@ public partial class ConjugatedPortDefinition : IConjugatedPortDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1543092026091_217766_16748")] [RedefinedByProperty("IConjugatedPortDefinition.OwnedPortConjugator")] [Implements(implementation: "IType.OwnedConjugator")] - public Guid? ownedConjugator { get; internal set; } + Guid? Core.Types.IType.ownedConjugator => this.ownedPortConjugator; /// /// The ConnectorAsUsages that are ownedUsages of this Definition. Note that this list includes @@ -716,7 +716,7 @@ public partial class ConjugatedPortDefinition : IConjugatedPortDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674980_717955_43271")] [RedefinedByProperty("IConjugatedPortDefinition.OriginalPortDefinition")] [Implements(implementation: "IElement.OwningNamespace")] - public Guid? owningNamespace { get; internal set; } + Guid? Root.Elements.IElement.owningNamespace => this.originalPortDefinition; /// /// The Relationship for which this Element is an ownedRelatedElement, if any. diff --git a/SysML2.NET/Core/AutoGenDto/ConjugatedPortTyping.cs b/SysML2.NET/Core/AutoGenDto/ConjugatedPortTyping.cs index 299490ee..7b944890 100644 --- a/SysML2.NET/Core/AutoGenDto/ConjugatedPortTyping.cs +++ b/SysML2.NET/Core/AutoGenDto/ConjugatedPortTyping.cs @@ -104,7 +104,14 @@ public partial class ConjugatedPortTyping : IConjugatedPortTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IFeatureTyping.Type")] [Implements(implementation: "ISpecialization.General")] - public Guid General { get; set; } + Guid Core.Types.ISpecialization.General + { + get => ((SysML2.NET.Core.DTO.Core.Features.IFeatureTyping)this).Type; + set + { + ((SysML2.NET.Core.DTO.Core.Features.IFeatureTyping)this).Type = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -235,7 +242,7 @@ public partial class ConjugatedPortTyping : IConjugatedPortTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("IFeatureTyping.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public Guid? owningType { get; internal set; } + Guid? Core.Types.ISpecialization.owningType => this.owningFeature.HasValue ? this.owningFeature.Value : Guid.Empty; /// /// The originalPortDefinition of the conjugatedPortDefinition of this ConjugatedPortTyping. @@ -281,7 +288,18 @@ public partial class ConjugatedPortTyping : IConjugatedPortTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific = value[0]; + } + + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -290,7 +308,14 @@ public partial class ConjugatedPortTyping : IConjugatedPortTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureTyping.TypedFeature")] [Implements(implementation: "ISpecialization.Specific")] - public Guid Specific { get; set; } + Guid Core.Types.ISpecialization.Specific + { + get => this.TypedFeature; + set + { + this.TypedFeature = value; + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -299,7 +324,18 @@ public partial class ConjugatedPortTyping : IConjugatedPortTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. @@ -317,7 +353,14 @@ public partial class ConjugatedPortTyping : IConjugatedPortTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674980_563969_43273")] [RedefinedByProperty("IConjugatedPortTyping.ConjugatedPortDefinition")] [Implements(implementation: "IFeatureTyping.Type")] - public Guid Type { get; set; } + Guid Core.Features.IFeatureTyping.Type + { + get => this.ConjugatedPortDefinition; + set + { + this.ConjugatedPortDefinition = value; + } + } /// /// The Feature that has a type determined by this FeatureTyping. diff --git a/SysML2.NET/Core/AutoGenDto/Conjugation.cs b/SysML2.NET/Core/AutoGenDto/Conjugation.cs index 49148cdd..f2ea4689 100644 --- a/SysML2.NET/Core/AutoGenDto/Conjugation.cs +++ b/SysML2.NET/Core/AutoGenDto/Conjugation.cs @@ -267,7 +267,18 @@ public partial class Conjugation : IConjugation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConjugation.ConjugatedType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.ConjugatedType]; + set + { + if (value.Count != 0) + { + this.ConjugatedType = value[0]; + } + + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -276,7 +287,18 @@ public partial class Conjugation : IConjugation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConjugation.OriginalType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.OriginalType]; + set + { + if (value.Count != 0) + { + this.OriginalType = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/ConnectionDefinition.cs b/SysML2.NET/Core/AutoGenDto/ConnectionDefinition.cs index 82c7b644..8d553e9f 100644 --- a/SysML2.NET/Core/AutoGenDto/ConnectionDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/ConnectionDefinition.cs @@ -63,7 +63,7 @@ public partial class ConnectionDefinition : IConnectionDefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1562476168385_824569_22106")] [RedefinedByProperty("IConnectionDefinition.ConnectionEnd")] [Implements(implementation: "IAssociation.AssociationEnd")] - public List associationEnd { get; internal set; } = []; + List Kernel.Associations.IAssociation.associationEnd => this.connectionEnd; /// /// The Usages that define the things related by the ConnectionDefinition. @@ -144,7 +144,7 @@ public partial class ConnectionDefinition : IConnectionDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => ((SysML2.NET.Core.DTO.Kernel.Associations.IAssociation)this).associationEnd; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -276,7 +276,14 @@ public partial class ConnectionDefinition : IConnectionDefinition [Property(xmiId: "_18_5_3_b9102da_1564072709069_937523_30797", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IConnectionDefinition.IsSufficient")] [Implements(implementation: "IType.IsSufficient")] - bool Core.Types.IType.IsSufficient { get; set; } + bool Core.Types.IType.IsSufficient + { + get => this.IsSufficient; + set + { + this.IsSufficient = value; + } + } /// /// Whether this Definition is for a variation point or not. If true, then all the memberships of the @@ -767,7 +774,7 @@ public partial class ConnectionDefinition : IConnectionDefinition [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedType; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -795,7 +802,11 @@ public partial class ConnectionDefinition : IConnectionDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType.HasValue ? [this.sourceType.Value] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -813,7 +824,11 @@ public partial class ConnectionDefinition : IConnectionDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetType; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenDto/ConnectionUsage.cs b/SysML2.NET/Core/AutoGenDto/ConnectionUsage.cs index b3050938..d5f35cba 100644 --- a/SysML2.NET/Core/AutoGenDto/ConnectionUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/ConnectionUsage.cs @@ -64,7 +64,7 @@ public partial class ConnectionUsage : IConnectionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IConnectionUsage.ConnectionDefinition")] [Implements(implementation: "IConnector.Association")] - public List association { get; internal set; } = []; + List Kernel.Connectors.IConnector.association => this.connectionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -144,7 +144,7 @@ public partial class ConnectionUsage : IConnectionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -208,7 +208,7 @@ public partial class ConnectionUsage : IConnectionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -443,7 +443,11 @@ public partial class ConnectionUsage : IConnectionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1087,7 +1091,7 @@ public partial class ConnectionUsage : IConnectionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1115,7 +1119,11 @@ public partial class ConnectionUsage : IConnectionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1133,7 +1141,11 @@ public partial class ConnectionUsage : IConnectionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1163,7 +1175,7 @@ public partial class ConnectionUsage : IConnectionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/Connector.cs b/SysML2.NET/Core/AutoGenDto/Connector.cs index 4d40fc85..0c07ff2a 100644 --- a/SysML2.NET/Core/AutoGenDto/Connector.cs +++ b/SysML2.NET/Core/AutoGenDto/Connector.cs @@ -176,7 +176,7 @@ public partial class Connector : IConnector [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -737,7 +737,7 @@ public partial class Connector : IConnector [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -765,7 +765,11 @@ public partial class Connector : IConnector [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -783,7 +787,11 @@ public partial class Connector : IConnector [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -813,7 +821,7 @@ public partial class Connector : IConnector [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => this.association; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/ConstraintDefinition.cs b/SysML2.NET/Core/AutoGenDto/ConstraintDefinition.cs index e9ef3a7d..d2ecbe98 100644 --- a/SysML2.NET/Core/AutoGenDto/ConstraintDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/ConstraintDefinition.cs @@ -91,7 +91,7 @@ public partial class ConstraintDefinition : IConstraintDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenDto/ConstraintUsage.cs b/SysML2.NET/Core/AutoGenDto/ConstraintUsage.cs index 12a15b12..bc641e88 100644 --- a/SysML2.NET/Core/AutoGenDto/ConstraintUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/ConstraintUsage.cs @@ -65,7 +65,7 @@ public partial class ConstraintUsage : IConstraintUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -125,7 +125,7 @@ public partial class ConstraintUsage : IConstraintUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -147,7 +147,7 @@ public partial class ConstraintUsage : IConstraintUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -242,7 +242,7 @@ public partial class ConstraintUsage : IConstraintUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.HasValue ? ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -433,7 +433,11 @@ public partial class ConstraintUsage : IConstraintUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1040,7 +1044,7 @@ public partial class ConstraintUsage : IConstraintUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public Guid? predicate { get; internal set; } + Guid? Kernel.Functions.IBooleanExpression.predicate => this.constraintDefinition.HasValue ? this.constraintDefinition.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1093,7 +1097,7 @@ public partial class ConstraintUsage : IConstraintUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/ConstructorExpression.cs b/SysML2.NET/Core/AutoGenDto/ConstructorExpression.cs index b06ca0a4..429b6ba9 100644 --- a/SysML2.NET/Core/AutoGenDto/ConstructorExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/ConstructorExpression.cs @@ -71,7 +71,7 @@ public partial class ConstructorExpression : IConstructorExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -132,7 +132,7 @@ public partial class ConstructorExpression : IConstructorExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/CrossSubsetting.cs b/SysML2.NET/Core/AutoGenDto/CrossSubsetting.cs index f715c665..744827bd 100644 --- a/SysML2.NET/Core/AutoGenDto/CrossSubsetting.cs +++ b/SysML2.NET/Core/AutoGenDto/CrossSubsetting.cs @@ -122,7 +122,14 @@ public partial class CrossSubsetting : ICrossSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubsetting.SubsettedFeature")] [Implements(implementation: "ISpecialization.General")] - public Guid General { get; set; } + Guid Core.Types.ISpecialization.General + { + get => ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettedFeature; + set + { + ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettedFeature = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -210,7 +217,7 @@ public partial class CrossSubsetting : ICrossSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_573157_43226")] [RedefinedByProperty("ICrossSubsetting.CrossingFeature")] [Implements(implementation: "ISubsetting.OwningFeature")] - public Guid? owningFeature { get; internal set; } + Guid? ISubsetting.owningFeature => this.crossingFeature; /// /// The owningRelationship of this Element, if that Relationship is a Membership. @@ -254,7 +261,7 @@ public partial class CrossSubsetting : ICrossSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubsetting.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public Guid? owningType { get; internal set; } + Guid? Core.Types.ISpecialization.owningType => ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).owningFeature.HasValue ? ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).owningFeature.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -293,7 +300,18 @@ public partial class CrossSubsetting : ICrossSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific = value[0]; + } + + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -302,7 +320,14 @@ public partial class CrossSubsetting : ICrossSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubsetting.SubsettingFeature")] [Implements(implementation: "ISpecialization.Specific")] - public Guid Specific { get; set; } + Guid Core.Types.ISpecialization.Specific + { + get => ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettingFeature; + set + { + ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettingFeature = value; + } + } /// /// The Feature that is subsetted by the subsettingFeature of this Subsetting. @@ -311,7 +336,14 @@ public partial class CrossSubsetting : ICrossSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674980_563969_43273")] [RedefinedByProperty("ICrossSubsetting.CrossedFeature")] [Implements(implementation: "ISubsetting.SubsettedFeature")] - public Guid SubsettedFeature { get; set; } + Guid ISubsetting.SubsettedFeature + { + get => this.CrossedFeature; + set + { + this.CrossedFeature = value; + } + } /// /// The Feature that is a subset of the subsettedFeature of this Subsetting. @@ -320,7 +352,11 @@ public partial class CrossSubsetting : ICrossSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ICrossSubsetting.CrossingFeature")] [Implements(implementation: "ISubsetting.SubsettingFeature")] - public Guid SubsettingFeature { get; set; } + Guid ISubsetting.SubsettingFeature + { + get => this.crossingFeature; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -329,7 +365,18 @@ public partial class CrossSubsetting : ICrossSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/DecisionNode.cs b/SysML2.NET/Core/AutoGenDto/DecisionNode.cs index c92bf291..74725856 100644 --- a/SysML2.NET/Core/AutoGenDto/DecisionNode.cs +++ b/SysML2.NET/Core/AutoGenDto/DecisionNode.cs @@ -71,7 +71,7 @@ public partial class DecisionNode : IDecisionNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -121,7 +121,7 @@ public partial class DecisionNode : IDecisionNode [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -143,7 +143,7 @@ public partial class DecisionNode : IDecisionNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -412,7 +412,11 @@ public partial class DecisionNode : IDecisionNode [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -699,7 +703,7 @@ public partial class DecisionNode : IDecisionNode [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1053,7 +1057,7 @@ public partial class DecisionNode : IDecisionNode [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/Dependency.cs b/SysML2.NET/Core/AutoGenDto/Dependency.cs index 0db729ab..7f971d53 100644 --- a/SysML2.NET/Core/AutoGenDto/Dependency.cs +++ b/SysML2.NET/Core/AutoGenDto/Dependency.cs @@ -246,7 +246,14 @@ public partial class Dependency : IDependency [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDependency.Client")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.Client; + set + { + this.Client = value; + } + } /// /// The Element or Elements on which the client Elements depend in some respect. @@ -263,7 +270,14 @@ public partial class Dependency : IDependency [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDependency.Supplier")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.Supplier; + set + { + this.Supplier = value; + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/Differencing.cs b/SysML2.NET/Core/AutoGenDto/Differencing.cs index 1af90a92..b9cf0776 100644 --- a/SysML2.NET/Core/AutoGenDto/Differencing.cs +++ b/SysML2.NET/Core/AutoGenDto/Differencing.cs @@ -245,7 +245,11 @@ public partial class Differencing : IDifferencing [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDifferencing.TypeDifferenced")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.typeDifferenced]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -254,7 +258,18 @@ public partial class Differencing : IDifferencing [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDifferencing.DifferencingType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.DifferencingType]; + set + { + if (value.Count != 0) + { + this.DifferencingType = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/Disjoining.cs b/SysML2.NET/Core/AutoGenDto/Disjoining.cs index 012527f5..b693cdfd 100644 --- a/SysML2.NET/Core/AutoGenDto/Disjoining.cs +++ b/SysML2.NET/Core/AutoGenDto/Disjoining.cs @@ -255,7 +255,18 @@ public partial class Disjoining : IDisjoining [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDisjoining.TypeDisjoined")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.TypeDisjoined]; + set + { + if (value.Count != 0) + { + this.TypeDisjoined = value[0]; + } + + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -264,7 +275,18 @@ public partial class Disjoining : IDisjoining [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDisjoining.DisjoiningType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.DisjoiningType]; + set + { + if (value.Count != 0) + { + this.DisjoiningType = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/Documentation.cs b/SysML2.NET/Core/AutoGenDto/Documentation.cs index c003f4b8..677ca6a6 100644 --- a/SysML2.NET/Core/AutoGenDto/Documentation.cs +++ b/SysML2.NET/Core/AutoGenDto/Documentation.cs @@ -59,7 +59,7 @@ public partial class Documentation : IDocumentation [Property(xmiId: "_19_0_2_12e503d9_1594145755058_99428_86", aggregation: AggregationKind.None, lowerValue: 1, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IDocumentation.DocumentedElement")] [Implements(implementation: "IAnnotatingElement.AnnotatedElement")] - public List annotatedElement { get; internal set; } = []; + List IAnnotatingElement.annotatedElement => [this.documentedElement]; /// /// The Annotations that relate this AnnotatingElement to its annotatedElements. This includes the diff --git a/SysML2.NET/Core/AutoGenDto/ElementFilterMembership.cs b/SysML2.NET/Core/AutoGenDto/ElementFilterMembership.cs index 85a5e65e..b75e4222 100644 --- a/SysML2.NET/Core/AutoGenDto/ElementFilterMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/ElementFilterMembership.cs @@ -132,7 +132,11 @@ public partial class ElementFilterMembership : IElementFilterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -140,7 +144,7 @@ public partial class ElementFilterMembership : IElementFilterMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -148,7 +152,11 @@ public partial class ElementFilterMembership : IElementFilterMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -166,7 +174,11 @@ public partial class ElementFilterMembership : IElementFilterMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -205,7 +217,7 @@ public partial class ElementFilterMembership : IElementFilterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IElementFilterMembership.Condition")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => this.condition; /// /// The elementId of the ownedMemberElement. @@ -326,7 +338,11 @@ public partial class ElementFilterMembership : IElementFilterMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -335,7 +351,18 @@ public partial class ElementFilterMembership : IElementFilterMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/EndFeatureMembership.cs b/SysML2.NET/Core/AutoGenDto/EndFeatureMembership.cs index 9c28351b..ba16deb0 100644 --- a/SysML2.NET/Core/AutoGenDto/EndFeatureMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/EndFeatureMembership.cs @@ -121,7 +121,11 @@ public partial class EndFeatureMembership : IEndFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -129,7 +133,7 @@ public partial class EndFeatureMembership : IEndFeatureMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -137,7 +141,11 @@ public partial class EndFeatureMembership : IEndFeatureMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -148,7 +156,7 @@ public partial class EndFeatureMembership : IEndFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -156,7 +164,11 @@ public partial class EndFeatureMembership : IEndFeatureMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -195,7 +207,7 @@ public partial class EndFeatureMembership : IEndFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -220,7 +232,7 @@ public partial class EndFeatureMembership : IEndFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IEndFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - Guid Core.Types.IFeatureMembership.ownedMemberFeature { get; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedMemberFeature; /// /// The name of the ownedMemberElement. @@ -342,7 +354,11 @@ public partial class EndFeatureMembership : IEndFeatureMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -351,7 +367,18 @@ public partial class EndFeatureMembership : IEndFeatureMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/EnumerationDefinition.cs b/SysML2.NET/Core/AutoGenDto/EnumerationDefinition.cs index c702c31c..8de6689f 100644 --- a/SysML2.NET/Core/AutoGenDto/EnumerationDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/EnumerationDefinition.cs @@ -259,7 +259,14 @@ public partial class EnumerationDefinition : IEnumerationDefinition [Property(xmiId: "_19_0_2_12e503d9_1590978283180_265362_419", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IEnumerationDefinition.IsVariation")] [Implements(implementation: "IDefinition.IsVariation")] - bool Systems.DefinitionAndUsage.IDefinition.IsVariation { get; set; } + bool Systems.DefinitionAndUsage.IDefinition.IsVariation + { + get => this.IsVariation; + set + { + this.IsVariation = value; + } + } /// /// The set of all member Elements of this Namespace, which are the memberElements of all memberships of @@ -765,7 +772,7 @@ public partial class EnumerationDefinition : IEnumerationDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674979_259543_43268")] [RedefinedByProperty("IEnumerationDefinition.EnumeratedValue")] [Implements(implementation: "IDefinition.Variant")] - public List variant { get; internal set; } = []; + List Systems.DefinitionAndUsage.IDefinition.variant => this.enumeratedValue; /// /// The ownedMemberships of this Definition that are VariantMemberships. If isVariation = true, then diff --git a/SysML2.NET/Core/AutoGenDto/EnumerationUsage.cs b/SysML2.NET/Core/AutoGenDto/EnumerationUsage.cs index 0c82e238..b29a2109 100644 --- a/SysML2.NET/Core/AutoGenDto/EnumerationUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/EnumerationUsage.cs @@ -62,7 +62,7 @@ public partial class EnumerationUsage : IEnumerationUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IEnumerationUsage.EnumerationDefinition")] [Implements(implementation: "IAttributeUsage.AttributeDefinition")] - public List attributeDefinition { get; internal set; } = []; + List Systems.Attributes.IAttributeUsage.attributeDefinition => [this.enumerationDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -112,7 +112,7 @@ public partial class EnumerationUsage : IEnumerationUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IAttributeUsage.AttributeDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Attributes.IAttributeUsage)this).attributeDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -375,7 +375,7 @@ public partial class EnumerationUsage : IEnumerationUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IAttributeUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool Systems.DefinitionAndUsage.IUsage.isReference { get; } + bool Systems.DefinitionAndUsage.IUsage.isReference => this.isReference; /// /// Whether all things that meet the classification conditions of this Type must be classified by the @@ -403,7 +403,11 @@ public partial class EnumerationUsage : IEnumerationUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1015,7 +1019,7 @@ public partial class EnumerationUsage : IEnumerationUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/EventOccurrenceUsage.cs b/SysML2.NET/Core/AutoGenDto/EventOccurrenceUsage.cs index dc71f6c2..82ede305 100644 --- a/SysML2.NET/Core/AutoGenDto/EventOccurrenceUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/EventOccurrenceUsage.cs @@ -106,7 +106,7 @@ public partial class EventOccurrenceUsage : IEventOccurrenceUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -386,7 +386,7 @@ public partial class EventOccurrenceUsage : IEventOccurrenceUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IEventOccurrenceUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool Systems.DefinitionAndUsage.IUsage.isReference { get; } + bool Systems.DefinitionAndUsage.IUsage.isReference => this.isReference; /// /// Whether all things that meet the classification conditions of this Type must be classified by the @@ -414,7 +414,11 @@ public partial class EventOccurrenceUsage : IEventOccurrenceUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1045,7 +1049,7 @@ public partial class EventOccurrenceUsage : IEventOccurrenceUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/ExhibitStateUsage.cs b/SysML2.NET/Core/AutoGenDto/ExhibitStateUsage.cs index 155b5d41..7e21eae7 100644 --- a/SysML2.NET/Core/AutoGenDto/ExhibitStateUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/ExhibitStateUsage.cs @@ -60,7 +60,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("IStateUsage.StateDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition { get; internal set; } = []; + List Systems.Actions.IActionUsage.actionDefinition => this.stateDefinition; /// /// Various alternative identifiers for this Element. Generally, these will be set by tools. @@ -76,7 +76,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Systems.Actions.IActionUsage)this).actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -126,7 +126,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -148,7 +148,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -228,7 +228,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [Property(xmiId: "_19_0_4_12e503d9_1622831790393_676695_195", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IPerformActionUsage.PerformedAction")] [Implements(implementation: "IEventOccurrenceUsage.EventOccurrence")] - public Guid eventOccurrence { get; internal set; } + Guid Systems.Occurrences.IEventOccurrenceUsage.eventOccurrence => ((SysML2.NET.Core.DTO.Systems.Actions.IPerformActionUsage)this).performedAction; /// /// The StateUsage to be exhibited by the ExhibitStateUsage. It is the performedAction of the @@ -445,7 +445,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IEventOccurrenceUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool Systems.DefinitionAndUsage.IUsage.isReference { get; } + bool Systems.DefinitionAndUsage.IUsage.isReference => this.isReference; /// /// Always true for an EventOccurrenceUsage. @@ -481,7 +481,11 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -768,7 +772,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => ((SysML2.NET.Core.DTO.Systems.Actions.IActionUsage)this).actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1081,7 +1085,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1622831790393_676695_195")] [RedefinedByProperty("IExhibitStateUsage.ExhibitedState")] [Implements(implementation: "IPerformActionUsage.PerformedAction")] - public Guid performedAction { get; internal set; } + Guid Systems.Actions.IPerformActionUsage.performedAction => this.exhibitedState; /// /// The kind of temporal portion (time slice or snapshot) is represented by this OccurrenceUsage. If @@ -1141,7 +1145,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/Expression.cs b/SysML2.NET/Core/AutoGenDto/Expression.cs index 3bd744fe..c4dff1f3 100644 --- a/SysML2.NET/Core/AutoGenDto/Expression.cs +++ b/SysML2.NET/Core/AutoGenDto/Expression.cs @@ -64,7 +64,7 @@ public partial class Expression : IExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -125,7 +125,7 @@ public partial class Expression : IExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/FeatureChainExpression.cs b/SysML2.NET/Core/AutoGenDto/FeatureChainExpression.cs index 4ed94ea3..8f3bb382 100644 --- a/SysML2.NET/Core/AutoGenDto/FeatureChainExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/FeatureChainExpression.cs @@ -71,7 +71,7 @@ public partial class FeatureChainExpression : IFeatureChainExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -132,7 +132,7 @@ public partial class FeatureChainExpression : IFeatureChainExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -444,7 +444,14 @@ public partial class FeatureChainExpression : IFeatureChainExpression [Property(xmiId: "_18_5_3_12e503d9_1557528808100_646606_111674", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IFeatureChainExpression.Operator")] [Implements(implementation: "IOperatorExpression.Operator")] - string IOperatorExpression.Operator { get; set; } + string IOperatorExpression.Operator + { + get => this.Operator; + set + { + this.Operator = value; + } + } /// /// All features related to this Type by FeatureMemberships that have direction out or inout. diff --git a/SysML2.NET/Core/AutoGenDto/FeatureChaining.cs b/SysML2.NET/Core/AutoGenDto/FeatureChaining.cs index 3a255eff..f5a2e1df 100644 --- a/SysML2.NET/Core/AutoGenDto/FeatureChaining.cs +++ b/SysML2.NET/Core/AutoGenDto/FeatureChaining.cs @@ -255,7 +255,11 @@ public partial class FeatureChaining : IFeatureChaining [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IFeatureChaining.FeatureChained")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.featureChained]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -264,7 +268,18 @@ public partial class FeatureChaining : IFeatureChaining [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IFeatureChaining.ChainingFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.ChainingFeature]; + set + { + if (value.Count != 0) + { + this.ChainingFeature = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/FeatureInverting.cs b/SysML2.NET/Core/AutoGenDto/FeatureInverting.cs index 3d79d2f1..da4b3361 100644 --- a/SysML2.NET/Core/AutoGenDto/FeatureInverting.cs +++ b/SysML2.NET/Core/AutoGenDto/FeatureInverting.cs @@ -264,7 +264,18 @@ public partial class FeatureInverting : IFeatureInverting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IFeatureInverting.FeatureInverted")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.FeatureInverted]; + set + { + if (value.Count != 0) + { + this.FeatureInverted = value[0]; + } + + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -273,7 +284,18 @@ public partial class FeatureInverting : IFeatureInverting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IFeatureInverting.InvertingFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.InvertingFeature]; + set + { + if (value.Count != 0) + { + this.InvertingFeature = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/FeatureMembership.cs b/SysML2.NET/Core/AutoGenDto/FeatureMembership.cs index 938b118b..3d575658 100644 --- a/SysML2.NET/Core/AutoGenDto/FeatureMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/FeatureMembership.cs @@ -124,7 +124,11 @@ public partial class FeatureMembership : IFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -132,7 +136,7 @@ public partial class FeatureMembership : IFeatureMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -140,7 +144,11 @@ public partial class FeatureMembership : IFeatureMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -151,7 +159,7 @@ public partial class FeatureMembership : IFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -159,7 +167,11 @@ public partial class FeatureMembership : IFeatureMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -198,7 +210,7 @@ public partial class FeatureMembership : IFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => this.ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -337,7 +349,11 @@ public partial class FeatureMembership : IFeatureMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -346,7 +362,18 @@ public partial class FeatureMembership : IFeatureMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/FeatureReferenceExpression.cs b/SysML2.NET/Core/AutoGenDto/FeatureReferenceExpression.cs index 4984d6d9..c4493603 100644 --- a/SysML2.NET/Core/AutoGenDto/FeatureReferenceExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/FeatureReferenceExpression.cs @@ -60,7 +60,7 @@ public partial class FeatureReferenceExpression : IFeatureReferenceExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -121,7 +121,7 @@ public partial class FeatureReferenceExpression : IFeatureReferenceExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/FeatureTyping.cs b/SysML2.NET/Core/AutoGenDto/FeatureTyping.cs index 4b65ddec..e16c8d48 100644 --- a/SysML2.NET/Core/AutoGenDto/FeatureTyping.cs +++ b/SysML2.NET/Core/AutoGenDto/FeatureTyping.cs @@ -96,7 +96,14 @@ public partial class FeatureTyping : IFeatureTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IFeatureTyping.Type")] [Implements(implementation: "ISpecialization.General")] - public Guid General { get; set; } + Guid Core.Types.ISpecialization.General + { + get => this.Type; + set + { + this.Type = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -227,7 +234,7 @@ public partial class FeatureTyping : IFeatureTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("IFeatureTyping.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public Guid? owningType { get; internal set; } + Guid? Core.Types.ISpecialization.owningType => this.owningFeature.HasValue ? this.owningFeature.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -266,7 +273,18 @@ public partial class FeatureTyping : IFeatureTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific = value[0]; + } + + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -275,7 +293,14 @@ public partial class FeatureTyping : IFeatureTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureTyping.TypedFeature")] [Implements(implementation: "ISpecialization.Specific")] - public Guid Specific { get; set; } + Guid Core.Types.ISpecialization.Specific + { + get => this.TypedFeature; + set + { + this.TypedFeature = value; + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -284,7 +309,18 @@ public partial class FeatureTyping : IFeatureTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/FeatureValue.cs b/SysML2.NET/Core/AutoGenDto/FeatureValue.cs index 26094d23..a9b5d229 100644 --- a/SysML2.NET/Core/AutoGenDto/FeatureValue.cs +++ b/SysML2.NET/Core/AutoGenDto/FeatureValue.cs @@ -152,7 +152,11 @@ public partial class FeatureValue : IFeatureValue [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -160,7 +164,7 @@ public partial class FeatureValue : IFeatureValue [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -168,7 +172,11 @@ public partial class FeatureValue : IFeatureValue [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -186,7 +194,11 @@ public partial class FeatureValue : IFeatureValue [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -225,7 +237,7 @@ public partial class FeatureValue : IFeatureValue [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureValue.Value")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => this.value; /// /// The elementId of the ownedMemberElement. @@ -346,7 +358,11 @@ public partial class FeatureValue : IFeatureValue [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -355,7 +371,18 @@ public partial class FeatureValue : IFeatureValue [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/Flow.cs b/SysML2.NET/Core/AutoGenDto/Flow.cs index bedd547b..57dba154 100644 --- a/SysML2.NET/Core/AutoGenDto/Flow.cs +++ b/SysML2.NET/Core/AutoGenDto/Flow.cs @@ -62,7 +62,7 @@ public partial class Flow : IFlow [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IConnector.Association")] - public List association { get; internal set; } = []; + List Kernel.Connectors.IConnector.association => this.interaction; /// /// The Behaviors that type this Step. @@ -71,7 +71,7 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.interaction; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -151,7 +151,7 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -185,7 +185,7 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -788,7 +788,7 @@ public partial class Flow : IFlow [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -816,7 +816,11 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -842,7 +846,11 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -880,7 +888,7 @@ public partial class Flow : IFlow [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Kernel.Connectors.IConnector)this).association; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/FlowDefinition.cs b/SysML2.NET/Core/AutoGenDto/FlowDefinition.cs index f480de24..1790ef0a 100644 --- a/SysML2.NET/Core/AutoGenDto/FlowDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/FlowDefinition.cs @@ -73,7 +73,7 @@ public partial class FlowDefinition : IFlowDefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1562476168385_824569_22106")] [RedefinedByProperty("IFlowDefinition.FlowEnd")] [Implements(implementation: "IAssociation.AssociationEnd")] - public List associationEnd { get; internal set; } = []; + List Kernel.Associations.IAssociation.associationEnd => this.flowEnd; /// /// The declared name of this Element. @@ -112,7 +112,7 @@ public partial class FlowDefinition : IFlowDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Definition that are directedFeatures. @@ -147,7 +147,7 @@ public partial class FlowDefinition : IFlowDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => ((SysML2.NET.Core.DTO.Kernel.Associations.IAssociation)this).associationEnd; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -778,7 +778,7 @@ public partial class FlowDefinition : IFlowDefinition [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedType; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -806,7 +806,11 @@ public partial class FlowDefinition : IFlowDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType.HasValue ? [this.sourceType.Value] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -832,7 +836,11 @@ public partial class FlowDefinition : IFlowDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetType; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenDto/FlowUsage.cs b/SysML2.NET/Core/AutoGenDto/FlowUsage.cs index 8e4dfb40..5d14116d 100644 --- a/SysML2.NET/Core/AutoGenDto/FlowUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/FlowUsage.cs @@ -59,7 +59,7 @@ public partial class FlowUsage : IFlowUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("IFlowUsage.FlowDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition { get; internal set; } = []; + List Systems.Actions.IActionUsage.actionDefinition => this.flowDefinition; /// /// Various alternative identifiers for this Element. Generally, these will be set by tools. @@ -75,7 +75,7 @@ public partial class FlowUsage : IFlowUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IConnector.Association")] - public List association { get; internal set; } = []; + List Kernel.Connectors.IConnector.association => ((SysML2.NET.Core.DTO.Kernel.Interactions.IFlow)this).interaction; /// /// The Behaviors that type this Step. @@ -84,7 +84,7 @@ public partial class FlowUsage : IFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Interactions.IFlow)this).interaction; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -153,7 +153,7 @@ public partial class FlowUsage : IFlowUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -175,7 +175,7 @@ public partial class FlowUsage : IFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -218,7 +218,7 @@ public partial class FlowUsage : IFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -333,7 +333,7 @@ public partial class FlowUsage : IFlowUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IFlowUsage.FlowDefinition")] [Implements(implementation: "IFlow.Interaction")] - public List interaction { get; internal set; } = []; + List Kernel.Interactions.IFlow.interaction => this.flowDefinition; /// /// The interpretations of a Type with intersectingTypes are asserted to be those in common among the @@ -483,7 +483,11 @@ public partial class FlowUsage : IFlowUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -770,7 +774,7 @@ public partial class FlowUsage : IFlowUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => ((SysML2.NET.Core.DTO.Systems.Actions.IActionUsage)this).actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1134,7 +1138,7 @@ public partial class FlowUsage : IFlowUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1162,7 +1166,11 @@ public partial class FlowUsage : IFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1188,7 +1196,11 @@ public partial class FlowUsage : IFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1226,7 +1238,7 @@ public partial class FlowUsage : IFlowUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/ForLoopActionUsage.cs b/SysML2.NET/Core/AutoGenDto/ForLoopActionUsage.cs index 3ee6d9e7..8dc76a0e 100644 --- a/SysML2.NET/Core/AutoGenDto/ForLoopActionUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/ForLoopActionUsage.cs @@ -73,7 +73,7 @@ public partial class ForLoopActionUsage : IForLoopActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The ActionUsage to be performed repeatedly by the LoopActionUsage. It is the second parameter of the @@ -131,7 +131,7 @@ public partial class ForLoopActionUsage : IForLoopActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -153,7 +153,7 @@ public partial class ForLoopActionUsage : IForLoopActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -422,7 +422,11 @@ public partial class ForLoopActionUsage : IForLoopActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -718,7 +722,7 @@ public partial class ForLoopActionUsage : IForLoopActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1081,7 +1085,7 @@ public partial class ForLoopActionUsage : IForLoopActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/ForkNode.cs b/SysML2.NET/Core/AutoGenDto/ForkNode.cs index 78a958f2..c60d018f 100644 --- a/SysML2.NET/Core/AutoGenDto/ForkNode.cs +++ b/SysML2.NET/Core/AutoGenDto/ForkNode.cs @@ -72,7 +72,7 @@ public partial class ForkNode : IForkNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -122,7 +122,7 @@ public partial class ForkNode : IForkNode [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -144,7 +144,7 @@ public partial class ForkNode : IForkNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -413,7 +413,11 @@ public partial class ForkNode : IForkNode [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -700,7 +704,7 @@ public partial class ForkNode : IForkNode [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1054,7 +1058,7 @@ public partial class ForkNode : IForkNode [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/FramedConcernMembership.cs b/SysML2.NET/Core/AutoGenDto/FramedConcernMembership.cs index c9e319f7..34a029bc 100644 --- a/SysML2.NET/Core/AutoGenDto/FramedConcernMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/FramedConcernMembership.cs @@ -128,7 +128,14 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_2_12e503d9_1584048161309_821854_390", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IFramedConcernMembership.Kind")] [Implements(implementation: "IRequirementConstraintMembership.Kind")] - RequirementConstraintKind IRequirementConstraintMembership.Kind { get; set; } + RequirementConstraintKind IRequirementConstraintMembership.Kind + { + get => this.Kind; + set + { + this.Kind = value; + } + } /// /// The Element that becomes a member of the membershipOwningNamespace due to this Membership. @@ -137,7 +144,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -145,7 +156,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -153,7 +164,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -164,7 +179,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -172,7 +187,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -209,7 +228,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674993_898044_43344")] [RedefinedByProperty("IFramedConcernMembership.OwnedConcern")] [Implements(implementation: "IRequirementConstraintMembership.OwnedConstraint")] - public Guid ownedConstraint { get; internal set; } + Guid IRequirementConstraintMembership.ownedConstraint => this.ownedConcern; /// /// The Elements owned by this Element, derived as the ownedRelatedElements of the ownedRelationships of @@ -228,7 +247,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -246,7 +265,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IRequirementConstraintMembership.OwnedConstraint")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => ((SysML2.NET.Core.DTO.Systems.Requirements.IRequirementConstraintMembership)this).ownedConstraint; /// /// The name of the ownedMemberElement. @@ -361,7 +380,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_4_12e503d9_1617118807597_77864_3544", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IFramedConcernMembership.ReferencedConcern")] [Implements(implementation: "IRequirementConstraintMembership.ReferencedConstraint")] - public Guid referencedConstraint { get; internal set; } + Guid IRequirementConstraintMembership.referencedConstraint => this.referencedConcern; /// /// The Elements that are related by this Relationship, derived as the union of the source and target @@ -388,7 +407,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -397,7 +420,18 @@ public partial class FramedConcernMembership : IFramedConcernMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/Function.cs b/SysML2.NET/Core/AutoGenDto/Function.cs index 20366c9b..54841071 100644 --- a/SysML2.NET/Core/AutoGenDto/Function.cs +++ b/SysML2.NET/Core/AutoGenDto/Function.cs @@ -91,7 +91,7 @@ public partial class Function : IFunction [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The Documentation owned by this Element. diff --git a/SysML2.NET/Core/AutoGenDto/IfActionUsage.cs b/SysML2.NET/Core/AutoGenDto/IfActionUsage.cs index c4370f07..b64247c0 100644 --- a/SysML2.NET/Core/AutoGenDto/IfActionUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/IfActionUsage.cs @@ -73,7 +73,7 @@ public partial class IfActionUsage : IIfActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -123,7 +123,7 @@ public partial class IfActionUsage : IIfActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -145,7 +145,7 @@ public partial class IfActionUsage : IIfActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -430,7 +430,11 @@ public partial class IfActionUsage : IIfActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -717,7 +721,7 @@ public partial class IfActionUsage : IIfActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1079,7 +1083,7 @@ public partial class IfActionUsage : IIfActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/IncludeUseCaseUsage.cs b/SysML2.NET/Core/AutoGenDto/IncludeUseCaseUsage.cs index 647646aa..9607424b 100644 --- a/SysML2.NET/Core/AutoGenDto/IncludeUseCaseUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/IncludeUseCaseUsage.cs @@ -60,7 +60,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition { get; internal set; } = []; + List Systems.Actions.IActionUsage.actionDefinition => ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.HasValue ? [((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.Value] : []; /// /// The parameters of this CaseUsage that represent actors involved in the case. @@ -85,7 +85,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Function that is the type of this CalculationUsage. Nominally, this would be a @@ -97,7 +97,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1565500905804_589845_30779")] [RedefinedByProperty("ICaseUsage.CaseDefinition")] [Implements(implementation: "ICalculationUsage.CalculationDefinition")] - public Guid? calculationDefinition { get; internal set; } + Guid? Systems.Calculations.ICalculationUsage.calculationDefinition => ((SysML2.NET.Core.DTO.Systems.Cases.ICaseUsage)this).caseDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Cases.ICaseUsage)this).caseDefinition.Value : Guid.Empty; /// /// The CaseDefinition that is the type of this CaseUsage. @@ -106,7 +106,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1588213526305_899324_302")] [RedefinedByProperty("IUseCaseUsage.UseCaseDefinition")] [Implements(implementation: "ICaseUsage.CaseDefinition")] - public Guid? caseDefinition { get; internal set; } + Guid? Systems.Cases.ICaseUsage.caseDefinition => this.useCaseDefinition.HasValue ? this.useCaseDefinition.Value : Guid.Empty; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -156,7 +156,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -178,7 +178,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -240,7 +240,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [Property(xmiId: "_19_0_4_12e503d9_1622831790393_676695_195", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IPerformActionUsage.PerformedAction")] [Implements(implementation: "IEventOccurrenceUsage.EventOccurrence")] - public Guid eventOccurrence { get; internal set; } + Guid Systems.Occurrences.IEventOccurrenceUsage.eventOccurrence => ((SysML2.NET.Core.DTO.Systems.Actions.IPerformActionUsage)this).performedAction; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -283,7 +283,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -455,7 +455,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IEventOccurrenceUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool Systems.DefinitionAndUsage.IUsage.isReference { get; } + bool Systems.DefinitionAndUsage.IUsage.isReference => this.isReference; /// /// Always true for an EventOccurrenceUsage. @@ -491,7 +491,11 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -786,7 +790,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => ((SysML2.NET.Core.DTO.Systems.Actions.IActionUsage)this).actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1099,7 +1103,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1622831790393_676695_195")] [RedefinedByProperty("IIncludeUseCaseUsage.UseCaseIncluded")] [Implements(implementation: "IPerformActionUsage.PerformedAction")] - public Guid performedAction { get; internal set; } + Guid Systems.Actions.IPerformActionUsage.performedAction => this.useCaseIncluded; /// /// The kind of temporal portion (time slice or snapshot) is represented by this OccurrenceUsage. If @@ -1170,7 +1174,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/IndexExpression.cs b/SysML2.NET/Core/AutoGenDto/IndexExpression.cs index aa5de4ff..12b00a71 100644 --- a/SysML2.NET/Core/AutoGenDto/IndexExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/IndexExpression.cs @@ -70,7 +70,7 @@ public partial class IndexExpression : IIndexExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -131,7 +131,7 @@ public partial class IndexExpression : IIndexExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -443,7 +443,14 @@ public partial class IndexExpression : IIndexExpression [Property(xmiId: "_18_5_3_12e503d9_1557528808100_646606_111674", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IIndexExpression.Operator")] [Implements(implementation: "IOperatorExpression.Operator")] - string IOperatorExpression.Operator { get; set; } + string IOperatorExpression.Operator + { + get => this.Operator; + set + { + this.Operator = value; + } + } /// /// All features related to this Type by FeatureMemberships that have direction out or inout. diff --git a/SysML2.NET/Core/AutoGenDto/Interaction.cs b/SysML2.NET/Core/AutoGenDto/Interaction.cs index 4584491e..17b3e62f 100644 --- a/SysML2.NET/Core/AutoGenDto/Interaction.cs +++ b/SysML2.NET/Core/AutoGenDto/Interaction.cs @@ -101,7 +101,7 @@ public partial class Interaction : IInteraction [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The Documentation owned by this Element. @@ -127,7 +127,7 @@ public partial class Interaction : IInteraction [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.associationEnd; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -516,7 +516,7 @@ public partial class Interaction : IInteraction [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedType; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -544,7 +544,11 @@ public partial class Interaction : IInteraction [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType.HasValue ? [this.sourceType.Value] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -570,7 +574,11 @@ public partial class Interaction : IInteraction [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetType; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenDto/InterfaceDefinition.cs b/SysML2.NET/Core/AutoGenDto/InterfaceDefinition.cs index cc5f8418..028d62d3 100644 --- a/SysML2.NET/Core/AutoGenDto/InterfaceDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/InterfaceDefinition.cs @@ -62,7 +62,7 @@ public partial class InterfaceDefinition : IInterfaceDefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1562476168385_824569_22106")] [RedefinedByProperty("IConnectionDefinition.ConnectionEnd")] [Implements(implementation: "IAssociation.AssociationEnd")] - public List associationEnd { get; internal set; } = []; + List Kernel.Associations.IAssociation.associationEnd => ((SysML2.NET.Core.DTO.Systems.Connections.IConnectionDefinition)this).connectionEnd; /// /// The Usages that define the things related by the ConnectionDefinition. @@ -71,7 +71,7 @@ public partial class InterfaceDefinition : IInterfaceDefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1562477648742_24204_22901")] [RedefinedByProperty("IInterfaceDefinition.InterfaceEnd")] [Implements(implementation: "IConnectionDefinition.ConnectionEnd")] - public List connectionEnd { get; internal set; } = []; + List Systems.Connections.IConnectionDefinition.connectionEnd => this.interfaceEnd; /// /// The declared name of this Element. @@ -144,7 +144,7 @@ public partial class InterfaceDefinition : IInterfaceDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => ((SysML2.NET.Core.DTO.Kernel.Associations.IAssociation)this).associationEnd; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -284,7 +284,14 @@ public partial class InterfaceDefinition : IInterfaceDefinition [Property(xmiId: "_18_5_3_b9102da_1564072709069_937523_30797", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IConnectionDefinition.IsSufficient")] [Implements(implementation: "IType.IsSufficient")] - bool Core.Types.IType.IsSufficient { get; set; } + bool Core.Types.IType.IsSufficient + { + get => this.IsSufficient; + set + { + this.IsSufficient = value; + } + } /// /// Whether this Definition is for a variation point or not. If true, then all the memberships of the @@ -775,7 +782,7 @@ public partial class InterfaceDefinition : IInterfaceDefinition [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedType; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -803,7 +810,11 @@ public partial class InterfaceDefinition : IInterfaceDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType.HasValue ? [this.sourceType.Value] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -821,7 +832,11 @@ public partial class InterfaceDefinition : IInterfaceDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetType; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenDto/InterfaceUsage.cs b/SysML2.NET/Core/AutoGenDto/InterfaceUsage.cs index f0bbbdf9..9af48838 100644 --- a/SysML2.NET/Core/AutoGenDto/InterfaceUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/InterfaceUsage.cs @@ -62,7 +62,7 @@ public partial class InterfaceUsage : IInterfaceUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IConnectionUsage.ConnectionDefinition")] [Implements(implementation: "IConnector.Association")] - public List association { get; internal set; } = []; + List Kernel.Connectors.IConnector.association => ((SysML2.NET.Core.DTO.Systems.Connections.IConnectionUsage)this).connectionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -86,7 +86,7 @@ public partial class InterfaceUsage : IInterfaceUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674983_471497_43284")] [RedefinedByProperty("IInterfaceUsage.InterfaceDefinition")] [Implements(implementation: "IConnectionUsage.ConnectionDefinition")] - public List connectionDefinition { get; internal set; } = []; + List Systems.Connections.IConnectionUsage.connectionDefinition => this.interfaceDefinition; /// /// The endFeatures of a Connector, which redefine the endFeatures of the associations of the Connector. @@ -143,7 +143,7 @@ public partial class InterfaceUsage : IInterfaceUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -207,7 +207,7 @@ public partial class InterfaceUsage : IInterfaceUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -450,7 +450,11 @@ public partial class InterfaceUsage : IInterfaceUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1094,7 +1098,7 @@ public partial class InterfaceUsage : IInterfaceUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1122,7 +1126,11 @@ public partial class InterfaceUsage : IInterfaceUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1140,7 +1148,11 @@ public partial class InterfaceUsage : IInterfaceUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1170,7 +1182,7 @@ public partial class InterfaceUsage : IInterfaceUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/Intersecting.cs b/SysML2.NET/Core/AutoGenDto/Intersecting.cs index 0d06edaf..155e2fe8 100644 --- a/SysML2.NET/Core/AutoGenDto/Intersecting.cs +++ b/SysML2.NET/Core/AutoGenDto/Intersecting.cs @@ -245,7 +245,11 @@ public partial class Intersecting : IIntersecting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IIntersecting.TypeIntersected")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.typeIntersected]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -254,7 +258,18 @@ public partial class Intersecting : IIntersecting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IIntersecting.IntersectingType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.IntersectingType]; + set + { + if (value.Count != 0) + { + this.IntersectingType = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/Invariant.cs b/SysML2.NET/Core/AutoGenDto/Invariant.cs index bcc45384..d12f8953 100644 --- a/SysML2.NET/Core/AutoGenDto/Invariant.cs +++ b/SysML2.NET/Core/AutoGenDto/Invariant.cs @@ -61,7 +61,7 @@ public partial class Invariant : IInvariant [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -122,7 +122,7 @@ public partial class Invariant : IInvariant [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -208,7 +208,7 @@ public partial class Invariant : IInvariant [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? IExpression.function => this.predicate.HasValue ? this.predicate.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. diff --git a/SysML2.NET/Core/AutoGenDto/InvocationExpression.cs b/SysML2.NET/Core/AutoGenDto/InvocationExpression.cs index 8c48a74b..81e2efa3 100644 --- a/SysML2.NET/Core/AutoGenDto/InvocationExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/InvocationExpression.cs @@ -74,7 +74,7 @@ public partial class InvocationExpression : IInvocationExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -135,7 +135,7 @@ public partial class InvocationExpression : IInvocationExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/ItemUsage.cs b/SysML2.NET/Core/AutoGenDto/ItemUsage.cs index d3c49906..542817a6 100644 --- a/SysML2.NET/Core/AutoGenDto/ItemUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/ItemUsage.cs @@ -105,7 +105,7 @@ public partial class ItemUsage : IItemUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -395,7 +395,11 @@ public partial class ItemUsage : IItemUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1036,7 +1040,7 @@ public partial class ItemUsage : IItemUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/JoinNode.cs b/SysML2.NET/Core/AutoGenDto/JoinNode.cs index 6d2553f8..176ac037 100644 --- a/SysML2.NET/Core/AutoGenDto/JoinNode.cs +++ b/SysML2.NET/Core/AutoGenDto/JoinNode.cs @@ -72,7 +72,7 @@ public partial class JoinNode : IJoinNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -122,7 +122,7 @@ public partial class JoinNode : IJoinNode [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -144,7 +144,7 @@ public partial class JoinNode : IJoinNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -413,7 +413,11 @@ public partial class JoinNode : IJoinNode [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -700,7 +704,7 @@ public partial class JoinNode : IJoinNode [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1054,7 +1058,7 @@ public partial class JoinNode : IJoinNode [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/LiteralBoolean.cs b/SysML2.NET/Core/AutoGenDto/LiteralBoolean.cs index 460d2ff4..c289a7b7 100644 --- a/SysML2.NET/Core/AutoGenDto/LiteralBoolean.cs +++ b/SysML2.NET/Core/AutoGenDto/LiteralBoolean.cs @@ -60,7 +60,7 @@ public partial class LiteralBoolean : ILiteralBoolean [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -121,7 +121,7 @@ public partial class LiteralBoolean : ILiteralBoolean [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/LiteralExpression.cs b/SysML2.NET/Core/AutoGenDto/LiteralExpression.cs index 95dd119c..a0613ead 100644 --- a/SysML2.NET/Core/AutoGenDto/LiteralExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/LiteralExpression.cs @@ -60,7 +60,7 @@ public partial class LiteralExpression : ILiteralExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -121,7 +121,7 @@ public partial class LiteralExpression : ILiteralExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/LiteralInfinity.cs b/SysML2.NET/Core/AutoGenDto/LiteralInfinity.cs index 10d62150..ec571d78 100644 --- a/SysML2.NET/Core/AutoGenDto/LiteralInfinity.cs +++ b/SysML2.NET/Core/AutoGenDto/LiteralInfinity.cs @@ -60,7 +60,7 @@ public partial class LiteralInfinity : ILiteralInfinity [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -121,7 +121,7 @@ public partial class LiteralInfinity : ILiteralInfinity [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/LiteralInteger.cs b/SysML2.NET/Core/AutoGenDto/LiteralInteger.cs index 74af44a3..7ee06649 100644 --- a/SysML2.NET/Core/AutoGenDto/LiteralInteger.cs +++ b/SysML2.NET/Core/AutoGenDto/LiteralInteger.cs @@ -60,7 +60,7 @@ public partial class LiteralInteger : ILiteralInteger [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -121,7 +121,7 @@ public partial class LiteralInteger : ILiteralInteger [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/LiteralRational.cs b/SysML2.NET/Core/AutoGenDto/LiteralRational.cs index 1423b7b9..9db8ca0d 100644 --- a/SysML2.NET/Core/AutoGenDto/LiteralRational.cs +++ b/SysML2.NET/Core/AutoGenDto/LiteralRational.cs @@ -60,7 +60,7 @@ public partial class LiteralRational : ILiteralRational [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -121,7 +121,7 @@ public partial class LiteralRational : ILiteralRational [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/LiteralString.cs b/SysML2.NET/Core/AutoGenDto/LiteralString.cs index 34135dec..e9c6accf 100644 --- a/SysML2.NET/Core/AutoGenDto/LiteralString.cs +++ b/SysML2.NET/Core/AutoGenDto/LiteralString.cs @@ -60,7 +60,7 @@ public partial class LiteralString : ILiteralString [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -121,7 +121,7 @@ public partial class LiteralString : ILiteralString [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/Membership.cs b/SysML2.NET/Core/AutoGenDto/Membership.cs index 862883ed..4facf846 100644 --- a/SysML2.NET/Core/AutoGenDto/Membership.cs +++ b/SysML2.NET/Core/AutoGenDto/Membership.cs @@ -281,7 +281,11 @@ public partial class Membership : IMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -290,7 +294,18 @@ public partial class Membership : IMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.MemberElement]; + set + { + if (value.Count != 0) + { + this.MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/MembershipExpose.cs b/SysML2.NET/Core/AutoGenDto/MembershipExpose.cs index 1109c11e..014218ee 100644 --- a/SysML2.NET/Core/AutoGenDto/MembershipExpose.cs +++ b/SysML2.NET/Core/AutoGenDto/MembershipExpose.cs @@ -139,7 +139,14 @@ public partial class MembershipExpose : IMembershipExpose [Property(xmiId: "_19_0_4_12e503d9_1622577942205_869984_64", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IExpose.IsImportAll")] [Implements(implementation: "IImport.IsImportAll")] - bool Root.Namespaces.IImport.IsImportAll { get; set; } + bool Root.Namespaces.IImport.IsImportAll + { + get => this.IsImportAll; + set + { + this.IsImportAll = value; + } + } /// /// An Expose always imports all Elements, regardless of visibility (isImportAll = true). @@ -286,7 +293,11 @@ public partial class MembershipExpose : IMembershipExpose [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IImport.ImportOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.importOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -295,7 +306,18 @@ public partial class MembershipExpose : IMembershipExpose [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembershipImport.ImportedMembership")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.ImportedMembership]; + set + { + if (value.Count != 0) + { + this.ImportedMembership = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. @@ -313,7 +335,14 @@ public partial class MembershipExpose : IMembershipExpose [Property(xmiId: "_18_5_3_12e503d9_1533160674976_798509_43257", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "private")] [RedefinedByProperty("IExpose.Visibility")] [Implements(implementation: "IImport.Visibility")] - VisibilityKind Root.Namespaces.IImport.Visibility { get; set; } = VisibilityKind.Private; + VisibilityKind Root.Namespaces.IImport.Visibility + { + get => this.Visibility; + set + { + this.Visibility = value; + } + } /// /// An Expose always has protected visibility. diff --git a/SysML2.NET/Core/AutoGenDto/MembershipImport.cs b/SysML2.NET/Core/AutoGenDto/MembershipImport.cs index d21d2ac8..32e3facd 100644 --- a/SysML2.NET/Core/AutoGenDto/MembershipImport.cs +++ b/SysML2.NET/Core/AutoGenDto/MembershipImport.cs @@ -277,7 +277,11 @@ public partial class MembershipImport : IMembershipImport [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IImport.ImportOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.importOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -286,7 +290,18 @@ public partial class MembershipImport : IMembershipImport [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembershipImport.ImportedMembership")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.ImportedMembership]; + set + { + if (value.Count != 0) + { + this.ImportedMembership = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/MergeNode.cs b/SysML2.NET/Core/AutoGenDto/MergeNode.cs index 4e5f0ebe..ca403b7a 100644 --- a/SysML2.NET/Core/AutoGenDto/MergeNode.cs +++ b/SysML2.NET/Core/AutoGenDto/MergeNode.cs @@ -72,7 +72,7 @@ public partial class MergeNode : IMergeNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -122,7 +122,7 @@ public partial class MergeNode : IMergeNode [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -144,7 +144,7 @@ public partial class MergeNode : IMergeNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -413,7 +413,11 @@ public partial class MergeNode : IMergeNode [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -700,7 +704,7 @@ public partial class MergeNode : IMergeNode [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1054,7 +1058,7 @@ public partial class MergeNode : IMergeNode [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/MetadataAccessExpression.cs b/SysML2.NET/Core/AutoGenDto/MetadataAccessExpression.cs index 24de6c8b..3a49c431 100644 --- a/SysML2.NET/Core/AutoGenDto/MetadataAccessExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/MetadataAccessExpression.cs @@ -63,7 +63,7 @@ public partial class MetadataAccessExpression : IMetadataAccessExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -124,7 +124,7 @@ public partial class MetadataAccessExpression : IMetadataAccessExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/MetadataUsage.cs b/SysML2.NET/Core/AutoGenDto/MetadataUsage.cs index 364a01c3..25719e64 100644 --- a/SysML2.NET/Core/AutoGenDto/MetadataUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/MetadataUsage.cs @@ -124,7 +124,7 @@ public partial class MetadataUsage : IMetadataUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -414,7 +414,11 @@ public partial class MetadataUsage : IMetadataUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -433,7 +437,7 @@ public partial class MetadataUsage : IMetadataUsage [SubsettedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("IMetadataUsage.MetadataDefinition")] [Implements(implementation: "IItemUsage.ItemDefinition")] - public List itemDefinition { get; internal set; } = []; + List Systems.Items.IItemUsage.itemDefinition => this.metadataDefinition.HasValue ? [this.metadataDefinition.Value] : []; /// /// Whether this Usage may be time varying (that is, whether it is featured by the snapshots of its @@ -471,7 +475,7 @@ public partial class MetadataUsage : IMetadataUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IMetadataUsage.MetadataDefinition")] [Implements(implementation: "IMetadataFeature.Metaclass")] - public Guid? metaclass { get; internal set; } + Guid? Kernel.Metadata.IMetadataFeature.metaclass => this.metadataDefinition.HasValue ? this.metadataDefinition.Value : Guid.Empty; /// /// The MetadataDefinition that is the definition of this MetadataUsage. @@ -1093,7 +1097,7 @@ public partial class MetadataUsage : IMetadataUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/NamespaceExpose.cs b/SysML2.NET/Core/AutoGenDto/NamespaceExpose.cs index 7ed16106..0194dd6e 100644 --- a/SysML2.NET/Core/AutoGenDto/NamespaceExpose.cs +++ b/SysML2.NET/Core/AutoGenDto/NamespaceExpose.cs @@ -147,7 +147,14 @@ public partial class NamespaceExpose : INamespaceExpose [Property(xmiId: "_19_0_4_12e503d9_1622577942205_869984_64", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IExpose.IsImportAll")] [Implements(implementation: "IImport.IsImportAll")] - bool Root.Namespaces.IImport.IsImportAll { get; set; } + bool Root.Namespaces.IImport.IsImportAll + { + get => this.IsImportAll; + set + { + this.IsImportAll = value; + } + } /// /// Whether this Element is contained in the ownership tree of a library model. @@ -286,7 +293,11 @@ public partial class NamespaceExpose : INamespaceExpose [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IImport.ImportOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.importOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -295,7 +306,18 @@ public partial class NamespaceExpose : INamespaceExpose [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("INamespaceImport.ImportedNamespace")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.ImportedNamespace]; + set + { + if (value.Count != 0) + { + this.ImportedNamespace = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. @@ -321,7 +343,14 @@ public partial class NamespaceExpose : INamespaceExpose [Property(xmiId: "_18_5_3_12e503d9_1533160674976_798509_43257", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "private")] [RedefinedByProperty("IExpose.Visibility")] [Implements(implementation: "IImport.Visibility")] - VisibilityKind Root.Namespaces.IImport.Visibility { get; set; } = VisibilityKind.Private; + VisibilityKind Root.Namespaces.IImport.Visibility + { + get => this.Visibility; + set + { + this.Visibility = value; + } + } } } diff --git a/SysML2.NET/Core/AutoGenDto/NamespaceImport.cs b/SysML2.NET/Core/AutoGenDto/NamespaceImport.cs index 967bbaab..9f1a72e0 100644 --- a/SysML2.NET/Core/AutoGenDto/NamespaceImport.cs +++ b/SysML2.NET/Core/AutoGenDto/NamespaceImport.cs @@ -278,7 +278,11 @@ public partial class NamespaceImport : INamespaceImport [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IImport.ImportOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.importOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -287,7 +291,18 @@ public partial class NamespaceImport : INamespaceImport [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("INamespaceImport.ImportedNamespace")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.ImportedNamespace]; + set + { + if (value.Count != 0) + { + this.ImportedNamespace = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/NullExpression.cs b/SysML2.NET/Core/AutoGenDto/NullExpression.cs index 6fdae7d1..6aaafa86 100644 --- a/SysML2.NET/Core/AutoGenDto/NullExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/NullExpression.cs @@ -60,7 +60,7 @@ public partial class NullExpression : INullExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -121,7 +121,7 @@ public partial class NullExpression : INullExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/ObjectiveMembership.cs b/SysML2.NET/Core/AutoGenDto/ObjectiveMembership.cs index ef2a1d05..e6843fac 100644 --- a/SysML2.NET/Core/AutoGenDto/ObjectiveMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/ObjectiveMembership.cs @@ -121,7 +121,11 @@ public partial class ObjectiveMembership : IObjectiveMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -129,7 +133,7 @@ public partial class ObjectiveMembership : IObjectiveMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -137,7 +141,11 @@ public partial class ObjectiveMembership : IObjectiveMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -148,7 +156,7 @@ public partial class ObjectiveMembership : IObjectiveMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -156,7 +164,11 @@ public partial class ObjectiveMembership : IObjectiveMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -195,7 +207,7 @@ public partial class ObjectiveMembership : IObjectiveMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -213,7 +225,7 @@ public partial class ObjectiveMembership : IObjectiveMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IObjectiveMembership.OwnedObjectiveRequirement")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedObjectiveRequirement; /// /// The name of the ownedMemberElement. @@ -343,7 +355,11 @@ public partial class ObjectiveMembership : IObjectiveMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -352,7 +368,18 @@ public partial class ObjectiveMembership : IObjectiveMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/OccurrenceUsage.cs b/SysML2.NET/Core/AutoGenDto/OccurrenceUsage.cs index ecda5e10..0ec1e995 100644 --- a/SysML2.NET/Core/AutoGenDto/OccurrenceUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/OccurrenceUsage.cs @@ -105,7 +105,7 @@ public partial class OccurrenceUsage : IOccurrenceUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -395,7 +395,11 @@ public partial class OccurrenceUsage : IOccurrenceUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1026,7 +1030,7 @@ public partial class OccurrenceUsage : IOccurrenceUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/OperatorExpression.cs b/SysML2.NET/Core/AutoGenDto/OperatorExpression.cs index 6dfb6283..492b4f35 100644 --- a/SysML2.NET/Core/AutoGenDto/OperatorExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/OperatorExpression.cs @@ -70,7 +70,7 @@ public partial class OperatorExpression : IOperatorExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -131,7 +131,7 @@ public partial class OperatorExpression : IOperatorExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/OwningMembership.cs b/SysML2.NET/Core/AutoGenDto/OwningMembership.cs index bf5ffa86..c614e2c3 100644 --- a/SysML2.NET/Core/AutoGenDto/OwningMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/OwningMembership.cs @@ -120,7 +120,11 @@ public partial class OwningMembership : IOwningMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid IMembership.MemberElement + { + get => this.ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -128,7 +132,7 @@ public partial class OwningMembership : IOwningMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -136,7 +140,11 @@ public partial class OwningMembership : IOwningMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -154,7 +162,11 @@ public partial class OwningMembership : IOwningMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -313,7 +325,11 @@ public partial class OwningMembership : IOwningMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -322,7 +338,18 @@ public partial class OwningMembership : IOwningMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/ParameterMembership.cs b/SysML2.NET/Core/AutoGenDto/ParameterMembership.cs index bd81f094..de965cc7 100644 --- a/SysML2.NET/Core/AutoGenDto/ParameterMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/ParameterMembership.cs @@ -122,7 +122,11 @@ public partial class ParameterMembership : IParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -130,7 +134,7 @@ public partial class ParameterMembership : IParameterMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -138,7 +142,11 @@ public partial class ParameterMembership : IParameterMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -149,7 +157,7 @@ public partial class ParameterMembership : IParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -157,7 +165,11 @@ public partial class ParameterMembership : IParameterMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -196,7 +208,7 @@ public partial class ParameterMembership : IParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -214,7 +226,7 @@ public partial class ParameterMembership : IParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IParameterMembership.OwnedMemberParameter")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedMemberParameter; /// /// The name of the ownedMemberElement. @@ -344,7 +356,11 @@ public partial class ParameterMembership : IParameterMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -353,7 +369,18 @@ public partial class ParameterMembership : IParameterMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/PartUsage.cs b/SysML2.NET/Core/AutoGenDto/PartUsage.cs index 7c6c6731..645626ba 100644 --- a/SysML2.NET/Core/AutoGenDto/PartUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/PartUsage.cs @@ -104,7 +104,7 @@ public partial class PartUsage : IPartUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -394,7 +394,11 @@ public partial class PartUsage : IPartUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1043,7 +1047,7 @@ public partial class PartUsage : IPartUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/PerformActionUsage.cs b/SysML2.NET/Core/AutoGenDto/PerformActionUsage.cs index 1d011e26..ea1e78f4 100644 --- a/SysML2.NET/Core/AutoGenDto/PerformActionUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/PerformActionUsage.cs @@ -75,7 +75,7 @@ public partial class PerformActionUsage : IPerformActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -125,7 +125,7 @@ public partial class PerformActionUsage : IPerformActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -147,7 +147,7 @@ public partial class PerformActionUsage : IPerformActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -209,7 +209,7 @@ public partial class PerformActionUsage : IPerformActionUsage [Property(xmiId: "_19_0_4_12e503d9_1622831790393_676695_195", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IPerformActionUsage.PerformedAction")] [Implements(implementation: "IEventOccurrenceUsage.EventOccurrence")] - public Guid eventOccurrence { get; internal set; } + Guid Systems.Occurrences.IEventOccurrenceUsage.eventOccurrence => this.performedAction; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -399,7 +399,7 @@ public partial class PerformActionUsage : IPerformActionUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IEventOccurrenceUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool Systems.DefinitionAndUsage.IUsage.isReference { get; } + bool Systems.DefinitionAndUsage.IUsage.isReference => this.isReference; /// /// Always true for an EventOccurrenceUsage. @@ -435,7 +435,11 @@ public partial class PerformActionUsage : IPerformActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -722,7 +726,7 @@ public partial class PerformActionUsage : IPerformActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1085,7 +1089,7 @@ public partial class PerformActionUsage : IPerformActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/PortConjugation.cs b/SysML2.NET/Core/AutoGenDto/PortConjugation.cs index e07a89c5..dd1ced45 100644 --- a/SysML2.NET/Core/AutoGenDto/PortConjugation.cs +++ b/SysML2.NET/Core/AutoGenDto/PortConjugation.cs @@ -157,7 +157,14 @@ public partial class PortConjugation : IPortConjugation [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IPortConjugation.OriginalPortDefinition")] [Implements(implementation: "IConjugation.OriginalType")] - public Guid OriginalType { get; set; } + Guid Core.Types.IConjugation.OriginalType + { + get => this.OriginalPortDefinition; + set + { + this.OriginalPortDefinition = value; + } + } /// /// The ownedRelationships of this Element that are Annotations, for which this Element is the @@ -243,7 +250,7 @@ public partial class PortConjugation : IPortConjugation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1543092026091_693018_16749")] [RedefinedByProperty("IPortConjugation.ConjugatedPortDefinition")] [Implements(implementation: "IConjugation.OwningType")] - public Guid? owningType { get; internal set; } + Guid? Core.Types.IConjugation.owningType => this.conjugatedPortDefinition; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -282,7 +289,18 @@ public partial class PortConjugation : IPortConjugation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConjugation.ConjugatedType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.ConjugatedType]; + set + { + if (value.Count != 0) + { + this.ConjugatedType = value[0]; + } + + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -291,7 +309,18 @@ public partial class PortConjugation : IPortConjugation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConjugation.OriginalType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Core.Types.IConjugation)this).OriginalType]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.IConjugation)this).OriginalType = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/PortUsage.cs b/SysML2.NET/Core/AutoGenDto/PortUsage.cs index b97c0114..afcaffbc 100644 --- a/SysML2.NET/Core/AutoGenDto/PortUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/PortUsage.cs @@ -103,7 +103,7 @@ public partial class PortUsage : IPortUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -393,7 +393,11 @@ public partial class PortUsage : IPortUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -680,7 +684,7 @@ public partial class PortUsage : IPortUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IPortUsage.PortDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.portDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1033,7 +1037,7 @@ public partial class PortUsage : IPortUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/Predicate.cs b/SysML2.NET/Core/AutoGenDto/Predicate.cs index 7edcc383..63b683e5 100644 --- a/SysML2.NET/Core/AutoGenDto/Predicate.cs +++ b/SysML2.NET/Core/AutoGenDto/Predicate.cs @@ -88,7 +88,7 @@ public partial class Predicate : IPredicate [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The Documentation owned by this Element. diff --git a/SysML2.NET/Core/AutoGenDto/Redefinition.cs b/SysML2.NET/Core/AutoGenDto/Redefinition.cs index bd2585bf..31060336 100644 --- a/SysML2.NET/Core/AutoGenDto/Redefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/Redefinition.cs @@ -103,7 +103,14 @@ public partial class Redefinition : IRedefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubsetting.SubsettedFeature")] [Implements(implementation: "ISpecialization.General")] - public Guid General { get; set; } + Guid Core.Types.ISpecialization.General + { + get => ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettedFeature; + set + { + ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettedFeature = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -234,7 +241,7 @@ public partial class Redefinition : IRedefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubsetting.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public Guid? owningType { get; internal set; } + Guid? Core.Types.ISpecialization.owningType => this.owningFeature.HasValue ? this.owningFeature.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -289,7 +296,18 @@ public partial class Redefinition : IRedefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific = value[0]; + } + + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -298,7 +316,14 @@ public partial class Redefinition : IRedefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubsetting.SubsettingFeature")] [Implements(implementation: "ISpecialization.Specific")] - public Guid Specific { get; set; } + Guid Core.Types.ISpecialization.Specific + { + get => ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettingFeature; + set + { + ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettingFeature = value; + } + } /// /// The Feature that is subsetted by the subsettingFeature of this Subsetting. @@ -307,7 +332,14 @@ public partial class Redefinition : IRedefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674980_563969_43273")] [RedefinedByProperty("IRedefinition.RedefinedFeature")] [Implements(implementation: "ISubsetting.SubsettedFeature")] - public Guid SubsettedFeature { get; set; } + Guid ISubsetting.SubsettedFeature + { + get => this.RedefinedFeature; + set + { + this.RedefinedFeature = value; + } + } /// /// The Feature that is a subset of the subsettedFeature of this Subsetting. @@ -316,7 +348,14 @@ public partial class Redefinition : IRedefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("IRedefinition.RedefiningFeature")] [Implements(implementation: "ISubsetting.SubsettingFeature")] - public Guid SubsettingFeature { get; set; } + Guid ISubsetting.SubsettingFeature + { + get => this.RedefiningFeature; + set + { + this.RedefiningFeature = value; + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -325,7 +364,18 @@ public partial class Redefinition : IRedefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/ReferenceSubsetting.cs b/SysML2.NET/Core/AutoGenDto/ReferenceSubsetting.cs index 52cc785d..261e201b 100644 --- a/SysML2.NET/Core/AutoGenDto/ReferenceSubsetting.cs +++ b/SysML2.NET/Core/AutoGenDto/ReferenceSubsetting.cs @@ -97,7 +97,14 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubsetting.SubsettedFeature")] [Implements(implementation: "ISpecialization.General")] - public Guid General { get; set; } + Guid Core.Types.ISpecialization.General + { + get => ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettedFeature; + set + { + ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettedFeature = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -185,7 +192,7 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_573157_43226")] [RedefinedByProperty("IReferenceSubsetting.ReferencingFeature")] [Implements(implementation: "ISubsetting.OwningFeature")] - public Guid? owningFeature { get; internal set; } + Guid? ISubsetting.owningFeature => this.referencingFeature; /// /// The owningRelationship of this Element, if that Relationship is a Membership. @@ -229,7 +236,7 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubsetting.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public Guid? owningType { get; internal set; } + Guid? Core.Types.ISpecialization.owningType => ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).owningFeature.HasValue ? ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).owningFeature.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -285,7 +292,18 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific = value[0]; + } + + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -294,7 +312,14 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubsetting.SubsettingFeature")] [Implements(implementation: "ISpecialization.Specific")] - public Guid Specific { get; set; } + Guid Core.Types.ISpecialization.Specific + { + get => ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettingFeature; + set + { + ((SysML2.NET.Core.DTO.Core.Features.ISubsetting)this).SubsettingFeature = value; + } + } /// /// The Feature that is subsetted by the subsettingFeature of this Subsetting. @@ -303,7 +328,14 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674980_563969_43273")] [RedefinedByProperty("IReferenceSubsetting.ReferencedFeature")] [Implements(implementation: "ISubsetting.SubsettedFeature")] - public Guid SubsettedFeature { get; set; } + Guid ISubsetting.SubsettedFeature + { + get => this.ReferencedFeature; + set + { + this.ReferencedFeature = value; + } + } /// /// The Feature that is a subset of the subsettedFeature of this Subsetting. @@ -312,7 +344,11 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("IReferenceSubsetting.ReferencingFeature")] [Implements(implementation: "ISubsetting.SubsettingFeature")] - public Guid SubsettingFeature { get; set; } + Guid ISubsetting.SubsettingFeature + { + get => this.referencingFeature; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -321,7 +357,18 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/ReferenceUsage.cs b/SysML2.NET/Core/AutoGenDto/ReferenceUsage.cs index d61dba8c..a7a59b2c 100644 --- a/SysML2.NET/Core/AutoGenDto/ReferenceUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/ReferenceUsage.cs @@ -358,7 +358,7 @@ public partial class ReferenceUsage : IReferenceUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IReferenceUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool IUsage.isReference { get; } + bool IUsage.isReference => this.isReference; /// /// Whether all things that meet the classification conditions of this Type must be classified by the @@ -386,7 +386,11 @@ public partial class ReferenceUsage : IReferenceUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -998,7 +1002,7 @@ public partial class ReferenceUsage : IReferenceUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => this.definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/RenderingUsage.cs b/SysML2.NET/Core/AutoGenDto/RenderingUsage.cs index 6764079b..0ffa32b7 100644 --- a/SysML2.NET/Core/AutoGenDto/RenderingUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/RenderingUsage.cs @@ -103,7 +103,7 @@ public partial class RenderingUsage : IRenderingUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -393,7 +393,11 @@ public partial class RenderingUsage : IRenderingUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -992,7 +996,7 @@ public partial class RenderingUsage : IRenderingUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1565471361757_649736_20796")] [RedefinedByProperty("IRenderingUsage.RenderingDefinition")] [Implements(implementation: "IPartUsage.PartDefinition")] - public List partDefinition { get; internal set; } = []; + List Systems.Parts.IPartUsage.partDefinition => this.renderingDefinition.HasValue ? [this.renderingDefinition.Value] : []; /// /// The kind of temporal portion (time slice or snapshot) is represented by this OccurrenceUsage. If @@ -1051,7 +1055,7 @@ public partial class RenderingUsage : IRenderingUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/RequirementConstraintMembership.cs b/SysML2.NET/Core/AutoGenDto/RequirementConstraintMembership.cs index 2ba31e6b..a36ae695 100644 --- a/SysML2.NET/Core/AutoGenDto/RequirementConstraintMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/RequirementConstraintMembership.cs @@ -129,7 +129,11 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -137,7 +141,7 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -145,7 +149,11 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -156,7 +164,7 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -164,7 +172,11 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -211,7 +223,7 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -229,7 +241,7 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IRequirementConstraintMembership.OwnedConstraint")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedConstraint; /// /// The name of the ownedMemberElement. @@ -360,7 +372,11 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -369,7 +385,18 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/RequirementDefinition.cs b/SysML2.NET/Core/AutoGenDto/RequirementDefinition.cs index 11d83e46..c5615766 100644 --- a/SysML2.NET/Core/AutoGenDto/RequirementDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/RequirementDefinition.cs @@ -89,7 +89,14 @@ public partial class RequirementDefinition : IRequirementDefinition [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementDefinition.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -111,7 +118,7 @@ public partial class RequirementDefinition : IRequirementDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenDto/RequirementUsage.cs b/SysML2.NET/Core/AutoGenDto/RequirementUsage.cs index 716324f8..78040ef4 100644 --- a/SysML2.NET/Core/AutoGenDto/RequirementUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/RequirementUsage.cs @@ -80,7 +80,7 @@ public partial class RequirementUsage : IRequirementUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -103,7 +103,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578025035149_386_969")] [RedefinedByProperty("IRequirementUsage.RequirementDefinition")] [Implements(implementation: "IConstraintUsage.ConstraintDefinition")] - public Guid? constraintDefinition { get; internal set; } + Guid? Systems.Constraints.IConstraintUsage.constraintDefinition => this.requirementDefinition.HasValue ? this.requirementDefinition.Value : Guid.Empty; /// /// The second chainingFeature of the crossedFeature of the ownedCrossSubsetting of this Feature, if it @@ -131,7 +131,14 @@ public partial class RequirementUsage : IRequirementUsage [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementUsage.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The Classifiers that are the types of this Usage. Nominally, these are Definitions, but other kinds @@ -142,7 +149,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -164,7 +171,7 @@ public partial class RequirementUsage : IRequirementUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -268,7 +275,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.HasValue ? ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -459,7 +466,11 @@ public partial class RequirementUsage : IRequirementUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1066,7 +1077,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public Guid? predicate { get; internal set; } + Guid? Kernel.Functions.IBooleanExpression.predicate => ((SysML2.NET.Core.DTO.Systems.Constraints.IConstraintUsage)this).constraintDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Constraints.IConstraintUsage)this).constraintDefinition.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1173,7 +1184,7 @@ public partial class RequirementUsage : IRequirementUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/RequirementVerificationMembership.cs b/SysML2.NET/Core/AutoGenDto/RequirementVerificationMembership.cs index 422ad9f9..48d1e9d6 100644 --- a/SysML2.NET/Core/AutoGenDto/RequirementVerificationMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/RequirementVerificationMembership.cs @@ -129,7 +129,14 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [Property(xmiId: "_19_0_2_12e503d9_1584048161309_821854_390", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementVerificationMembership.Kind")] [Implements(implementation: "IRequirementConstraintMembership.Kind")] - RequirementConstraintKind Systems.Requirements.IRequirementConstraintMembership.Kind { get; set; } + RequirementConstraintKind Systems.Requirements.IRequirementConstraintMembership.Kind + { + get => this.Kind; + set + { + this.Kind = value; + } + } /// /// The Element that becomes a member of the membershipOwningNamespace due to this Membership. @@ -138,7 +145,11 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -146,7 +157,7 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -154,7 +165,11 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -165,7 +180,7 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -173,7 +188,11 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -202,7 +221,7 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674993_898044_43344")] [RedefinedByProperty("IRequirementVerificationMembership.OwnedRequirement")] [Implements(implementation: "IRequirementConstraintMembership.OwnedConstraint")] - public Guid ownedConstraint { get; internal set; } + Guid Systems.Requirements.IRequirementConstraintMembership.ownedConstraint => this.ownedRequirement; /// /// The Elements owned by this Element, derived as the ownedRelatedElements of the ownedRelationships of @@ -221,7 +240,7 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -239,7 +258,7 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IRequirementConstraintMembership.OwnedConstraint")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => ((SysML2.NET.Core.DTO.Systems.Requirements.IRequirementConstraintMembership)this).ownedConstraint; /// /// The name of the ownedMemberElement. @@ -354,7 +373,7 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [Property(xmiId: "_19_0_4_12e503d9_1617118807597_77864_3544", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementVerificationMembership.VerifiedRequirement")] [Implements(implementation: "IRequirementConstraintMembership.ReferencedConstraint")] - public Guid referencedConstraint { get; internal set; } + Guid Systems.Requirements.IRequirementConstraintMembership.referencedConstraint => this.verifiedRequirement; /// /// The Elements that are related by this Relationship, derived as the union of the source and target @@ -381,7 +400,11 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -390,7 +413,18 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/ResultExpressionMembership.cs b/SysML2.NET/Core/AutoGenDto/ResultExpressionMembership.cs index b1b24220..8d7b27e8 100644 --- a/SysML2.NET/Core/AutoGenDto/ResultExpressionMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/ResultExpressionMembership.cs @@ -123,7 +123,11 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -131,7 +135,7 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -139,7 +143,11 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -150,7 +158,7 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -158,7 +166,11 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -197,7 +209,7 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -215,7 +227,7 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IResultExpressionMembership.OwnedResultExpression")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedResultExpression; /// /// The name of the ownedMemberElement. @@ -345,7 +357,11 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -354,7 +370,18 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/ReturnParameterMembership.cs b/SysML2.NET/Core/AutoGenDto/ReturnParameterMembership.cs index 495f2c3e..754cf8cb 100644 --- a/SysML2.NET/Core/AutoGenDto/ReturnParameterMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/ReturnParameterMembership.cs @@ -122,7 +122,11 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -130,7 +134,7 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -138,7 +142,11 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -149,7 +157,7 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -157,7 +165,11 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -196,7 +208,7 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -214,7 +226,7 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IParameterMembership.OwnedMemberParameter")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedMemberParameter; /// /// The name of the ownedMemberElement. @@ -344,7 +356,11 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -353,7 +369,18 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/SatisfyRequirementUsage.cs b/SysML2.NET/Core/AutoGenDto/SatisfyRequirementUsage.cs index 5a4a33e7..83ad451d 100644 --- a/SysML2.NET/Core/AutoGenDto/SatisfyRequirementUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/SatisfyRequirementUsage.cs @@ -74,7 +74,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [Property(xmiId: "_19_0_2_12e503d9_1581045158665_239617_9458", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("ISatisfyRequirementUsage.SatisfiedRequirement")] [Implements(implementation: "IAssertConstraintUsage.AssertedConstraint")] - public Guid assertedConstraint { get; internal set; } + Guid Systems.Constraints.IAssertConstraintUsage.assertedConstraint => this.satisfiedRequirement; /// /// The owned ConstraintUsages that represent assumptions of this RequirementUsage, derived as the @@ -93,7 +93,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -116,7 +116,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578025035149_386_969")] [RedefinedByProperty("IRequirementUsage.RequirementDefinition")] [Implements(implementation: "IConstraintUsage.ConstraintDefinition")] - public Guid? constraintDefinition { get; internal set; } + Guid? Systems.Constraints.IConstraintUsage.constraintDefinition => this.requirementDefinition.HasValue ? this.requirementDefinition.Value : Guid.Empty; /// /// The second chainingFeature of the crossedFeature of the ownedCrossSubsetting of this Feature, if it @@ -144,7 +144,14 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementUsage.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The Classifiers that are the types of this Usage. Nominally, these are Definitions, but other kinds @@ -155,7 +162,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -177,7 +184,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -281,7 +288,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.HasValue ? ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -479,7 +486,11 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1086,7 +1097,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public Guid? predicate { get; internal set; } + Guid? Kernel.Functions.IBooleanExpression.predicate => ((SysML2.NET.Core.DTO.Systems.Constraints.IConstraintUsage)this).constraintDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Constraints.IConstraintUsage)this).constraintDefinition.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1211,7 +1222,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/SelectExpression.cs b/SysML2.NET/Core/AutoGenDto/SelectExpression.cs index 8f2e4d40..4114c96a 100644 --- a/SysML2.NET/Core/AutoGenDto/SelectExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/SelectExpression.cs @@ -70,7 +70,7 @@ public partial class SelectExpression : ISelectExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -131,7 +131,7 @@ public partial class SelectExpression : ISelectExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -443,7 +443,14 @@ public partial class SelectExpression : ISelectExpression [Property(xmiId: "_18_5_3_12e503d9_1557528808100_646606_111674", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("ISelectExpression.Operator")] [Implements(implementation: "IOperatorExpression.Operator")] - string IOperatorExpression.Operator { get; set; } + string IOperatorExpression.Operator + { + get => this.Operator; + set + { + this.Operator = value; + } + } /// /// All features related to this Type by FeatureMemberships that have direction out or inout. diff --git a/SysML2.NET/Core/AutoGenDto/SendActionUsage.cs b/SysML2.NET/Core/AutoGenDto/SendActionUsage.cs index 9803653c..d31e71b9 100644 --- a/SysML2.NET/Core/AutoGenDto/SendActionUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/SendActionUsage.cs @@ -76,7 +76,7 @@ public partial class SendActionUsage : ISendActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -126,7 +126,7 @@ public partial class SendActionUsage : ISendActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -148,7 +148,7 @@ public partial class SendActionUsage : ISendActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -417,7 +417,11 @@ public partial class SendActionUsage : ISendActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -704,7 +708,7 @@ public partial class SendActionUsage : ISendActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1079,7 +1083,7 @@ public partial class SendActionUsage : ISendActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/Specialization.cs b/SysML2.NET/Core/AutoGenDto/Specialization.cs index bbd1a390..623f53f3 100644 --- a/SysML2.NET/Core/AutoGenDto/Specialization.cs +++ b/SysML2.NET/Core/AutoGenDto/Specialization.cs @@ -254,7 +254,18 @@ public partial class Specialization : ISpecialization [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.Specific]; + set + { + if (value.Count != 0) + { + this.Specific = value[0]; + } + + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -271,7 +282,18 @@ public partial class Specialization : ISpecialization [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.General]; + set + { + if (value.Count != 0) + { + this.General = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/StakeholderMembership.cs b/SysML2.NET/Core/AutoGenDto/StakeholderMembership.cs index 05a4c074..04d5b451 100644 --- a/SysML2.NET/Core/AutoGenDto/StakeholderMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/StakeholderMembership.cs @@ -122,7 +122,11 @@ public partial class StakeholderMembership : IStakeholderMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -130,7 +134,7 @@ public partial class StakeholderMembership : IStakeholderMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -138,7 +142,11 @@ public partial class StakeholderMembership : IStakeholderMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -149,7 +157,7 @@ public partial class StakeholderMembership : IStakeholderMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -157,7 +165,11 @@ public partial class StakeholderMembership : IStakeholderMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -196,7 +208,7 @@ public partial class StakeholderMembership : IStakeholderMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -214,7 +226,7 @@ public partial class StakeholderMembership : IStakeholderMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IParameterMembership.OwnedMemberParameter")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => ((SysML2.NET.Core.DTO.Kernel.Behaviors.IParameterMembership)this).ownedMemberParameter; /// /// The name of the ownedMemberElement. @@ -231,7 +243,7 @@ public partial class StakeholderMembership : IStakeholderMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674993_898044_43344")] [RedefinedByProperty("IStakeholderMembership.OwnedStakeholderParameter")] [Implements(implementation: "IParameterMembership.OwnedMemberParameter")] - public Guid ownedMemberParameter { get; internal set; } + Guid Kernel.Behaviors.IParameterMembership.ownedMemberParameter => this.ownedStakeholderParameter; /// /// The shortName of the ownedMemberElement. @@ -353,7 +365,11 @@ public partial class StakeholderMembership : IStakeholderMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -362,7 +378,18 @@ public partial class StakeholderMembership : IStakeholderMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/StateDefinition.cs b/SysML2.NET/Core/AutoGenDto/StateDefinition.cs index 5c229d1a..ae0defa1 100644 --- a/SysML2.NET/Core/AutoGenDto/StateDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/StateDefinition.cs @@ -102,7 +102,7 @@ public partial class StateDefinition : IStateDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenDto/StateSubactionMembership.cs b/SysML2.NET/Core/AutoGenDto/StateSubactionMembership.cs index 051331e1..bb907492 100644 --- a/SysML2.NET/Core/AutoGenDto/StateSubactionMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/StateSubactionMembership.cs @@ -137,7 +137,11 @@ public partial class StateSubactionMembership : IStateSubactionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -145,7 +149,7 @@ public partial class StateSubactionMembership : IStateSubactionMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -153,7 +157,11 @@ public partial class StateSubactionMembership : IStateSubactionMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -164,7 +172,7 @@ public partial class StateSubactionMembership : IStateSubactionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -172,7 +180,11 @@ public partial class StateSubactionMembership : IStateSubactionMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -211,7 +223,7 @@ public partial class StateSubactionMembership : IStateSubactionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -229,7 +241,7 @@ public partial class StateSubactionMembership : IStateSubactionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IStateSubactionMembership.Action")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => this.action; /// /// The name of the ownedMemberElement. @@ -351,7 +363,11 @@ public partial class StateSubactionMembership : IStateSubactionMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -360,7 +376,18 @@ public partial class StateSubactionMembership : IStateSubactionMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/StateUsage.cs b/SysML2.NET/Core/AutoGenDto/StateUsage.cs index dbead799..995dc55f 100644 --- a/SysML2.NET/Core/AutoGenDto/StateUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/StateUsage.cs @@ -60,7 +60,7 @@ public partial class StateUsage : IStateUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("IStateUsage.StateDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition { get; internal set; } = []; + List Systems.Actions.IActionUsage.actionDefinition => this.stateDefinition; /// /// Various alternative identifiers for this Element. Generally, these will be set by tools. @@ -76,7 +76,7 @@ public partial class StateUsage : IStateUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Systems.Actions.IActionUsage)this).actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -126,7 +126,7 @@ public partial class StateUsage : IStateUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -148,7 +148,7 @@ public partial class StateUsage : IStateUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -453,7 +453,11 @@ public partial class StateUsage : IStateUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -740,7 +744,7 @@ public partial class StateUsage : IStateUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => ((SysML2.NET.Core.DTO.Systems.Actions.IActionUsage)this).actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1103,7 +1107,7 @@ public partial class StateUsage : IStateUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/Step.cs b/SysML2.NET/Core/AutoGenDto/Step.cs index bfb3e832..bb02b5ab 100644 --- a/SysML2.NET/Core/AutoGenDto/Step.cs +++ b/SysML2.NET/Core/AutoGenDto/Step.cs @@ -123,7 +123,7 @@ public partial class Step : IStep [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/Subclassification.cs b/SysML2.NET/Core/AutoGenDto/Subclassification.cs index 13f80a54..63ebf703 100644 --- a/SysML2.NET/Core/AutoGenDto/Subclassification.cs +++ b/SysML2.NET/Core/AutoGenDto/Subclassification.cs @@ -94,7 +94,14 @@ public partial class Subclassification : ISubclassification [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubclassification.Superclassifier")] [Implements(implementation: "ISpecialization.General")] - public Guid General { get; set; } + Guid Core.Types.ISpecialization.General + { + get => this.Superclassifier; + set + { + this.Superclassifier = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -224,7 +231,7 @@ public partial class Subclassification : ISubclassification [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubclassification.OwningClassifier")] [Implements(implementation: "ISpecialization.OwningType")] - public Guid? owningType { get; internal set; } + Guid? Core.Types.ISpecialization.owningType => this.owningClassifier.HasValue ? this.owningClassifier.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -263,7 +270,18 @@ public partial class Subclassification : ISubclassification [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific = value[0]; + } + + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -272,7 +290,14 @@ public partial class Subclassification : ISubclassification [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubclassification.Subclassifier")] [Implements(implementation: "ISpecialization.Specific")] - public Guid Specific { get; set; } + Guid Core.Types.ISpecialization.Specific + { + get => this.Subclassifier; + set + { + this.Subclassifier = value; + } + } /// /// The more specific Classifier in this Subclassification. @@ -297,7 +322,18 @@ public partial class Subclassification : ISubclassification [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/SubjectMembership.cs b/SysML2.NET/Core/AutoGenDto/SubjectMembership.cs index 680097b6..5103272f 100644 --- a/SysML2.NET/Core/AutoGenDto/SubjectMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/SubjectMembership.cs @@ -122,7 +122,11 @@ public partial class SubjectMembership : ISubjectMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -130,7 +134,7 @@ public partial class SubjectMembership : ISubjectMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -138,7 +142,11 @@ public partial class SubjectMembership : ISubjectMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -149,7 +157,7 @@ public partial class SubjectMembership : ISubjectMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -157,7 +165,11 @@ public partial class SubjectMembership : ISubjectMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -196,7 +208,7 @@ public partial class SubjectMembership : ISubjectMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -214,7 +226,7 @@ public partial class SubjectMembership : ISubjectMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IParameterMembership.OwnedMemberParameter")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => ((SysML2.NET.Core.DTO.Kernel.Behaviors.IParameterMembership)this).ownedMemberParameter; /// /// The name of the ownedMemberElement. @@ -231,7 +243,7 @@ public partial class SubjectMembership : ISubjectMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674993_898044_43344")] [RedefinedByProperty("ISubjectMembership.OwnedSubjectParameter")] [Implements(implementation: "IParameterMembership.OwnedMemberParameter")] - public Guid ownedMemberParameter { get; internal set; } + Guid Kernel.Behaviors.IParameterMembership.ownedMemberParameter => this.ownedSubjectParameter; /// /// The shortName of the ownedMemberElement. @@ -353,7 +365,11 @@ public partial class SubjectMembership : ISubjectMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -362,7 +378,18 @@ public partial class SubjectMembership : ISubjectMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/Subsetting.cs b/SysML2.NET/Core/AutoGenDto/Subsetting.cs index ceb3a374..988ff38b 100644 --- a/SysML2.NET/Core/AutoGenDto/Subsetting.cs +++ b/SysML2.NET/Core/AutoGenDto/Subsetting.cs @@ -98,7 +98,14 @@ public partial class Subsetting : ISubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubsetting.SubsettedFeature")] [Implements(implementation: "ISpecialization.General")] - public Guid General { get; set; } + Guid Core.Types.ISpecialization.General + { + get => this.SubsettedFeature; + set + { + this.SubsettedFeature = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -229,7 +236,7 @@ public partial class Subsetting : ISubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubsetting.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public Guid? owningType { get; internal set; } + Guid? Core.Types.ISpecialization.owningType => this.owningFeature.HasValue ? this.owningFeature.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -268,7 +275,18 @@ public partial class Subsetting : ISubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).Specific = value[0]; + } + + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -277,7 +295,14 @@ public partial class Subsetting : ISubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubsetting.SubsettingFeature")] [Implements(implementation: "ISpecialization.Specific")] - public Guid Specific { get; set; } + Guid Core.Types.ISpecialization.Specific + { + get => this.SubsettingFeature; + set + { + this.SubsettingFeature = value; + } + } /// /// The Feature that is subsetted by the subsettingFeature of this Subsetting. @@ -302,7 +327,18 @@ public partial class Subsetting : ISubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Core.Types.ISpecialization)this).General = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/Succession.cs b/SysML2.NET/Core/AutoGenDto/Succession.cs index e7ac4cf0..b4b1257b 100644 --- a/SysML2.NET/Core/AutoGenDto/Succession.cs +++ b/SysML2.NET/Core/AutoGenDto/Succession.cs @@ -171,7 +171,7 @@ public partial class Succession : ISuccession [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -732,7 +732,7 @@ public partial class Succession : ISuccession [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -760,7 +760,11 @@ public partial class Succession : ISuccession [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -778,7 +782,11 @@ public partial class Succession : ISuccession [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -808,7 +816,7 @@ public partial class Succession : ISuccession [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => this.association; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/SuccessionAsUsage.cs b/SysML2.NET/Core/AutoGenDto/SuccessionAsUsage.cs index 4f1273cc..54d70e8f 100644 --- a/SysML2.NET/Core/AutoGenDto/SuccessionAsUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/SuccessionAsUsage.cs @@ -191,7 +191,7 @@ public partial class SuccessionAsUsage : ISuccessionAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -410,7 +410,11 @@ public partial class SuccessionAsUsage : ISuccessionAsUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1017,7 +1021,7 @@ public partial class SuccessionAsUsage : ISuccessionAsUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1045,7 +1049,11 @@ public partial class SuccessionAsUsage : ISuccessionAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1063,7 +1071,11 @@ public partial class SuccessionAsUsage : ISuccessionAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1093,7 +1105,7 @@ public partial class SuccessionAsUsage : ISuccessionAsUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => this.definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/SuccessionFlow.cs b/SysML2.NET/Core/AutoGenDto/SuccessionFlow.cs index 1fc4600e..9f1e1ed0 100644 --- a/SysML2.NET/Core/AutoGenDto/SuccessionFlow.cs +++ b/SysML2.NET/Core/AutoGenDto/SuccessionFlow.cs @@ -62,7 +62,7 @@ public partial class SuccessionFlow : ISuccessionFlow [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IConnector.Association")] - public List association { get; internal set; } = []; + List Kernel.Connectors.IConnector.association => this.interaction; /// /// The Behaviors that type this Step. @@ -71,7 +71,7 @@ public partial class SuccessionFlow : ISuccessionFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.interaction; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -151,7 +151,7 @@ public partial class SuccessionFlow : ISuccessionFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -185,7 +185,7 @@ public partial class SuccessionFlow : ISuccessionFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -788,7 +788,7 @@ public partial class SuccessionFlow : ISuccessionFlow [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -816,7 +816,11 @@ public partial class SuccessionFlow : ISuccessionFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -842,7 +846,11 @@ public partial class SuccessionFlow : ISuccessionFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -880,7 +888,7 @@ public partial class SuccessionFlow : ISuccessionFlow [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Kernel.Connectors.IConnector)this).association; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/SuccessionFlowUsage.cs b/SysML2.NET/Core/AutoGenDto/SuccessionFlowUsage.cs index d068cbc3..7558f9f8 100644 --- a/SysML2.NET/Core/AutoGenDto/SuccessionFlowUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/SuccessionFlowUsage.cs @@ -57,7 +57,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("IFlowUsage.FlowDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition { get; internal set; } = []; + List Systems.Actions.IActionUsage.actionDefinition => this.flowDefinition; /// /// Various alternative identifiers for this Element. Generally, these will be set by tools. @@ -73,7 +73,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IConnector.Association")] - public List association { get; internal set; } = []; + List Kernel.Connectors.IConnector.association => ((SysML2.NET.Core.DTO.Kernel.Interactions.IFlow)this).interaction; /// /// The Behaviors that type this Step. @@ -82,7 +82,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Interactions.IFlow)this).interaction; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -151,7 +151,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -173,7 +173,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -216,7 +216,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature { get; internal set; } = []; + List Core.Types.IType.endFeature => this.connectorEnd; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -331,7 +331,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IFlowUsage.FlowDefinition")] [Implements(implementation: "IFlow.Interaction")] - public List interaction { get; internal set; } = []; + List Kernel.Interactions.IFlow.interaction => this.flowDefinition; /// /// The interpretations of a Type with intersectingTypes are asserted to be those in common among the @@ -481,7 +481,11 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -768,7 +772,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => ((SysML2.NET.Core.DTO.Systems.Actions.IActionUsage)this).actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1132,7 +1136,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement { get; internal set; } = []; + List Root.Elements.IRelationship.relatedElement => this.relatedFeature; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1160,7 +1164,11 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature.HasValue ? [this.sourceFeature.Value] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1186,7 +1194,11 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.targetFeature; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1224,7 +1236,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Kernel.Connectors.IConnector)this).association; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/TerminateActionUsage.cs b/SysML2.NET/Core/AutoGenDto/TerminateActionUsage.cs index eb23b0ab..4c2943c9 100644 --- a/SysML2.NET/Core/AutoGenDto/TerminateActionUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/TerminateActionUsage.cs @@ -75,7 +75,7 @@ public partial class TerminateActionUsage : ITerminateActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -125,7 +125,7 @@ public partial class TerminateActionUsage : ITerminateActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -147,7 +147,7 @@ public partial class TerminateActionUsage : ITerminateActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -416,7 +416,11 @@ public partial class TerminateActionUsage : ITerminateActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -703,7 +707,7 @@ public partial class TerminateActionUsage : ITerminateActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1065,7 +1069,7 @@ public partial class TerminateActionUsage : ITerminateActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/TextualRepresentation.cs b/SysML2.NET/Core/AutoGenDto/TextualRepresentation.cs index a1228ab5..769ba1f9 100644 --- a/SysML2.NET/Core/AutoGenDto/TextualRepresentation.cs +++ b/SysML2.NET/Core/AutoGenDto/TextualRepresentation.cs @@ -82,7 +82,7 @@ public partial class TextualRepresentation : ITextualRepresentation [Property(xmiId: "_19_0_2_12e503d9_1594145755058_99428_86", aggregation: AggregationKind.None, lowerValue: 1, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("ITextualRepresentation.RepresentedElement")] [Implements(implementation: "IAnnotatingElement.AnnotatedElement")] - public List annotatedElement { get; internal set; } = []; + List IAnnotatingElement.annotatedElement => [this.representedElement]; /// /// The Annotations that relate this AnnotatingElement to its annotatedElements. This includes the diff --git a/SysML2.NET/Core/AutoGenDto/TransitionFeatureMembership.cs b/SysML2.NET/Core/AutoGenDto/TransitionFeatureMembership.cs index cf67182e..10cf479d 100644 --- a/SysML2.NET/Core/AutoGenDto/TransitionFeatureMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/TransitionFeatureMembership.cs @@ -130,7 +130,11 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -138,7 +142,7 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -146,7 +150,11 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -157,7 +165,7 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -165,7 +173,11 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -204,7 +216,7 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -222,7 +234,7 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("ITransitionFeatureMembership.TransitionFeature")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => this.transitionFeature; /// /// The name of the ownedMemberElement. @@ -344,7 +356,11 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -353,7 +369,18 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/TransitionUsage.cs b/SysML2.NET/Core/AutoGenDto/TransitionUsage.cs index ab400e0b..2440691d 100644 --- a/SysML2.NET/Core/AutoGenDto/TransitionUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/TransitionUsage.cs @@ -77,7 +77,7 @@ public partial class TransitionUsage : ITransitionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -127,7 +127,7 @@ public partial class TransitionUsage : ITransitionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -149,7 +149,7 @@ public partial class TransitionUsage : ITransitionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -438,7 +438,11 @@ public partial class TransitionUsage : ITransitionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -725,7 +729,7 @@ public partial class TransitionUsage : ITransitionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1114,7 +1118,7 @@ public partial class TransitionUsage : ITransitionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/TriggerInvocationExpression.cs b/SysML2.NET/Core/AutoGenDto/TriggerInvocationExpression.cs index 446161b6..4cf9d3aa 100644 --- a/SysML2.NET/Core/AutoGenDto/TriggerInvocationExpression.cs +++ b/SysML2.NET/Core/AutoGenDto/TriggerInvocationExpression.cs @@ -72,7 +72,7 @@ public partial class TriggerInvocationExpression : ITriggerInvocationExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.function.HasValue ? [this.function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -133,7 +133,7 @@ public partial class TriggerInvocationExpression : ITriggerInvocationExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenDto/TypeFeaturing.cs b/SysML2.NET/Core/AutoGenDto/TypeFeaturing.cs index 2d1cd249..6bd77540 100644 --- a/SysML2.NET/Core/AutoGenDto/TypeFeaturing.cs +++ b/SysML2.NET/Core/AutoGenDto/TypeFeaturing.cs @@ -261,7 +261,18 @@ public partial class TypeFeaturing : ITypeFeaturing [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ITypeFeaturing.FeatureOfType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.FeatureOfType]; + set + { + if (value.Count != 0) + { + this.FeatureOfType = value[0]; + } + + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -270,7 +281,18 @@ public partial class TypeFeaturing : ITypeFeaturing [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ITypeFeaturing.FeaturingType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.FeaturingType]; + set + { + if (value.Count != 0) + { + this.FeaturingType = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/Unioning.cs b/SysML2.NET/Core/AutoGenDto/Unioning.cs index 6a376cb0..ed1edb8c 100644 --- a/SysML2.NET/Core/AutoGenDto/Unioning.cs +++ b/SysML2.NET/Core/AutoGenDto/Unioning.cs @@ -235,7 +235,11 @@ public partial class Unioning : IUnioning [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IUnioning.TypeUnioned")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.typeUnioned]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -244,7 +248,18 @@ public partial class Unioning : IUnioning [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IUnioning.UnioningType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [this.UnioningType]; + set + { + if (value.Count != 0) + { + this.UnioningType = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/Usage.cs b/SysML2.NET/Core/AutoGenDto/Usage.cs index 3667c740..9b37b899 100644 --- a/SysML2.NET/Core/AutoGenDto/Usage.cs +++ b/SysML2.NET/Core/AutoGenDto/Usage.cs @@ -380,7 +380,11 @@ public partial class Usage : IUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -992,7 +996,7 @@ public partial class Usage : IUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => this.definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/UseCaseDefinition.cs b/SysML2.NET/Core/AutoGenDto/UseCaseDefinition.cs index 7f868a39..1df59690 100644 --- a/SysML2.NET/Core/AutoGenDto/UseCaseDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/UseCaseDefinition.cs @@ -119,7 +119,7 @@ public partial class UseCaseDefinition : IUseCaseDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenDto/UseCaseUsage.cs b/SysML2.NET/Core/AutoGenDto/UseCaseUsage.cs index 32bb7a17..7fa0ec69 100644 --- a/SysML2.NET/Core/AutoGenDto/UseCaseUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/UseCaseUsage.cs @@ -57,7 +57,7 @@ public partial class UseCaseUsage : IUseCaseUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition { get; internal set; } = []; + List Systems.Actions.IActionUsage.actionDefinition => ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.HasValue ? [((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.Value] : []; /// /// The parameters of this CaseUsage that represent actors involved in the case. @@ -82,7 +82,7 @@ public partial class UseCaseUsage : IUseCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Function that is the type of this CalculationUsage. Nominally, this would be a @@ -94,7 +94,7 @@ public partial class UseCaseUsage : IUseCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1565500905804_589845_30779")] [RedefinedByProperty("ICaseUsage.CaseDefinition")] [Implements(implementation: "ICalculationUsage.CalculationDefinition")] - public Guid? calculationDefinition { get; internal set; } + Guid? Systems.Calculations.ICalculationUsage.calculationDefinition => ((SysML2.NET.Core.DTO.Systems.Cases.ICaseUsage)this).caseDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Cases.ICaseUsage)this).caseDefinition.Value : Guid.Empty; /// /// The CaseDefinition that is the type of this CaseUsage. @@ -103,7 +103,7 @@ public partial class UseCaseUsage : IUseCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1588213526305_899324_302")] [RedefinedByProperty("IUseCaseUsage.UseCaseDefinition")] [Implements(implementation: "ICaseUsage.CaseDefinition")] - public Guid? caseDefinition { get; internal set; } + Guid? Systems.Cases.ICaseUsage.caseDefinition => this.useCaseDefinition.HasValue ? this.useCaseDefinition.Value : Guid.Empty; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -153,7 +153,7 @@ public partial class UseCaseUsage : IUseCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -175,7 +175,7 @@ public partial class UseCaseUsage : IUseCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -270,7 +270,7 @@ public partial class UseCaseUsage : IUseCaseUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -469,7 +469,11 @@ public partial class UseCaseUsage : IUseCaseUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -764,7 +768,7 @@ public partial class UseCaseUsage : IUseCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => ((SysML2.NET.Core.DTO.Systems.Actions.IActionUsage)this).actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1138,7 +1142,7 @@ public partial class UseCaseUsage : IUseCaseUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/VariantMembership.cs b/SysML2.NET/Core/AutoGenDto/VariantMembership.cs index 38e3a90c..b5eafca2 100644 --- a/SysML2.NET/Core/AutoGenDto/VariantMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/VariantMembership.cs @@ -122,7 +122,11 @@ public partial class VariantMembership : IVariantMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -130,7 +134,7 @@ public partial class VariantMembership : IVariantMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -138,7 +142,11 @@ public partial class VariantMembership : IVariantMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -156,7 +164,11 @@ public partial class VariantMembership : IVariantMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -195,7 +207,7 @@ public partial class VariantMembership : IVariantMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IVariantMembership.OwnedVariantUsage")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => this.ownedVariantUsage; /// /// The elementId of the ownedMemberElement. @@ -325,7 +337,11 @@ public partial class VariantMembership : IVariantMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [this.membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -334,7 +350,18 @@ public partial class VariantMembership : IVariantMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/VerificationCaseDefinition.cs b/SysML2.NET/Core/AutoGenDto/VerificationCaseDefinition.cs index 118f9ea1..3719d71e 100644 --- a/SysML2.NET/Core/AutoGenDto/VerificationCaseDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/VerificationCaseDefinition.cs @@ -118,7 +118,7 @@ public partial class VerificationCaseDefinition : IVerificationCaseDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenDto/VerificationCaseUsage.cs b/SysML2.NET/Core/AutoGenDto/VerificationCaseUsage.cs index 1db7341a..3e5b01f9 100644 --- a/SysML2.NET/Core/AutoGenDto/VerificationCaseUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/VerificationCaseUsage.cs @@ -57,7 +57,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition { get; internal set; } = []; + List Systems.Actions.IActionUsage.actionDefinition => ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.HasValue ? [((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.Value] : []; /// /// The parameters of this CaseUsage that represent actors involved in the case. @@ -82,7 +82,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Function that is the type of this CalculationUsage. Nominally, this would be a @@ -94,7 +94,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1565500905804_589845_30779")] [RedefinedByProperty("ICaseUsage.CaseDefinition")] [Implements(implementation: "ICalculationUsage.CalculationDefinition")] - public Guid? calculationDefinition { get; internal set; } + Guid? Systems.Calculations.ICalculationUsage.calculationDefinition => this.caseDefinition.HasValue ? this.caseDefinition.Value : Guid.Empty; /// /// The CaseDefinition that is the type of this CaseUsage. @@ -152,7 +152,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -174,7 +174,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -269,7 +269,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Calculations.ICalculationUsage)this).calculationDefinition.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -460,7 +460,11 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -755,7 +759,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => ((SysML2.NET.Core.DTO.Systems.Actions.IActionUsage)this).actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1129,7 +1133,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/ViewRenderingMembership.cs b/SysML2.NET/Core/AutoGenDto/ViewRenderingMembership.cs index ef43726f..4c299582 100644 --- a/SysML2.NET/Core/AutoGenDto/ViewRenderingMembership.cs +++ b/SysML2.NET/Core/AutoGenDto/ViewRenderingMembership.cs @@ -121,7 +121,11 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public Guid MemberElement { get; set; } + Guid Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.DTO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -129,7 +133,7 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId { get; internal set; } + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -137,7 +141,11 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -148,7 +156,7 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public Guid membershipOwningNamespace { get; internal set; } + Guid Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -156,7 +164,11 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -195,7 +207,7 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public Guid ownedMemberElement { get; internal set; } + Guid Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.DTO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -213,7 +225,7 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IViewRenderingMembership.OwnedRendering")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public Guid ownedMemberFeature { get; internal set; } + Guid Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedRendering; /// /// The name of the ownedMemberElement. @@ -353,7 +365,11 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).membershipOwningNamespace]; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -362,7 +378,18 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement]; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.DTO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenDto/ViewUsage.cs b/SysML2.NET/Core/AutoGenDto/ViewUsage.cs index fa69ab6a..ff520e53 100644 --- a/SysML2.NET/Core/AutoGenDto/ViewUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/ViewUsage.cs @@ -104,7 +104,7 @@ public partial class ViewUsage : IViewUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -403,7 +403,11 @@ public partial class ViewUsage : IViewUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1002,7 +1006,7 @@ public partial class ViewUsage : IViewUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1565471361757_649736_20796")] [RedefinedByProperty("IViewUsage.ViewDefinition")] [Implements(implementation: "IPartUsage.PartDefinition")] - public List partDefinition { get; internal set; } = []; + List Systems.Parts.IPartUsage.partDefinition => this.viewDefinition.HasValue ? [this.viewDefinition.Value] : []; /// /// The kind of temporal portion (time slice or snapshot) is represented by this OccurrenceUsage. If @@ -1062,7 +1066,7 @@ public partial class ViewUsage : IViewUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/ViewpointDefinition.cs b/SysML2.NET/Core/AutoGenDto/ViewpointDefinition.cs index bfa47b30..04947c75 100644 --- a/SysML2.NET/Core/AutoGenDto/ViewpointDefinition.cs +++ b/SysML2.NET/Core/AutoGenDto/ViewpointDefinition.cs @@ -88,7 +88,14 @@ public partial class ViewpointDefinition : IViewpointDefinition [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementDefinition.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -110,7 +117,7 @@ public partial class ViewpointDefinition : IViewpointDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenDto/ViewpointUsage.cs b/SysML2.NET/Core/AutoGenDto/ViewpointUsage.cs index 45e801de..83a98845 100644 --- a/SysML2.NET/Core/AutoGenDto/ViewpointUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/ViewpointUsage.cs @@ -80,7 +80,7 @@ public partial class ViewpointUsage : IViewpointUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.HasValue ? [((SysML2.NET.Core.DTO.Kernel.Functions.IExpression)this).function.Value] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -103,7 +103,7 @@ public partial class ViewpointUsage : IViewpointUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578025035149_386_969")] [RedefinedByProperty("IRequirementUsage.RequirementDefinition")] [Implements(implementation: "IConstraintUsage.ConstraintDefinition")] - public Guid? constraintDefinition { get; internal set; } + Guid? Systems.Constraints.IConstraintUsage.constraintDefinition => ((SysML2.NET.Core.DTO.Systems.Requirements.IRequirementUsage)this).requirementDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Requirements.IRequirementUsage)this).requirementDefinition.Value : Guid.Empty; /// /// The second chainingFeature of the crossedFeature of the ownedCrossSubsetting of this Feature, if it @@ -131,7 +131,14 @@ public partial class ViewpointUsage : IViewpointUsage [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementUsage.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The Classifiers that are the types of this Usage. Nominally, these are Definitions, but other kinds @@ -142,7 +149,7 @@ public partial class ViewpointUsage : IViewpointUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => this.occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -164,7 +171,7 @@ public partial class ViewpointUsage : IViewpointUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -268,7 +275,7 @@ public partial class ViewpointUsage : IViewpointUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public Guid? function { get; internal set; } + Guid? Kernel.Functions.IExpression.function => ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.HasValue ? ((SysML2.NET.Core.DTO.Kernel.Functions.IBooleanExpression)this).predicate.Value : Guid.Empty; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -459,7 +466,11 @@ public partial class ViewpointUsage : IViewpointUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1066,7 +1077,7 @@ public partial class ViewpointUsage : IViewpointUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public Guid? predicate { get; internal set; } + Guid? Kernel.Functions.IBooleanExpression.predicate => ((SysML2.NET.Core.DTO.Systems.Constraints.IConstraintUsage)this).constraintDefinition.HasValue ? ((SysML2.NET.Core.DTO.Systems.Constraints.IConstraintUsage)this).constraintDefinition.Value : Guid.Empty; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1107,7 +1118,7 @@ public partial class ViewpointUsage : IViewpointUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578067546711_751168_1745")] [RedefinedByProperty("IViewpointUsage.ViewpointDefinition")] [Implements(implementation: "IRequirementUsage.RequirementDefinition")] - public Guid? requirementDefinition { get; internal set; } + Guid? Systems.Requirements.IRequirementUsage.requirementDefinition => this.viewpointDefinition.HasValue ? this.viewpointDefinition.Value : Guid.Empty; /// /// An output parameter of the Expression whose value is the result of the Expression. The result of an @@ -1174,7 +1185,7 @@ public partial class ViewpointUsage : IViewpointUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenDto/WhileLoopActionUsage.cs b/SysML2.NET/Core/AutoGenDto/WhileLoopActionUsage.cs index 759c7a28..692575f7 100644 --- a/SysML2.NET/Core/AutoGenDto/WhileLoopActionUsage.cs +++ b/SysML2.NET/Core/AutoGenDto/WhileLoopActionUsage.cs @@ -75,7 +75,7 @@ public partial class WhileLoopActionUsage : IWhileLoopActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior { get; internal set; } = []; + List Kernel.Behaviors.IStep.behavior => this.actionDefinition; /// /// The ActionUsage to be performed repeatedly by the LoopActionUsage. It is the second parameter of the @@ -133,7 +133,7 @@ public partial class WhileLoopActionUsage : IWhileLoopActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition { get; internal set; } = []; + List Systems.DefinitionAndUsage.IUsage.definition => ((SysML2.NET.Core.DTO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -155,7 +155,7 @@ public partial class WhileLoopActionUsage : IWhileLoopActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature { get; internal set; } = []; + List Core.Types.IType.directedFeature => this.parameter; /// /// The usages of this Usage that are directedFeatures. @@ -424,7 +424,11 @@ public partial class WhileLoopActionUsage : IWhileLoopActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -711,7 +715,7 @@ public partial class WhileLoopActionUsage : IWhileLoopActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition { get; internal set; } = []; + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => this.actionDefinition; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1065,7 +1069,7 @@ public partial class WhileLoopActionUsage : IWhileLoopActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type { get; internal set; } = []; + List Core.Features.IFeature.type => ((SysML2.NET.Core.DTO.Systems.DefinitionAndUsage.IUsage)this).definition; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/AcceptActionUsage.cs b/SysML2.NET/Core/AutoGenPoco/AcceptActionUsage.cs index dd43bedc..d285bd9f 100644 --- a/SysML2.NET/Core/AutoGenPoco/AcceptActionUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/AcceptActionUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -105,7 +106,7 @@ public partial class AcceptActionUsage : IAcceptActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -155,7 +156,7 @@ public partial class AcceptActionUsage : IAcceptActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -177,7 +178,7 @@ public partial class AcceptActionUsage : IAcceptActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -446,7 +447,11 @@ public partial class AcceptActionUsage : IAcceptActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -733,7 +738,7 @@ public partial class AcceptActionUsage : IAcceptActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1112,7 +1117,7 @@ public partial class AcceptActionUsage : IAcceptActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/ActionDefinition.cs b/SysML2.NET/Core/AutoGenPoco/ActionDefinition.cs index 933400d4..dc38da8d 100644 --- a/SysML2.NET/Core/AutoGenPoco/ActionDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/ActionDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -127,7 +128,7 @@ public partial class ActionDefinition : IActionDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenPoco/ActionUsage.cs b/SysML2.NET/Core/AutoGenPoco/ActionUsage.cs index 41ee4f99..1c6e8a48 100644 --- a/SysML2.NET/Core/AutoGenPoco/ActionUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/ActionUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -103,7 +104,7 @@ public partial class ActionUsage : IActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -153,7 +154,7 @@ public partial class ActionUsage : IActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -175,7 +176,7 @@ public partial class ActionUsage : IActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -444,7 +445,11 @@ public partial class ActionUsage : IActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -731,7 +736,7 @@ public partial class ActionUsage : IActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1085,7 +1090,7 @@ public partial class ActionUsage : IActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/ActorMembership.cs b/SysML2.NET/Core/AutoGenPoco/ActorMembership.cs index b665aec4..1b081eb3 100644 --- a/SysML2.NET/Core/AutoGenPoco/ActorMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/ActorMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Requirements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Core.Features; @@ -128,7 +129,11 @@ public partial class ActorMembership : IActorMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -136,7 +141,7 @@ public partial class ActorMembership : IActorMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -144,7 +149,11 @@ public partial class ActorMembership : IActorMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -155,7 +164,7 @@ public partial class ActorMembership : IActorMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -163,7 +172,11 @@ public partial class ActorMembership : IActorMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -210,7 +223,7 @@ public partial class ActorMembership : IActorMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -228,7 +241,7 @@ public partial class ActorMembership : IActorMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IParameterMembership.OwnedMemberParameter")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => ((SysML2.NET.Core.POCO.Kernel.Behaviors.IParameterMembership)this).ownedMemberParameter; /// /// The name of the ownedMemberElement. @@ -245,7 +258,7 @@ public partial class ActorMembership : IActorMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674993_898044_43344")] [RedefinedByProperty("IActorMembership.OwnedActorParameter")] [Implements(implementation: "IParameterMembership.OwnedMemberParameter")] - public IFeature ownedMemberParameter => this.ComputeOwnedMemberParameter(); + IFeature Kernel.Behaviors.IParameterMembership.ownedMemberParameter => this.ownedActorParameter; /// /// The shortName of the ownedMemberElement. @@ -359,7 +372,11 @@ public partial class ActorMembership : IActorMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -368,7 +385,17 @@ public partial class ActorMembership : IActorMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/AllocationDefinition.cs b/SysML2.NET/Core/AutoGenPoco/AllocationDefinition.cs index 9245adb1..99001fcf 100644 --- a/SysML2.NET/Core/AutoGenPoco/AllocationDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/AllocationDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Allocations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -101,7 +102,7 @@ public partial class AllocationDefinition : IAllocationDefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1562476168385_824569_22106")] [RedefinedByProperty("IConnectionDefinition.ConnectionEnd")] [Implements(implementation: "IAssociation.AssociationEnd")] - public List associationEnd => this.ComputeAssociationEnd(); + List Kernel.Associations.IAssociation.associationEnd => [.. this.connectionEnd]; /// /// The Usages that define the things related by the ConnectionDefinition. @@ -182,7 +183,7 @@ public partial class AllocationDefinition : IAllocationDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. ((SysML2.NET.Core.POCO.Kernel.Associations.IAssociation)this).associationEnd]; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -314,7 +315,14 @@ public partial class AllocationDefinition : IAllocationDefinition [Property(xmiId: "_18_5_3_b9102da_1564072709069_937523_30797", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IConnectionDefinition.IsSufficient")] [Implements(implementation: "IType.IsSufficient")] - bool Core.Types.IType.IsSufficient { get; set; } + bool Core.Types.IType.IsSufficient + { + get => this.IsSufficient; + set + { + this.IsSufficient = value; + } + } /// /// Whether this Definition is for a variation point or not. If true, then all the memberships of the @@ -805,7 +813,7 @@ public partial class AllocationDefinition : IAllocationDefinition [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedType]; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -833,7 +841,11 @@ public partial class AllocationDefinition : IAllocationDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType != null ? [this.sourceType] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -851,7 +863,11 @@ public partial class AllocationDefinition : IAllocationDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetType]; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenPoco/AllocationUsage.cs b/SysML2.NET/Core/AutoGenPoco/AllocationUsage.cs index bf458dfe..3c93ec7e 100644 --- a/SysML2.NET/Core/AutoGenPoco/AllocationUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/AllocationUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Allocations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -100,7 +101,7 @@ public partial class AllocationUsage : IAllocationUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IConnectionUsage.ConnectionDefinition")] [Implements(implementation: "IConnector.Association")] - public List association => this.ComputeAssociation(); + List Kernel.Connectors.IConnector.association => [.. ((SysML2.NET.Core.POCO.Systems.Connections.IConnectionUsage)this).connectionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -124,7 +125,7 @@ public partial class AllocationUsage : IAllocationUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674983_471497_43284")] [RedefinedByProperty("IAllocationUsage.AllocationDefinition")] [Implements(implementation: "IConnectionUsage.ConnectionDefinition")] - public List connectionDefinition => this.ComputeConnectionDefinition(); + List Systems.Connections.IConnectionUsage.connectionDefinition => [.. this.allocationDefinition]; /// /// The endFeatures of a Connector, which redefine the endFeatures of the associations of the Connector. @@ -181,7 +182,7 @@ public partial class AllocationUsage : IAllocationUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -245,7 +246,7 @@ public partial class AllocationUsage : IAllocationUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -480,7 +481,11 @@ public partial class AllocationUsage : IAllocationUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1124,7 +1129,7 @@ public partial class AllocationUsage : IAllocationUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1152,7 +1157,11 @@ public partial class AllocationUsage : IAllocationUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1170,7 +1179,11 @@ public partial class AllocationUsage : IAllocationUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1200,7 +1213,7 @@ public partial class AllocationUsage : IAllocationUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/AnalysisCaseDefinition.cs b/SysML2.NET/Core/AutoGenPoco/AnalysisCaseDefinition.cs index 2f0e61ac..e2423c44 100644 --- a/SysML2.NET/Core/AutoGenPoco/AnalysisCaseDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/AnalysisCaseDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.AnalysisCases using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -145,7 +146,7 @@ public partial class AnalysisCaseDefinition : IAnalysisCaseDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenPoco/AnalysisCaseUsage.cs b/SysML2.NET/Core/AutoGenPoco/AnalysisCaseUsage.cs index 83e400ae..20c1817d 100644 --- a/SysML2.NET/Core/AutoGenPoco/AnalysisCaseUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/AnalysisCaseUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.AnalysisCases using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -86,7 +87,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition => this.ComputeActionDefinition(); + List Systems.Actions.IActionUsage.actionDefinition => ((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition != null ? [((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition] : []; /// /// The parameters of this CaseUsage that represent actors involved in the case. @@ -119,7 +120,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Function that is the type of this CalculationUsage. Nominally, this would be a @@ -131,7 +132,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1565500905804_589845_30779")] [RedefinedByProperty("ICaseUsage.CaseDefinition")] [Implements(implementation: "ICalculationUsage.CalculationDefinition")] - public IFunction calculationDefinition => this.ComputeCalculationDefinition(); + IFunction Systems.Calculations.ICalculationUsage.calculationDefinition => ((SysML2.NET.Core.POCO.Systems.Cases.ICaseUsage)this).caseDefinition; /// /// The CaseDefinition that is the type of this CaseUsage. @@ -140,7 +141,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1588213526305_899324_302")] [RedefinedByProperty("IAnalysisCaseUsage.AnalysisCaseDefinition")] [Implements(implementation: "ICaseUsage.CaseDefinition")] - public ICaseDefinition caseDefinition => this.ComputeCaseDefinition(); + ICaseDefinition Systems.Cases.ICaseUsage.caseDefinition => this.analysisCaseDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -190,7 +191,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -212,7 +213,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -307,7 +308,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => ((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -498,7 +499,11 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -793,7 +798,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. ((SysML2.NET.Core.POCO.Systems.Actions.IActionUsage)this).actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1176,7 +1181,7 @@ public partial class AnalysisCaseUsage : IAnalysisCaseUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/AnnotatingElement.cs b/SysML2.NET/Core/AutoGenPoco/AnnotatingElement.cs index 817b69ea..d08787b1 100644 --- a/SysML2.NET/Core/AutoGenPoco/AnnotatingElement.cs +++ b/SysML2.NET/Core/AutoGenPoco/AnnotatingElement.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Annotations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Elements; using SysML2.NET.Core.POCO.Root.Namespaces; diff --git a/SysML2.NET/Core/AutoGenPoco/Annotation.cs b/SysML2.NET/Core/AutoGenPoco/Annotation.cs index ee9f1322..f9e5b028 100644 --- a/SysML2.NET/Core/AutoGenPoco/Annotation.cs +++ b/SysML2.NET/Core/AutoGenPoco/Annotation.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Annotations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Elements; using SysML2.NET.Core.POCO.Root.Namespaces; @@ -281,7 +282,11 @@ public partial class Annotation : IAnnotation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAnnotation.AnnotatingElement")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.annotatingElement != null ? [this.annotatingElement] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -290,7 +295,17 @@ public partial class Annotation : IAnnotation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAnnotation.AnnotatedElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.AnnotatedElement != null ? [this.AnnotatedElement] : []; + set + { + if (value.Count != 0) + { + this.AnnotatedElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/AssertConstraintUsage.cs b/SysML2.NET/Core/AutoGenPoco/AssertConstraintUsage.cs index c8803c87..a0b081b3 100644 --- a/SysML2.NET/Core/AutoGenPoco/AssertConstraintUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/AssertConstraintUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Constraints using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -101,7 +102,7 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -161,7 +162,7 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -183,7 +184,7 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -278,7 +279,7 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => ((SysML2.NET.Core.POCO.Kernel.Functions.IBooleanExpression)this).predicate; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -476,7 +477,11 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1083,7 +1088,7 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public IPredicate predicate => this.ComputePredicate(); + IPredicate Kernel.Functions.IBooleanExpression.predicate => this.constraintDefinition; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1136,7 +1141,7 @@ public partial class AssertConstraintUsage : IAssertConstraintUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/AssignmentActionUsage.cs b/SysML2.NET/Core/AutoGenPoco/AssignmentActionUsage.cs index 5e6b7409..9ab249d0 100644 --- a/SysML2.NET/Core/AutoGenPoco/AssignmentActionUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/AssignmentActionUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -104,7 +105,7 @@ public partial class AssignmentActionUsage : IAssignmentActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -154,7 +155,7 @@ public partial class AssignmentActionUsage : IAssignmentActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -176,7 +177,7 @@ public partial class AssignmentActionUsage : IAssignmentActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -445,7 +446,11 @@ public partial class AssignmentActionUsage : IAssignmentActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -732,7 +737,7 @@ public partial class AssignmentActionUsage : IAssignmentActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1103,7 +1108,7 @@ public partial class AssignmentActionUsage : IAssignmentActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Association.cs b/SysML2.NET/Core/AutoGenPoco/Association.cs index 89a236cf..b571d899 100644 --- a/SysML2.NET/Core/AutoGenPoco/Association.cs +++ b/SysML2.NET/Core/AutoGenPoco/Association.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Associations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -131,7 +132,7 @@ public partial class Association : IAssociation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.associationEnd]; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -511,7 +512,7 @@ public partial class Association : IAssociation [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedType]; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -539,7 +540,11 @@ public partial class Association : IAssociation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType != null ? [this.sourceType] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -557,7 +562,11 @@ public partial class Association : IAssociation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetType]; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenPoco/AssociationStructure.cs b/SysML2.NET/Core/AutoGenPoco/AssociationStructure.cs index 21fb977d..aa9e11cc 100644 --- a/SysML2.NET/Core/AutoGenPoco/AssociationStructure.cs +++ b/SysML2.NET/Core/AutoGenPoco/AssociationStructure.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Associations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -133,7 +134,7 @@ public partial class AssociationStructure : IAssociationStructure [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.associationEnd]; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -513,7 +514,7 @@ public partial class AssociationStructure : IAssociationStructure [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedType]; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -541,7 +542,11 @@ public partial class AssociationStructure : IAssociationStructure [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType != null ? [this.sourceType] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -559,7 +564,11 @@ public partial class AssociationStructure : IAssociationStructure [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetType]; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenPoco/AttributeDefinition.cs b/SysML2.NET/Core/AutoGenPoco/AttributeDefinition.cs index 237ab779..6dcc1bf8 100644 --- a/SysML2.NET/Core/AutoGenPoco/AttributeDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/AttributeDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Attributes using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/AttributeUsage.cs b/SysML2.NET/Core/AutoGenPoco/AttributeUsage.cs index 9c8a9408..8251d562 100644 --- a/SysML2.NET/Core/AutoGenPoco/AttributeUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/AttributeUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Attributes using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Classifiers; @@ -143,7 +144,7 @@ public partial class AttributeUsage : IAttributeUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IAttributeUsage.AttributeDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.attributeDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -398,7 +399,7 @@ public partial class AttributeUsage : IAttributeUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IAttributeUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool Systems.DefinitionAndUsage.IUsage.isReference => throw new InvalidOperationException("Redefined by property IAttributeUsage.IsReference"); + bool Systems.DefinitionAndUsage.IUsage.isReference => this.isReference; /// /// Whether all things that meet the classification conditions of this Type must be classified by the @@ -426,7 +427,11 @@ public partial class AttributeUsage : IAttributeUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1038,7 +1043,7 @@ public partial class AttributeUsage : IAttributeUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Behavior.cs b/SysML2.NET/Core/AutoGenPoco/Behavior.cs index 504e1571..016a2754 100644 --- a/SysML2.NET/Core/AutoGenPoco/Behavior.cs +++ b/SysML2.NET/Core/AutoGenPoco/Behavior.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Behaviors using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -96,7 +97,7 @@ public partial class Behavior : IBehavior [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The Documentation owned by this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/BindingConnector.cs b/SysML2.NET/Core/AutoGenPoco/BindingConnector.cs index e98f40f8..54c9199c 100644 --- a/SysML2.NET/Core/AutoGenPoco/BindingConnector.cs +++ b/SysML2.NET/Core/AutoGenPoco/BindingConnector.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Connectors using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -178,7 +179,7 @@ public partial class BindingConnector : IBindingConnector [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -739,7 +740,7 @@ public partial class BindingConnector : IBindingConnector [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -767,7 +768,11 @@ public partial class BindingConnector : IBindingConnector [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -785,7 +790,11 @@ public partial class BindingConnector : IBindingConnector [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -815,7 +824,7 @@ public partial class BindingConnector : IBindingConnector [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. this.association]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/BindingConnectorAsUsage.cs b/SysML2.NET/Core/AutoGenPoco/BindingConnectorAsUsage.cs index 4314adb1..06f3a26a 100644 --- a/SysML2.NET/Core/AutoGenPoco/BindingConnectorAsUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/BindingConnectorAsUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Connections using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Classifiers; @@ -219,7 +220,7 @@ public partial class BindingConnectorAsUsage : IBindingConnectorAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -438,7 +439,11 @@ public partial class BindingConnectorAsUsage : IBindingConnectorAsUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1045,7 +1050,7 @@ public partial class BindingConnectorAsUsage : IBindingConnectorAsUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1073,7 +1078,11 @@ public partial class BindingConnectorAsUsage : IBindingConnectorAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1091,7 +1100,11 @@ public partial class BindingConnectorAsUsage : IBindingConnectorAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1121,7 +1134,7 @@ public partial class BindingConnectorAsUsage : IBindingConnectorAsUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. this.association]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/BooleanExpression.cs b/SysML2.NET/Core/AutoGenPoco/BooleanExpression.cs index 24bf8514..3468ceff 100644 --- a/SysML2.NET/Core/AutoGenPoco/BooleanExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/BooleanExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Functions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -66,7 +67,7 @@ public partial class BooleanExpression : IBooleanExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -127,7 +128,7 @@ public partial class BooleanExpression : IBooleanExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -213,7 +214,7 @@ public partial class BooleanExpression : IBooleanExpression [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction IExpression.function => this.predicate; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. diff --git a/SysML2.NET/Core/AutoGenPoco/CalculationDefinition.cs b/SysML2.NET/Core/AutoGenPoco/CalculationDefinition.cs index fbad648d..e174f6ed 100644 --- a/SysML2.NET/Core/AutoGenPoco/CalculationDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/CalculationDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Calculations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -137,7 +138,7 @@ public partial class CalculationDefinition : ICalculationDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenPoco/CalculationUsage.cs b/SysML2.NET/Core/AutoGenPoco/CalculationUsage.cs index 07c55066..346c38f4 100644 --- a/SysML2.NET/Core/AutoGenPoco/CalculationUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/CalculationUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Calculations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -89,7 +90,7 @@ public partial class CalculationUsage : ICalculationUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition => this.ComputeActionDefinition(); + List Systems.Actions.IActionUsage.actionDefinition => this.calculationDefinition != null ? [this.calculationDefinition] : []; /// /// Various alternative identifiers for this Element. Generally, these will be set by tools. @@ -105,7 +106,7 @@ public partial class CalculationUsage : ICalculationUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Function that is the type of this CalculationUsage. Nominally, this would be a @@ -166,7 +167,7 @@ public partial class CalculationUsage : ICalculationUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -188,7 +189,7 @@ public partial class CalculationUsage : ICalculationUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -283,7 +284,7 @@ public partial class CalculationUsage : ICalculationUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => this.calculationDefinition; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -474,7 +475,11 @@ public partial class CalculationUsage : ICalculationUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -761,7 +766,7 @@ public partial class CalculationUsage : ICalculationUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. ((SysML2.NET.Core.POCO.Systems.Actions.IActionUsage)this).actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1126,7 +1131,7 @@ public partial class CalculationUsage : ICalculationUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/CaseDefinition.cs b/SysML2.NET/Core/AutoGenPoco/CaseDefinition.cs index 9e6286b5..a3526e6e 100644 --- a/SysML2.NET/Core/AutoGenPoco/CaseDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/CaseDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Cases using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -147,7 +148,7 @@ public partial class CaseDefinition : ICaseDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenPoco/CaseUsage.cs b/SysML2.NET/Core/AutoGenPoco/CaseUsage.cs index 302229b9..4cce4686 100644 --- a/SysML2.NET/Core/AutoGenPoco/CaseUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/CaseUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Cases using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -86,7 +87,7 @@ public partial class CaseUsage : ICaseUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition => this.ComputeActionDefinition(); + List Systems.Actions.IActionUsage.actionDefinition => ((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition != null ? [((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition] : []; /// /// The parameters of this CaseUsage that represent actors involved in the case. @@ -111,7 +112,7 @@ public partial class CaseUsage : ICaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Function that is the type of this CalculationUsage. Nominally, this would be a @@ -123,7 +124,7 @@ public partial class CaseUsage : ICaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1565500905804_589845_30779")] [RedefinedByProperty("ICaseUsage.CaseDefinition")] [Implements(implementation: "ICalculationUsage.CalculationDefinition")] - public IFunction calculationDefinition => this.ComputeCalculationDefinition(); + IFunction Systems.Calculations.ICalculationUsage.calculationDefinition => this.caseDefinition; /// /// The CaseDefinition that is the type of this CaseUsage. @@ -181,7 +182,7 @@ public partial class CaseUsage : ICaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -203,7 +204,7 @@ public partial class CaseUsage : ICaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -298,7 +299,7 @@ public partial class CaseUsage : ICaseUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => ((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -489,7 +490,11 @@ public partial class CaseUsage : ICaseUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -784,7 +789,7 @@ public partial class CaseUsage : ICaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. ((SysML2.NET.Core.POCO.Systems.Actions.IActionUsage)this).actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1158,7 +1163,7 @@ public partial class CaseUsage : ICaseUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Class.cs b/SysML2.NET/Core/AutoGenPoco/Class.cs index 8d2ca956..cea9c753 100644 --- a/SysML2.NET/Core/AutoGenPoco/Class.cs +++ b/SysML2.NET/Core/AutoGenPoco/Class.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Classes using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/Classifier.cs b/SysML2.NET/Core/AutoGenPoco/Classifier.cs index bec9e7cc..120553f1 100644 --- a/SysML2.NET/Core/AutoGenPoco/Classifier.cs +++ b/SysML2.NET/Core/AutoGenPoco/Classifier.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Classifiers using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Features; using SysML2.NET.Core.POCO.Core.Types; diff --git a/SysML2.NET/Core/AutoGenPoco/CollectExpression.cs b/SysML2.NET/Core/AutoGenPoco/CollectExpression.cs index 75cd6abf..7f22095f 100644 --- a/SysML2.NET/Core/AutoGenPoco/CollectExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/CollectExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -77,7 +78,7 @@ public partial class CollectExpression : ICollectExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -138,7 +139,7 @@ public partial class CollectExpression : ICollectExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -450,7 +451,14 @@ public partial class CollectExpression : ICollectExpression [Property(xmiId: "_18_5_3_12e503d9_1557528808100_646606_111674", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("ICollectExpression.Operator")] [Implements(implementation: "IOperatorExpression.Operator")] - string IOperatorExpression.Operator { get; set; } + string IOperatorExpression.Operator + { + get => this.Operator; + set + { + this.Operator = value; + } + } /// /// All features related to this Type by FeatureMemberships that have direction out or inout. diff --git a/SysML2.NET/Core/AutoGenPoco/Comment.cs b/SysML2.NET/Core/AutoGenPoco/Comment.cs index c5e4722b..6349da29 100644 --- a/SysML2.NET/Core/AutoGenPoco/Comment.cs +++ b/SysML2.NET/Core/AutoGenPoco/Comment.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Annotations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Elements; using SysML2.NET.Core.POCO.Root.Namespaces; diff --git a/SysML2.NET/Core/AutoGenPoco/ConcernDefinition.cs b/SysML2.NET/Core/AutoGenPoco/ConcernDefinition.cs index 178bd236..374ef274 100644 --- a/SysML2.NET/Core/AutoGenPoco/ConcernDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/ConcernDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Requirements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -117,7 +118,14 @@ public partial class ConcernDefinition : IConcernDefinition [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementDefinition.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -139,7 +147,7 @@ public partial class ConcernDefinition : IConcernDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenPoco/ConcernUsage.cs b/SysML2.NET/Core/AutoGenPoco/ConcernUsage.cs index c98b8f78..d9c2e512 100644 --- a/SysML2.NET/Core/AutoGenPoco/ConcernUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/ConcernUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Requirements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -112,7 +113,7 @@ public partial class ConcernUsage : IConcernUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -143,7 +144,7 @@ public partial class ConcernUsage : IConcernUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578025035149_386_969")] [RedefinedByProperty("IRequirementUsage.RequirementDefinition")] [Implements(implementation: "IConstraintUsage.ConstraintDefinition")] - public IPredicate constraintDefinition => this.ComputeConstraintDefinition(); + IPredicate Systems.Constraints.IConstraintUsage.constraintDefinition => ((SysML2.NET.Core.POCO.Systems.Requirements.IRequirementUsage)this).requirementDefinition; /// /// The second chainingFeature of the crossedFeature of the ownedCrossSubsetting of this Feature, if it @@ -171,7 +172,14 @@ public partial class ConcernUsage : IConcernUsage [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementUsage.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The Classifiers that are the types of this Usage. Nominally, these are Definitions, but other kinds @@ -182,7 +190,7 @@ public partial class ConcernUsage : IConcernUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -204,7 +212,7 @@ public partial class ConcernUsage : IConcernUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -308,7 +316,7 @@ public partial class ConcernUsage : IConcernUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => ((SysML2.NET.Core.POCO.Kernel.Functions.IBooleanExpression)this).predicate; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -499,7 +507,11 @@ public partial class ConcernUsage : IConcernUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1106,7 +1118,7 @@ public partial class ConcernUsage : IConcernUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public IPredicate predicate => this.ComputePredicate(); + IPredicate Kernel.Functions.IBooleanExpression.predicate => ((SysML2.NET.Core.POCO.Systems.Constraints.IConstraintUsage)this).constraintDefinition; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1147,7 +1159,7 @@ public partial class ConcernUsage : IConcernUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578067546711_751168_1745")] [RedefinedByProperty("IConcernUsage.ConcernDefinition")] [Implements(implementation: "IRequirementUsage.RequirementDefinition")] - public IRequirementDefinition requirementDefinition => this.ComputeRequirementDefinition(); + IRequirementDefinition IRequirementUsage.requirementDefinition => this.concernDefinition; /// /// An output parameter of the Expression whose value is the result of the Expression. The result of an @@ -1214,7 +1226,7 @@ public partial class ConcernUsage : IConcernUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/ConjugatedPortDefinition.cs b/SysML2.NET/Core/AutoGenPoco/ConjugatedPortDefinition.cs index ab373190..4b5918ca 100644 --- a/SysML2.NET/Core/AutoGenPoco/ConjugatedPortDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/ConjugatedPortDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Ports using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -414,7 +415,7 @@ public partial class ConjugatedPortDefinition : IConjugatedPortDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1543092026091_217766_16748")] [RedefinedByProperty("IConjugatedPortDefinition.OwnedPortConjugator")] [Implements(implementation: "IType.OwnedConjugator")] - public IConjugation ownedConjugator => this.ComputeOwnedConjugator(); + IConjugation Core.Types.IType.ownedConjugator => this.ownedPortConjugator; /// /// The ConnectorAsUsages that are ownedUsages of this Definition. Note that this list includes @@ -743,7 +744,7 @@ public partial class ConjugatedPortDefinition : IConjugatedPortDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674980_717955_43271")] [RedefinedByProperty("IConjugatedPortDefinition.OriginalPortDefinition")] [Implements(implementation: "IElement.OwningNamespace")] - public INamespace owningNamespace => this.ComputeOwningNamespace(); + INamespace Root.Elements.IElement.owningNamespace => this.originalPortDefinition; /// /// The Relationship for which this Element is an ownedRelatedElement, if any. diff --git a/SysML2.NET/Core/AutoGenPoco/ConjugatedPortTyping.cs b/SysML2.NET/Core/AutoGenPoco/ConjugatedPortTyping.cs index 84d925ae..1e42d153 100644 --- a/SysML2.NET/Core/AutoGenPoco/ConjugatedPortTyping.cs +++ b/SysML2.NET/Core/AutoGenPoco/ConjugatedPortTyping.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Ports using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Features; using SysML2.NET.Core.POCO.Core.Types; @@ -108,7 +109,14 @@ public partial class ConjugatedPortTyping : IConjugatedPortTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IFeatureTyping.Type")] [Implements(implementation: "ISpecialization.General")] - public IType General { get; set; } + IType Core.Types.ISpecialization.General + { + get => ((SysML2.NET.Core.POCO.Core.Features.IFeatureTyping)this).Type; + set + { + ((SysML2.NET.Core.POCO.Core.Features.IFeatureTyping)this).Type = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -239,7 +247,7 @@ public partial class ConjugatedPortTyping : IConjugatedPortTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("IFeatureTyping.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public IType owningType => this.ComputeOwningType(); + IType Core.Types.ISpecialization.owningType => this.owningFeature; /// /// The originalPortDefinition of the conjugatedPortDefinition of this ConjugatedPortTyping. @@ -285,7 +293,17 @@ public partial class ConjugatedPortTyping : IConjugatedPortTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific = firstValue; + } + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -294,7 +312,17 @@ public partial class ConjugatedPortTyping : IConjugatedPortTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureTyping.TypedFeature")] [Implements(implementation: "ISpecialization.Specific")] - public IType Specific { get; set; } + IType Core.Types.ISpecialization.Specific + { + get => this.TypedFeature; + set + { + if (value is IFeature castedValue) + { + this.TypedFeature = castedValue; + } + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -303,7 +331,17 @@ public partial class ConjugatedPortTyping : IConjugatedPortTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. @@ -321,7 +359,17 @@ public partial class ConjugatedPortTyping : IConjugatedPortTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674980_563969_43273")] [RedefinedByProperty("IConjugatedPortTyping.ConjugatedPortDefinition")] [Implements(implementation: "IFeatureTyping.Type")] - public IType Type { get; set; } + IType Core.Features.IFeatureTyping.Type + { + get => this.ConjugatedPortDefinition; + set + { + if (value is IConjugatedPortDefinition castedValue) + { + this.ConjugatedPortDefinition = castedValue; + } + } + } /// /// The Feature that has a type determined by this FeatureTyping. diff --git a/SysML2.NET/Core/AutoGenPoco/Conjugation.cs b/SysML2.NET/Core/AutoGenPoco/Conjugation.cs index 9453174b..5e6c2176 100644 --- a/SysML2.NET/Core/AutoGenPoco/Conjugation.cs +++ b/SysML2.NET/Core/AutoGenPoco/Conjugation.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Types using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Elements; @@ -269,7 +270,17 @@ public partial class Conjugation : IConjugation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConjugation.ConjugatedType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.ConjugatedType != null ? [this.ConjugatedType] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.ConjugatedType = firstValue; + } + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -278,7 +289,17 @@ public partial class Conjugation : IConjugation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConjugation.OriginalType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.OriginalType != null ? [this.OriginalType] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.OriginalType = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/ConnectionDefinition.cs b/SysML2.NET/Core/AutoGenPoco/ConnectionDefinition.cs index 4dfda296..e5aa838d 100644 --- a/SysML2.NET/Core/AutoGenPoco/ConnectionDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/ConnectionDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Connections using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -89,7 +90,7 @@ public partial class ConnectionDefinition : IConnectionDefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1562476168385_824569_22106")] [RedefinedByProperty("IConnectionDefinition.ConnectionEnd")] [Implements(implementation: "IAssociation.AssociationEnd")] - public List associationEnd => this.ComputeAssociationEnd(); + List Kernel.Associations.IAssociation.associationEnd => [.. this.connectionEnd]; /// /// The Usages that define the things related by the ConnectionDefinition. @@ -170,7 +171,7 @@ public partial class ConnectionDefinition : IConnectionDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. ((SysML2.NET.Core.POCO.Kernel.Associations.IAssociation)this).associationEnd]; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -302,7 +303,14 @@ public partial class ConnectionDefinition : IConnectionDefinition [Property(xmiId: "_18_5_3_b9102da_1564072709069_937523_30797", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IConnectionDefinition.IsSufficient")] [Implements(implementation: "IType.IsSufficient")] - bool Core.Types.IType.IsSufficient { get; set; } + bool Core.Types.IType.IsSufficient + { + get => this.IsSufficient; + set + { + this.IsSufficient = value; + } + } /// /// Whether this Definition is for a variation point or not. If true, then all the memberships of the @@ -793,7 +801,7 @@ public partial class ConnectionDefinition : IConnectionDefinition [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedType]; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -821,7 +829,11 @@ public partial class ConnectionDefinition : IConnectionDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType != null ? [this.sourceType] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -839,7 +851,11 @@ public partial class ConnectionDefinition : IConnectionDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetType]; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenPoco/ConnectionUsage.cs b/SysML2.NET/Core/AutoGenPoco/ConnectionUsage.cs index 1dc88a31..21c66052 100644 --- a/SysML2.NET/Core/AutoGenPoco/ConnectionUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/ConnectionUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Connections using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -94,7 +95,7 @@ public partial class ConnectionUsage : IConnectionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IConnectionUsage.ConnectionDefinition")] [Implements(implementation: "IConnector.Association")] - public List association => this.ComputeAssociation(); + List Kernel.Connectors.IConnector.association => [.. this.connectionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -174,7 +175,7 @@ public partial class ConnectionUsage : IConnectionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -238,7 +239,7 @@ public partial class ConnectionUsage : IConnectionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -473,7 +474,11 @@ public partial class ConnectionUsage : IConnectionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1117,7 +1122,7 @@ public partial class ConnectionUsage : IConnectionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1145,7 +1150,11 @@ public partial class ConnectionUsage : IConnectionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1163,7 +1172,11 @@ public partial class ConnectionUsage : IConnectionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1193,7 +1206,7 @@ public partial class ConnectionUsage : IConnectionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Connector.cs b/SysML2.NET/Core/AutoGenPoco/Connector.cs index 56ef5b88..52395cf4 100644 --- a/SysML2.NET/Core/AutoGenPoco/Connector.cs +++ b/SysML2.NET/Core/AutoGenPoco/Connector.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Connectors using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -180,7 +181,7 @@ public partial class Connector : IConnector [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -741,7 +742,7 @@ public partial class Connector : IConnector [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -769,7 +770,11 @@ public partial class Connector : IConnector [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -787,7 +792,11 @@ public partial class Connector : IConnector [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -817,7 +826,7 @@ public partial class Connector : IConnector [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. this.association]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/ConnectorAsUsage.cs b/SysML2.NET/Core/AutoGenPoco/ConnectorAsUsage.cs index 8c543095..ccf0f2bc 100644 --- a/SysML2.NET/Core/AutoGenPoco/ConnectorAsUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/ConnectorAsUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Connections using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Classifiers; @@ -221,7 +222,7 @@ public partial class ConnectorAsUsage : IConnectorAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -440,7 +441,11 @@ public partial class ConnectorAsUsage : IConnectorAsUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1047,7 +1052,7 @@ public partial class ConnectorAsUsage : IConnectorAsUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1075,7 +1080,11 @@ public partial class ConnectorAsUsage : IConnectorAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1093,7 +1102,11 @@ public partial class ConnectorAsUsage : IConnectorAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1123,7 +1136,7 @@ public partial class ConnectorAsUsage : IConnectorAsUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. this.definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/ConstraintDefinition.cs b/SysML2.NET/Core/AutoGenPoco/ConstraintDefinition.cs index 73646cb2..6330d922 100644 --- a/SysML2.NET/Core/AutoGenPoco/ConstraintDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/ConstraintDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Constraints using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -118,7 +119,7 @@ public partial class ConstraintDefinition : IConstraintDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenPoco/ConstraintUsage.cs b/SysML2.NET/Core/AutoGenPoco/ConstraintUsage.cs index 21e08c98..fde3ba6d 100644 --- a/SysML2.NET/Core/AutoGenPoco/ConstraintUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/ConstraintUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Constraints using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -93,7 +94,7 @@ public partial class ConstraintUsage : IConstraintUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -153,7 +154,7 @@ public partial class ConstraintUsage : IConstraintUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -175,7 +176,7 @@ public partial class ConstraintUsage : IConstraintUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -270,7 +271,7 @@ public partial class ConstraintUsage : IConstraintUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => ((SysML2.NET.Core.POCO.Kernel.Functions.IBooleanExpression)this).predicate; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -461,7 +462,11 @@ public partial class ConstraintUsage : IConstraintUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1068,7 +1073,7 @@ public partial class ConstraintUsage : IConstraintUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public IPredicate predicate => this.ComputePredicate(); + IPredicate Kernel.Functions.IBooleanExpression.predicate => this.constraintDefinition; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1121,7 +1126,7 @@ public partial class ConstraintUsage : IConstraintUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/ConstructorExpression.cs b/SysML2.NET/Core/AutoGenPoco/ConstructorExpression.cs index cd759f10..473da2ee 100644 --- a/SysML2.NET/Core/AutoGenPoco/ConstructorExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/ConstructorExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -78,7 +79,7 @@ public partial class ConstructorExpression : IConstructorExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -139,7 +140,7 @@ public partial class ConstructorExpression : IConstructorExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/ControlNode.cs b/SysML2.NET/Core/AutoGenPoco/ControlNode.cs index ac4bdfa0..4d967784 100644 --- a/SysML2.NET/Core/AutoGenPoco/ControlNode.cs +++ b/SysML2.NET/Core/AutoGenPoco/ControlNode.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -102,7 +103,7 @@ public partial class ControlNode : IControlNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -152,7 +153,7 @@ public partial class ControlNode : IControlNode [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -174,7 +175,7 @@ public partial class ControlNode : IControlNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -443,7 +444,11 @@ public partial class ControlNode : IControlNode [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -730,7 +735,7 @@ public partial class ControlNode : IControlNode [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1084,7 +1089,7 @@ public partial class ControlNode : IControlNode [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/CrossSubsetting.cs b/SysML2.NET/Core/AutoGenPoco/CrossSubsetting.cs index 8cd53bb2..63584f21 100644 --- a/SysML2.NET/Core/AutoGenPoco/CrossSubsetting.cs +++ b/SysML2.NET/Core/AutoGenPoco/CrossSubsetting.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Types; using SysML2.NET.Core.POCO.Root.Annotations; @@ -126,7 +127,17 @@ public partial class CrossSubsetting : ICrossSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubsetting.SubsettedFeature")] [Implements(implementation: "ISpecialization.General")] - public IType General { get; set; } + IType Core.Types.ISpecialization.General + { + get => ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettedFeature; + set + { + if (value is IFeature castedValue) + { + ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettedFeature = castedValue; + } + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -214,7 +225,7 @@ public partial class CrossSubsetting : ICrossSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_573157_43226")] [RedefinedByProperty("ICrossSubsetting.CrossingFeature")] [Implements(implementation: "ISubsetting.OwningFeature")] - public IFeature owningFeature => this.ComputeOwningFeature(); + IFeature ISubsetting.owningFeature => this.crossingFeature; /// /// The owningRelationship of this Element, if that Relationship is a Membership. @@ -258,7 +269,7 @@ public partial class CrossSubsetting : ICrossSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubsetting.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public IType owningType => this.ComputeOwningType(); + IType Core.Types.ISpecialization.owningType => ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).owningFeature; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -297,7 +308,17 @@ public partial class CrossSubsetting : ICrossSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific = firstValue; + } + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -306,7 +327,17 @@ public partial class CrossSubsetting : ICrossSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubsetting.SubsettingFeature")] [Implements(implementation: "ISpecialization.Specific")] - public IType Specific { get; set; } + IType Core.Types.ISpecialization.Specific + { + get => ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettingFeature; + set + { + if (value is IFeature castedValue) + { + ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettingFeature = castedValue; + } + } + } /// /// The Feature that is subsetted by the subsettingFeature of this Subsetting. @@ -315,7 +346,14 @@ public partial class CrossSubsetting : ICrossSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674980_563969_43273")] [RedefinedByProperty("ICrossSubsetting.CrossedFeature")] [Implements(implementation: "ISubsetting.SubsettedFeature")] - public IFeature SubsettedFeature { get; set; } + IFeature ISubsetting.SubsettedFeature + { + get => this.CrossedFeature; + set + { + this.CrossedFeature = value; + } + } /// /// The Feature that is a subset of the subsettedFeature of this Subsetting. @@ -324,7 +362,11 @@ public partial class CrossSubsetting : ICrossSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ICrossSubsetting.CrossingFeature")] [Implements(implementation: "ISubsetting.SubsettingFeature")] - public IFeature SubsettingFeature { get; set; } + IFeature ISubsetting.SubsettingFeature + { + get => this.crossingFeature; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -333,7 +375,17 @@ public partial class CrossSubsetting : ICrossSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/DataType.cs b/SysML2.NET/Core/AutoGenPoco/DataType.cs index 60451784..c1085589 100644 --- a/SysML2.NET/Core/AutoGenPoco/DataType.cs +++ b/SysML2.NET/Core/AutoGenPoco/DataType.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.DataTypes using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/DecisionNode.cs b/SysML2.NET/Core/AutoGenPoco/DecisionNode.cs index c7086398..385a26bf 100644 --- a/SysML2.NET/Core/AutoGenPoco/DecisionNode.cs +++ b/SysML2.NET/Core/AutoGenPoco/DecisionNode.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -100,7 +101,7 @@ public partial class DecisionNode : IDecisionNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -150,7 +151,7 @@ public partial class DecisionNode : IDecisionNode [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -172,7 +173,7 @@ public partial class DecisionNode : IDecisionNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -441,7 +442,11 @@ public partial class DecisionNode : IDecisionNode [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -728,7 +733,7 @@ public partial class DecisionNode : IDecisionNode [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1082,7 +1087,7 @@ public partial class DecisionNode : IDecisionNode [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Definition.cs b/SysML2.NET/Core/AutoGenPoco/Definition.cs index 0c019193..380836cb 100644 --- a/SysML2.NET/Core/AutoGenPoco/Definition.cs +++ b/SysML2.NET/Core/AutoGenPoco/Definition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.DefinitionAndUsage using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/Dependency.cs b/SysML2.NET/Core/AutoGenPoco/Dependency.cs index 62f20b6c..6bd8c27b 100644 --- a/SysML2.NET/Core/AutoGenPoco/Dependency.cs +++ b/SysML2.NET/Core/AutoGenPoco/Dependency.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Dependencies using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Elements; @@ -248,7 +249,14 @@ public partial class Dependency : IDependency [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDependency.Client")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => [.. this.Client]; + set + { + this.Client = value; + } + } /// /// The Element or Elements on which the client Elements depend in some respect. @@ -265,7 +273,14 @@ public partial class Dependency : IDependency [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDependency.Supplier")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.Supplier]; + set + { + this.Supplier = value; + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/Differencing.cs b/SysML2.NET/Core/AutoGenPoco/Differencing.cs index 86de35d1..4d560dd4 100644 --- a/SysML2.NET/Core/AutoGenPoco/Differencing.cs +++ b/SysML2.NET/Core/AutoGenPoco/Differencing.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Types using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Elements; @@ -247,7 +248,11 @@ public partial class Differencing : IDifferencing [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDifferencing.TypeDifferenced")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.typeDifferenced != null ? [this.typeDifferenced] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -256,7 +261,17 @@ public partial class Differencing : IDifferencing [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDifferencing.DifferencingType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.DifferencingType != null ? [this.DifferencingType] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.DifferencingType = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/Disjoining.cs b/SysML2.NET/Core/AutoGenPoco/Disjoining.cs index 61aa173a..8491af50 100644 --- a/SysML2.NET/Core/AutoGenPoco/Disjoining.cs +++ b/SysML2.NET/Core/AutoGenPoco/Disjoining.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Types using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Elements; @@ -257,7 +258,17 @@ public partial class Disjoining : IDisjoining [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDisjoining.TypeDisjoined")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.TypeDisjoined != null ? [this.TypeDisjoined] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.TypeDisjoined = firstValue; + } + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -266,7 +277,17 @@ public partial class Disjoining : IDisjoining [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IDisjoining.DisjoiningType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.DisjoiningType != null ? [this.DisjoiningType] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.DisjoiningType = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/Documentation.cs b/SysML2.NET/Core/AutoGenPoco/Documentation.cs index 7d83ea57..19b70f6a 100644 --- a/SysML2.NET/Core/AutoGenPoco/Documentation.cs +++ b/SysML2.NET/Core/AutoGenPoco/Documentation.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Annotations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Elements; using SysML2.NET.Core.POCO.Root.Namespaces; @@ -61,7 +62,7 @@ public partial class Documentation : IDocumentation [Property(xmiId: "_19_0_2_12e503d9_1594145755058_99428_86", aggregation: AggregationKind.None, lowerValue: 1, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IDocumentation.DocumentedElement")] [Implements(implementation: "IAnnotatingElement.AnnotatedElement")] - public List annotatedElement => this.ComputeAnnotatedElement(); + List IAnnotatingElement.annotatedElement => this.documentedElement != null ? [this.documentedElement] : []; /// /// The Annotations that relate this AnnotatingElement to its annotatedElements. This includes the diff --git a/SysML2.NET/Core/AutoGenPoco/Element.cs b/SysML2.NET/Core/AutoGenPoco/Element.cs index bf3fb98f..57bd2368 100644 --- a/SysML2.NET/Core/AutoGenPoco/Element.cs +++ b/SysML2.NET/Core/AutoGenPoco/Element.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Elements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Namespaces; diff --git a/SysML2.NET/Core/AutoGenPoco/ElementFilterMembership.cs b/SysML2.NET/Core/AutoGenPoco/ElementFilterMembership.cs index c5c7aacb..ebb3d492 100644 --- a/SysML2.NET/Core/AutoGenPoco/ElementFilterMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/ElementFilterMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Packages using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Kernel.Functions; @@ -135,7 +136,11 @@ public partial class ElementFilterMembership : IElementFilterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -143,7 +148,7 @@ public partial class ElementFilterMembership : IElementFilterMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -151,7 +156,11 @@ public partial class ElementFilterMembership : IElementFilterMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -169,7 +178,11 @@ public partial class ElementFilterMembership : IElementFilterMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -208,7 +221,7 @@ public partial class ElementFilterMembership : IElementFilterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IElementFilterMembership.Condition")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => this.condition; /// /// The elementId of the ownedMemberElement. @@ -329,7 +342,11 @@ public partial class ElementFilterMembership : IElementFilterMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.membershipOwningNamespace != null ? [this.membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -338,7 +355,17 @@ public partial class ElementFilterMembership : IElementFilterMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/EndFeatureMembership.cs b/SysML2.NET/Core/AutoGenPoco/EndFeatureMembership.cs index c49910ff..d0c167cb 100644 --- a/SysML2.NET/Core/AutoGenPoco/EndFeatureMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/EndFeatureMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Core.Types; @@ -124,7 +125,11 @@ public partial class EndFeatureMembership : IEndFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -132,7 +137,7 @@ public partial class EndFeatureMembership : IEndFeatureMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -140,7 +145,11 @@ public partial class EndFeatureMembership : IEndFeatureMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -151,7 +160,7 @@ public partial class EndFeatureMembership : IEndFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -159,7 +168,11 @@ public partial class EndFeatureMembership : IEndFeatureMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -198,7 +211,7 @@ public partial class EndFeatureMembership : IEndFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -223,7 +236,7 @@ public partial class EndFeatureMembership : IEndFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IEndFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - IFeature Core.Types.IFeatureMembership.ownedMemberFeature => throw new InvalidOperationException("Redefined by property IEndFeatureMembership.OwnedMemberFeature"); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedMemberFeature; /// /// The name of the ownedMemberElement. @@ -345,7 +358,11 @@ public partial class EndFeatureMembership : IEndFeatureMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -354,7 +371,17 @@ public partial class EndFeatureMembership : IEndFeatureMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/EnumerationDefinition.cs b/SysML2.NET/Core/AutoGenPoco/EnumerationDefinition.cs index 665b7841..30d19d2f 100644 --- a/SysML2.NET/Core/AutoGenPoco/EnumerationDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/EnumerationDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Enumerations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -285,7 +286,14 @@ public partial class EnumerationDefinition : IEnumerationDefinition [Property(xmiId: "_19_0_2_12e503d9_1590978283180_265362_419", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IEnumerationDefinition.IsVariation")] [Implements(implementation: "IDefinition.IsVariation")] - bool Systems.DefinitionAndUsage.IDefinition.IsVariation { get; set; } + bool Systems.DefinitionAndUsage.IDefinition.IsVariation + { + get => this.IsVariation; + set + { + this.IsVariation = value; + } + } /// /// The set of all member Elements of this Namespace, which are the memberElements of all memberships of @@ -791,7 +799,7 @@ public partial class EnumerationDefinition : IEnumerationDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674979_259543_43268")] [RedefinedByProperty("IEnumerationDefinition.EnumeratedValue")] [Implements(implementation: "IDefinition.Variant")] - public List variant => this.ComputeVariant(); + List Systems.DefinitionAndUsage.IDefinition.variant => [.. this.enumeratedValue]; /// /// The ownedMemberships of this Definition that are VariantMemberships. If isVariation = true, then diff --git a/SysML2.NET/Core/AutoGenPoco/EnumerationUsage.cs b/SysML2.NET/Core/AutoGenPoco/EnumerationUsage.cs index 1019e256..fcb8a213 100644 --- a/SysML2.NET/Core/AutoGenPoco/EnumerationUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/EnumerationUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Enumerations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Classifiers; @@ -89,7 +90,7 @@ public partial class EnumerationUsage : IEnumerationUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IEnumerationUsage.EnumerationDefinition")] [Implements(implementation: "IAttributeUsage.AttributeDefinition")] - public List attributeDefinition => this.ComputeAttributeDefinition(); + List Systems.Attributes.IAttributeUsage.attributeDefinition => this.enumerationDefinition != null ? [this.enumerationDefinition] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -139,7 +140,7 @@ public partial class EnumerationUsage : IEnumerationUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IAttributeUsage.AttributeDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Attributes.IAttributeUsage)this).attributeDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -402,7 +403,7 @@ public partial class EnumerationUsage : IEnumerationUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IAttributeUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool Systems.DefinitionAndUsage.IUsage.isReference => throw new InvalidOperationException("Redefined by property IAttributeUsage.IsReference"); + bool Systems.DefinitionAndUsage.IUsage.isReference => this.isReference; /// /// Whether all things that meet the classification conditions of this Type must be classified by the @@ -430,7 +431,11 @@ public partial class EnumerationUsage : IEnumerationUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1042,7 +1047,7 @@ public partial class EnumerationUsage : IEnumerationUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/EventOccurrenceUsage.cs b/SysML2.NET/Core/AutoGenPoco/EventOccurrenceUsage.cs index a16a765f..5332f945 100644 --- a/SysML2.NET/Core/AutoGenPoco/EventOccurrenceUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/EventOccurrenceUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Occurrences using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -134,7 +135,7 @@ public partial class EventOccurrenceUsage : IEventOccurrenceUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -414,7 +415,7 @@ public partial class EventOccurrenceUsage : IEventOccurrenceUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IEventOccurrenceUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool Systems.DefinitionAndUsage.IUsage.isReference => throw new InvalidOperationException("Redefined by property IEventOccurrenceUsage.IsReference"); + bool Systems.DefinitionAndUsage.IUsage.isReference => this.isReference; /// /// Whether all things that meet the classification conditions of this Type must be classified by the @@ -442,7 +443,11 @@ public partial class EventOccurrenceUsage : IEventOccurrenceUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1073,7 +1078,7 @@ public partial class EventOccurrenceUsage : IEventOccurrenceUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/ExhibitStateUsage.cs b/SysML2.NET/Core/AutoGenPoco/ExhibitStateUsage.cs index e0a09774..7c7e11bb 100644 --- a/SysML2.NET/Core/AutoGenPoco/ExhibitStateUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/ExhibitStateUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.States using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -88,7 +89,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("IStateUsage.StateDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition => this.ComputeActionDefinition(); + List Systems.Actions.IActionUsage.actionDefinition => [.. this.stateDefinition]; /// /// Various alternative identifiers for this Element. Generally, these will be set by tools. @@ -104,7 +105,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. ((SysML2.NET.Core.POCO.Systems.Actions.IActionUsage)this).actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -154,7 +155,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -176,7 +177,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -256,7 +257,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [Property(xmiId: "_19_0_4_12e503d9_1622831790393_676695_195", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IPerformActionUsage.PerformedAction")] [Implements(implementation: "IEventOccurrenceUsage.EventOccurrence")] - public IOccurrenceUsage eventOccurrence => this.ComputeEventOccurrence(); + IOccurrenceUsage Systems.Occurrences.IEventOccurrenceUsage.eventOccurrence => ((SysML2.NET.Core.POCO.Systems.Actions.IPerformActionUsage)this).performedAction; /// /// The StateUsage to be exhibited by the ExhibitStateUsage. It is the performedAction of the @@ -473,7 +474,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IEventOccurrenceUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool Systems.DefinitionAndUsage.IUsage.isReference => throw new InvalidOperationException("Redefined by property IEventOccurrenceUsage.IsReference"); + bool Systems.DefinitionAndUsage.IUsage.isReference => this.isReference; /// /// Always true for an EventOccurrenceUsage. @@ -509,7 +510,11 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -796,7 +801,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. ((SysML2.NET.Core.POCO.Systems.Actions.IActionUsage)this).actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1109,7 +1114,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1622831790393_676695_195")] [RedefinedByProperty("IExhibitStateUsage.ExhibitedState")] [Implements(implementation: "IPerformActionUsage.PerformedAction")] - public IActionUsage performedAction => this.ComputePerformedAction(); + IActionUsage Systems.Actions.IPerformActionUsage.performedAction => this.exhibitedState; /// /// The kind of temporal portion (time slice or snapshot) is represented by this OccurrenceUsage. If @@ -1169,7 +1174,7 @@ public partial class ExhibitStateUsage : IExhibitStateUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Expose.cs b/SysML2.NET/Core/AutoGenPoco/Expose.cs index d2c3169d..d3f8226b 100644 --- a/SysML2.NET/Core/AutoGenPoco/Expose.cs +++ b/SysML2.NET/Core/AutoGenPoco/Expose.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Views using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Root.Annotations; @@ -141,7 +142,14 @@ public partial class Expose : IExpose [Property(xmiId: "_19_0_4_12e503d9_1622577942205_869984_64", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IExpose.IsImportAll")] [Implements(implementation: "IImport.IsImportAll")] - bool Root.Namespaces.IImport.IsImportAll { get; set; } + bool Root.Namespaces.IImport.IsImportAll + { + get => this.IsImportAll; + set + { + this.IsImportAll = value; + } + } /// /// Whether this Element is contained in the ownership tree of a library model. @@ -280,7 +288,11 @@ public partial class Expose : IExpose [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IImport.ImportOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.importOwningNamespace != null ? [this.importOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -314,7 +326,14 @@ public partial class Expose : IExpose [Property(xmiId: "_18_5_3_12e503d9_1533160674976_798509_43257", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "private")] [RedefinedByProperty("IExpose.Visibility")] [Implements(implementation: "IImport.Visibility")] - VisibilityKind Root.Namespaces.IImport.Visibility { get; set; } = VisibilityKind.Private; + VisibilityKind Root.Namespaces.IImport.Visibility + { + get => this.Visibility; + set + { + this.Visibility = value; + } + } } } diff --git a/SysML2.NET/Core/AutoGenPoco/Expression.cs b/SysML2.NET/Core/AutoGenPoco/Expression.cs index cf07a2b8..26c82e1e 100644 --- a/SysML2.NET/Core/AutoGenPoco/Expression.cs +++ b/SysML2.NET/Core/AutoGenPoco/Expression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Functions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -69,7 +70,7 @@ public partial class Expression : IExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -130,7 +131,7 @@ public partial class Expression : IExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/Feature.cs b/SysML2.NET/Core/AutoGenPoco/Feature.cs index 21af5f79..7f07de1f 100644 --- a/SysML2.NET/Core/AutoGenPoco/Feature.cs +++ b/SysML2.NET/Core/AutoGenPoco/Feature.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Types; diff --git a/SysML2.NET/Core/AutoGenPoco/FeatureChainExpression.cs b/SysML2.NET/Core/AutoGenPoco/FeatureChainExpression.cs index 79590d70..68f585ba 100644 --- a/SysML2.NET/Core/AutoGenPoco/FeatureChainExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/FeatureChainExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -78,7 +79,7 @@ public partial class FeatureChainExpression : IFeatureChainExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -139,7 +140,7 @@ public partial class FeatureChainExpression : IFeatureChainExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -451,7 +452,14 @@ public partial class FeatureChainExpression : IFeatureChainExpression [Property(xmiId: "_18_5_3_12e503d9_1557528808100_646606_111674", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IFeatureChainExpression.Operator")] [Implements(implementation: "IOperatorExpression.Operator")] - string IOperatorExpression.Operator { get; set; } + string IOperatorExpression.Operator + { + get => this.Operator; + set + { + this.Operator = value; + } + } /// /// All features related to this Type by FeatureMemberships that have direction out or inout. diff --git a/SysML2.NET/Core/AutoGenPoco/FeatureChaining.cs b/SysML2.NET/Core/AutoGenPoco/FeatureChaining.cs index 51724df4..b2481179 100644 --- a/SysML2.NET/Core/AutoGenPoco/FeatureChaining.cs +++ b/SysML2.NET/Core/AutoGenPoco/FeatureChaining.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Elements; @@ -257,7 +258,11 @@ public partial class FeatureChaining : IFeatureChaining [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IFeatureChaining.FeatureChained")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.featureChained != null ? [this.featureChained] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -266,7 +271,17 @@ public partial class FeatureChaining : IFeatureChaining [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IFeatureChaining.ChainingFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.ChainingFeature != null ? [this.ChainingFeature] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.ChainingFeature = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/FeatureInverting.cs b/SysML2.NET/Core/AutoGenPoco/FeatureInverting.cs index c2a48b82..122b3ff4 100644 --- a/SysML2.NET/Core/AutoGenPoco/FeatureInverting.cs +++ b/SysML2.NET/Core/AutoGenPoco/FeatureInverting.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Elements; @@ -266,7 +267,17 @@ public partial class FeatureInverting : IFeatureInverting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IFeatureInverting.FeatureInverted")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.FeatureInverted != null ? [this.FeatureInverted] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.FeatureInverted = firstValue; + } + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -275,7 +286,17 @@ public partial class FeatureInverting : IFeatureInverting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IFeatureInverting.InvertingFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.InvertingFeature != null ? [this.InvertingFeature] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.InvertingFeature = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/FeatureMembership.cs b/SysML2.NET/Core/AutoGenPoco/FeatureMembership.cs index 2317d07f..f2e71263 100644 --- a/SysML2.NET/Core/AutoGenPoco/FeatureMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/FeatureMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Types using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Core.Features; @@ -127,7 +128,11 @@ public partial class FeatureMembership : IFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -135,7 +140,7 @@ public partial class FeatureMembership : IFeatureMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -143,7 +148,11 @@ public partial class FeatureMembership : IFeatureMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -154,7 +163,7 @@ public partial class FeatureMembership : IFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -162,7 +171,11 @@ public partial class FeatureMembership : IFeatureMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -201,7 +214,7 @@ public partial class FeatureMembership : IFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => this.ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -340,7 +353,11 @@ public partial class FeatureMembership : IFeatureMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -349,7 +366,17 @@ public partial class FeatureMembership : IFeatureMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/FeatureReferenceExpression.cs b/SysML2.NET/Core/AutoGenPoco/FeatureReferenceExpression.cs index e72319a8..69da3735 100644 --- a/SysML2.NET/Core/AutoGenPoco/FeatureReferenceExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/FeatureReferenceExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -66,7 +67,7 @@ public partial class FeatureReferenceExpression : IFeatureReferenceExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -127,7 +128,7 @@ public partial class FeatureReferenceExpression : IFeatureReferenceExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/FeatureTyping.cs b/SysML2.NET/Core/AutoGenPoco/FeatureTyping.cs index 5bbe1305..abdeecb5 100644 --- a/SysML2.NET/Core/AutoGenPoco/FeatureTyping.cs +++ b/SysML2.NET/Core/AutoGenPoco/FeatureTyping.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Types; using SysML2.NET.Core.POCO.Root.Annotations; @@ -99,7 +100,14 @@ public partial class FeatureTyping : IFeatureTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IFeatureTyping.Type")] [Implements(implementation: "ISpecialization.General")] - public IType General { get; set; } + IType Core.Types.ISpecialization.General + { + get => this.Type; + set + { + this.Type = value; + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -230,7 +238,7 @@ public partial class FeatureTyping : IFeatureTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("IFeatureTyping.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public IType owningType => this.ComputeOwningType(); + IType Core.Types.ISpecialization.owningType => this.owningFeature; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -269,7 +277,17 @@ public partial class FeatureTyping : IFeatureTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific = firstValue; + } + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -278,7 +296,17 @@ public partial class FeatureTyping : IFeatureTyping [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureTyping.TypedFeature")] [Implements(implementation: "ISpecialization.Specific")] - public IType Specific { get; set; } + IType Core.Types.ISpecialization.Specific + { + get => this.TypedFeature; + set + { + if (value is IFeature castedValue) + { + this.TypedFeature = castedValue; + } + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -287,7 +315,17 @@ public partial class FeatureTyping : IFeatureTyping [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/FeatureValue.cs b/SysML2.NET/Core/AutoGenPoco/FeatureValue.cs index 4d7ebbba..551ea794 100644 --- a/SysML2.NET/Core/AutoGenPoco/FeatureValue.cs +++ b/SysML2.NET/Core/AutoGenPoco/FeatureValue.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.FeatureValues using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Core.Features; @@ -156,7 +157,11 @@ public partial class FeatureValue : IFeatureValue [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -164,7 +169,7 @@ public partial class FeatureValue : IFeatureValue [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -172,7 +177,11 @@ public partial class FeatureValue : IFeatureValue [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -190,7 +199,11 @@ public partial class FeatureValue : IFeatureValue [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -229,7 +242,7 @@ public partial class FeatureValue : IFeatureValue [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureValue.Value")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => this.value; /// /// The elementId of the ownedMemberElement. @@ -350,7 +363,11 @@ public partial class FeatureValue : IFeatureValue [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.membershipOwningNamespace != null ? [this.membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -359,7 +376,17 @@ public partial class FeatureValue : IFeatureValue [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/Flow.cs b/SysML2.NET/Core/AutoGenPoco/Flow.cs index 80a56b08..e1463d10 100644 --- a/SysML2.NET/Core/AutoGenPoco/Flow.cs +++ b/SysML2.NET/Core/AutoGenPoco/Flow.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Interactions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Classifiers; @@ -69,7 +70,7 @@ public partial class Flow : IFlow [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IConnector.Association")] - public List association => this.ComputeAssociation(); + List Kernel.Connectors.IConnector.association => [.. this.interaction]; /// /// The Behaviors that type this Step. @@ -78,7 +79,7 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.interaction]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -158,7 +159,7 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -192,7 +193,7 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -795,7 +796,7 @@ public partial class Flow : IFlow [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -823,7 +824,11 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -849,7 +854,11 @@ public partial class Flow : IFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -887,7 +896,7 @@ public partial class Flow : IFlow [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Kernel.Connectors.IConnector)this).association]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/FlowDefinition.cs b/SysML2.NET/Core/AutoGenPoco/FlowDefinition.cs index 8ad6df49..72ee0e55 100644 --- a/SysML2.NET/Core/AutoGenPoco/FlowDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/FlowDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Flows using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -101,7 +102,7 @@ public partial class FlowDefinition : IFlowDefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1562476168385_824569_22106")] [RedefinedByProperty("IFlowDefinition.FlowEnd")] [Implements(implementation: "IAssociation.AssociationEnd")] - public List associationEnd => this.ComputeAssociationEnd(); + List Kernel.Associations.IAssociation.associationEnd => [.. this.flowEnd]; /// /// The declared name of this Element. @@ -140,7 +141,7 @@ public partial class FlowDefinition : IFlowDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Definition that are directedFeatures. @@ -175,7 +176,7 @@ public partial class FlowDefinition : IFlowDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. ((SysML2.NET.Core.POCO.Kernel.Associations.IAssociation)this).associationEnd]; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -806,7 +807,7 @@ public partial class FlowDefinition : IFlowDefinition [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedType]; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -834,7 +835,11 @@ public partial class FlowDefinition : IFlowDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType != null ? [this.sourceType] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -860,7 +865,11 @@ public partial class FlowDefinition : IFlowDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetType]; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenPoco/FlowEnd.cs b/SysML2.NET/Core/AutoGenPoco/FlowEnd.cs index f3446113..d0099b78 100644 --- a/SysML2.NET/Core/AutoGenPoco/FlowEnd.cs +++ b/SysML2.NET/Core/AutoGenPoco/FlowEnd.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Interactions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/FlowUsage.cs b/SysML2.NET/Core/AutoGenPoco/FlowUsage.cs index 3bd4543a..85c2a845 100644 --- a/SysML2.NET/Core/AutoGenPoco/FlowUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/FlowUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Flows using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -88,7 +89,7 @@ public partial class FlowUsage : IFlowUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("IFlowUsage.FlowDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition => this.ComputeActionDefinition(); + List Systems.Actions.IActionUsage.actionDefinition => [.. this.flowDefinition]; /// /// Various alternative identifiers for this Element. Generally, these will be set by tools. @@ -104,7 +105,7 @@ public partial class FlowUsage : IFlowUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IConnector.Association")] - public List association => this.ComputeAssociation(); + List Kernel.Connectors.IConnector.association => [.. ((SysML2.NET.Core.POCO.Kernel.Interactions.IFlow)this).interaction]; /// /// The Behaviors that type this Step. @@ -113,7 +114,7 @@ public partial class FlowUsage : IFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. ((SysML2.NET.Core.POCO.Kernel.Interactions.IFlow)this).interaction]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -182,7 +183,7 @@ public partial class FlowUsage : IFlowUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -204,7 +205,7 @@ public partial class FlowUsage : IFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -247,7 +248,7 @@ public partial class FlowUsage : IFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -362,7 +363,7 @@ public partial class FlowUsage : IFlowUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IFlowUsage.FlowDefinition")] [Implements(implementation: "IFlow.Interaction")] - public List interaction => this.ComputeInteraction(); + List Kernel.Interactions.IFlow.interaction => [.. this.flowDefinition]; /// /// The interpretations of a Type with intersectingTypes are asserted to be those in common among the @@ -512,7 +513,11 @@ public partial class FlowUsage : IFlowUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -799,7 +804,7 @@ public partial class FlowUsage : IFlowUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. ((SysML2.NET.Core.POCO.Systems.Actions.IActionUsage)this).actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1163,7 +1168,7 @@ public partial class FlowUsage : IFlowUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1191,7 +1196,11 @@ public partial class FlowUsage : IFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1217,7 +1226,11 @@ public partial class FlowUsage : IFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1255,7 +1268,7 @@ public partial class FlowUsage : IFlowUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/ForLoopActionUsage.cs b/SysML2.NET/Core/AutoGenPoco/ForLoopActionUsage.cs index e8d90729..3d8370f1 100644 --- a/SysML2.NET/Core/AutoGenPoco/ForLoopActionUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/ForLoopActionUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -103,7 +104,7 @@ public partial class ForLoopActionUsage : IForLoopActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The ActionUsage to be performed repeatedly by the LoopActionUsage. It is the second parameter of the @@ -161,7 +162,7 @@ public partial class ForLoopActionUsage : IForLoopActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -183,7 +184,7 @@ public partial class ForLoopActionUsage : IForLoopActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -452,7 +453,11 @@ public partial class ForLoopActionUsage : IForLoopActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -748,7 +753,7 @@ public partial class ForLoopActionUsage : IForLoopActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1111,7 +1116,7 @@ public partial class ForLoopActionUsage : IForLoopActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/ForkNode.cs b/SysML2.NET/Core/AutoGenPoco/ForkNode.cs index 87c92e29..15e34c8e 100644 --- a/SysML2.NET/Core/AutoGenPoco/ForkNode.cs +++ b/SysML2.NET/Core/AutoGenPoco/ForkNode.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -101,7 +102,7 @@ public partial class ForkNode : IForkNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -151,7 +152,7 @@ public partial class ForkNode : IForkNode [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -173,7 +174,7 @@ public partial class ForkNode : IForkNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -442,7 +443,11 @@ public partial class ForkNode : IForkNode [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -729,7 +734,7 @@ public partial class ForkNode : IForkNode [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1083,7 +1088,7 @@ public partial class ForkNode : IForkNode [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/FramedConcernMembership.cs b/SysML2.NET/Core/AutoGenPoco/FramedConcernMembership.cs index 51144276..7e5cf264 100644 --- a/SysML2.NET/Core/AutoGenPoco/FramedConcernMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/FramedConcernMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Requirements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.Systems.Requirements; @@ -134,7 +135,14 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_2_12e503d9_1584048161309_821854_390", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IFramedConcernMembership.Kind")] [Implements(implementation: "IRequirementConstraintMembership.Kind")] - RequirementConstraintKind IRequirementConstraintMembership.Kind { get; set; } + RequirementConstraintKind IRequirementConstraintMembership.Kind + { + get => this.Kind; + set + { + this.Kind = value; + } + } /// /// The Element that becomes a member of the membershipOwningNamespace due to this Membership. @@ -143,7 +151,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -151,7 +163,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -159,7 +171,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -170,7 +186,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -178,7 +194,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -215,7 +235,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674993_898044_43344")] [RedefinedByProperty("IFramedConcernMembership.OwnedConcern")] [Implements(implementation: "IRequirementConstraintMembership.OwnedConstraint")] - public IConstraintUsage ownedConstraint => this.ComputeOwnedConstraint(); + IConstraintUsage IRequirementConstraintMembership.ownedConstraint => this.ownedConcern; /// /// The Elements owned by this Element, derived as the ownedRelatedElements of the ownedRelationships of @@ -234,7 +254,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -252,7 +272,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IRequirementConstraintMembership.OwnedConstraint")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => ((SysML2.NET.Core.POCO.Systems.Requirements.IRequirementConstraintMembership)this).ownedConstraint; /// /// The name of the ownedMemberElement. @@ -367,7 +387,7 @@ public partial class FramedConcernMembership : IFramedConcernMembership [Property(xmiId: "_19_0_4_12e503d9_1617118807597_77864_3544", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IFramedConcernMembership.ReferencedConcern")] [Implements(implementation: "IRequirementConstraintMembership.ReferencedConstraint")] - public IConstraintUsage referencedConstraint => this.ComputeReferencedConstraint(); + IConstraintUsage IRequirementConstraintMembership.referencedConstraint => this.referencedConcern; /// /// The Elements that are related by this Relationship, derived as the union of the source and target @@ -394,7 +414,11 @@ public partial class FramedConcernMembership : IFramedConcernMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -403,7 +427,17 @@ public partial class FramedConcernMembership : IFramedConcernMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/Function.cs b/SysML2.NET/Core/AutoGenPoco/Function.cs index 026ab6d0..877cb420 100644 --- a/SysML2.NET/Core/AutoGenPoco/Function.cs +++ b/SysML2.NET/Core/AutoGenPoco/Function.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Functions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -97,7 +98,7 @@ public partial class Function : IFunction [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The Documentation owned by this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/IfActionUsage.cs b/SysML2.NET/Core/AutoGenPoco/IfActionUsage.cs index 1a11fcdd..0e134b8a 100644 --- a/SysML2.NET/Core/AutoGenPoco/IfActionUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/IfActionUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -103,7 +104,7 @@ public partial class IfActionUsage : IIfActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -153,7 +154,7 @@ public partial class IfActionUsage : IIfActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -175,7 +176,7 @@ public partial class IfActionUsage : IIfActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -460,7 +461,11 @@ public partial class IfActionUsage : IIfActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -747,7 +752,7 @@ public partial class IfActionUsage : IIfActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1109,7 +1114,7 @@ public partial class IfActionUsage : IIfActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Import.cs b/SysML2.NET/Core/AutoGenPoco/Import.cs index 79b26826..f1fe2e6c 100644 --- a/SysML2.NET/Core/AutoGenPoco/Import.cs +++ b/SysML2.NET/Core/AutoGenPoco/Import.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Namespaces using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Root.Annotations; @@ -275,7 +276,11 @@ public partial class Import : IImport [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IImport.ImportOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.importOwningNamespace != null ? [this.importOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. diff --git a/SysML2.NET/Core/AutoGenPoco/IncludeUseCaseUsage.cs b/SysML2.NET/Core/AutoGenPoco/IncludeUseCaseUsage.cs index 8aaf3806..7c912bfc 100644 --- a/SysML2.NET/Core/AutoGenPoco/IncludeUseCaseUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/IncludeUseCaseUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.UseCases using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -89,7 +90,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition => this.ComputeActionDefinition(); + List Systems.Actions.IActionUsage.actionDefinition => ((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition != null ? [((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition] : []; /// /// The parameters of this CaseUsage that represent actors involved in the case. @@ -114,7 +115,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Function that is the type of this CalculationUsage. Nominally, this would be a @@ -126,7 +127,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1565500905804_589845_30779")] [RedefinedByProperty("ICaseUsage.CaseDefinition")] [Implements(implementation: "ICalculationUsage.CalculationDefinition")] - public IFunction calculationDefinition => this.ComputeCalculationDefinition(); + IFunction Systems.Calculations.ICalculationUsage.calculationDefinition => ((SysML2.NET.Core.POCO.Systems.Cases.ICaseUsage)this).caseDefinition; /// /// The CaseDefinition that is the type of this CaseUsage. @@ -135,7 +136,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1588213526305_899324_302")] [RedefinedByProperty("IUseCaseUsage.UseCaseDefinition")] [Implements(implementation: "ICaseUsage.CaseDefinition")] - public ICaseDefinition caseDefinition => this.ComputeCaseDefinition(); + ICaseDefinition Systems.Cases.ICaseUsage.caseDefinition => this.useCaseDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -185,7 +186,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -207,7 +208,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -269,7 +270,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [Property(xmiId: "_19_0_4_12e503d9_1622831790393_676695_195", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IPerformActionUsage.PerformedAction")] [Implements(implementation: "IEventOccurrenceUsage.EventOccurrence")] - public IOccurrenceUsage eventOccurrence => this.ComputeEventOccurrence(); + IOccurrenceUsage Systems.Occurrences.IEventOccurrenceUsage.eventOccurrence => ((SysML2.NET.Core.POCO.Systems.Actions.IPerformActionUsage)this).performedAction; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -312,7 +313,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => ((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -484,7 +485,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IEventOccurrenceUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool Systems.DefinitionAndUsage.IUsage.isReference => throw new InvalidOperationException("Redefined by property IEventOccurrenceUsage.IsReference"); + bool Systems.DefinitionAndUsage.IUsage.isReference => this.isReference; /// /// Always true for an EventOccurrenceUsage. @@ -520,7 +521,11 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -815,7 +820,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. ((SysML2.NET.Core.POCO.Systems.Actions.IActionUsage)this).actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1128,7 +1133,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1622831790393_676695_195")] [RedefinedByProperty("IIncludeUseCaseUsage.UseCaseIncluded")] [Implements(implementation: "IPerformActionUsage.PerformedAction")] - public IActionUsage performedAction => this.ComputePerformedAction(); + IActionUsage Systems.Actions.IPerformActionUsage.performedAction => this.useCaseIncluded; /// /// The kind of temporal portion (time slice or snapshot) is represented by this OccurrenceUsage. If @@ -1199,7 +1204,7 @@ public partial class IncludeUseCaseUsage : IIncludeUseCaseUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/IndexExpression.cs b/SysML2.NET/Core/AutoGenPoco/IndexExpression.cs index 435f0e09..689c4bae 100644 --- a/SysML2.NET/Core/AutoGenPoco/IndexExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/IndexExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -77,7 +78,7 @@ public partial class IndexExpression : IIndexExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -138,7 +139,7 @@ public partial class IndexExpression : IIndexExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -450,7 +451,14 @@ public partial class IndexExpression : IIndexExpression [Property(xmiId: "_18_5_3_12e503d9_1557528808100_646606_111674", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IIndexExpression.Operator")] [Implements(implementation: "IOperatorExpression.Operator")] - string IOperatorExpression.Operator { get; set; } + string IOperatorExpression.Operator + { + get => this.Operator; + set + { + this.Operator = value; + } + } /// /// All features related to this Type by FeatureMemberships that have direction out or inout. diff --git a/SysML2.NET/Core/AutoGenPoco/InstantiationExpression.cs b/SysML2.NET/Core/AutoGenPoco/InstantiationExpression.cs index 9f6717e9..c3c1351a 100644 --- a/SysML2.NET/Core/AutoGenPoco/InstantiationExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/InstantiationExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -78,7 +79,7 @@ public partial class InstantiationExpression : IInstantiationExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -139,7 +140,7 @@ public partial class InstantiationExpression : IInstantiationExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/Interaction.cs b/SysML2.NET/Core/AutoGenPoco/Interaction.cs index 1dc20022..41283290 100644 --- a/SysML2.NET/Core/AutoGenPoco/Interaction.cs +++ b/SysML2.NET/Core/AutoGenPoco/Interaction.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Interactions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -107,7 +108,7 @@ public partial class Interaction : IInteraction [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The Documentation owned by this Element. @@ -133,7 +134,7 @@ public partial class Interaction : IInteraction [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.associationEnd]; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -522,7 +523,7 @@ public partial class Interaction : IInteraction [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedType]; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -550,7 +551,11 @@ public partial class Interaction : IInteraction [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType != null ? [this.sourceType] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -576,7 +581,11 @@ public partial class Interaction : IInteraction [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetType]; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenPoco/InterfaceDefinition.cs b/SysML2.NET/Core/AutoGenPoco/InterfaceDefinition.cs index 49c5bd5d..690b8052 100644 --- a/SysML2.NET/Core/AutoGenPoco/InterfaceDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/InterfaceDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Interfaces using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -89,7 +90,7 @@ public partial class InterfaceDefinition : IInterfaceDefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1562476168385_824569_22106")] [RedefinedByProperty("IConnectionDefinition.ConnectionEnd")] [Implements(implementation: "IAssociation.AssociationEnd")] - public List associationEnd => this.ComputeAssociationEnd(); + List Kernel.Associations.IAssociation.associationEnd => [.. ((SysML2.NET.Core.POCO.Systems.Connections.IConnectionDefinition)this).connectionEnd]; /// /// The Usages that define the things related by the ConnectionDefinition. @@ -98,7 +99,7 @@ public partial class InterfaceDefinition : IInterfaceDefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1562477648742_24204_22901")] [RedefinedByProperty("IInterfaceDefinition.InterfaceEnd")] [Implements(implementation: "IConnectionDefinition.ConnectionEnd")] - public List connectionEnd => this.ComputeConnectionEnd(); + List Systems.Connections.IConnectionDefinition.connectionEnd => [.. this.interfaceEnd]; /// /// The declared name of this Element. @@ -171,7 +172,7 @@ public partial class InterfaceDefinition : IInterfaceDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IAssociation.AssociationEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. ((SysML2.NET.Core.POCO.Kernel.Associations.IAssociation)this).associationEnd]; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -311,7 +312,14 @@ public partial class InterfaceDefinition : IInterfaceDefinition [Property(xmiId: "_18_5_3_b9102da_1564072709069_937523_30797", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IConnectionDefinition.IsSufficient")] [Implements(implementation: "IType.IsSufficient")] - bool Core.Types.IType.IsSufficient { get; set; } + bool Core.Types.IType.IsSufficient + { + get => this.IsSufficient; + set + { + this.IsSufficient = value; + } + } /// /// Whether this Definition is for a variation point or not. If true, then all the memberships of the @@ -802,7 +810,7 @@ public partial class InterfaceDefinition : IInterfaceDefinition [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IAssociation.RelatedType")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedType]; /// /// The types of the associationEnds of the Association, which are the relatedElements of the @@ -830,7 +838,11 @@ public partial class InterfaceDefinition : IInterfaceDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.SourceType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceType != null ? [this.sourceType] : []; + set { } + } /// /// The source relatedType for this Association. It is the first relatedType of the Association. @@ -848,7 +860,11 @@ public partial class InterfaceDefinition : IInterfaceDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IAssociation.TargetType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetType]; + set { } + } /// /// The target relatedTypes for this Association. This includes all the relatedTypes other than the diff --git a/SysML2.NET/Core/AutoGenPoco/InterfaceUsage.cs b/SysML2.NET/Core/AutoGenPoco/InterfaceUsage.cs index 1e3f1115..4d8f23a5 100644 --- a/SysML2.NET/Core/AutoGenPoco/InterfaceUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/InterfaceUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Interfaces using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -92,7 +93,7 @@ public partial class InterfaceUsage : IInterfaceUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IConnectionUsage.ConnectionDefinition")] [Implements(implementation: "IConnector.Association")] - public List association => this.ComputeAssociation(); + List Kernel.Connectors.IConnector.association => [.. ((SysML2.NET.Core.POCO.Systems.Connections.IConnectionUsage)this).connectionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -116,7 +117,7 @@ public partial class InterfaceUsage : IInterfaceUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674983_471497_43284")] [RedefinedByProperty("IInterfaceUsage.InterfaceDefinition")] [Implements(implementation: "IConnectionUsage.ConnectionDefinition")] - public List connectionDefinition => this.ComputeConnectionDefinition(); + List Systems.Connections.IConnectionUsage.connectionDefinition => [.. this.interfaceDefinition]; /// /// The endFeatures of a Connector, which redefine the endFeatures of the associations of the Connector. @@ -173,7 +174,7 @@ public partial class InterfaceUsage : IInterfaceUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -237,7 +238,7 @@ public partial class InterfaceUsage : IInterfaceUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -480,7 +481,11 @@ public partial class InterfaceUsage : IInterfaceUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1124,7 +1129,7 @@ public partial class InterfaceUsage : IInterfaceUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1152,7 +1157,11 @@ public partial class InterfaceUsage : IInterfaceUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1170,7 +1179,11 @@ public partial class InterfaceUsage : IInterfaceUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1200,7 +1213,7 @@ public partial class InterfaceUsage : IInterfaceUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Intersecting.cs b/SysML2.NET/Core/AutoGenPoco/Intersecting.cs index 16c8402e..ddbb03ec 100644 --- a/SysML2.NET/Core/AutoGenPoco/Intersecting.cs +++ b/SysML2.NET/Core/AutoGenPoco/Intersecting.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Types using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Elements; @@ -247,7 +248,11 @@ public partial class Intersecting : IIntersecting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IIntersecting.TypeIntersected")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.typeIntersected != null ? [this.typeIntersected] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -256,7 +261,17 @@ public partial class Intersecting : IIntersecting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IIntersecting.IntersectingType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.IntersectingType != null ? [this.IntersectingType] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.IntersectingType = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/Invariant.cs b/SysML2.NET/Core/AutoGenPoco/Invariant.cs index af477cfc..ef423a47 100644 --- a/SysML2.NET/Core/AutoGenPoco/Invariant.cs +++ b/SysML2.NET/Core/AutoGenPoco/Invariant.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Functions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -67,7 +68,7 @@ public partial class Invariant : IInvariant [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -128,7 +129,7 @@ public partial class Invariant : IInvariant [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -214,7 +215,7 @@ public partial class Invariant : IInvariant [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction IExpression.function => this.predicate; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. diff --git a/SysML2.NET/Core/AutoGenPoco/InvocationExpression.cs b/SysML2.NET/Core/AutoGenPoco/InvocationExpression.cs index 58cc96b7..9136b508 100644 --- a/SysML2.NET/Core/AutoGenPoco/InvocationExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/InvocationExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -81,7 +82,7 @@ public partial class InvocationExpression : IInvocationExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -142,7 +143,7 @@ public partial class InvocationExpression : IInvocationExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/ItemDefinition.cs b/SysML2.NET/Core/AutoGenPoco/ItemDefinition.cs index 6ca5da22..d00250a1 100644 --- a/SysML2.NET/Core/AutoGenPoco/ItemDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/ItemDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Items using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/ItemUsage.cs b/SysML2.NET/Core/AutoGenPoco/ItemUsage.cs index 79cf109c..05dc0679 100644 --- a/SysML2.NET/Core/AutoGenPoco/ItemUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/ItemUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Items using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -133,7 +134,7 @@ public partial class ItemUsage : IItemUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -423,7 +424,11 @@ public partial class ItemUsage : IItemUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1064,7 +1069,7 @@ public partial class ItemUsage : IItemUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/JoinNode.cs b/SysML2.NET/Core/AutoGenPoco/JoinNode.cs index 21ddeff0..26b6e488 100644 --- a/SysML2.NET/Core/AutoGenPoco/JoinNode.cs +++ b/SysML2.NET/Core/AutoGenPoco/JoinNode.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -101,7 +102,7 @@ public partial class JoinNode : IJoinNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -151,7 +152,7 @@ public partial class JoinNode : IJoinNode [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -173,7 +174,7 @@ public partial class JoinNode : IJoinNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -442,7 +443,11 @@ public partial class JoinNode : IJoinNode [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -729,7 +734,7 @@ public partial class JoinNode : IJoinNode [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1083,7 +1088,7 @@ public partial class JoinNode : IJoinNode [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/LibraryPackage.cs b/SysML2.NET/Core/AutoGenPoco/LibraryPackage.cs index 3a04a016..cf338f14 100644 --- a/SysML2.NET/Core/AutoGenPoco/LibraryPackage.cs +++ b/SysML2.NET/Core/AutoGenPoco/LibraryPackage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Packages using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Kernel.Functions; using SysML2.NET.Core.POCO.Root.Annotations; diff --git a/SysML2.NET/Core/AutoGenPoco/LiteralBoolean.cs b/SysML2.NET/Core/AutoGenPoco/LiteralBoolean.cs index e9a82aa5..ee8a7dfc 100644 --- a/SysML2.NET/Core/AutoGenPoco/LiteralBoolean.cs +++ b/SysML2.NET/Core/AutoGenPoco/LiteralBoolean.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -67,7 +68,7 @@ public partial class LiteralBoolean : ILiteralBoolean [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -128,7 +129,7 @@ public partial class LiteralBoolean : ILiteralBoolean [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/LiteralExpression.cs b/SysML2.NET/Core/AutoGenPoco/LiteralExpression.cs index f19ec840..082eadc2 100644 --- a/SysML2.NET/Core/AutoGenPoco/LiteralExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/LiteralExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -66,7 +67,7 @@ public partial class LiteralExpression : ILiteralExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -127,7 +128,7 @@ public partial class LiteralExpression : ILiteralExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/LiteralInfinity.cs b/SysML2.NET/Core/AutoGenPoco/LiteralInfinity.cs index 816836f0..aca3ef81 100644 --- a/SysML2.NET/Core/AutoGenPoco/LiteralInfinity.cs +++ b/SysML2.NET/Core/AutoGenPoco/LiteralInfinity.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -67,7 +68,7 @@ public partial class LiteralInfinity : ILiteralInfinity [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -128,7 +129,7 @@ public partial class LiteralInfinity : ILiteralInfinity [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/LiteralInteger.cs b/SysML2.NET/Core/AutoGenPoco/LiteralInteger.cs index 92d404fc..ec27b392 100644 --- a/SysML2.NET/Core/AutoGenPoco/LiteralInteger.cs +++ b/SysML2.NET/Core/AutoGenPoco/LiteralInteger.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -67,7 +68,7 @@ public partial class LiteralInteger : ILiteralInteger [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -128,7 +129,7 @@ public partial class LiteralInteger : ILiteralInteger [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/LiteralRational.cs b/SysML2.NET/Core/AutoGenPoco/LiteralRational.cs index c4e449d4..7f435be4 100644 --- a/SysML2.NET/Core/AutoGenPoco/LiteralRational.cs +++ b/SysML2.NET/Core/AutoGenPoco/LiteralRational.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -67,7 +68,7 @@ public partial class LiteralRational : ILiteralRational [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -128,7 +129,7 @@ public partial class LiteralRational : ILiteralRational [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/LiteralString.cs b/SysML2.NET/Core/AutoGenPoco/LiteralString.cs index 320f69f5..0ddc35c8 100644 --- a/SysML2.NET/Core/AutoGenPoco/LiteralString.cs +++ b/SysML2.NET/Core/AutoGenPoco/LiteralString.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -67,7 +68,7 @@ public partial class LiteralString : ILiteralString [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -128,7 +129,7 @@ public partial class LiteralString : ILiteralString [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/LoopActionUsage.cs b/SysML2.NET/Core/AutoGenPoco/LoopActionUsage.cs index 13fe09b8..2deb4663 100644 --- a/SysML2.NET/Core/AutoGenPoco/LoopActionUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/LoopActionUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -102,7 +103,7 @@ public partial class LoopActionUsage : ILoopActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The ActionUsage to be performed repeatedly by the LoopActionUsage. It is the second parameter of the @@ -160,7 +161,7 @@ public partial class LoopActionUsage : ILoopActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -182,7 +183,7 @@ public partial class LoopActionUsage : ILoopActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -451,7 +452,11 @@ public partial class LoopActionUsage : ILoopActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -738,7 +743,7 @@ public partial class LoopActionUsage : ILoopActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1092,7 +1097,7 @@ public partial class LoopActionUsage : ILoopActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Membership.cs b/SysML2.NET/Core/AutoGenPoco/Membership.cs index f5456776..511669fe 100644 --- a/SysML2.NET/Core/AutoGenPoco/Membership.cs +++ b/SysML2.NET/Core/AutoGenPoco/Membership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Namespaces using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Root.Annotations; @@ -282,7 +283,11 @@ public partial class Membership : IMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.membershipOwningNamespace != null ? [this.membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -291,7 +296,17 @@ public partial class Membership : IMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.MemberElement != null ? [this.MemberElement] : []; + set + { + if (value.Count != 0) + { + this.MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/MembershipExpose.cs b/SysML2.NET/Core/AutoGenPoco/MembershipExpose.cs index 848dcb06..c1502b2d 100644 --- a/SysML2.NET/Core/AutoGenPoco/MembershipExpose.cs +++ b/SysML2.NET/Core/AutoGenPoco/MembershipExpose.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Views using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Root.Annotations; @@ -141,7 +142,14 @@ public partial class MembershipExpose : IMembershipExpose [Property(xmiId: "_19_0_4_12e503d9_1622577942205_869984_64", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IExpose.IsImportAll")] [Implements(implementation: "IImport.IsImportAll")] - bool Root.Namespaces.IImport.IsImportAll { get; set; } + bool Root.Namespaces.IImport.IsImportAll + { + get => this.IsImportAll; + set + { + this.IsImportAll = value; + } + } /// /// An Expose always imports all Elements, regardless of visibility (isImportAll = true). @@ -288,7 +296,11 @@ public partial class MembershipExpose : IMembershipExpose [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IImport.ImportOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.importOwningNamespace != null ? [this.importOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -297,7 +309,17 @@ public partial class MembershipExpose : IMembershipExpose [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembershipImport.ImportedMembership")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.ImportedMembership != null ? [this.ImportedMembership] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.ImportedMembership = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. @@ -315,7 +337,14 @@ public partial class MembershipExpose : IMembershipExpose [Property(xmiId: "_18_5_3_12e503d9_1533160674976_798509_43257", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "private")] [RedefinedByProperty("IExpose.Visibility")] [Implements(implementation: "IImport.Visibility")] - VisibilityKind Root.Namespaces.IImport.Visibility { get; set; } = VisibilityKind.Private; + VisibilityKind Root.Namespaces.IImport.Visibility + { + get => this.Visibility; + set + { + this.Visibility = value; + } + } /// /// An Expose always has protected visibility. diff --git a/SysML2.NET/Core/AutoGenPoco/MembershipImport.cs b/SysML2.NET/Core/AutoGenPoco/MembershipImport.cs index 939e18c9..c53c1399 100644 --- a/SysML2.NET/Core/AutoGenPoco/MembershipImport.cs +++ b/SysML2.NET/Core/AutoGenPoco/MembershipImport.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Namespaces using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Root.Annotations; @@ -279,7 +280,11 @@ public partial class MembershipImport : IMembershipImport [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IImport.ImportOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.importOwningNamespace != null ? [this.importOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -288,7 +293,17 @@ public partial class MembershipImport : IMembershipImport [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembershipImport.ImportedMembership")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.ImportedMembership != null ? [this.ImportedMembership] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.ImportedMembership = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/MergeNode.cs b/SysML2.NET/Core/AutoGenPoco/MergeNode.cs index 61334db5..e44d7899 100644 --- a/SysML2.NET/Core/AutoGenPoco/MergeNode.cs +++ b/SysML2.NET/Core/AutoGenPoco/MergeNode.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -101,7 +102,7 @@ public partial class MergeNode : IMergeNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -151,7 +152,7 @@ public partial class MergeNode : IMergeNode [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -173,7 +174,7 @@ public partial class MergeNode : IMergeNode [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -442,7 +443,11 @@ public partial class MergeNode : IMergeNode [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -729,7 +734,7 @@ public partial class MergeNode : IMergeNode [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1083,7 +1088,7 @@ public partial class MergeNode : IMergeNode [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Metaclass.cs b/SysML2.NET/Core/AutoGenPoco/Metaclass.cs index 937506e0..475eb9aa 100644 --- a/SysML2.NET/Core/AutoGenPoco/Metaclass.cs +++ b/SysML2.NET/Core/AutoGenPoco/Metaclass.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Metadata using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/MetadataAccessExpression.cs b/SysML2.NET/Core/AutoGenPoco/MetadataAccessExpression.cs index 978f5943..b2787950 100644 --- a/SysML2.NET/Core/AutoGenPoco/MetadataAccessExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/MetadataAccessExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -69,7 +70,7 @@ public partial class MetadataAccessExpression : IMetadataAccessExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -130,7 +131,7 @@ public partial class MetadataAccessExpression : IMetadataAccessExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/MetadataDefinition.cs b/SysML2.NET/Core/AutoGenPoco/MetadataDefinition.cs index d9739be7..437fef10 100644 --- a/SysML2.NET/Core/AutoGenPoco/MetadataDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/MetadataDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Metadata using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/MetadataFeature.cs b/SysML2.NET/Core/AutoGenPoco/MetadataFeature.cs index f53d7367..81921358 100644 --- a/SysML2.NET/Core/AutoGenPoco/MetadataFeature.cs +++ b/SysML2.NET/Core/AutoGenPoco/MetadataFeature.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Metadata using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/MetadataUsage.cs b/SysML2.NET/Core/AutoGenPoco/MetadataUsage.cs index cb6a641a..781b553c 100644 --- a/SysML2.NET/Core/AutoGenPoco/MetadataUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/MetadataUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Metadata using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -152,7 +153,7 @@ public partial class MetadataUsage : IMetadataUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -442,7 +443,11 @@ public partial class MetadataUsage : IMetadataUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -461,7 +466,7 @@ public partial class MetadataUsage : IMetadataUsage [SubsettedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("IMetadataUsage.MetadataDefinition")] [Implements(implementation: "IItemUsage.ItemDefinition")] - public List itemDefinition => this.ComputeItemDefinition(); + List Systems.Items.IItemUsage.itemDefinition => this.metadataDefinition != null ? [this.metadataDefinition] : []; /// /// Whether this Usage may be time varying (that is, whether it is featured by the snapshots of its @@ -499,7 +504,7 @@ public partial class MetadataUsage : IMetadataUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IMetadataUsage.MetadataDefinition")] [Implements(implementation: "IMetadataFeature.Metaclass")] - public IMetaclass metaclass => this.ComputeMetaclass(); + IMetaclass Kernel.Metadata.IMetadataFeature.metaclass => this.metadataDefinition; /// /// The MetadataDefinition that is the definition of this MetadataUsage. @@ -1121,7 +1126,7 @@ public partial class MetadataUsage : IMetadataUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Multiplicity.cs b/SysML2.NET/Core/AutoGenPoco/Multiplicity.cs index fade1383..e1b49718 100644 --- a/SysML2.NET/Core/AutoGenPoco/Multiplicity.cs +++ b/SysML2.NET/Core/AutoGenPoco/Multiplicity.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Types using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/MultiplicityRange.cs b/SysML2.NET/Core/AutoGenPoco/MultiplicityRange.cs index d55744e9..0788c1db 100644 --- a/SysML2.NET/Core/AutoGenPoco/MultiplicityRange.cs +++ b/SysML2.NET/Core/AutoGenPoco/MultiplicityRange.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Multiplicities using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/Namespace.cs b/SysML2.NET/Core/AutoGenPoco/Namespace.cs index 840a3cf5..88d1eac8 100644 --- a/SysML2.NET/Core/AutoGenPoco/Namespace.cs +++ b/SysML2.NET/Core/AutoGenPoco/Namespace.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Namespaces using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Elements; diff --git a/SysML2.NET/Core/AutoGenPoco/NamespaceExpose.cs b/SysML2.NET/Core/AutoGenPoco/NamespaceExpose.cs index aad84016..7d09ef45 100644 --- a/SysML2.NET/Core/AutoGenPoco/NamespaceExpose.cs +++ b/SysML2.NET/Core/AutoGenPoco/NamespaceExpose.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Views using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Root.Annotations; @@ -149,7 +150,14 @@ public partial class NamespaceExpose : INamespaceExpose [Property(xmiId: "_19_0_4_12e503d9_1622577942205_869984_64", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IExpose.IsImportAll")] [Implements(implementation: "IImport.IsImportAll")] - bool Root.Namespaces.IImport.IsImportAll { get; set; } + bool Root.Namespaces.IImport.IsImportAll + { + get => this.IsImportAll; + set + { + this.IsImportAll = value; + } + } /// /// Whether this Element is contained in the ownership tree of a library model. @@ -288,7 +296,11 @@ public partial class NamespaceExpose : INamespaceExpose [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IImport.ImportOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.importOwningNamespace != null ? [this.importOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -297,7 +309,17 @@ public partial class NamespaceExpose : INamespaceExpose [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("INamespaceImport.ImportedNamespace")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.ImportedNamespace != null ? [this.ImportedNamespace] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.ImportedNamespace = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. @@ -323,7 +345,14 @@ public partial class NamespaceExpose : INamespaceExpose [Property(xmiId: "_18_5_3_12e503d9_1533160674976_798509_43257", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "private")] [RedefinedByProperty("IExpose.Visibility")] [Implements(implementation: "IImport.Visibility")] - VisibilityKind Root.Namespaces.IImport.Visibility { get; set; } = VisibilityKind.Private; + VisibilityKind Root.Namespaces.IImport.Visibility + { + get => this.Visibility; + set + { + this.Visibility = value; + } + } } } diff --git a/SysML2.NET/Core/AutoGenPoco/NamespaceImport.cs b/SysML2.NET/Core/AutoGenPoco/NamespaceImport.cs index dec96013..ec138e69 100644 --- a/SysML2.NET/Core/AutoGenPoco/NamespaceImport.cs +++ b/SysML2.NET/Core/AutoGenPoco/NamespaceImport.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Namespaces using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Root.Annotations; @@ -280,7 +281,11 @@ public partial class NamespaceImport : INamespaceImport [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IImport.ImportOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.importOwningNamespace != null ? [this.importOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -289,7 +294,17 @@ public partial class NamespaceImport : INamespaceImport [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("INamespaceImport.ImportedNamespace")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.ImportedNamespace != null ? [this.ImportedNamespace] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.ImportedNamespace = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/NullExpression.cs b/SysML2.NET/Core/AutoGenPoco/NullExpression.cs index 0113e27e..8e83f2b1 100644 --- a/SysML2.NET/Core/AutoGenPoco/NullExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/NullExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -66,7 +67,7 @@ public partial class NullExpression : INullExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -127,7 +128,7 @@ public partial class NullExpression : INullExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/ObjectiveMembership.cs b/SysML2.NET/Core/AutoGenPoco/ObjectiveMembership.cs index 4e2eae8a..842d61b2 100644 --- a/SysML2.NET/Core/AutoGenPoco/ObjectiveMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/ObjectiveMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Cases using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Core.Features; @@ -126,7 +127,11 @@ public partial class ObjectiveMembership : IObjectiveMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -134,7 +139,7 @@ public partial class ObjectiveMembership : IObjectiveMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -142,7 +147,11 @@ public partial class ObjectiveMembership : IObjectiveMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -153,7 +162,7 @@ public partial class ObjectiveMembership : IObjectiveMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -161,7 +170,11 @@ public partial class ObjectiveMembership : IObjectiveMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -200,7 +213,7 @@ public partial class ObjectiveMembership : IObjectiveMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -218,7 +231,7 @@ public partial class ObjectiveMembership : IObjectiveMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IObjectiveMembership.OwnedObjectiveRequirement")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedObjectiveRequirement; /// /// The name of the ownedMemberElement. @@ -348,7 +361,11 @@ public partial class ObjectiveMembership : IObjectiveMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -357,7 +374,17 @@ public partial class ObjectiveMembership : IObjectiveMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/OccurrenceDefinition.cs b/SysML2.NET/Core/AutoGenPoco/OccurrenceDefinition.cs index b2832aef..633e6095 100644 --- a/SysML2.NET/Core/AutoGenPoco/OccurrenceDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/OccurrenceDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Occurrences using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/OccurrenceUsage.cs b/SysML2.NET/Core/AutoGenPoco/OccurrenceUsage.cs index 1f9c23a3..b7636888 100644 --- a/SysML2.NET/Core/AutoGenPoco/OccurrenceUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/OccurrenceUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Occurrences using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -132,7 +133,7 @@ public partial class OccurrenceUsage : IOccurrenceUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -422,7 +423,11 @@ public partial class OccurrenceUsage : IOccurrenceUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1053,7 +1058,7 @@ public partial class OccurrenceUsage : IOccurrenceUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/OperatorExpression.cs b/SysML2.NET/Core/AutoGenPoco/OperatorExpression.cs index 7376bc2d..228a638e 100644 --- a/SysML2.NET/Core/AutoGenPoco/OperatorExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/OperatorExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -77,7 +78,7 @@ public partial class OperatorExpression : IOperatorExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -138,7 +139,7 @@ public partial class OperatorExpression : IOperatorExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/OwningMembership.cs b/SysML2.NET/Core/AutoGenPoco/OwningMembership.cs index 1e51bf9e..3c5aaf2c 100644 --- a/SysML2.NET/Core/AutoGenPoco/OwningMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/OwningMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Namespaces using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Root.Annotations; @@ -122,7 +123,11 @@ public partial class OwningMembership : IOwningMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement IMembership.MemberElement + { + get => this.ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -130,7 +135,7 @@ public partial class OwningMembership : IOwningMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -138,7 +143,11 @@ public partial class OwningMembership : IOwningMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -156,7 +165,11 @@ public partial class OwningMembership : IOwningMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -315,7 +328,11 @@ public partial class OwningMembership : IOwningMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.membershipOwningNamespace != null ? [this.membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -324,7 +341,17 @@ public partial class OwningMembership : IOwningMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/Package.cs b/SysML2.NET/Core/AutoGenPoco/Package.cs index 274e2875..12a29f64 100644 --- a/SysML2.NET/Core/AutoGenPoco/Package.cs +++ b/SysML2.NET/Core/AutoGenPoco/Package.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Packages using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Kernel.Functions; using SysML2.NET.Core.POCO.Root.Annotations; diff --git a/SysML2.NET/Core/AutoGenPoco/ParameterMembership.cs b/SysML2.NET/Core/AutoGenPoco/ParameterMembership.cs index bfbb633a..b844ce53 100644 --- a/SysML2.NET/Core/AutoGenPoco/ParameterMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/ParameterMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Behaviors using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Core.Features; @@ -126,7 +127,11 @@ public partial class ParameterMembership : IParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -134,7 +139,7 @@ public partial class ParameterMembership : IParameterMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -142,7 +147,11 @@ public partial class ParameterMembership : IParameterMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -153,7 +162,7 @@ public partial class ParameterMembership : IParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -161,7 +170,11 @@ public partial class ParameterMembership : IParameterMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -200,7 +213,7 @@ public partial class ParameterMembership : IParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -218,7 +231,7 @@ public partial class ParameterMembership : IParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IParameterMembership.OwnedMemberParameter")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedMemberParameter; /// /// The name of the ownedMemberElement. @@ -348,7 +361,11 @@ public partial class ParameterMembership : IParameterMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -357,7 +374,17 @@ public partial class ParameterMembership : IParameterMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/PartDefinition.cs b/SysML2.NET/Core/AutoGenPoco/PartDefinition.cs index 8bef58f0..f178763f 100644 --- a/SysML2.NET/Core/AutoGenPoco/PartDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/PartDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Parts using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/PartUsage.cs b/SysML2.NET/Core/AutoGenPoco/PartUsage.cs index b5a52ff2..f650849d 100644 --- a/SysML2.NET/Core/AutoGenPoco/PartUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/PartUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Parts using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -132,7 +133,7 @@ public partial class PartUsage : IPartUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -422,7 +423,11 @@ public partial class PartUsage : IPartUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1071,7 +1076,7 @@ public partial class PartUsage : IPartUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/PayloadFeature.cs b/SysML2.NET/Core/AutoGenPoco/PayloadFeature.cs index 1e3b0ca9..f8e1e6c2 100644 --- a/SysML2.NET/Core/AutoGenPoco/PayloadFeature.cs +++ b/SysML2.NET/Core/AutoGenPoco/PayloadFeature.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Interactions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/PerformActionUsage.cs b/SysML2.NET/Core/AutoGenPoco/PerformActionUsage.cs index 26e70a6b..01d5b111 100644 --- a/SysML2.NET/Core/AutoGenPoco/PerformActionUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/PerformActionUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -103,7 +104,7 @@ public partial class PerformActionUsage : IPerformActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -153,7 +154,7 @@ public partial class PerformActionUsage : IPerformActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -175,7 +176,7 @@ public partial class PerformActionUsage : IPerformActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -237,7 +238,7 @@ public partial class PerformActionUsage : IPerformActionUsage [Property(xmiId: "_19_0_4_12e503d9_1622831790393_676695_195", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IPerformActionUsage.PerformedAction")] [Implements(implementation: "IEventOccurrenceUsage.EventOccurrence")] - public IOccurrenceUsage eventOccurrence => this.ComputeEventOccurrence(); + IOccurrenceUsage Systems.Occurrences.IEventOccurrenceUsage.eventOccurrence => this.performedAction; /// /// The ownedMemberFeatures of the featureMemberships of this Type. @@ -427,7 +428,7 @@ public partial class PerformActionUsage : IPerformActionUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IEventOccurrenceUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool Systems.DefinitionAndUsage.IUsage.isReference => throw new InvalidOperationException("Redefined by property IEventOccurrenceUsage.IsReference"); + bool Systems.DefinitionAndUsage.IUsage.isReference => this.isReference; /// /// Always true for an EventOccurrenceUsage. @@ -463,7 +464,11 @@ public partial class PerformActionUsage : IPerformActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -750,7 +755,7 @@ public partial class PerformActionUsage : IPerformActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1113,7 +1118,7 @@ public partial class PerformActionUsage : IPerformActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/PortConjugation.cs b/SysML2.NET/Core/AutoGenPoco/PortConjugation.cs index 7ce588d6..fd630ae5 100644 --- a/SysML2.NET/Core/AutoGenPoco/PortConjugation.cs +++ b/SysML2.NET/Core/AutoGenPoco/PortConjugation.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Ports using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Types; using SysML2.NET.Core.POCO.Root.Annotations; @@ -160,7 +161,17 @@ public partial class PortConjugation : IPortConjugation [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IPortConjugation.OriginalPortDefinition")] [Implements(implementation: "IConjugation.OriginalType")] - public IType OriginalType { get; set; } + IType Core.Types.IConjugation.OriginalType + { + get => this.OriginalPortDefinition; + set + { + if (value is IPortDefinition castedValue) + { + this.OriginalPortDefinition = castedValue; + } + } + } /// /// The ownedRelationships of this Element that are Annotations, for which this Element is the @@ -246,7 +257,7 @@ public partial class PortConjugation : IPortConjugation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1543092026091_693018_16749")] [RedefinedByProperty("IPortConjugation.ConjugatedPortDefinition")] [Implements(implementation: "IConjugation.OwningType")] - public IType owningType => this.ComputeOwningType(); + IType Core.Types.IConjugation.owningType => this.conjugatedPortDefinition; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -285,7 +296,17 @@ public partial class PortConjugation : IPortConjugation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConjugation.ConjugatedType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.ConjugatedType != null ? [this.ConjugatedType] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.ConjugatedType = firstValue; + } + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -294,7 +315,17 @@ public partial class PortConjugation : IPortConjugation [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConjugation.OriginalType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Core.Types.IConjugation)this).OriginalType != null ? [((SysML2.NET.Core.POCO.Core.Types.IConjugation)this).OriginalType] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.IConjugation)this).OriginalType = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/PortDefinition.cs b/SysML2.NET/Core/AutoGenPoco/PortDefinition.cs index f36b0fc4..473cd1bf 100644 --- a/SysML2.NET/Core/AutoGenPoco/PortDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/PortDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Ports using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/PortUsage.cs b/SysML2.NET/Core/AutoGenPoco/PortUsage.cs index 4969c18e..0181526b 100644 --- a/SysML2.NET/Core/AutoGenPoco/PortUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/PortUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Ports using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -130,7 +131,7 @@ public partial class PortUsage : IPortUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -420,7 +421,11 @@ public partial class PortUsage : IPortUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -707,7 +712,7 @@ public partial class PortUsage : IPortUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IPortUsage.PortDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.portDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1060,7 +1065,7 @@ public partial class PortUsage : IPortUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Predicate.cs b/SysML2.NET/Core/AutoGenPoco/Predicate.cs index ab98f667..948d0c5a 100644 --- a/SysML2.NET/Core/AutoGenPoco/Predicate.cs +++ b/SysML2.NET/Core/AutoGenPoco/Predicate.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Functions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -95,7 +96,7 @@ public partial class Predicate : IPredicate [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The Documentation owned by this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/Redefinition.cs b/SysML2.NET/Core/AutoGenPoco/Redefinition.cs index a5e75e43..4b5240d8 100644 --- a/SysML2.NET/Core/AutoGenPoco/Redefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/Redefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Types; using SysML2.NET.Core.POCO.Root.Annotations; @@ -107,7 +108,17 @@ public partial class Redefinition : IRedefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubsetting.SubsettedFeature")] [Implements(implementation: "ISpecialization.General")] - public IType General { get; set; } + IType Core.Types.ISpecialization.General + { + get => ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettedFeature; + set + { + if (value is IFeature castedValue) + { + ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettedFeature = castedValue; + } + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -238,7 +249,7 @@ public partial class Redefinition : IRedefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubsetting.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public IType owningType => this.ComputeOwningType(); + IType Core.Types.ISpecialization.owningType => this.owningFeature; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -293,7 +304,17 @@ public partial class Redefinition : IRedefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific = firstValue; + } + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -302,7 +323,17 @@ public partial class Redefinition : IRedefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubsetting.SubsettingFeature")] [Implements(implementation: "ISpecialization.Specific")] - public IType Specific { get; set; } + IType Core.Types.ISpecialization.Specific + { + get => ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettingFeature; + set + { + if (value is IFeature castedValue) + { + ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettingFeature = castedValue; + } + } + } /// /// The Feature that is subsetted by the subsettingFeature of this Subsetting. @@ -311,7 +342,14 @@ public partial class Redefinition : IRedefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674980_563969_43273")] [RedefinedByProperty("IRedefinition.RedefinedFeature")] [Implements(implementation: "ISubsetting.SubsettedFeature")] - public IFeature SubsettedFeature { get; set; } + IFeature ISubsetting.SubsettedFeature + { + get => this.RedefinedFeature; + set + { + this.RedefinedFeature = value; + } + } /// /// The Feature that is a subset of the subsettedFeature of this Subsetting. @@ -320,7 +358,14 @@ public partial class Redefinition : IRedefinition [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("IRedefinition.RedefiningFeature")] [Implements(implementation: "ISubsetting.SubsettingFeature")] - public IFeature SubsettingFeature { get; set; } + IFeature ISubsetting.SubsettingFeature + { + get => this.RedefiningFeature; + set + { + this.RedefiningFeature = value; + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -329,7 +374,17 @@ public partial class Redefinition : IRedefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/ReferenceSubsetting.cs b/SysML2.NET/Core/AutoGenPoco/ReferenceSubsetting.cs index 135094dd..03038af1 100644 --- a/SysML2.NET/Core/AutoGenPoco/ReferenceSubsetting.cs +++ b/SysML2.NET/Core/AutoGenPoco/ReferenceSubsetting.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Types; using SysML2.NET.Core.POCO.Root.Annotations; @@ -101,7 +102,17 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubsetting.SubsettedFeature")] [Implements(implementation: "ISpecialization.General")] - public IType General { get; set; } + IType Core.Types.ISpecialization.General + { + get => ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettedFeature; + set + { + if (value is IFeature castedValue) + { + ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettedFeature = castedValue; + } + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -189,7 +200,7 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_573157_43226")] [RedefinedByProperty("IReferenceSubsetting.ReferencingFeature")] [Implements(implementation: "ISubsetting.OwningFeature")] - public IFeature owningFeature => this.ComputeOwningFeature(); + IFeature ISubsetting.owningFeature => this.referencingFeature; /// /// The owningRelationship of this Element, if that Relationship is a Membership. @@ -233,7 +244,7 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubsetting.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public IType owningType => this.ComputeOwningType(); + IType Core.Types.ISpecialization.owningType => ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).owningFeature; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -289,7 +300,17 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific = firstValue; + } + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -298,7 +319,17 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubsetting.SubsettingFeature")] [Implements(implementation: "ISpecialization.Specific")] - public IType Specific { get; set; } + IType Core.Types.ISpecialization.Specific + { + get => ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettingFeature; + set + { + if (value is IFeature castedValue) + { + ((SysML2.NET.Core.POCO.Core.Features.ISubsetting)this).SubsettingFeature = castedValue; + } + } + } /// /// The Feature that is subsetted by the subsettingFeature of this Subsetting. @@ -307,7 +338,14 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674980_563969_43273")] [RedefinedByProperty("IReferenceSubsetting.ReferencedFeature")] [Implements(implementation: "ISubsetting.SubsettedFeature")] - public IFeature SubsettedFeature { get; set; } + IFeature ISubsetting.SubsettedFeature + { + get => this.ReferencedFeature; + set + { + this.ReferencedFeature = value; + } + } /// /// The Feature that is a subset of the subsettedFeature of this Subsetting. @@ -316,7 +354,11 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("IReferenceSubsetting.ReferencingFeature")] [Implements(implementation: "ISubsetting.SubsettingFeature")] - public IFeature SubsettingFeature { get; set; } + IFeature ISubsetting.SubsettingFeature + { + get => this.referencingFeature; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -325,7 +367,17 @@ public partial class ReferenceSubsetting : IReferenceSubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/ReferenceUsage.cs b/SysML2.NET/Core/AutoGenPoco/ReferenceUsage.cs index ebdcd877..427b7f6e 100644 --- a/SysML2.NET/Core/AutoGenPoco/ReferenceUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/ReferenceUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.DefinitionAndUsage using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Classifiers; @@ -385,7 +386,7 @@ public partial class ReferenceUsage : IReferenceUsage [Property(xmiId: "_19_0_4_12e503d9_1624035114787_488767_41423", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IReferenceUsage.IsReference")] [Implements(implementation: "IUsage.IsReference")] - bool IUsage.isReference => throw new InvalidOperationException("Redefined by property IReferenceUsage.IsReference"); + bool IUsage.isReference => this.isReference; /// /// Whether all things that meet the classification conditions of this Type must be classified by the @@ -413,7 +414,11 @@ public partial class ReferenceUsage : IReferenceUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1025,7 +1030,7 @@ public partial class ReferenceUsage : IReferenceUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. this.definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Relationship.cs b/SysML2.NET/Core/AutoGenPoco/Relationship.cs index b47105fc..0638eb0e 100644 --- a/SysML2.NET/Core/AutoGenPoco/Relationship.cs +++ b/SysML2.NET/Core/AutoGenPoco/Relationship.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Elements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Namespaces; diff --git a/SysML2.NET/Core/AutoGenPoco/RenderingDefinition.cs b/SysML2.NET/Core/AutoGenPoco/RenderingDefinition.cs index 9c94ba40..303760d7 100644 --- a/SysML2.NET/Core/AutoGenPoco/RenderingDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/RenderingDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Views using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/RenderingUsage.cs b/SysML2.NET/Core/AutoGenPoco/RenderingUsage.cs index fbfa5a88..7e26644c 100644 --- a/SysML2.NET/Core/AutoGenPoco/RenderingUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/RenderingUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Views using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -131,7 +132,7 @@ public partial class RenderingUsage : IRenderingUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -421,7 +422,11 @@ public partial class RenderingUsage : IRenderingUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1020,7 +1025,7 @@ public partial class RenderingUsage : IRenderingUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1565471361757_649736_20796")] [RedefinedByProperty("IRenderingUsage.RenderingDefinition")] [Implements(implementation: "IPartUsage.PartDefinition")] - public List partDefinition => this.ComputePartDefinition(); + List Systems.Parts.IPartUsage.partDefinition => this.renderingDefinition != null ? [this.renderingDefinition] : []; /// /// The kind of temporal portion (time slice or snapshot) is represented by this OccurrenceUsage. If @@ -1079,7 +1084,7 @@ public partial class RenderingUsage : IRenderingUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/RequirementConstraintMembership.cs b/SysML2.NET/Core/AutoGenPoco/RequirementConstraintMembership.cs index b03ff24d..13a4d21c 100644 --- a/SysML2.NET/Core/AutoGenPoco/RequirementConstraintMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/RequirementConstraintMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Requirements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.Systems.Requirements; @@ -134,7 +135,11 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -142,7 +147,7 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -150,7 +155,11 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -161,7 +170,7 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -169,7 +178,11 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -216,7 +229,7 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -234,7 +247,7 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IRequirementConstraintMembership.OwnedConstraint")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedConstraint; /// /// The name of the ownedMemberElement. @@ -365,7 +378,11 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -374,7 +391,17 @@ public partial class RequirementConstraintMembership : IRequirementConstraintMem [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/RequirementDefinition.cs b/SysML2.NET/Core/AutoGenPoco/RequirementDefinition.cs index 71aa92da..77dcff65 100644 --- a/SysML2.NET/Core/AutoGenPoco/RequirementDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/RequirementDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Requirements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -117,7 +118,14 @@ public partial class RequirementDefinition : IRequirementDefinition [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementDefinition.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -139,7 +147,7 @@ public partial class RequirementDefinition : IRequirementDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenPoco/RequirementUsage.cs b/SysML2.NET/Core/AutoGenPoco/RequirementUsage.cs index 8466a30c..e6fb73e4 100644 --- a/SysML2.NET/Core/AutoGenPoco/RequirementUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/RequirementUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Requirements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -109,7 +110,7 @@ public partial class RequirementUsage : IRequirementUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -132,7 +133,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578025035149_386_969")] [RedefinedByProperty("IRequirementUsage.RequirementDefinition")] [Implements(implementation: "IConstraintUsage.ConstraintDefinition")] - public IPredicate constraintDefinition => this.ComputeConstraintDefinition(); + IPredicate Systems.Constraints.IConstraintUsage.constraintDefinition => this.requirementDefinition; /// /// The second chainingFeature of the crossedFeature of the ownedCrossSubsetting of this Feature, if it @@ -160,7 +161,14 @@ public partial class RequirementUsage : IRequirementUsage [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementUsage.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The Classifiers that are the types of this Usage. Nominally, these are Definitions, but other kinds @@ -171,7 +179,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -193,7 +201,7 @@ public partial class RequirementUsage : IRequirementUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -297,7 +305,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => ((SysML2.NET.Core.POCO.Kernel.Functions.IBooleanExpression)this).predicate; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -488,7 +496,11 @@ public partial class RequirementUsage : IRequirementUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1095,7 +1107,7 @@ public partial class RequirementUsage : IRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public IPredicate predicate => this.ComputePredicate(); + IPredicate Kernel.Functions.IBooleanExpression.predicate => ((SysML2.NET.Core.POCO.Systems.Constraints.IConstraintUsage)this).constraintDefinition; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1202,7 +1214,7 @@ public partial class RequirementUsage : IRequirementUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/RequirementVerificationMembership.cs b/SysML2.NET/Core/AutoGenPoco/RequirementVerificationMembership.cs index b0ecf888..f4bf91b9 100644 --- a/SysML2.NET/Core/AutoGenPoco/RequirementVerificationMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/RequirementVerificationMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.VerificationCases using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.Systems.Requirements; @@ -135,7 +136,14 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [Property(xmiId: "_19_0_2_12e503d9_1584048161309_821854_390", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementVerificationMembership.Kind")] [Implements(implementation: "IRequirementConstraintMembership.Kind")] - RequirementConstraintKind Systems.Requirements.IRequirementConstraintMembership.Kind { get; set; } + RequirementConstraintKind Systems.Requirements.IRequirementConstraintMembership.Kind + { + get => this.Kind; + set + { + this.Kind = value; + } + } /// /// The Element that becomes a member of the membershipOwningNamespace due to this Membership. @@ -144,7 +152,11 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -152,7 +164,7 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -160,7 +172,11 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -171,7 +187,7 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -179,7 +195,11 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -208,7 +228,7 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674993_898044_43344")] [RedefinedByProperty("IRequirementVerificationMembership.OwnedRequirement")] [Implements(implementation: "IRequirementConstraintMembership.OwnedConstraint")] - public IConstraintUsage ownedConstraint => this.ComputeOwnedConstraint(); + IConstraintUsage Systems.Requirements.IRequirementConstraintMembership.ownedConstraint => this.ownedRequirement; /// /// The Elements owned by this Element, derived as the ownedRelatedElements of the ownedRelationships of @@ -227,7 +247,7 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -245,7 +265,7 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IRequirementConstraintMembership.OwnedConstraint")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => ((SysML2.NET.Core.POCO.Systems.Requirements.IRequirementConstraintMembership)this).ownedConstraint; /// /// The name of the ownedMemberElement. @@ -360,7 +380,7 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [Property(xmiId: "_19_0_4_12e503d9_1617118807597_77864_3544", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementVerificationMembership.VerifiedRequirement")] [Implements(implementation: "IRequirementConstraintMembership.ReferencedConstraint")] - public IConstraintUsage referencedConstraint => this.ComputeReferencedConstraint(); + IConstraintUsage Systems.Requirements.IRequirementConstraintMembership.referencedConstraint => this.verifiedRequirement; /// /// The Elements that are related by this Relationship, derived as the union of the source and target @@ -387,7 +407,11 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -396,7 +420,17 @@ public partial class RequirementVerificationMembership : IRequirementVerificatio [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/ResultExpressionMembership.cs b/SysML2.NET/Core/AutoGenPoco/ResultExpressionMembership.cs index e75e5ed3..4995fde8 100644 --- a/SysML2.NET/Core/AutoGenPoco/ResultExpressionMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/ResultExpressionMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Functions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Core.Features; @@ -127,7 +128,11 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -135,7 +140,7 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -143,7 +148,11 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -154,7 +163,7 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -162,7 +171,11 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -201,7 +214,7 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -219,7 +232,7 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IResultExpressionMembership.OwnedResultExpression")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedResultExpression; /// /// The name of the ownedMemberElement. @@ -349,7 +362,11 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -358,7 +375,17 @@ public partial class ResultExpressionMembership : IResultExpressionMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/ReturnParameterMembership.cs b/SysML2.NET/Core/AutoGenPoco/ReturnParameterMembership.cs index da688b26..7fba82a5 100644 --- a/SysML2.NET/Core/AutoGenPoco/ReturnParameterMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/ReturnParameterMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Functions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Core.Features; @@ -127,7 +128,11 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -135,7 +140,7 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -143,7 +148,11 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -154,7 +163,7 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -162,7 +171,11 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -201,7 +214,7 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -219,7 +232,7 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IParameterMembership.OwnedMemberParameter")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedMemberParameter; /// /// The name of the ownedMemberElement. @@ -349,7 +362,11 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -358,7 +375,17 @@ public partial class ReturnParameterMembership : IReturnParameterMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/SatisfyRequirementUsage.cs b/SysML2.NET/Core/AutoGenPoco/SatisfyRequirementUsage.cs index 30c9dee8..58338e60 100644 --- a/SysML2.NET/Core/AutoGenPoco/SatisfyRequirementUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/SatisfyRequirementUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Requirements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -103,7 +104,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [Property(xmiId: "_19_0_2_12e503d9_1581045158665_239617_9458", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("ISatisfyRequirementUsage.SatisfiedRequirement")] [Implements(implementation: "IAssertConstraintUsage.AssertedConstraint")] - public IConstraintUsage assertedConstraint => this.ComputeAssertedConstraint(); + IConstraintUsage Systems.Constraints.IAssertConstraintUsage.assertedConstraint => this.satisfiedRequirement; /// /// The owned ConstraintUsages that represent assumptions of this RequirementUsage, derived as the @@ -122,7 +123,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -145,7 +146,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578025035149_386_969")] [RedefinedByProperty("IRequirementUsage.RequirementDefinition")] [Implements(implementation: "IConstraintUsage.ConstraintDefinition")] - public IPredicate constraintDefinition => this.ComputeConstraintDefinition(); + IPredicate Systems.Constraints.IConstraintUsage.constraintDefinition => this.requirementDefinition; /// /// The second chainingFeature of the crossedFeature of the ownedCrossSubsetting of this Feature, if it @@ -173,7 +174,14 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementUsage.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The Classifiers that are the types of this Usage. Nominally, these are Definitions, but other kinds @@ -184,7 +192,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -206,7 +214,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -310,7 +318,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => ((SysML2.NET.Core.POCO.Kernel.Functions.IBooleanExpression)this).predicate; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -508,7 +516,11 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1115,7 +1127,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public IPredicate predicate => this.ComputePredicate(); + IPredicate Kernel.Functions.IBooleanExpression.predicate => ((SysML2.NET.Core.POCO.Systems.Constraints.IConstraintUsage)this).constraintDefinition; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1240,7 +1252,7 @@ public partial class SatisfyRequirementUsage : ISatisfyRequirementUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/SelectExpression.cs b/SysML2.NET/Core/AutoGenPoco/SelectExpression.cs index 8dbf2bba..4fe6a06f 100644 --- a/SysML2.NET/Core/AutoGenPoco/SelectExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/SelectExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Expressions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -77,7 +78,7 @@ public partial class SelectExpression : ISelectExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -138,7 +139,7 @@ public partial class SelectExpression : ISelectExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -450,7 +451,14 @@ public partial class SelectExpression : ISelectExpression [Property(xmiId: "_18_5_3_12e503d9_1557528808100_646606_111674", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("ISelectExpression.Operator")] [Implements(implementation: "IOperatorExpression.Operator")] - string IOperatorExpression.Operator { get; set; } + string IOperatorExpression.Operator + { + get => this.Operator; + set + { + this.Operator = value; + } + } /// /// All features related to this Type by FeatureMemberships that have direction out or inout. diff --git a/SysML2.NET/Core/AutoGenPoco/SendActionUsage.cs b/SysML2.NET/Core/AutoGenPoco/SendActionUsage.cs index db93f673..a0dca1a3 100644 --- a/SysML2.NET/Core/AutoGenPoco/SendActionUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/SendActionUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -106,7 +107,7 @@ public partial class SendActionUsage : ISendActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -156,7 +157,7 @@ public partial class SendActionUsage : ISendActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -178,7 +179,7 @@ public partial class SendActionUsage : ISendActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -447,7 +448,11 @@ public partial class SendActionUsage : ISendActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -734,7 +739,7 @@ public partial class SendActionUsage : ISendActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1109,7 +1114,7 @@ public partial class SendActionUsage : ISendActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Specialization.cs b/SysML2.NET/Core/AutoGenPoco/Specialization.cs index a394e2e9..0dd2ce8e 100644 --- a/SysML2.NET/Core/AutoGenPoco/Specialization.cs +++ b/SysML2.NET/Core/AutoGenPoco/Specialization.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Types using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Elements; @@ -256,7 +257,17 @@ public partial class Specialization : ISpecialization [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.Specific != null ? [this.Specific] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.Specific = firstValue; + } + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -273,7 +284,17 @@ public partial class Specialization : ISpecialization [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.General != null ? [this.General] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.General = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/StakeholderMembership.cs b/SysML2.NET/Core/AutoGenPoco/StakeholderMembership.cs index 29381f18..a036e177 100644 --- a/SysML2.NET/Core/AutoGenPoco/StakeholderMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/StakeholderMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Requirements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Core.Features; @@ -128,7 +129,11 @@ public partial class StakeholderMembership : IStakeholderMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -136,7 +141,7 @@ public partial class StakeholderMembership : IStakeholderMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -144,7 +149,11 @@ public partial class StakeholderMembership : IStakeholderMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -155,7 +164,7 @@ public partial class StakeholderMembership : IStakeholderMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -163,7 +172,11 @@ public partial class StakeholderMembership : IStakeholderMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -202,7 +215,7 @@ public partial class StakeholderMembership : IStakeholderMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -220,7 +233,7 @@ public partial class StakeholderMembership : IStakeholderMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IParameterMembership.OwnedMemberParameter")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => ((SysML2.NET.Core.POCO.Kernel.Behaviors.IParameterMembership)this).ownedMemberParameter; /// /// The name of the ownedMemberElement. @@ -237,7 +250,7 @@ public partial class StakeholderMembership : IStakeholderMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674993_898044_43344")] [RedefinedByProperty("IStakeholderMembership.OwnedStakeholderParameter")] [Implements(implementation: "IParameterMembership.OwnedMemberParameter")] - public IFeature ownedMemberParameter => this.ComputeOwnedMemberParameter(); + IFeature Kernel.Behaviors.IParameterMembership.ownedMemberParameter => this.ownedStakeholderParameter; /// /// The shortName of the ownedMemberElement. @@ -359,7 +372,11 @@ public partial class StakeholderMembership : IStakeholderMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -368,7 +385,17 @@ public partial class StakeholderMembership : IStakeholderMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/StateDefinition.cs b/SysML2.NET/Core/AutoGenPoco/StateDefinition.cs index feb1174b..1e5c7f92 100644 --- a/SysML2.NET/Core/AutoGenPoco/StateDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/StateDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.States using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -129,7 +130,7 @@ public partial class StateDefinition : IStateDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenPoco/StateSubactionMembership.cs b/SysML2.NET/Core/AutoGenPoco/StateSubactionMembership.cs index 51b062cb..69cb5ae2 100644 --- a/SysML2.NET/Core/AutoGenPoco/StateSubactionMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/StateSubactionMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.States using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.Systems.States; @@ -142,7 +143,11 @@ public partial class StateSubactionMembership : IStateSubactionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -150,7 +155,7 @@ public partial class StateSubactionMembership : IStateSubactionMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -158,7 +163,11 @@ public partial class StateSubactionMembership : IStateSubactionMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -169,7 +178,7 @@ public partial class StateSubactionMembership : IStateSubactionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -177,7 +186,11 @@ public partial class StateSubactionMembership : IStateSubactionMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -216,7 +229,7 @@ public partial class StateSubactionMembership : IStateSubactionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -234,7 +247,7 @@ public partial class StateSubactionMembership : IStateSubactionMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IStateSubactionMembership.Action")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => this.action; /// /// The name of the ownedMemberElement. @@ -356,7 +369,11 @@ public partial class StateSubactionMembership : IStateSubactionMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -365,7 +382,17 @@ public partial class StateSubactionMembership : IStateSubactionMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/StateUsage.cs b/SysML2.NET/Core/AutoGenPoco/StateUsage.cs index a2d53e44..d1c2c10d 100644 --- a/SysML2.NET/Core/AutoGenPoco/StateUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/StateUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.States using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -88,7 +89,7 @@ public partial class StateUsage : IStateUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("IStateUsage.StateDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition => this.ComputeActionDefinition(); + List Systems.Actions.IActionUsage.actionDefinition => [.. this.stateDefinition]; /// /// Various alternative identifiers for this Element. Generally, these will be set by tools. @@ -104,7 +105,7 @@ public partial class StateUsage : IStateUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. ((SysML2.NET.Core.POCO.Systems.Actions.IActionUsage)this).actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -154,7 +155,7 @@ public partial class StateUsage : IStateUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -176,7 +177,7 @@ public partial class StateUsage : IStateUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -481,7 +482,11 @@ public partial class StateUsage : IStateUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -768,7 +773,7 @@ public partial class StateUsage : IStateUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. ((SysML2.NET.Core.POCO.Systems.Actions.IActionUsage)this).actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1131,7 +1136,7 @@ public partial class StateUsage : IStateUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/Step.cs b/SysML2.NET/Core/AutoGenPoco/Step.cs index 3f6b6ee5..a90ae9e6 100644 --- a/SysML2.NET/Core/AutoGenPoco/Step.cs +++ b/SysML2.NET/Core/AutoGenPoco/Step.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Behaviors using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -127,7 +128,7 @@ public partial class Step : IStep [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/Structure.cs b/SysML2.NET/Core/AutoGenPoco/Structure.cs index e4f5f854..5f5313d5 100644 --- a/SysML2.NET/Core/AutoGenPoco/Structure.cs +++ b/SysML2.NET/Core/AutoGenPoco/Structure.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Structures using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/Subclassification.cs b/SysML2.NET/Core/AutoGenPoco/Subclassification.cs index 6162c429..9f0ed924 100644 --- a/SysML2.NET/Core/AutoGenPoco/Subclassification.cs +++ b/SysML2.NET/Core/AutoGenPoco/Subclassification.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Classifiers using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Types; using SysML2.NET.Core.POCO.Root.Annotations; @@ -97,7 +98,17 @@ public partial class Subclassification : ISubclassification [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubclassification.Superclassifier")] [Implements(implementation: "ISpecialization.General")] - public IType General { get; set; } + IType Core.Types.ISpecialization.General + { + get => this.Superclassifier; + set + { + if (value is IClassifier castedValue) + { + this.Superclassifier = castedValue; + } + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -227,7 +238,7 @@ public partial class Subclassification : ISubclassification [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubclassification.OwningClassifier")] [Implements(implementation: "ISpecialization.OwningType")] - public IType owningType => this.ComputeOwningType(); + IType Core.Types.ISpecialization.owningType => this.owningClassifier; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -266,7 +277,17 @@ public partial class Subclassification : ISubclassification [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific = firstValue; + } + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -275,7 +296,17 @@ public partial class Subclassification : ISubclassification [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubclassification.Subclassifier")] [Implements(implementation: "ISpecialization.Specific")] - public IType Specific { get; set; } + IType Core.Types.ISpecialization.Specific + { + get => this.Subclassifier; + set + { + if (value is IClassifier castedValue) + { + this.Subclassifier = castedValue; + } + } + } /// /// The more specific Classifier in this Subclassification. @@ -300,7 +331,17 @@ public partial class Subclassification : ISubclassification [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/SubjectMembership.cs b/SysML2.NET/Core/AutoGenPoco/SubjectMembership.cs index 270ae2ae..f2ef0c61 100644 --- a/SysML2.NET/Core/AutoGenPoco/SubjectMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/SubjectMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Requirements using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Core.Features; @@ -128,7 +129,11 @@ public partial class SubjectMembership : ISubjectMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -136,7 +141,7 @@ public partial class SubjectMembership : ISubjectMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -144,7 +149,11 @@ public partial class SubjectMembership : ISubjectMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -155,7 +164,7 @@ public partial class SubjectMembership : ISubjectMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -163,7 +172,11 @@ public partial class SubjectMembership : ISubjectMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -202,7 +215,7 @@ public partial class SubjectMembership : ISubjectMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -220,7 +233,7 @@ public partial class SubjectMembership : ISubjectMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IParameterMembership.OwnedMemberParameter")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => ((SysML2.NET.Core.POCO.Kernel.Behaviors.IParameterMembership)this).ownedMemberParameter; /// /// The name of the ownedMemberElement. @@ -237,7 +250,7 @@ public partial class SubjectMembership : ISubjectMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674993_898044_43344")] [RedefinedByProperty("ISubjectMembership.OwnedSubjectParameter")] [Implements(implementation: "IParameterMembership.OwnedMemberParameter")] - public IFeature ownedMemberParameter => this.ComputeOwnedMemberParameter(); + IFeature Kernel.Behaviors.IParameterMembership.ownedMemberParameter => this.ownedSubjectParameter; /// /// The shortName of the ownedMemberElement. @@ -359,7 +372,11 @@ public partial class SubjectMembership : ISubjectMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -368,7 +385,17 @@ public partial class SubjectMembership : ISubjectMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/Subsetting.cs b/SysML2.NET/Core/AutoGenPoco/Subsetting.cs index c03286ba..dcc813ec 100644 --- a/SysML2.NET/Core/AutoGenPoco/Subsetting.cs +++ b/SysML2.NET/Core/AutoGenPoco/Subsetting.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Types; using SysML2.NET.Core.POCO.Root.Annotations; @@ -101,7 +102,17 @@ public partial class Subsetting : ISubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("ISubsetting.SubsettedFeature")] [Implements(implementation: "ISpecialization.General")] - public IType General { get; set; } + IType Core.Types.ISpecialization.General + { + get => this.SubsettedFeature; + set + { + if (value is IFeature castedValue) + { + this.SubsettedFeature = castedValue; + } + } + } /// /// Whether this Relationship was generated by tooling to meet semantic rules, rather than being @@ -232,7 +243,7 @@ public partial class Subsetting : ISubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674982_253967_43281")] [RedefinedByProperty("ISubsetting.OwningFeature")] [Implements(implementation: "ISpecialization.OwningType")] - public IType owningType => this.ComputeOwningType(); + IType Core.Types.ISpecialization.owningType => this.owningFeature; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -271,7 +282,17 @@ public partial class Subsetting : ISubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.Specific")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).Specific = firstValue; + } + } + } /// /// A Type with a subset of all instances of the general Type, which might be the same set. @@ -280,7 +301,17 @@ public partial class Subsetting : ISubsetting [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("ISubsetting.SubsettingFeature")] [Implements(implementation: "ISpecialization.Specific")] - public IType Specific { get; set; } + IType Core.Types.ISpecialization.Specific + { + get => this.SubsettingFeature; + set + { + if (value is IFeature castedValue) + { + this.SubsettingFeature = castedValue; + } + } + } /// /// The Feature that is subsetted by the subsettingFeature of this Subsetting. @@ -305,7 +336,17 @@ public partial class Subsetting : ISubsetting [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ISpecialization.General")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General != null ? [((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + ((SysML2.NET.Core.POCO.Core.Types.ISpecialization)this).General = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/Succession.cs b/SysML2.NET/Core/AutoGenPoco/Succession.cs index 1849eda6..8052888a 100644 --- a/SysML2.NET/Core/AutoGenPoco/Succession.cs +++ b/SysML2.NET/Core/AutoGenPoco/Succession.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Connectors using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Features; @@ -177,7 +178,7 @@ public partial class Succession : ISuccession [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -738,7 +739,7 @@ public partial class Succession : ISuccession [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -766,7 +767,11 @@ public partial class Succession : ISuccession [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -784,7 +789,11 @@ public partial class Succession : ISuccession [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -814,7 +823,7 @@ public partial class Succession : ISuccession [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. this.association]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/SuccessionAsUsage.cs b/SysML2.NET/Core/AutoGenPoco/SuccessionAsUsage.cs index 15a121a0..be6a2883 100644 --- a/SysML2.NET/Core/AutoGenPoco/SuccessionAsUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/SuccessionAsUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Connections using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Classifiers; @@ -219,7 +220,7 @@ public partial class SuccessionAsUsage : ISuccessionAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -438,7 +439,11 @@ public partial class SuccessionAsUsage : ISuccessionAsUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1045,7 +1050,7 @@ public partial class SuccessionAsUsage : ISuccessionAsUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1073,7 +1078,11 @@ public partial class SuccessionAsUsage : ISuccessionAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1091,7 +1100,11 @@ public partial class SuccessionAsUsage : ISuccessionAsUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1121,7 +1134,7 @@ public partial class SuccessionAsUsage : ISuccessionAsUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. this.definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/SuccessionFlow.cs b/SysML2.NET/Core/AutoGenPoco/SuccessionFlow.cs index 5cd40148..dc623e07 100644 --- a/SysML2.NET/Core/AutoGenPoco/SuccessionFlow.cs +++ b/SysML2.NET/Core/AutoGenPoco/SuccessionFlow.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Kernel.Interactions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Classifiers; @@ -70,7 +71,7 @@ public partial class SuccessionFlow : ISuccessionFlow [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IConnector.Association")] - public List association => this.ComputeAssociation(); + List Kernel.Connectors.IConnector.association => [.. this.interaction]; /// /// The Behaviors that type this Step. @@ -79,7 +80,7 @@ public partial class SuccessionFlow : ISuccessionFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.interaction]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -159,7 +160,7 @@ public partial class SuccessionFlow : ISuccessionFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the @@ -193,7 +194,7 @@ public partial class SuccessionFlow : ISuccessionFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -796,7 +797,7 @@ public partial class SuccessionFlow : ISuccessionFlow [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -824,7 +825,11 @@ public partial class SuccessionFlow : ISuccessionFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -850,7 +855,11 @@ public partial class SuccessionFlow : ISuccessionFlow [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -888,7 +897,7 @@ public partial class SuccessionFlow : ISuccessionFlow [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Kernel.Connectors.IConnector)this).association]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/SuccessionFlowUsage.cs b/SysML2.NET/Core/AutoGenPoco/SuccessionFlowUsage.cs index ed97a539..5a1f611e 100644 --- a/SysML2.NET/Core/AutoGenPoco/SuccessionFlowUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/SuccessionFlowUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Flows using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -88,7 +89,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("IFlowUsage.FlowDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition => this.ComputeActionDefinition(); + List Systems.Actions.IActionUsage.actionDefinition => [.. this.flowDefinition]; /// /// Various alternative identifiers for this Element. Generally, these will be set by tools. @@ -104,7 +105,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IConnector.Association")] - public List association => this.ComputeAssociation(); + List Kernel.Connectors.IConnector.association => [.. ((SysML2.NET.Core.POCO.Kernel.Interactions.IFlow)this).interaction]; /// /// The Behaviors that type this Step. @@ -113,7 +114,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IFlow.Interaction")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. ((SysML2.NET.Core.POCO.Kernel.Interactions.IFlow)this).interaction]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -182,7 +183,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -204,7 +205,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -247,7 +248,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IConnector.ConnectorEnd")] [Implements(implementation: "IType.EndFeature")] - public List endFeature => this.ComputeEndFeature(); + List Core.Types.IType.endFeature => [.. this.connectorEnd]; /// /// The Type that is related to this Feature by an EndFeatureMembership in which the Feature is an @@ -362,7 +363,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IFlowUsage.FlowDefinition")] [Implements(implementation: "IFlow.Interaction")] - public List interaction => this.ComputeInteraction(); + List Kernel.Interactions.IFlow.interaction => [.. this.flowDefinition]; /// /// The interpretations of a Type with intersectingTypes are asserted to be those in common among the @@ -512,7 +513,11 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -799,7 +804,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. ((SysML2.NET.Core.POCO.Systems.Actions.IActionUsage)this).actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1163,7 +1168,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674961_132339_43177", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: false, defaultValue: null)] [RedefinedByProperty("IConnector.RelatedFeature")] [Implements(implementation: "IRelationship.RelatedElement")] - public List relatedElement => this.ComputeRelatedElement(); + List Root.Elements.IRelationship.relatedElement => [.. this.relatedFeature]; /// /// The Features that are related by this Connector considered as a Relationship and that restrict the @@ -1191,7 +1196,11 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.SourceFeature")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.sourceFeature != null ? [this.sourceFeature] : []; + set { } + } /// /// The source relatedFeature for this Connector. It is the first relatedFeature. @@ -1217,7 +1226,11 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IConnector.TargetFeature")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => [.. this.targetFeature]; + set { } + } /// /// The target relatedFeatures for this Connector. This includes all the relatedFeatures other than the @@ -1255,7 +1268,7 @@ public partial class SuccessionFlowUsage : ISuccessionFlowUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IConnector.Association")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Kernel.Connectors.IConnector)this).association]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/TerminateActionUsage.cs b/SysML2.NET/Core/AutoGenPoco/TerminateActionUsage.cs index 2b4aa9f7..f542f7b2 100644 --- a/SysML2.NET/Core/AutoGenPoco/TerminateActionUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/TerminateActionUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -105,7 +106,7 @@ public partial class TerminateActionUsage : ITerminateActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -155,7 +156,7 @@ public partial class TerminateActionUsage : ITerminateActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -177,7 +178,7 @@ public partial class TerminateActionUsage : ITerminateActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -446,7 +447,11 @@ public partial class TerminateActionUsage : ITerminateActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -733,7 +738,7 @@ public partial class TerminateActionUsage : ITerminateActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1095,7 +1100,7 @@ public partial class TerminateActionUsage : ITerminateActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/TextualRepresentation.cs b/SysML2.NET/Core/AutoGenPoco/TextualRepresentation.cs index 02996dd2..0a6ca061 100644 --- a/SysML2.NET/Core/AutoGenPoco/TextualRepresentation.cs +++ b/SysML2.NET/Core/AutoGenPoco/TextualRepresentation.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Root.Annotations using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Elements; using SysML2.NET.Core.POCO.Root.Namespaces; @@ -84,7 +85,7 @@ public partial class TextualRepresentation : ITextualRepresentation [Property(xmiId: "_19_0_2_12e503d9_1594145755058_99428_86", aggregation: AggregationKind.None, lowerValue: 1, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("ITextualRepresentation.RepresentedElement")] [Implements(implementation: "IAnnotatingElement.AnnotatedElement")] - public List annotatedElement => this.ComputeAnnotatedElement(); + List IAnnotatingElement.annotatedElement => this.representedElement != null ? [this.representedElement] : []; /// /// The Annotations that relate this AnnotatingElement to its annotatedElements. This includes the diff --git a/SysML2.NET/Core/AutoGenPoco/TransitionFeatureMembership.cs b/SysML2.NET/Core/AutoGenPoco/TransitionFeatureMembership.cs index 2c96638e..80ecdc97 100644 --- a/SysML2.NET/Core/AutoGenPoco/TransitionFeatureMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/TransitionFeatureMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.States using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.Systems.States; @@ -135,7 +136,11 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -143,7 +148,7 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -151,7 +156,11 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -162,7 +171,7 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -170,7 +179,11 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -209,7 +222,7 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -227,7 +240,7 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("ITransitionFeatureMembership.TransitionFeature")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => this.transitionFeature; /// /// The name of the ownedMemberElement. @@ -349,7 +362,11 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -358,7 +375,17 @@ public partial class TransitionFeatureMembership : ITransitionFeatureMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/TransitionUsage.cs b/SysML2.NET/Core/AutoGenPoco/TransitionUsage.cs index 173c8d82..6da65fbb 100644 --- a/SysML2.NET/Core/AutoGenPoco/TransitionUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/TransitionUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.States using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -107,7 +108,7 @@ public partial class TransitionUsage : ITransitionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -157,7 +158,7 @@ public partial class TransitionUsage : ITransitionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -179,7 +180,7 @@ public partial class TransitionUsage : ITransitionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -468,7 +469,11 @@ public partial class TransitionUsage : ITransitionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -755,7 +760,7 @@ public partial class TransitionUsage : ITransitionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1144,7 +1149,7 @@ public partial class TransitionUsage : ITransitionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/TriggerInvocationExpression.cs b/SysML2.NET/Core/AutoGenPoco/TriggerInvocationExpression.cs index 822eb289..8dfd6773 100644 --- a/SysML2.NET/Core/AutoGenPoco/TriggerInvocationExpression.cs +++ b/SysML2.NET/Core/AutoGenPoco/TriggerInvocationExpression.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Actions; @@ -79,7 +80,7 @@ public partial class TriggerInvocationExpression : ITriggerInvocationExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => this.function != null ? [this.function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -140,7 +141,7 @@ public partial class TriggerInvocationExpression : ITriggerInvocationExpression [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// Indicates how values of this Feature are determined or used (as specified for the diff --git a/SysML2.NET/Core/AutoGenPoco/Type.cs b/SysML2.NET/Core/AutoGenPoco/Type.cs index f66406b3..2c9094b2 100644 --- a/SysML2.NET/Core/AutoGenPoco/Type.cs +++ b/SysML2.NET/Core/AutoGenPoco/Type.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Types using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Features; using SysML2.NET.Core.POCO.Root.Annotations; diff --git a/SysML2.NET/Core/AutoGenPoco/TypeFeaturing.cs b/SysML2.NET/Core/AutoGenPoco/TypeFeaturing.cs index 64cf6e85..677dd7d8 100644 --- a/SysML2.NET/Core/AutoGenPoco/TypeFeaturing.cs +++ b/SysML2.NET/Core/AutoGenPoco/TypeFeaturing.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Features using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Types; using SysML2.NET.Core.POCO.Root.Annotations; @@ -264,7 +265,17 @@ public partial class TypeFeaturing : ITypeFeaturing [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ITypeFeaturing.FeatureOfType")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.FeatureOfType != null ? [this.FeatureOfType] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.FeatureOfType = firstValue; + } + } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -273,7 +284,17 @@ public partial class TypeFeaturing : ITypeFeaturing [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("ITypeFeaturing.FeaturingType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.FeaturingType != null ? [this.FeaturingType] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.FeaturingType = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/Unioning.cs b/SysML2.NET/Core/AutoGenPoco/Unioning.cs index de05ccc5..9dd73b10 100644 --- a/SysML2.NET/Core/AutoGenPoco/Unioning.cs +++ b/SysML2.NET/Core/AutoGenPoco/Unioning.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Core.Types using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Root.Annotations; using SysML2.NET.Core.POCO.Root.Elements; @@ -237,7 +238,11 @@ public partial class Unioning : IUnioning [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IUnioning.TypeUnioned")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.typeUnioned != null ? [this.typeUnioned] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -246,7 +251,17 @@ public partial class Unioning : IUnioning [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IUnioning.UnioningType")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => this.UnioningType != null ? [this.UnioningType] : []; + set + { + if (value.OfType().FirstOrDefault() is { } firstValue) + { + this.UnioningType = firstValue; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/Usage.cs b/SysML2.NET/Core/AutoGenPoco/Usage.cs index cc2aa686..61cda7ef 100644 --- a/SysML2.NET/Core/AutoGenPoco/Usage.cs +++ b/SysML2.NET/Core/AutoGenPoco/Usage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.DefinitionAndUsage using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.POCO.Core.Classifiers; @@ -406,7 +407,11 @@ public partial class Usage : IUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1018,7 +1023,7 @@ public partial class Usage : IUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. this.definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/UseCaseDefinition.cs b/SysML2.NET/Core/AutoGenPoco/UseCaseDefinition.cs index b6334539..cb43371f 100644 --- a/SysML2.NET/Core/AutoGenPoco/UseCaseDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/UseCaseDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.UseCases using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -147,7 +148,7 @@ public partial class UseCaseDefinition : IUseCaseDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenPoco/UseCaseUsage.cs b/SysML2.NET/Core/AutoGenPoco/UseCaseUsage.cs index edf27e1e..c5842f66 100644 --- a/SysML2.NET/Core/AutoGenPoco/UseCaseUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/UseCaseUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.UseCases using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -86,7 +87,7 @@ public partial class UseCaseUsage : IUseCaseUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition => this.ComputeActionDefinition(); + List Systems.Actions.IActionUsage.actionDefinition => ((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition != null ? [((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition] : []; /// /// The parameters of this CaseUsage that represent actors involved in the case. @@ -111,7 +112,7 @@ public partial class UseCaseUsage : IUseCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Function that is the type of this CalculationUsage. Nominally, this would be a @@ -123,7 +124,7 @@ public partial class UseCaseUsage : IUseCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1565500905804_589845_30779")] [RedefinedByProperty("ICaseUsage.CaseDefinition")] [Implements(implementation: "ICalculationUsage.CalculationDefinition")] - public IFunction calculationDefinition => this.ComputeCalculationDefinition(); + IFunction Systems.Calculations.ICalculationUsage.calculationDefinition => ((SysML2.NET.Core.POCO.Systems.Cases.ICaseUsage)this).caseDefinition; /// /// The CaseDefinition that is the type of this CaseUsage. @@ -132,7 +133,7 @@ public partial class UseCaseUsage : IUseCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1588213526305_899324_302")] [RedefinedByProperty("IUseCaseUsage.UseCaseDefinition")] [Implements(implementation: "ICaseUsage.CaseDefinition")] - public ICaseDefinition caseDefinition => this.ComputeCaseDefinition(); + ICaseDefinition Systems.Cases.ICaseUsage.caseDefinition => this.useCaseDefinition; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -182,7 +183,7 @@ public partial class UseCaseUsage : IUseCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -204,7 +205,7 @@ public partial class UseCaseUsage : IUseCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -299,7 +300,7 @@ public partial class UseCaseUsage : IUseCaseUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => ((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -498,7 +499,11 @@ public partial class UseCaseUsage : IUseCaseUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -793,7 +798,7 @@ public partial class UseCaseUsage : IUseCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. ((SysML2.NET.Core.POCO.Systems.Actions.IActionUsage)this).actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1167,7 +1172,7 @@ public partial class UseCaseUsage : IUseCaseUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/VariantMembership.cs b/SysML2.NET/Core/AutoGenPoco/VariantMembership.cs index edbee72d..431dd632 100644 --- a/SysML2.NET/Core/AutoGenPoco/VariantMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/VariantMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.DefinitionAndUsage using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Root.Annotations; @@ -124,7 +125,11 @@ public partial class VariantMembership : IVariantMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -132,7 +137,7 @@ public partial class VariantMembership : IVariantMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -140,7 +145,11 @@ public partial class VariantMembership : IVariantMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -158,7 +167,11 @@ public partial class VariantMembership : IVariantMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -197,7 +210,7 @@ public partial class VariantMembership : IVariantMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IVariantMembership.OwnedVariantUsage")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => this.ownedVariantUsage; /// /// The elementId of the ownedMemberElement. @@ -327,7 +340,11 @@ public partial class VariantMembership : IVariantMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => this.membershipOwningNamespace != null ? [this.membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -336,7 +353,17 @@ public partial class VariantMembership : IVariantMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/VerificationCaseDefinition.cs b/SysML2.NET/Core/AutoGenPoco/VerificationCaseDefinition.cs index 6db65d61..e65236bc 100644 --- a/SysML2.NET/Core/AutoGenPoco/VerificationCaseDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/VerificationCaseDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.VerificationCases using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -146,7 +147,7 @@ public partial class VerificationCaseDefinition : IVerificationCaseDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenPoco/VerificationCaseUsage.cs b/SysML2.NET/Core/AutoGenPoco/VerificationCaseUsage.cs index 5c5b87b9..4ebebc69 100644 --- a/SysML2.NET/Core/AutoGenPoco/VerificationCaseUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/VerificationCaseUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.VerificationCases using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -86,7 +87,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [RedefinedProperty(propertyName: "_19_0_4_12e503d9_1618943843466_158863_236")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IActionUsage.ActionDefinition")] - public List actionDefinition => this.ComputeActionDefinition(); + List Systems.Actions.IActionUsage.actionDefinition => ((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition != null ? [((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition] : []; /// /// The parameters of this CaseUsage that represent actors involved in the case. @@ -111,7 +112,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Function that is the type of this CalculationUsage. Nominally, this would be a @@ -123,7 +124,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1565500905804_589845_30779")] [RedefinedByProperty("ICaseUsage.CaseDefinition")] [Implements(implementation: "ICalculationUsage.CalculationDefinition")] - public IFunction calculationDefinition => this.ComputeCalculationDefinition(); + IFunction Systems.Calculations.ICalculationUsage.calculationDefinition => this.caseDefinition; /// /// The CaseDefinition that is the type of this CaseUsage. @@ -181,7 +182,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -203,7 +204,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -298,7 +299,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("ICalculationUsage.CalculationDefinition")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => ((SysML2.NET.Core.POCO.Systems.Calculations.ICalculationUsage)this).calculationDefinition; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -489,7 +490,11 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -784,7 +789,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. ((SysML2.NET.Core.POCO.Systems.Actions.IActionUsage)this).actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1158,7 +1163,7 @@ public partial class VerificationCaseUsage : IVerificationCaseUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/ViewDefinition.cs b/SysML2.NET/Core/AutoGenPoco/ViewDefinition.cs index c7cc3975..fad01dee 100644 --- a/SysML2.NET/Core/AutoGenPoco/ViewDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/ViewDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Views using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; diff --git a/SysML2.NET/Core/AutoGenPoco/ViewRenderingMembership.cs b/SysML2.NET/Core/AutoGenPoco/ViewRenderingMembership.cs index 3bf18bce..3970e8dd 100644 --- a/SysML2.NET/Core/AutoGenPoco/ViewRenderingMembership.cs +++ b/SysML2.NET/Core/AutoGenPoco/ViewRenderingMembership.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Views using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Root.Namespaces; using SysML2.NET.Core.POCO.Core.Features; @@ -125,7 +126,11 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_138197_43179")] [RedefinedByProperty("IOwningMembership.OwnedMemberElement")] [Implements(implementation: "IMembership.MemberElement")] - public IElement MemberElement { get; set; } + IElement Root.Namespaces.IMembership.MemberElement + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IOwningMembership)this).ownedMemberElement; + set { } + } /// /// The elementId of the memberElement. @@ -133,7 +138,7 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [Property(xmiId: "_19_0_4_12e503d9_1651721199802_246768_242", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberElementId")] [Implements(implementation: "IMembership.MemberElementId")] - public string memberElementId => this.ComputeMemberElementId(); + string Root.Namespaces.IMembership.memberElementId => this.ownedMemberElementId; /// /// The name of the memberElement relative to the membershipOwningNamespace. @@ -141,7 +146,11 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [Property(xmiId: "_18_5_3_12e503d9_1533160674964_35293_43192", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberName")] [Implements(implementation: "IMembership.MemberName")] - public string MemberName { get; set; } + string Root.Namespaces.IMembership.MemberName + { + get => this.ownedMemberName; + set { } + } /// /// The Namespace of which the memberElement becomes a member due to this Membership. @@ -152,7 +161,7 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674971_696758_43228")] [RedefinedByProperty("IFeatureMembership.OwningType")] [Implements(implementation: "IMembership.MembershipOwningNamespace")] - public INamespace membershipOwningNamespace => this.ComputeMembershipOwningNamespace(); + INamespace Root.Namespaces.IMembership.membershipOwningNamespace => this.owningType; /// /// The short name of the memberElement relative to the membershipOwningNamespace. @@ -160,7 +169,11 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [Property(xmiId: "_19_0_4_12e503d9_1651721174176_601088_238", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IOwningMembership.OwnedMemberShortName")] [Implements(implementation: "IMembership.MemberShortName")] - public string MemberShortName { get; set; } + string Root.Namespaces.IMembership.MemberShortName + { + get => this.ownedMemberShortName; + set { } + } /// /// The name to be used for this Element during name resolution within its owningNamespace. This is @@ -199,7 +212,7 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674964_819490_43195")] [RedefinedByProperty("IFeatureMembership.OwnedMemberFeature")] [Implements(implementation: "IOwningMembership.OwnedMemberElement")] - public IElement ownedMemberElement => this.ComputeOwnedMemberElement(); + IElement Root.Namespaces.IOwningMembership.ownedMemberElement => ((SysML2.NET.Core.POCO.Core.Types.IFeatureMembership)this).ownedMemberFeature; /// /// The elementId of the ownedMemberElement. @@ -217,7 +230,7 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674965_501750_43196")] [RedefinedByProperty("IViewRenderingMembership.OwnedRendering")] [Implements(implementation: "IFeatureMembership.OwnedMemberFeature")] - public IFeature ownedMemberFeature => this.ComputeOwnedMemberFeature(); + IFeature Core.Types.IFeatureMembership.ownedMemberFeature => this.ownedRendering; /// /// The name of the ownedMemberElement. @@ -357,7 +370,11 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MembershipOwningNamespace")] [Implements(implementation: "IRelationship.Source")] - public List Source { get; set; } = []; + List Root.Elements.IRelationship.Source + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).membershipOwningNamespace] : []; + set { } + } /// /// The relatedElements to which this Relationship is considered to be directed. @@ -366,7 +383,17 @@ public partial class ViewRenderingMembership : IViewRenderingMembership [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674961_132339_43177")] [RedefinedByProperty("IMembership.MemberElement")] [Implements(implementation: "IRelationship.Target")] - public List Target { get; set; } = []; + List Root.Elements.IRelationship.Target + { + get => ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement != null ? [((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement] : []; + set + { + if (value.Count != 0) + { + ((SysML2.NET.Core.POCO.Root.Namespaces.IMembership)this).MemberElement = value[0]; + } + } + } /// /// The TextualRepresentations that annotate this Element. diff --git a/SysML2.NET/Core/AutoGenPoco/ViewUsage.cs b/SysML2.NET/Core/AutoGenPoco/ViewUsage.cs index 341d47f3..963c1c49 100644 --- a/SysML2.NET/Core/AutoGenPoco/ViewUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/ViewUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Views using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -133,7 +134,7 @@ public partial class ViewUsage : IViewUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -432,7 +433,11 @@ public partial class ViewUsage : IViewUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1031,7 +1036,7 @@ public partial class ViewUsage : IViewUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1565471361757_649736_20796")] [RedefinedByProperty("IViewUsage.ViewDefinition")] [Implements(implementation: "IPartUsage.PartDefinition")] - public List partDefinition => this.ComputePartDefinition(); + List Systems.Parts.IPartUsage.partDefinition => this.viewDefinition != null ? [this.viewDefinition] : []; /// /// The kind of temporal portion (time slice or snapshot) is represented by this OccurrenceUsage. If @@ -1091,7 +1096,7 @@ public partial class ViewUsage : IViewUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/ViewpointDefinition.cs b/SysML2.NET/Core/AutoGenPoco/ViewpointDefinition.cs index a42fe3be..43abceed 100644 --- a/SysML2.NET/Core/AutoGenPoco/ViewpointDefinition.cs +++ b/SysML2.NET/Core/AutoGenPoco/ViewpointDefinition.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Views using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.POCO.Core.Classifiers; using SysML2.NET.Core.POCO.Core.Features; @@ -116,7 +117,14 @@ public partial class ViewpointDefinition : IViewpointDefinition [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementDefinition.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -138,7 +146,7 @@ public partial class ViewpointDefinition : IViewpointDefinition [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IBehavior.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Definition that are directedFeatures. diff --git a/SysML2.NET/Core/AutoGenPoco/ViewpointUsage.cs b/SysML2.NET/Core/AutoGenPoco/ViewpointUsage.cs index 55857515..9ae756fc 100644 --- a/SysML2.NET/Core/AutoGenPoco/ViewpointUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/ViewpointUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Views using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -109,7 +110,7 @@ public partial class ViewpointUsage : IViewpointUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IExpression.Function")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => ((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function != null ? [((SysML2.NET.Core.POCO.Kernel.Functions.IExpression)this).function] : []; /// /// The Feature that are chained together to determine the values of this Feature, derived from the @@ -132,7 +133,7 @@ public partial class ViewpointUsage : IViewpointUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578025035149_386_969")] [RedefinedByProperty("IRequirementUsage.RequirementDefinition")] [Implements(implementation: "IConstraintUsage.ConstraintDefinition")] - public IPredicate constraintDefinition => this.ComputeConstraintDefinition(); + IPredicate Systems.Constraints.IConstraintUsage.constraintDefinition => ((SysML2.NET.Core.POCO.Systems.Requirements.IRequirementUsage)this).requirementDefinition; /// /// The second chainingFeature of the crossedFeature of the ownedCrossSubsetting of this Feature, if it @@ -160,7 +161,14 @@ public partial class ViewpointUsage : IViewpointUsage [Property(xmiId: "_19_0_2_12e503d9_1594160442439_915308_4153", aggregation: AggregationKind.None, lowerValue: 0, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IRequirementUsage.ReqId")] [Implements(implementation: "IElement.DeclaredShortName")] - public string DeclaredShortName { get; set; } + string Root.Elements.IElement.DeclaredShortName + { + get => this.ReqId; + set + { + this.ReqId = value; + } + } /// /// The Classifiers that are the types of this Usage. Nominally, these are Definitions, but other kinds @@ -171,7 +179,7 @@ public partial class ViewpointUsage : IViewpointUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. this.occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -193,7 +201,7 @@ public partial class ViewpointUsage : IViewpointUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -297,7 +305,7 @@ public partial class ViewpointUsage : IViewpointUsage [RedefinedProperty(propertyName: "_18_5_3_b9102da_1536346315176_954314_17388")] [RedefinedByProperty("IBooleanExpression.Predicate")] [Implements(implementation: "IExpression.Function")] - public IFunction function => this.ComputeFunction(); + IFunction Kernel.Functions.IExpression.function => ((SysML2.NET.Core.POCO.Kernel.Functions.IBooleanExpression)this).predicate; /// /// The Memberships in this Namespace that result from the ownedImports of this Namespace. @@ -488,7 +496,11 @@ public partial class ViewpointUsage : IViewpointUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -1095,7 +1107,7 @@ public partial class ViewpointUsage : IViewpointUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1543948477241_299049_20934")] [RedefinedByProperty("IConstraintUsage.ConstraintDefinition")] [Implements(implementation: "IBooleanExpression.Predicate")] - public IPredicate predicate => this.ComputePredicate(); + IPredicate Kernel.Functions.IBooleanExpression.predicate => ((SysML2.NET.Core.POCO.Systems.Constraints.IConstraintUsage)this).constraintDefinition; /// /// The full ownership-qualified name of this Element, represented in a form that is valid according to @@ -1136,7 +1148,7 @@ public partial class ViewpointUsage : IViewpointUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1578067546711_751168_1745")] [RedefinedByProperty("IViewpointUsage.ViewpointDefinition")] [Implements(implementation: "IRequirementUsage.RequirementDefinition")] - public IRequirementDefinition requirementDefinition => this.ComputeRequirementDefinition(); + IRequirementDefinition Systems.Requirements.IRequirementUsage.requirementDefinition => this.viewpointDefinition; /// /// An output parameter of the Expression whose value is the result of the Expression. The result of an @@ -1203,7 +1215,7 @@ public partial class ViewpointUsage : IViewpointUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/Core/AutoGenPoco/WhileLoopActionUsage.cs b/SysML2.NET/Core/AutoGenPoco/WhileLoopActionUsage.cs index 81af9f40..23f06ba4 100644 --- a/SysML2.NET/Core/AutoGenPoco/WhileLoopActionUsage.cs +++ b/SysML2.NET/Core/AutoGenPoco/WhileLoopActionUsage.cs @@ -27,6 +27,7 @@ namespace SysML2.NET.Core.POCO.Systems.Actions using System; using System.CodeDom.Compiler; using System.Collections.Generic; + using System.Linq; using SysML2.NET.Core.Core.Types; using SysML2.NET.Core.Systems.Occurrences; @@ -105,7 +106,7 @@ public partial class WhileLoopActionUsage : IWhileLoopActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IStep.Behavior")] - public List behavior => this.ComputeBehavior(); + List Kernel.Behaviors.IStep.behavior => [.. this.actionDefinition]; /// /// The ActionUsage to be performed repeatedly by the LoopActionUsage. It is the second parameter of the @@ -163,7 +164,7 @@ public partial class WhileLoopActionUsage : IWhileLoopActionUsage [RedefinedProperty(propertyName: "_18_5_3_12e503d9_1533160674969_376003_43216")] [RedefinedByProperty("IOccurrenceUsage.OccurrenceDefinition")] [Implements(implementation: "IUsage.Definition")] - public List definition => this.ComputeDefinition(); + List Systems.DefinitionAndUsage.IUsage.definition => [.. ((SysML2.NET.Core.POCO.Systems.Occurrences.IOccurrenceUsage)this).occurrenceDefinition]; /// /// The interpretations of a Type with differencingTypes are asserted to be those of the first of those @@ -185,7 +186,7 @@ public partial class WhileLoopActionUsage : IWhileLoopActionUsage [SubsettedProperty(propertyName: "_18_5_3_12e503d9_1533160674959_326391_43166")] [RedefinedByProperty("IStep.Parameter")] [Implements(implementation: "IType.DirectedFeature")] - public List directedFeature => this.ComputeDirectedFeature(); + List Core.Types.IType.directedFeature => [.. this.parameter]; /// /// The usages of this Usage that are directedFeatures. @@ -454,7 +455,11 @@ public partial class WhileLoopActionUsage : IWhileLoopActionUsage [Property(xmiId: "_2022x_2_12e503d9_1725998273002_23711_212", aggregation: AggregationKind.None, lowerValue: 1, upperValue: 1, isOrdered: false, isReadOnly: false, isDerived: false, isDerivedUnion: false, isUnique: true, defaultValue: "false")] [RedefinedByProperty("IUsage.MayTimeVary")] [Implements(implementation: "IFeature.IsVariable")] - public bool IsVariable { get; set; } + bool Core.Features.IFeature.IsVariable + { + get => this.mayTimeVary; + set { } + } /// /// Whether this Usage is for a variation point or not. If true, then all the memberships of the Usage @@ -741,7 +746,7 @@ public partial class WhileLoopActionUsage : IWhileLoopActionUsage [RedefinedProperty(propertyName: "_19_0_2_12e503d9_1591477641252_179221_958")] [RedefinedByProperty("IActionUsage.ActionDefinition")] [Implements(implementation: "IOccurrenceUsage.OccurrenceDefinition")] - public List occurrenceDefinition => this.ComputeOccurrenceDefinition(); + List Systems.Occurrences.IOccurrenceUsage.occurrenceDefinition => [.. this.actionDefinition]; /// /// All features related to this Type by FeatureMemberships that have direction out or inout. @@ -1095,7 +1100,7 @@ public partial class WhileLoopActionUsage : IWhileLoopActionUsage [Property(xmiId: "_18_5_3_12e503d9_1533160674969_376003_43216", aggregation: AggregationKind.None, lowerValue: 0, upperValue: int.MaxValue, isOrdered: true, isReadOnly: false, isDerived: true, isDerivedUnion: false, isUnique: true, defaultValue: null)] [RedefinedByProperty("IUsage.Definition")] [Implements(implementation: "IFeature.Type")] - public List type => this.ComputeType(); + List Core.Features.IFeature.type => [.. ((SysML2.NET.Core.POCO.Systems.DefinitionAndUsage.IUsage)this).definition]; /// /// The interpretations of a Type with unioningTypes are asserted to be the same as those of all the diff --git a/SysML2.NET/SysML2.NET.csproj b/SysML2.NET/SysML2.NET.csproj index 574d9e2a..e6a887c0 100644 --- a/SysML2.NET/SysML2.NET.csproj +++ b/SysML2.NET/SysML2.NET.csproj @@ -40,5 +40,6 @@ + \ No newline at end of file