armodel 1.6.2__py3-none-any.whl → 1.6.4__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- armodel/cli/arxml_dump_cli.py +13 -10
- armodel/cli/arxml_format_cli.py +1 -2
- armodel/cli/connector2xlsx_cli.py +2 -3
- armodel/cli/connector_update_cli.py +2 -5
- armodel/cli/memory_section_cli.py +2 -2
- armodel/cli/swc_list_cli.py +2 -3
- armodel/cli/system_signal_cli.py +2 -2
- armodel/lib/sw_component.py +3 -3
- armodel/lib/system_signal.py +3 -5
- armodel/models/{m2/autosar_templates/autosar_top_level_structure.py → M2/AUTOSARTemplates/AutosarTopLevelStructure.py} +5 -7
- armodel/models/{bsw_module_template.py → M2/AUTOSARTemplates/BswModuleTemplate/BswBehavior.py} +113 -140
- armodel/models/M2/AUTOSARTemplates/BswModuleTemplate/BswImplementation.py +60 -0
- armodel/models/M2/AUTOSARTemplates/BswModuleTemplate/BswInterfaces.py +52 -0
- armodel/models/M2/AUTOSARTemplates/BswModuleTemplate/BswOverview.py +77 -0
- armodel/models/M2/AUTOSARTemplates/BswModuleTemplate/__init__.py +4 -0
- armodel/models/M2/AUTOSARTemplates/CommonStructure/Implementation.py +238 -0
- armodel/models/{m2/autosar_templates/common_structure/implementation_data_types.py → M2/AUTOSARTemplates/CommonStructure/ImplementationDataTypes.py} +7 -6
- armodel/models/M2/AUTOSARTemplates/CommonStructure/InternalBehavior.py +119 -0
- armodel/models/M2/AUTOSARTemplates/CommonStructure/ModeDeclaration.py +96 -0
- armodel/models/M2/AUTOSARTemplates/CommonStructure/ResourceConsumption/MemorySectionUsage.py +69 -0
- armodel/models/M2/AUTOSARTemplates/CommonStructure/ResourceConsumption/__init__.py +20 -0
- armodel/models/{service_needs.py → M2/AUTOSARTemplates/CommonStructure/ServiceNeeds.py} +13 -9
- armodel/models/M2/AUTOSARTemplates/CommonStructure/SwcBswMapping.py +35 -0
- armodel/models/M2/AUTOSARTemplates/CommonStructure/SwcInternalBehavior/ModeDeclarationGroup.py +24 -0
- armodel/models/M2/AUTOSARTemplates/CommonStructure/Timing/TimingConstraint/ExecutionOrderConstraint.py +45 -0
- armodel/models/M2/AUTOSARTemplates/CommonStructure/Timing/TimingConstraint/TimingConstraint.py +24 -0
- armodel/models/M2/AUTOSARTemplates/CommonStructure/Timing/TimingConstraint/TimingExtensions.py +33 -0
- armodel/models/M2/AUTOSARTemplates/CommonStructure/TriggerDeclaration.py +9 -0
- armodel/models/{m2/autosar_templates/common_structure → M2/AUTOSARTemplates/CommonStructure}/__init__.py +4 -3
- armodel/models/{m2/autosar_templates/ecuc_description_template.py → M2/AUTOSARTemplates/ECUCDescriptionTemplate.py} +6 -7
- armodel/models/{m2/autosar_templates/generic_structure/abstract_structure.py → M2/AUTOSARTemplates/GenericStructure/AbstractStructure.py} +25 -5
- armodel/models/{m2/autosar_templates/generic_structure/ar_package.py → M2/AUTOSARTemplates/GenericStructure/GeneralTemplateClasses/ARPackage.py} +41 -29
- armodel/models/M2/AUTOSARTemplates/GenericStructure/GeneralTemplateClasses/ArObject.py +16 -0
- armodel/models/M2/AUTOSARTemplates/GenericStructure/GeneralTemplateClasses/ElementCollection.py +1 -0
- armodel/models/M2/AUTOSARTemplates/GenericStructure/GeneralTemplateClasses/EngineeringObject.py +52 -0
- armodel/models/{general_structure.py → M2/AUTOSARTemplates/GenericStructure/GeneralTemplateClasses/Identifiable.py} +42 -159
- armodel/models/{ar_object.py → M2/AUTOSARTemplates/GenericStructure/GeneralTemplateClasses/PrimitiveTypes.py} +179 -71
- armodel/models/M2/AUTOSARTemplates/GenericStructure/__init__.py +1 -0
- armodel/models/{m2/autosar_templates/sw_component_template/communication.py → M2/AUTOSARTemplates/SWComponentTemplate/Communication.py} +22 -5
- armodel/models/{m2/autosar_templates/sw_component_template/components/instance_refs.py → M2/AUTOSARTemplates/SWComponentTemplate/Components/InstanceRefs.py} +2 -4
- armodel/models/{m2/autosar_templates/sw_component_template/components → M2/AUTOSARTemplates/SWComponentTemplate/Components}/__init__.py +114 -10
- armodel/models/{m2/autosar_templates/sw_component_template/composition/instance_refs.py → M2/AUTOSARTemplates/SWComponentTemplate/Composition/InstanceRefs.py} +2 -5
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/Composition/__init__.py +96 -0
- armodel/models/{m2/autosar_templates/sw_component_template/data_type/data_prototypes.py → M2/AUTOSARTemplates/SWComponentTemplate/Datatype/DataPrototypes.py} +24 -8
- armodel/models/{datatype.py → M2/AUTOSARTemplates/SWComponentTemplate/Datatype/Datatypes.py} +16 -73
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/EndToEndProtection.py +177 -0
- armodel/models/{m2/autosar_templates/sw_component_template/port_interface/instance_refs.py → M2/AUTOSARTemplates/SWComponentTemplate/PortInterface/InstanceRefs.py} +2 -2
- armodel/models/{m2/autosar_templates/sw_component_template/port_interface → M2/AUTOSARTemplates/SWComponentTemplate/PortInterface}/__init__.py +10 -6
- armodel/models/{rpt_scenario.py → M2/AUTOSARTemplates/SWComponentTemplate/RPTScenario.py} +4 -6
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcImplementation.py +34 -0
- armodel/models/{m2/autosar_templates/sw_component_template/swc_internal_behavior/access_count.py → M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/AccessCount.py} +2 -2
- armodel/models/{m2/autosar_templates/sw_component_template/swc_internal_behavior/data_elements.py → M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/DataElements.py} +7 -5
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/IncludedDataTypes.py +24 -0
- armodel/models/{m2/autosar_templates/sw_component_template/swc_internal_behavior/instance_refs_usage.py → M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/InstanceRefsUsage.py} +3 -3
- armodel/models/{m2/autosar_templates/sw_component_template/swc_internal_behavior/mode_declaration_group.py → M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/ModeDeclarationGroup.py} +4 -4
- armodel/models/{per_instance_memory.py → M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/PerInstanceMemory.py} +5 -6
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/PortAPIOptions.py +86 -0
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/RTEEvents.py +174 -0
- armodel/models/{m2/autosar_templates/sw_component_template/swc_internal_behavior/server_call.py → M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/ServerCall.py} +3 -4
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/ServiceMapping.py +57 -0
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/Trigger.py +8 -0
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/__init__.py +358 -0
- armodel/models/{m2/autosar_templates/system_template/data_mapping.py → M2/AUTOSARTemplates/SystemTemplate/DataMapping.py} +2 -3
- armodel/models/{fibex/can_communication.py → M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Can/CanCommunication.py} +3 -3
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Ethernet/EthernetFrame.py +14 -0
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Ethernet/ServiceInstances.py +116 -0
- armodel/models/{fibex/lin_communication.py → M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Lin/LinCommunication.py} +5 -2
- armodel/models/{fibex/fibex_4_multiplatform.py → M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Multiplatform.py} +5 -4
- armodel/models/{fibex/fibex_core/core_communication.py → M2/AUTOSARTemplates/SystemTemplate/Fibex/FibexCore/CoreCommunication.py} +4 -6
- armodel/models/{fibex/fibex_core/core_topology.py → M2/AUTOSARTemplates/SystemTemplate/Fibex/FibexCore/CoreTopology.py} +6 -7
- armodel/models/{m2/autosar_templates/system_template/instance_refs.py → M2/AUTOSARTemplates/SystemTemplate/InstanceRefs.py} +2 -2
- armodel/models/{m2/autosar_templates/system_template/network_management.py → M2/AUTOSARTemplates/SystemTemplate/NetworkManagement.py} +5 -6
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/TransportProtocols.py +6 -0
- armodel/models/{m2/autosar_templates/system_template → M2/AUTOSARTemplates/SystemTemplate}/__init__.py +3 -4
- armodel/models/M2/MSR/AsamHdo/AdminData.py +18 -0
- armodel/models/M2/MSR/AsamHdo/BaseTypes.py +77 -0
- armodel/models/{m2_msr.py → M2/MSR/AsamHdo/ComputationMethod.py} +43 -28
- armodel/models/{global_constraints.py → M2/MSR/AsamHdo/Constraints/GlobalConstraints.py} +6 -4
- armodel/models/M2/MSR/AsamHdo/SpecialData.py +60 -0
- armodel/models/{m2/msr/asam_hdo/units.py → M2/MSR/AsamHdo/Units.py} +3 -3
- armodel/models/M2/MSR/CalibrationData/CalibrationValue.py +26 -0
- armodel/models/{m2/msr/data_dictionary/auxillary_objects.py → M2/MSR/DataDictionary/AuxillaryObjects.py} +3 -4
- armodel/models/M2/MSR/DataDictionary/Axis.py +145 -0
- armodel/models/M2/MSR/DataDictionary/CalibrationParameter.py +37 -0
- armodel/models/{m2/msr/data_dictionary/data_def_properties.py → M2/MSR/DataDictionary/DataDefProperties.py} +19 -10
- armodel/models/{record_layout.py → M2/MSR/DataDictionary/RecordLayout.py} +26 -25
- armodel/models/{annotation.py → M2/MSR/Documentation/Annotation.py} +8 -10
- armodel/models/{m2/msr/documentation/block_elements.py → M2/MSR/Documentation/BlockElements.py} +2 -2
- armodel/models/M2/MSR/Documentation/TextModel/LanguageDataModel.py +16 -0
- armodel/models/{multilanguage_data.py → M2/MSR/Documentation/TextModel/MultilanguageData.py} +20 -32
- armodel/models/M2/MSR/Documentation/TextModel/__init__.py +0 -0
- armodel/models/M2/MSR/Documentation/__init__.py +3 -0
- armodel/models/M2/MSR/__init__.py +1 -0
- armodel/models/M2/__init__.py +0 -0
- armodel/models/__init__.py +50 -24
- armodel/parser/abstract_arxml_parser.py +8 -4
- armodel/parser/arxml_parser.py +117 -90
- armodel/parser/connector_xlsx_parser.py +5 -3
- armodel/parser/file_parser.py +2 -1
- armodel/report/connector_xls_report.py +3 -2
- armodel/tests/test_armodel/models/test_ar_object.py +2 -3
- armodel/tests/test_armodel/models/test_ar_package.py +21 -9
- armodel/tests/test_armodel/models/test_ar_ref.py +7 -5
- armodel/tests/test_armodel/models/test_bsw_module_template.py +5 -1
- armodel/tests/test_armodel/models/test_common_structure.py +11 -5
- armodel/tests/test_armodel/models/test_data_dictionary.py +2 -2
- armodel/tests/test_armodel/models/test_data_prototype.py +8 -4
- armodel/tests/test_armodel/models/test_datatype.py +28 -14
- armodel/tests/test_armodel/models/test_general_structure.py +12 -2
- armodel/tests/test_armodel/models/test_implementation.py +3 -2
- armodel/tests/test_armodel/models/test_m2_msr.py +4 -2
- armodel/tests/test_armodel/models/test_port_interface.py +21 -11
- armodel/tests/test_armodel/models/test_port_prototype.py +1 -1
- armodel/tests/test_armodel/parser/test_parse_bswmd.py +13 -13
- armodel/tests/test_armodel/parser/test_sw_components.py +2 -2
- armodel/tests/test_armodel/parser/test_system.py +30 -0
- armodel/writer/abstract_arxml_writer.py +5 -2
- armodel/writer/arxml_writer.py +136 -91
- {armodel-1.6.2.dist-info → armodel-1.6.4.dist-info}/METADATA +16 -1
- armodel-1.6.4.dist-info/RECORD +156 -0
- armodel/lib/data_analyzer.py +0 -34
- armodel/models/ar_package.py +0 -641
- armodel/models/ar_ref.py +0 -25
- armodel/models/calibration.py +0 -119
- armodel/models/common_structure.py +0 -272
- armodel/models/communication.py +0 -17
- armodel/models/data_def_properties.py +0 -16
- armodel/models/data_dictionary.py +0 -59
- armodel/models/data_prototype.py +0 -103
- armodel/models/end_to_end_protection.py +0 -67
- armodel/models/fibex/fibex_core.py +0 -341
- armodel/models/fibex/lin_topology.py +0 -7
- armodel/models/implementation.py +0 -135
- armodel/models/internal_behavior.py +0 -63
- armodel/models/m2/autosar_templates/common_structure/implementation.py +0 -21
- armodel/models/m2/autosar_templates/sw_component_template/composition/__init__.py +0 -154
- armodel/models/m2/autosar_templates/sw_component_template/port_interface.py +0 -236
- armodel/models/m2/autosar_templates/sw_component_template/swc_internal_behavior/__init__.py +0 -203
- armodel/models/m2/autosar_templates/sw_component_template/swc_internal_behavior/trigger.py +0 -10
- armodel/models/m2/autosar_templates/system_template/transport_protocols.py +0 -7
- armodel/models/mode_declaration.py +0 -8
- armodel/models/port_interface.py +0 -165
- armodel/models/port_prototype.py +0 -6
- armodel/models/service_mapping.py +0 -11
- armodel/models/sw_component.py +0 -385
- armodel/models/system_template/network_management.py +0 -7
- armodel/models/system_template/transport_protocols.py +0 -7
- armodel/models/timing.py +0 -91
- armodel/models/unit.py +0 -14
- armodel-1.6.2.dist-info/RECORD +0 -142
- /armodel/models/{fibex → M2/AUTOSARTemplates/CommonStructure/SwcInternalBehavior}/__init__.py +0 -0
- /armodel/models/{fibex/fibex_4_can → M2/AUTOSARTemplates/CommonStructure/Timing/TimingConstraint}/__init__.py +0 -0
- /armodel/models/{fibex/fibex_4_lin → M2/AUTOSARTemplates/CommonStructure/Timing}/__init__.py +0 -0
- /armodel/models/{fibex/fibex_core → M2/AUTOSARTemplates/GenericStructure/GeneralTemplateClasses}/__init__.py +0 -0
- /armodel/models/{m2 → M2/AUTOSARTemplates/SWComponentTemplate/Datatype}/__init__.py +0 -0
- /armodel/models/{m2/autosar_templates → M2/AUTOSARTemplates/SWComponentTemplate}/__init__.py +0 -0
- /armodel/models/{m2/autosar_templates/generic_structure → M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Can}/__init__.py +0 -0
- /armodel/models/{m2/autosar_templates/sw_component_template → M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Ethernet}/__init__.py +0 -0
- /armodel/models/{m2/autosar_templates/sw_component_template/data_type → M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Lin}/__init__.py +0 -0
- /armodel/models/{m2/msr → M2/AUTOSARTemplates/SystemTemplate/Fibex/FibexCore}/__init__.py +0 -0
- /armodel/models/{m2/msr/asam_hdo → M2/AUTOSARTemplates/SystemTemplate/Fibex}/__init__.py +0 -0
- /armodel/models/{m2/msr/data_dictionary → M2/AUTOSARTemplates}/__init__.py +0 -0
- /armodel/models/{m2/msr/documentation → M2/MSR/AsamHdo/Constraints}/__init__.py +0 -0
- /armodel/models/{system_template → M2/MSR/AsamHdo}/__init__.py +0 -0
- /armodel/models/{ecuc_parameter_def_template.py → M2/MSR/CalibrationData/__init__.py} +0 -0
- /armodel/models/{m2/autosar_templates/common_structure/constants.py → M2/MSR/DataDictionary/__init__.py} +0 -0
- {armodel-1.6.2.dist-info → armodel-1.6.4.dist-info}/LICENSE +0 -0
- {armodel-1.6.2.dist-info → armodel-1.6.4.dist-info}/WHEEL +0 -0
- {armodel-1.6.2.dist-info → armodel-1.6.4.dist-info}/entry_points.txt +0 -0
- {armodel-1.6.2.dist-info → armodel-1.6.4.dist-info}/top_level.txt +0 -0
armodel/parser/arxml_parser.py
CHANGED
|
@@ -2,73 +2,93 @@ from typing import List
|
|
|
2
2
|
import xml.etree.ElementTree as ET
|
|
3
3
|
import os
|
|
4
4
|
|
|
5
|
-
from ..models.
|
|
6
|
-
|
|
7
|
-
from ..models.
|
|
8
|
-
from ..models.
|
|
9
|
-
from ..models.
|
|
10
|
-
from ..models.
|
|
11
|
-
from ..models.
|
|
12
|
-
from ..models.
|
|
13
|
-
from ..models.
|
|
14
|
-
from ..models.
|
|
15
|
-
from ..models.
|
|
16
|
-
from ..models.
|
|
17
|
-
from ..models.
|
|
18
|
-
from ..models.
|
|
19
|
-
from ..models.
|
|
20
|
-
|
|
21
|
-
from ..models.
|
|
22
|
-
from ..models.
|
|
23
|
-
|
|
24
|
-
from ..models.
|
|
25
|
-
from ..models.
|
|
26
|
-
from ..models.
|
|
27
|
-
from ..models.
|
|
28
|
-
from ..models.
|
|
29
|
-
from ..models.
|
|
30
|
-
from ..models.
|
|
31
|
-
from ..models.
|
|
32
|
-
from ..models.
|
|
33
|
-
from ..models.
|
|
34
|
-
from ..models.
|
|
35
|
-
from ..models.
|
|
36
|
-
from ..models.
|
|
37
|
-
from ..models.
|
|
38
|
-
from ..models.
|
|
39
|
-
from ..models.
|
|
40
|
-
from ..models.
|
|
41
|
-
from ..models.
|
|
42
|
-
from ..models.
|
|
43
|
-
from ..models.
|
|
44
|
-
from ..models.
|
|
45
|
-
from ..models.
|
|
46
|
-
from ..models.
|
|
47
|
-
from ..models.
|
|
48
|
-
from ..models.
|
|
49
|
-
from ..models.
|
|
50
|
-
from ..models.
|
|
51
|
-
from ..models.
|
|
52
|
-
from ..models.
|
|
53
|
-
from ..models.
|
|
54
|
-
from ..models.
|
|
55
|
-
from ..models.
|
|
56
|
-
from ..models.
|
|
57
|
-
from ..models.
|
|
58
|
-
|
|
59
|
-
from ..models import
|
|
60
|
-
from ..models import
|
|
61
|
-
|
|
62
|
-
from ..models import
|
|
63
|
-
from ..models import
|
|
64
|
-
from ..models import
|
|
65
|
-
from ..models import
|
|
66
|
-
from ..models import
|
|
67
|
-
from ..models import
|
|
68
|
-
from ..models import
|
|
69
|
-
from ..models import
|
|
70
|
-
from ..models import
|
|
71
|
-
from ..models import
|
|
5
|
+
from ..models.M2.MSR.AsamHdo.Constraints.GlobalConstraints import DataConstrRule, InternalConstrs, PhysConstrs
|
|
6
|
+
from ..models.M2.MSR.AsamHdo.BaseTypes import BaseTypeDirectDefinition
|
|
7
|
+
from ..models.M2.MSR.AsamHdo.SpecialData import Sdg
|
|
8
|
+
from ..models.M2.MSR.AsamHdo.AdminData import AdminData
|
|
9
|
+
from ..models.M2.MSR.AsamHdo.ComputationMethod import Compu, CompuConst, CompuConstTextContent, CompuNominatorDenominator, CompuRationalCoeffs, CompuScale, CompuScaleConstantContents, CompuScaleRationalFormula, CompuScales
|
|
10
|
+
from ..models.M2.MSR.CalibrationData.CalibrationValue import SwValues
|
|
11
|
+
from ..models.M2.MSR.DataDictionary.DataDefProperties import SwDataDefProps, SwPointerTargetProps
|
|
12
|
+
from ..models.M2.MSR.DataDictionary.CalibrationParameter import SwCalprmAxis
|
|
13
|
+
from ..models.M2.MSR.DataDictionary.Axis import SwAxisGrouped, SwAxisIndividual
|
|
14
|
+
from ..models.M2.MSR.DataDictionary.RecordLayout import SwRecordLayoutGroupContent, SwRecordLayoutV
|
|
15
|
+
from ..models.M2.MSR.DataDictionary.DataDefProperties import ValueList
|
|
16
|
+
from ..models.M2.MSR.DataDictionary.RecordLayout import SwRecordLayoutGroup
|
|
17
|
+
from ..models.M2.MSR.DataDictionary.CalibrationParameter import SwCalprmAxisSet
|
|
18
|
+
from ..models.M2.MSR.Documentation.TextModel.LanguageDataModel import LLongName
|
|
19
|
+
from ..models.M2.MSR.Documentation.BlockElements import DocumentationBlock
|
|
20
|
+
from ..models.M2.MSR.Documentation.TextModel.LanguageDataModel import LOverviewParagraph
|
|
21
|
+
from ..models.M2.MSR.Documentation.TextModel.MultilanguageData import MultiLanguageOverviewParagraph, MultiLanguageParagraph, MultilanguageLongName
|
|
22
|
+
from ..models.M2.MSR.Documentation.Annotation import GeneralAnnotation
|
|
23
|
+
|
|
24
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure import SwcInternalBehavior
|
|
25
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.PortAPIOptions import PortAPIOption, PortDefinedArgumentValue
|
|
26
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.RTEEvents import DataReceivedEvent, OperationInvokedEvent, RTEEvent, SwcModeSwitchEvent
|
|
27
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.Timing.TimingConstraint.ExecutionOrderConstraint import ExecutionOrderConstraint
|
|
28
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.Datatype.Datatypes import ApplicationCompositeDataType, ApplicationDataType, AutosarDataType, DataTypeMap, DataTypeMappingSet
|
|
29
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.Implementation import Code
|
|
30
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.EndToEndProtection import EndToEndDescription, EndToEndProtection, EndToEndProtectionVariablePrototype
|
|
31
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.ModeDeclaration import ModeDeclarationGroup, ModeRequestTypeMap
|
|
32
|
+
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.EngineeringObject import AutosarEngineeringObject, EngineeringObject
|
|
33
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.ResourceConsumption import ResourceConsumption
|
|
34
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.ResourceConsumption.MemorySectionUsage import MemorySection
|
|
35
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.InternalBehavior import ExecutableEntity
|
|
36
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.SwcInternalBehavior.ModeDeclarationGroup import IncludedModeDeclarationGroupSet
|
|
37
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.SwcBswMapping import SwcBswMapping, SwcBswRunnableMapping
|
|
38
|
+
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import Identifiable
|
|
39
|
+
from ..models.M2.AUTOSARTemplates.BswModuleTemplate.BswBehavior import BswInternalBehavior, BswModuleEntity, BswScheduleEvent
|
|
40
|
+
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ARPackage import ARPackage
|
|
41
|
+
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import RefType
|
|
42
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.Implementation import ImplementationProps
|
|
43
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure import ApplicationValueSpecification, ArrayValueSpecification, ConstantReference, NumericalValueSpecification, RecordValueSpecification, TextValueSpecification, ValueSpecification
|
|
44
|
+
from ..models.M2.AUTOSARTemplates.GenericStructure.AbstractStructure import AnyInstanceRef
|
|
45
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.ImplementationDataTypes import ImplementationDataType, ImplementationDataTypeElement
|
|
46
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.Composition.InstanceRefs import POperationInAtomicSwcInstanceRef, PPortInCompositionInstanceRef, ROperationInAtomicSwcInstanceRef, RPortInCompositionInstanceRef
|
|
47
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.PortInterface.InstanceRefs import ApplicationCompositeElementInPortInterfaceInstanceRef
|
|
48
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.InstanceRefsUsage import AutosarParameterRef, AutosarVariableRef, VariableInAtomicSWCTypeInstanceRef
|
|
49
|
+
from ..models.M2.AUTOSARTemplates.SystemTemplate.InstanceRefs import VariableDataPrototypeInSystemInstanceRef
|
|
50
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.Components.InstanceRefs import InnerPortGroupInCompositionInstanceRef, PModeGroupInAtomicSwcInstanceRef, RModeGroupInAtomicSWCInstanceRef, RModeInAtomicSwcInstanceRef, RVariableInAtomicSwcInstanceRef
|
|
51
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior import RunnableEntity, RunnableEntityArgument
|
|
52
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.Components import CompositionSwComponentType, PortGroup, SwComponentType, SymbolProps, PPortPrototype, RPortPrototype
|
|
53
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.Composition import AssemblySwConnector, DelegationSwConnector
|
|
54
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.ModeDeclarationGroup import ModeAccessPoint
|
|
55
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.ServerCall import ServerCallPoint
|
|
56
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.Communication import ClientComSpec, ModeSwitchReceiverComSpec, ModeSwitchSenderComSpec, NonqueuedReceiverComSpec, NonqueuedSenderComSpec, ParameterRequireComSpec, QueuedReceiverComSpec, QueuedSenderComSpec, ReceiverComSpec, SenderComSpec, ServerComSpec
|
|
57
|
+
from ..models.M2.AUTOSARTemplates.SystemTemplate.Fibex.Fibex4Lin.LinCommunication import LinFrameTriggering
|
|
58
|
+
from ..models.M2.AUTOSARTemplates.SystemTemplate.Fibex.FibexCore.CoreTopology import AbstractCanCluster, CanPhysicalChannel, CommunicationCluster, LinPhysicalChannel, PhysicalChannel
|
|
59
|
+
from ..models.M2.AUTOSARTemplates.SystemTemplate.Fibex.Fibex4Can.CanCommunication import CanFrameTriggering, RxIdentifierRange
|
|
60
|
+
from ..models.M2.AUTOSARTemplates.SystemTemplate.Fibex.Fibex4Multiplatform import ISignalMapping
|
|
61
|
+
from ..models.M2.AUTOSARTemplates.SystemTemplate.Fibex.FibexCore.CoreCommunication import Frame, FrameTriggering, IPdu, ISignalIPdu, ISignalTriggering, PduTriggering
|
|
62
|
+
from ..models.M2.AUTOSARTemplates.SystemTemplate import System, SystemMapping
|
|
63
|
+
from ..models.M2.AUTOSARTemplates.SystemTemplate.DataMapping import SenderReceiverToSignalGroupMapping, SenderReceiverToSignalMapping
|
|
64
|
+
from ..models.M2.AUTOSARTemplates.SystemTemplate.NetworkManagement import CanNmCluster, CanNmClusterCoupling, CanNmNode, NmCluster, NmConfig, NmNode
|
|
65
|
+
from ..models.M2.AUTOSARTemplates.ECUCDescriptionTemplate import EcucAbstractReferenceValue, EcucContainerValue, EcucInstanceReferenceValue, EcucModuleConfigurationValues, EcucNumericalParamValue, EcucParameterValue, EcucReferenceValue, EcucTextualParamValue, EcucValueCollection
|
|
66
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.Communication import CompositeNetworkRepresentation, TransmissionAcknowledgementRequest
|
|
67
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.IncludedDataTypes import IncludedDataTypeSet
|
|
68
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.Timing.TimingConstraint.TimingExtensions import TimingExtension
|
|
69
|
+
from ..models.M2.AUTOSARTemplates.BswModuleTemplate.BswBehavior import BswModeSenderPolicy
|
|
70
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.PortInterface import ArgumentDataPrototype, ClientServerInterface, ClientServerOperation, InvalidationPolicy, ModeSwitchInterface, ParameterInterface, PortInterface, SenderReceiverInterface
|
|
71
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.ModeDeclaration import ModeDeclarationGroupPrototype
|
|
72
|
+
from ..models.M2.AUTOSARTemplates.BswModuleTemplate.BswImplementation import BswImplementation
|
|
73
|
+
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import MultilanguageReferrable
|
|
74
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.Datatype.Datatypes import ApplicationArrayDataType
|
|
75
|
+
|
|
76
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.EndToEndProtection import EndToEndProtectionSet
|
|
77
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.ServiceMapping import RoleBasedPortAssignment, SwcServiceDependency
|
|
78
|
+
from ..models.M2.AUTOSARTemplates.AutosarTopLevelStructure import AUTOSAR
|
|
79
|
+
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARLiteral
|
|
80
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.ServiceNeeds import RoleBasedDataAssignment, ServiceDependency
|
|
81
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.Components import AtomicSwComponentType
|
|
82
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.Datatype.DataPrototypes import ApplicationCompositeElementDataPrototype, AutosarDataPrototype, DataPrototype, ParameterDataPrototype, VariableDataPrototype
|
|
83
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.Implementation import Implementation
|
|
84
|
+
from ..models.M2.MSR.Documentation.Annotation import Annotation
|
|
85
|
+
from ..models.M2.MSR.AsamHdo.Constraints.GlobalConstraints import DataConstr
|
|
86
|
+
from ..models.M2.MSR.AsamHdo.SpecialData import Sd
|
|
87
|
+
from ..models.M2.MSR.AsamHdo.ComputationMethod import CompuMethod
|
|
88
|
+
from ..models.M2.MSR.CalibrationData.CalibrationValue import SwValueCont
|
|
89
|
+
from ..models.M2.AUTOSARTemplates.CommonStructure.InternalBehavior import InternalBehavior
|
|
90
|
+
from ..models.M2.AUTOSARTemplates.BswModuleTemplate.BswOverview import BswModuleDescription
|
|
91
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.Datatype.Datatypes import ApplicationRecordDataType
|
|
72
92
|
|
|
73
93
|
from .abstract_arxml_parser import AbstractARXMLParser
|
|
74
94
|
|
|
@@ -369,7 +389,7 @@ class ARXMLParser(AbstractARXMLParser):
|
|
|
369
389
|
|
|
370
390
|
def getRoleBasedPortAssignment(self, element: ET.Element) -> RoleBasedPortAssignment:
|
|
371
391
|
assignment = RoleBasedPortAssignment()
|
|
372
|
-
assignment.
|
|
392
|
+
assignment.portPrototypeRef = self.getChildElementOptionalRefType(element, "PORT-PROTOTYPE-REF")
|
|
373
393
|
assignment.role = self.getChildElementOptionalLiteral(element, "ROLE")
|
|
374
394
|
return assignment
|
|
375
395
|
|
|
@@ -575,12 +595,12 @@ class ARXMLParser(AbstractARXMLParser):
|
|
|
575
595
|
def readImplementation(self, element: ET.Element, impl: Implementation):
|
|
576
596
|
self.readIdentifiable(element, impl)
|
|
577
597
|
self.readCodeDescriptor(element, impl)
|
|
578
|
-
impl.
|
|
598
|
+
impl.programmingLanguage = self.getChildElementOptionalLiteral(element, "PROGRAMMING-LANGUAGE")
|
|
579
599
|
self.readResourceConsumption(element, impl)
|
|
580
|
-
impl.
|
|
581
|
-
impl.
|
|
582
|
-
impl.
|
|
583
|
-
impl.
|
|
600
|
+
impl.swVersion = self.getChildElementOptionalLiteral(element, "SW-VERSION")
|
|
601
|
+
impl.swcBswMappingRef = self.getChildElementOptionalRefType(element, "SWC-BSW-MAPPING-REF")
|
|
602
|
+
impl.usedCodeGenerator = self.getChildElementOptionalLiteral(element, "USED-CODE-GENERATOR")
|
|
603
|
+
impl.vendorId = self.getChildElementOptionalNumericalValue(element, "VENDOR-ID")
|
|
584
604
|
|
|
585
605
|
def readBswImplementationVendorSpecificModuleDefRefs(self, element: ET.Element, parent: BswImplementation):
|
|
586
606
|
child_element = element.find("./xmlns:VENDOR-SPECIFIC-MODULE-DEF-REFS", self.nsmap)
|
|
@@ -593,8 +613,8 @@ class ARXMLParser(AbstractARXMLParser):
|
|
|
593
613
|
impl = parent.createBswImplementation(short_name)
|
|
594
614
|
self.logger.debug("readBswImplementation %s" % impl.getShortName())
|
|
595
615
|
self.readImplementation(element, impl)
|
|
596
|
-
impl.
|
|
597
|
-
|
|
616
|
+
impl.setArReleaseVersion(self.getChildElementOptionalLiteral(element, "AR-RELEASE-VERSION")) \
|
|
617
|
+
.setBehaviorRef(self.getChildElementOptionalRefType(element, "BEHAVIOR-REF"))
|
|
598
618
|
self.readBswImplementationVendorSpecificModuleDefRefs(element, impl)
|
|
599
619
|
|
|
600
620
|
def readSwcImplementation(self, element: ET.Element, parent: ARPackage):
|
|
@@ -602,7 +622,7 @@ class ARXMLParser(AbstractARXMLParser):
|
|
|
602
622
|
impl = parent.createSwcImplementation(short_name)
|
|
603
623
|
self.logger.debug("readSwcImplementation %s" % impl.getShortName())
|
|
604
624
|
self.readImplementation(element, impl)
|
|
605
|
-
impl.
|
|
625
|
+
impl.behaviorRef = self.getChildElementOptionalRefType(element, "BEHAVIOR-REF")
|
|
606
626
|
|
|
607
627
|
def readDataReceivePointByArguments(self, element, parent: RunnableEntity):
|
|
608
628
|
self._readVariableAccesses(element, parent, "DATA-RECEIVE-POINT-BY-ARGUMENTS")
|
|
@@ -784,7 +804,7 @@ class ARXMLParser(AbstractARXMLParser):
|
|
|
784
804
|
|
|
785
805
|
def readRTEEvent(self, element: ET.Element, event: RTEEvent):
|
|
786
806
|
self.readIdentifiable(element, event)
|
|
787
|
-
event.
|
|
807
|
+
event.startOnEventRef = self.getChildElementOptionalRefType(element, "START-ON-EVENT-REF")
|
|
788
808
|
for child_element in element.findall("./xmlns:DISABLED-MODE-IREFS/xmlns:DISABLED-MODE-IREF", self.nsmap):
|
|
789
809
|
iref = self.getRModeInAtomicSwcInstanceRef(child_element)
|
|
790
810
|
event.addDisabledModeIRef(iref)
|
|
@@ -792,9 +812,9 @@ class ARXMLParser(AbstractARXMLParser):
|
|
|
792
812
|
def readOperationIRef(self, element: ET.Element, parent: OperationInvokedEvent):
|
|
793
813
|
child_element = element.find("./xmlns:OPERATION-IREF", self.nsmap)
|
|
794
814
|
if (child_element is not None):
|
|
795
|
-
parent.
|
|
796
|
-
parent.
|
|
797
|
-
parent.
|
|
815
|
+
parent.operationIRef = POperationInAtomicSwcInstanceRef()
|
|
816
|
+
parent.operationIRef.context_p_port_ref = self.getChildElementRefType(parent.getShortName(), child_element, "CONTEXT-P-PORT-REF")
|
|
817
|
+
parent.operationIRef.target_provided_operation_ref = self.getChildElementRefType(parent.getShortName(), child_element, "TARGET-PROVIDED-OPERATION-REF")
|
|
798
818
|
|
|
799
819
|
def readOperationInvokedEvent(self, element: ET.Element, parent: SwcInternalBehavior):
|
|
800
820
|
short_name = self.getShortName(element)
|
|
@@ -842,15 +862,15 @@ class ARXMLParser(AbstractARXMLParser):
|
|
|
842
862
|
child_element = element.find("./xmlns:VALUE/*", self.nsmap)
|
|
843
863
|
if child_element is not None:
|
|
844
864
|
argument_value.value = self.getValueSpecification(child_element)
|
|
845
|
-
argument_value.
|
|
865
|
+
argument_value.valueTypeTRef = self.getChildElementOptionalRefType(element, "VALUE-TYPE-TREF")
|
|
846
866
|
return argument_value
|
|
847
867
|
|
|
848
868
|
def readPortAPIOptions(self, element: ET.Element, behavior: SwcInternalBehavior):
|
|
849
869
|
for child_element in element.findall("./xmlns:PORT-API-OPTIONS/xmlns:PORT-API-OPTION", self.nsmap):
|
|
850
870
|
option = PortAPIOption()
|
|
851
|
-
option.
|
|
852
|
-
option.
|
|
853
|
-
option.
|
|
871
|
+
option.enableTakeAddress = self.getChildElementOptionalBooleanValue(child_element, "ENABLE-TAKE-ADDRESS")
|
|
872
|
+
option.indirectAPI = self.getChildElementOptionalBooleanValue(child_element, "INDIRECT-API")
|
|
873
|
+
option.portRef = self.getChildElementOptionalRefType(child_element, "PORT-REF")
|
|
854
874
|
for argument_value_tag in child_element.findall("./xmlns:PORT-ARG-VALUES/xmlns:PORT-DEFINED-ARGUMENT-VALUE", self.nsmap):
|
|
855
875
|
option.addPortArgValue(self.readPortDefinedArgumentValue(argument_value_tag))
|
|
856
876
|
behavior.addPortAPIOption(option)
|
|
@@ -1096,10 +1116,10 @@ class ARXMLParser(AbstractARXMLParser):
|
|
|
1096
1116
|
'''
|
|
1097
1117
|
|
|
1098
1118
|
def readBaseTypeDirectDefinition(self, element: ET.Element, definition: BaseTypeDirectDefinition):
|
|
1099
|
-
definition.
|
|
1100
|
-
definition.
|
|
1101
|
-
definition.
|
|
1102
|
-
definition.
|
|
1119
|
+
definition.baseTypeSize = self.getChildElementOptionalNumericalValue(element, "BASE-TYPE-SIZE")
|
|
1120
|
+
definition.baseTypeEncoding = self.getChildElementOptionalLiteral(element, "BASE-TYPE-ENCODING")
|
|
1121
|
+
definition.memAlignment = self.getChildElementOptionalNumericalValue(element, "MEM-ALIGNMENT")
|
|
1122
|
+
definition.nativeDeclaration = self.getChildElementOptionalLiteral(element, "NATIVE-DECLARATION")
|
|
1103
1123
|
|
|
1104
1124
|
def readSwBaseType(self, element: ET.Element, parent: ARPackage):
|
|
1105
1125
|
short_name = self.getShortName(element)
|
|
@@ -2620,18 +2640,23 @@ class ARXMLParser(AbstractARXMLParser):
|
|
|
2620
2640
|
self.readSystemMappings(element, system)
|
|
2621
2641
|
|
|
2622
2642
|
def readParameterInterfaceParameters(self, element: ET.Element, parent: ParameterInterface):
|
|
2623
|
-
for child_element in
|
|
2643
|
+
for child_element in self.findall(element, "PARAMETERS/PARAMETER-DATA-PROTOTYPE"):
|
|
2624
2644
|
short_name = self.getShortName(child_element)
|
|
2625
2645
|
prototype = parent.createParameter(short_name)
|
|
2626
2646
|
self.readParameterDataPrototype(child_element, prototype)
|
|
2627
2647
|
|
|
2628
2648
|
def readParameterInterface(self, element: ET.Element, parent: ARPackage):
|
|
2629
2649
|
short_name = self.getShortName(element)
|
|
2630
|
-
self.logger.debug("ParameterInterface %s" % short_name)
|
|
2650
|
+
self.logger.debug("Read ParameterInterface %s" % short_name)
|
|
2631
2651
|
pi_interface = parent.createParameterInterface(short_name)
|
|
2632
2652
|
self.readIdentifiable(element, pi_interface)
|
|
2633
2653
|
self.readParameterInterfaceParameters(element, pi_interface)
|
|
2634
2654
|
|
|
2655
|
+
def readGenericEthernetFrame(self, element: ET.Element, parent: ARPackage):
|
|
2656
|
+
short_name = self.getShortName(element)
|
|
2657
|
+
self.logger.debug("Read EthernetFrame %s" % short_name)
|
|
2658
|
+
frame = parent.createGenericEthernetFrame(short_name)
|
|
2659
|
+
self.readFrame(element, frame)
|
|
2635
2660
|
|
|
2636
2661
|
def readARPackageElements(self, element: ET.Element, parent: ARPackage):
|
|
2637
2662
|
for child_element in self.findall(element, "./ELEMENTS/*"):
|
|
@@ -2744,6 +2769,8 @@ class ARXMLParser(AbstractARXMLParser):
|
|
|
2744
2769
|
self.readPhysicalDimensions(child_element, parent)
|
|
2745
2770
|
elif tag_name == "PARAMETER-INTERFACE":
|
|
2746
2771
|
self.readParameterInterface(child_element, parent)
|
|
2772
|
+
elif tag_name == "ETHERNET-FRAME":
|
|
2773
|
+
self.readGenericEthernetFrame(child_element, parent)
|
|
2747
2774
|
else:
|
|
2748
2775
|
self._raiseError("Unsupported element type of ARPackage <%s>" % tag_name)
|
|
2749
2776
|
|
|
@@ -5,13 +5,15 @@ from openpyxl.worksheet.worksheet import Worksheet
|
|
|
5
5
|
import openpyxl
|
|
6
6
|
import re
|
|
7
7
|
|
|
8
|
-
from ..models.
|
|
8
|
+
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import RefType
|
|
9
|
+
|
|
10
|
+
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ARPackage import ARPackage
|
|
9
11
|
|
|
10
12
|
from ..parser.excel_parser import AbstractExcelParser
|
|
11
13
|
from ..data_models.sw_connector import AssemblySwConnectorData, DelegationSwConnectorData, SwConnectorData
|
|
12
|
-
from ..models.ar_ref import PPortInCompositionInstanceRef, RPortInCompositionInstanceRef
|
|
14
|
+
from ..models.ar_ref import PPortInCompositionInstanceRef, RPortInCompositionInstanceRef
|
|
13
15
|
from ..models.sw_component import CompositionSwComponentType
|
|
14
|
-
from ..models.
|
|
16
|
+
from ..models.M2.AUTOSARTemplates.AutosarTopLevelStructure import AUTOSAR
|
|
15
17
|
|
|
16
18
|
class ConnectorXls:
|
|
17
19
|
|
armodel/parser/file_parser.py
CHANGED
|
@@ -20,7 +20,8 @@ class FileListParser:
|
|
|
20
20
|
try:
|
|
21
21
|
with open(file) as f_in:
|
|
22
22
|
for line in f_in:
|
|
23
|
-
|
|
23
|
+
if not line.startswith('#'):
|
|
24
|
+
self.file_list.append(line.strip())
|
|
24
25
|
except:
|
|
25
26
|
self.logger.error("No such file or directory: %s" % os.path.realpath(file))
|
|
26
27
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
from ..models.
|
|
1
|
+
from ..models.M2.AUTOSARTemplates.SWComponentTemplate.Components import CompositionSwComponentType
|
|
2
|
+
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ARPackage import ARPackage
|
|
2
3
|
from .excel_report import ExcelReporter
|
|
3
|
-
from ..models import AUTOSAR
|
|
4
|
+
from ..models import AUTOSAR
|
|
4
5
|
from ..models import PPortInCompositionInstanceRef, RPortInCompositionInstanceRef
|
|
5
6
|
from typing import List
|
|
6
7
|
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
from ....models.
|
|
3
|
-
|
|
1
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARFloat, ARLiteral, ARNumerical
|
|
2
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARBoolean
|
|
4
3
|
|
|
5
4
|
class TestARObject:
|
|
6
5
|
|
|
@@ -1,15 +1,27 @@
|
|
|
1
1
|
""" Test AR Package """
|
|
2
2
|
import pytest
|
|
3
3
|
|
|
4
|
-
from ....models.
|
|
5
|
-
|
|
6
|
-
from ....models.
|
|
7
|
-
|
|
8
|
-
from ....models.
|
|
9
|
-
|
|
10
|
-
from ....models.
|
|
11
|
-
|
|
12
|
-
from ....models.
|
|
4
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.Datatype.Datatypes import ApplicationPrimitiveDataType, ApplicationRecordDataType
|
|
5
|
+
|
|
6
|
+
from ....models.M2.MSR.AsamHdo.BaseTypes import SwBaseType
|
|
7
|
+
|
|
8
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import PackageableElement
|
|
9
|
+
|
|
10
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import CollectableElement
|
|
11
|
+
|
|
12
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import Identifiable, MultilanguageReferrable, Referrable
|
|
13
|
+
|
|
14
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
15
|
+
|
|
16
|
+
from ....models.M2.AUTOSARTemplates.CommonStructure.ImplementationDataTypes import ImplementationDataType
|
|
17
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.Components import ApplicationSwComponentType, AtomicSwComponentType, EcuAbstractionSwComponentType, SwComponentType
|
|
18
|
+
from ....models.M2.AUTOSARTemplates.AutosarTopLevelStructure import AUTOSAR
|
|
19
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.Datatype.Datatypes import DataTypeMappingSet
|
|
20
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import ARElement
|
|
21
|
+
from ....models.M2.MSR.AsamHdo.ComputationMethod import CompuMethod
|
|
22
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.PortInterface import ClientServerInterface, DataInterface, PortInterface, SenderReceiverInterface
|
|
23
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.Components import ServiceSwComponentType
|
|
24
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.Components import CompositionSwComponentType
|
|
13
25
|
|
|
14
26
|
class TestAUTOSAR:
|
|
15
27
|
|
|
@@ -2,11 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
import pytest
|
|
4
4
|
|
|
5
|
-
from ....models.
|
|
6
|
-
|
|
7
|
-
from ....models.
|
|
8
|
-
from ....models.
|
|
9
|
-
from ....models.
|
|
5
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import RefType
|
|
6
|
+
|
|
7
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.AbstractStructure import AtpInstanceRef
|
|
8
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.Composition.InstanceRefs import OperationInAtomicSwcInstanceRef, POperationInAtomicSwcInstanceRef, PPortInCompositionInstanceRef, ROperationInAtomicSwcInstanceRef, RPortInCompositionInstanceRef
|
|
9
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.InstanceRefsUsage import ArVariableInImplementationDataInstanceRef, AutosarVariableRef
|
|
10
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import TRefType
|
|
11
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
10
12
|
|
|
11
13
|
|
|
12
14
|
class TestARRef:
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
import pytest
|
|
2
2
|
|
|
3
|
-
from ....models.
|
|
3
|
+
from ....models.M2.AUTOSARTemplates.BswModuleTemplate.BswOverview import BswModuleDescription
|
|
4
|
+
|
|
5
|
+
from ....models.M2.AUTOSARTemplates.BswModuleTemplate.BswBehavior import BswCalledEntity, BswModuleEntity
|
|
6
|
+
|
|
7
|
+
from ....models.M2.AUTOSARTemplates.BswModuleTemplate.BswInterfaces import BswModuleEntry
|
|
4
8
|
from .... import AUTOSAR
|
|
5
9
|
|
|
6
10
|
class TestBswModuleDescription:
|
|
@@ -1,11 +1,17 @@
|
|
|
1
1
|
import pytest
|
|
2
2
|
|
|
3
|
-
from ....models.
|
|
3
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import CollectableElement
|
|
4
|
+
|
|
5
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import Identifiable, MultilanguageReferrable, Referrable
|
|
6
|
+
|
|
7
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
8
|
+
|
|
9
|
+
from ....models.M2.AUTOSARTemplates.CommonStructure.ImplementationDataTypes import AbstractImplementationDataTypeElement, ImplementationDataTypeElement
|
|
4
10
|
from .... import AUTOSAR
|
|
5
|
-
from ....models.
|
|
6
|
-
from ....models.
|
|
7
|
-
from ....models.
|
|
8
|
-
from ....models.
|
|
11
|
+
from ....models.M2.AUTOSARTemplates.CommonStructure import ConstantReference, ConstantSpecification, ValueSpecification
|
|
12
|
+
from ....models.M2.AUTOSARTemplates.CommonStructure.InternalBehavior import ExecutableEntity
|
|
13
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import ARElement
|
|
14
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import PackageableElement
|
|
9
15
|
|
|
10
16
|
class Test_M2_AUTOSARTemplates_CommonStructure_Constants:
|
|
11
17
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import pytest
|
|
2
2
|
|
|
3
|
-
from ....models.
|
|
4
|
-
from ....models.
|
|
3
|
+
from ....models.M2.MSR.DataDictionary.DataDefProperties import SwDataDefProps, SwPointerTargetProps
|
|
4
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
5
5
|
|
|
6
6
|
class Test_M2_MSR_DataDictionary_DataDefProperties:
|
|
7
7
|
def test_SwDataDefProps(self):
|
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
import pytest
|
|
2
2
|
|
|
3
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import Identifiable, MultilanguageReferrable, Referrable
|
|
4
|
+
|
|
5
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
6
|
+
|
|
3
7
|
from .... import AUTOSAR
|
|
4
|
-
from ....models.
|
|
5
|
-
from ....models.
|
|
6
|
-
from ....models.
|
|
8
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import RefType
|
|
9
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.Datatype.DataPrototypes import ApplicationArrayElement, ApplicationCompositeElementDataPrototype, ApplicationRecordElement, AtpPrototype, AutosarDataPrototype, DataPrototype, VariableDataPrototype
|
|
10
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.AbstractStructure import AtpFeature
|
|
7
11
|
|
|
8
12
|
class Test_M2_AUTOSARTemplates_SWComponentTemplate_Datatype_DataPrototypes:
|
|
9
13
|
|
|
@@ -42,7 +46,7 @@ class Test_M2_AUTOSARTemplates_SWComponentTemplate_Datatype_DataPrototypes:
|
|
|
42
46
|
assert(isinstance(prototype, MultilanguageReferrable))
|
|
43
47
|
assert(isinstance(prototype, Referrable))
|
|
44
48
|
|
|
45
|
-
assert(prototype.
|
|
49
|
+
assert(prototype.parent == ar_root)
|
|
46
50
|
assert(prototype.short_name == "prototype")
|
|
47
51
|
assert(prototype.typeTRef is None)
|
|
48
52
|
|
|
@@ -1,12 +1,26 @@
|
|
|
1
1
|
import pytest
|
|
2
2
|
|
|
3
|
-
from ....models.
|
|
4
|
-
|
|
5
|
-
from ....models.
|
|
6
|
-
|
|
7
|
-
from ....models.
|
|
8
|
-
|
|
9
|
-
from ....models.
|
|
3
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.Datatype.Datatypes import ApplicationArrayDataType, ApplicationCompositeDataType, ApplicationDataType, ApplicationPrimitiveDataType, ApplicationRecordDataType, AutosarDataType, DataTypeMap
|
|
4
|
+
|
|
5
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.AbstractStructure import AtpType
|
|
6
|
+
|
|
7
|
+
from ....models.M2.MSR.AsamHdo.BaseTypes import BaseType, BaseTypeDirectDefinition
|
|
8
|
+
|
|
9
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import PackageableElement
|
|
10
|
+
|
|
11
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import CollectableElement
|
|
12
|
+
|
|
13
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import Identifiable, MultilanguageReferrable, Referrable
|
|
14
|
+
|
|
15
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
16
|
+
|
|
17
|
+
from ....models.M2.AUTOSARTemplates.CommonStructure.ImplementationDataTypes import AbstractImplementationDataType, ImplementationDataType, ImplementationDataTypeElement
|
|
18
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.Components import SymbolProps
|
|
19
|
+
from ....models.M2.AUTOSARTemplates.CommonStructure.Implementation import ImplementationProps
|
|
20
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.Datatype.DataPrototypes import ApplicationRecordElement
|
|
21
|
+
from ....models.M2.AUTOSARTemplates.SWComponentTemplate.Datatype.Datatypes import DataTypeMappingSet
|
|
22
|
+
from ....models.M2.MSR.AsamHdo.BaseTypes import SwBaseType
|
|
23
|
+
from ....models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import ARElement
|
|
10
24
|
from .... import AUTOSAR
|
|
11
25
|
class Test_M2_AUTOSARTemplates_CommonStructure_Implementation:
|
|
12
26
|
def test_ImplementationProps(self):
|
|
@@ -26,7 +40,7 @@ class Test_M2_AUTOSARTemplates_CommonStructure_Implementation:
|
|
|
26
40
|
assert(isinstance(prototype, Referrable))
|
|
27
41
|
assert(isinstance(prototype, SymbolProps))
|
|
28
42
|
|
|
29
|
-
assert(prototype.
|
|
43
|
+
assert(prototype.parent == ar_root)
|
|
30
44
|
assert(prototype.short_name == "SymbolProps")
|
|
31
45
|
assert(prototype.symbol == None)
|
|
32
46
|
|
|
@@ -52,7 +66,7 @@ class Test_M2_MSR_AsamHdo_BaseTypes:
|
|
|
52
66
|
assert(isinstance(base_type, Referrable))
|
|
53
67
|
assert(isinstance(base_type, SwBaseType))
|
|
54
68
|
|
|
55
|
-
assert(base_type.
|
|
69
|
+
assert(base_type.parent == ar_root)
|
|
56
70
|
assert(base_type.short_name == "SwBaseType")
|
|
57
71
|
assert(isinstance(base_type.baseTypeDefinition, BaseTypeDirectDefinition))
|
|
58
72
|
|
|
@@ -97,7 +111,7 @@ class Test_M2_AUTOSARTemplates_SWComponentTemplate_Datatype_Datatypes:
|
|
|
97
111
|
assert(isinstance(data_type, Referrable))
|
|
98
112
|
assert(isinstance(data_type, ApplicationPrimitiveDataType))
|
|
99
113
|
|
|
100
|
-
assert(data_type.
|
|
114
|
+
assert(data_type.parent == ar_root)
|
|
101
115
|
assert(data_type.short_name == "ApplicationPrimitiveDataType")
|
|
102
116
|
assert(data_type.swDataDefProps == None)
|
|
103
117
|
|
|
@@ -128,7 +142,7 @@ class Test_M2_AUTOSARTemplates_SWComponentTemplate_Datatype_Datatypes:
|
|
|
128
142
|
assert(isinstance(data_type, Referrable))
|
|
129
143
|
assert(isinstance(data_type, ApplicationArrayDataType))
|
|
130
144
|
|
|
131
|
-
assert(data_type.
|
|
145
|
+
assert(data_type.parent == ar_root)
|
|
132
146
|
assert(data_type.short_name == "ApplicationArrayDataType")
|
|
133
147
|
assert(data_type.dynamic_array_size_profile == None)
|
|
134
148
|
assert(data_type.element == None)
|
|
@@ -153,7 +167,7 @@ class Test_M2_AUTOSARTemplates_SWComponentTemplate_Datatype_Datatypes:
|
|
|
153
167
|
assert(isinstance(data_type, Referrable))
|
|
154
168
|
assert(isinstance(data_type, ApplicationRecordDataType))
|
|
155
169
|
|
|
156
|
-
assert(data_type.
|
|
170
|
+
assert(data_type.parent == ar_root)
|
|
157
171
|
assert(data_type.short_name == "ApplicationRecordDataType")
|
|
158
172
|
|
|
159
173
|
element = data_type.createApplicationRecordElement("element")
|
|
@@ -185,7 +199,7 @@ class Test_M2_AUTOSARTemplates_SWComponentTemplate_Datatype_Datatypes:
|
|
|
185
199
|
assert(isinstance(data_type_mapping_set, Referrable))
|
|
186
200
|
assert(isinstance(data_type_mapping_set, DataTypeMappingSet))
|
|
187
201
|
|
|
188
|
-
assert(data_type_mapping_set.
|
|
202
|
+
assert(data_type_mapping_set.parent == ar_root)
|
|
189
203
|
assert(data_type_mapping_set.short_name == "DataTypeMappingSet")
|
|
190
204
|
assert(len(data_type_mapping_set._dataTypeMaps) == 0)
|
|
191
205
|
|
|
@@ -224,7 +238,7 @@ class Test_M2_AUTOSARTemplates_CommonStructure_ImplementationDataTypes:
|
|
|
224
238
|
assert(isinstance(data_type, Referrable))
|
|
225
239
|
assert(isinstance(data_type, ImplementationDataType))
|
|
226
240
|
|
|
227
|
-
assert(data_type.
|
|
241
|
+
assert(data_type.parent == ar_root)
|
|
228
242
|
assert(data_type.short_name == "ImplementationDataType")
|
|
229
243
|
assert(data_type.subElements == [])
|
|
230
244
|
assert(data_type.symbolProps == None)
|