armodel 1.6.3__py3-none-any.whl → 1.7.0__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 +7 -7
- armodel/cli/arxml_format_cli.py +14 -12
- armodel/cli/connector2xlsx_cli.py +2 -3
- armodel/cli/connector_update_cli.py +1 -4
- 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 +2 -2
- armodel/lib/system_signal.py +1 -3
- armodel/models/M2/AUTOSARTemplates/AutosarTopLevelStructure.py +5 -10
- armodel/models/M2/AUTOSARTemplates/BswModuleTemplate/BswBehavior.py +9 -11
- armodel/models/M2/AUTOSARTemplates/BswModuleTemplate/BswImplementation.py +51 -12
- armodel/models/M2/AUTOSARTemplates/BswModuleTemplate/BswInterfaces.py +3 -3
- armodel/models/M2/AUTOSARTemplates/BswModuleTemplate/BswOverview.py +5 -6
- armodel/models/M2/AUTOSARTemplates/BswModuleTemplate/__init__.py +4 -1
- armodel/models/M2/AUTOSARTemplates/CommonStructure/Filter.py +86 -0
- armodel/models/M2/AUTOSARTemplates/CommonStructure/Implementation.py +186 -29
- armodel/models/M2/AUTOSARTemplates/CommonStructure/ImplementationDataTypes.py +7 -10
- armodel/models/M2/AUTOSARTemplates/CommonStructure/InternalBehavior.py +21 -11
- armodel/models/M2/AUTOSARTemplates/CommonStructure/ModeDeclaration.py +3 -3
- armodel/models/M2/AUTOSARTemplates/CommonStructure/ResourceConsumption/MemorySectionUsage.py +3 -6
- armodel/models/M2/AUTOSARTemplates/CommonStructure/ResourceConsumption/__init__.py +3 -5
- armodel/models/M2/AUTOSARTemplates/CommonStructure/ServiceNeeds.py +10 -6
- armodel/models/M2/AUTOSARTemplates/CommonStructure/SwcBswMapping.py +3 -4
- armodel/models/M2/AUTOSARTemplates/CommonStructure/SwcInternalBehavior/ModeDeclarationGroup.py +2 -5
- armodel/models/M2/AUTOSARTemplates/CommonStructure/SwcInternalBehavior/__init__.py +0 -1
- 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 +2 -2
- armodel/models/M2/AUTOSARTemplates/CommonStructure/__init__.py +4 -6
- armodel/models/M2/AUTOSARTemplates/{ecuc_description_template.py → ECUCDescriptionTemplate.py} +6 -11
- armodel/models/M2/AUTOSARTemplates/GenericStructure/AbstractStructure.py +3 -6
- armodel/models/M2/AUTOSARTemplates/GenericStructure/GeneralTemplateClasses/ARPackage.py +42 -36
- armodel/models/M2/AUTOSARTemplates/GenericStructure/GeneralTemplateClasses/EngineeringObject.py +2 -5
- armodel/models/M2/AUTOSARTemplates/GenericStructure/GeneralTemplateClasses/Identifiable.py +11 -16
- armodel/models/M2/AUTOSARTemplates/GenericStructure/GeneralTemplateClasses/PrimitiveTypes.py +87 -4
- armodel/models/M2/AUTOSARTemplates/GenericStructure/GeneralTemplateClasses/__init__.py +0 -1
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/Communication.py +21 -8
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/Components/InstanceRefs.py +2 -4
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/Components/__init__.py +114 -12
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/Composition/InstanceRefs.py +2 -5
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/Composition/__init__.py +4 -62
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/Datatype/DataPrototypes.py +6 -8
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/Datatype/Datatypes.py +7 -7
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/Datatype/__init__.py +0 -1
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/{port_interface/instance_refs.py → PortInterface/InstanceRefs.py} +2 -2
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/{port_interface → PortInterface}/__init__.py +10 -10
- armodel/models/{rpt_scenario.py → M2/AUTOSARTemplates/SWComponentTemplate/RPTScenario.py} +4 -6
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcImplementation.py +29 -6
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/DataElements.py +6 -6
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/IncludedDataTypes.py +2 -2
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/InstanceRefsUsage.py +3 -3
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/ModeDeclarationGroup.py +28 -4
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/PerInstanceMemory.py +3 -3
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/PortAPIOptions.py +86 -0
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/RTEEvents.py +174 -0
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/ServerCall.py +3 -4
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/ServiceMapping.py +37 -3
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/Trigger.py +2 -4
- armodel/models/M2/AUTOSARTemplates/SWComponentTemplate/SwcInternalBehavior/__init__.py +166 -10
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/{data_mapping.py → DataMapping.py} +2 -3
- armodel/models/{fibex/can_communication.py → M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Can/CanCommunication.py} +3 -4
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Can/CanTopology.py +173 -0
- 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} +4 -5
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Lin/__init__.py +0 -0
- armodel/models/{fibex/fibex_4_multiplatform.py → M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Multiplatform.py} +5 -6
- armodel/models/{fibex/fibex_core/core_communication.py → M2/AUTOSARTemplates/SystemTemplate/Fibex/FibexCore/CoreCommunication.py} +6 -14
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/Fibex/FibexCore/CoreTopology.py +388 -0
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/Fibex/FibexCore/EcuInstance.py +223 -0
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/Fibex/FibexCore/Timing.py +177 -0
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/Fibex/FibexCore/__init__.py +0 -0
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/Fibex/__init__.py +0 -0
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/InstanceRefs.py +39 -2
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/{network_management.py → NetworkManagement.py} +5 -10
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/TransportProtocols.py +6 -0
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/__init__.py +86 -17
- armodel/models/M2/MSR/AsamHdo/AdminData.py +2 -5
- armodel/models/M2/MSR/AsamHdo/BaseTypes.py +3 -3
- armodel/models/M2/MSR/AsamHdo/ComputationMethod.py +5 -6
- armodel/models/M2/MSR/AsamHdo/Constraints/GlobalConstraints.py +3 -4
- armodel/models/M2/MSR/AsamHdo/Constraints/__init__.py +0 -1
- armodel/models/M2/MSR/AsamHdo/SpecialData.py +1 -4
- armodel/models/M2/MSR/AsamHdo/Units.py +3 -6
- armodel/models/M2/MSR/AsamHdo/__init__.py +0 -1
- armodel/models/M2/MSR/CalibrationData/CalibrationValue.py +3 -7
- armodel/models/M2/MSR/CalibrationData/__init__.py +0 -1
- armodel/models/M2/MSR/DataDictionary/AuxillaryObjects.py +3 -6
- armodel/models/M2/MSR/DataDictionary/Axis.py +3 -3
- armodel/models/M2/MSR/DataDictionary/CalibrationParameter.py +3 -3
- armodel/models/M2/MSR/DataDictionary/DataDefProperties.py +5 -6
- armodel/models/M2/MSR/DataDictionary/RecordLayout.py +4 -4
- armodel/models/M2/MSR/DataDictionary/__init__.py +0 -1
- armodel/models/M2/MSR/Documentation/Annotation.py +4 -6
- armodel/models/M2/MSR/Documentation/BlockElements.py +2 -2
- armodel/models/M2/MSR/Documentation/TextModel/LanguageDataModel.py +1 -2
- armodel/models/M2/MSR/Documentation/TextModel/MultilanguageData.py +3 -6
- armodel/models/M2/MSR/Documentation/TextModel/__init__.py +0 -2
- armodel/models/M2/MSR/Documentation/__init__.py +1 -1
- armodel/models/M2/MSR/__init__.py +1 -1
- armodel/models/M2/__init__.py +0 -1
- armodel/models/__init__.py +57 -3
- armodel/parser/abstract_arxml_parser.py +50 -16
- armodel/parser/arxml_parser.py +285 -112
- armodel/parser/file_parser.py +2 -1
- armodel/report/connector_xls_report.py +2 -1
- armodel/tests/test_armodel/models/test_ar_object.py +0 -2
- armodel/tests/test_armodel/models/test_ar_package.py +4 -4
- armodel/tests/test_armodel/models/test_data_prototype.py +1 -1
- armodel/tests/test_armodel/models/test_datatype.py +7 -7
- armodel/tests/test_armodel/models/test_port_interface.py +6 -6
- armodel/tests/test_armodel/parser/test_parse_bswmd.py +12 -12
- armodel/tests/test_armodel/parser/test_sw_components.py +1 -23
- armodel/tests/test_armodel/parser/test_system.py +3 -3
- armodel/writer/abstract_arxml_writer.py +10 -1
- armodel/writer/arxml_writer.py +249 -80
- {armodel-1.6.3.dist-info → armodel-1.7.0.dist-info}/METADATA +385 -366
- armodel-1.7.0.dist-info/RECORD +160 -0
- {armodel-1.6.3.dist-info → armodel-1.7.0.dist-info}/WHEEL +1 -1
- armodel/models/M2/AUTOSARTemplates/SystemTemplate/transport_protocols.py +0 -7
- armodel/models/fibex/fibex_core/core_topology.py +0 -184
- armodel/models/sw_component.py +0 -390
- armodel/models/timing.py +0 -91
- armodel-1.6.3.dist-info/RECORD +0 -148
- /armodel/models/{fibex → M2/AUTOSARTemplates/CommonStructure/Timing/TimingConstraint}/__init__.py +0 -0
- /armodel/models/{fibex/fibex_4_can → M2/AUTOSARTemplates/CommonStructure/Timing}/__init__.py +0 -0
- /armodel/models/{fibex/fibex_4_lin → M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Can}/__init__.py +0 -0
- /armodel/models/{fibex/fibex_core → M2/AUTOSARTemplates/SystemTemplate/Fibex/Fibex4Ethernet}/__init__.py +0 -0
- {armodel-1.6.3.dist-info → armodel-1.7.0.dist-info}/LICENSE +0 -0
- {armodel-1.6.3.dist-info → armodel-1.7.0.dist-info}/entry_points.txt +0 -0
- {armodel-1.6.3.dist-info → armodel-1.7.0.dist-info}/top_level.txt +0 -0
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
from typing import List
|
|
2
|
-
from
|
|
3
|
-
from
|
|
4
|
-
from
|
|
5
|
-
|
|
2
|
+
from .....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
3
|
+
from .....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import Identifiable
|
|
4
|
+
from .....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARNumerical, Limit, RefType
|
|
6
5
|
|
|
7
6
|
class InternalConstrs(ARObject):
|
|
8
7
|
def __init__(self):
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
from . import *
|
|
@@ -1,9 +1,6 @@
|
|
|
1
|
-
from
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
4
2
|
from typing import List
|
|
5
3
|
|
|
6
|
-
|
|
7
4
|
class Sd(ARObject):
|
|
8
5
|
def __init__(self):
|
|
9
6
|
super().__init__()
|
|
@@ -1,9 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
from
|
|
3
|
-
from
|
|
4
|
-
from ...AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import RefType
|
|
5
|
-
from ...AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARLiteral
|
|
6
|
-
from ...AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import ARElement
|
|
1
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
2
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARFloat, ARNumerical, RefType, ARLiteral
|
|
3
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import ARElement
|
|
7
4
|
|
|
8
5
|
class PhysicalDimension(ARElement):
|
|
9
6
|
def __init__(self, parent: ARObject, short_name: str):
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
from . import *
|
|
@@ -1,11 +1,7 @@
|
|
|
1
|
-
from armodel.models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
2
|
-
from armodel.models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARNumerical, RefType
|
|
3
|
-
|
|
4
|
-
|
|
5
1
|
from typing import List
|
|
6
|
-
|
|
7
|
-
from
|
|
8
|
-
|
|
2
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
3
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARNumerical, RefType
|
|
4
|
+
from ....M2.MSR.DataDictionary.DataDefProperties import ValueList
|
|
9
5
|
|
|
10
6
|
class SwValues(ARObject):
|
|
11
7
|
def __init__(self):
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
from . import *
|
|
@@ -1,10 +1,7 @@
|
|
|
1
|
-
|
|
2
1
|
from typing import List
|
|
3
|
-
|
|
4
|
-
from
|
|
5
|
-
from
|
|
6
|
-
from ...AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import Identifiable
|
|
7
|
-
|
|
2
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
3
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARLiteral
|
|
4
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import Identifiable
|
|
8
5
|
|
|
9
6
|
class SwAddrMethod(Identifiable):
|
|
10
7
|
def __init__(self, parent: ARObject, short_name: str):
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
from .CalibrationParameter import SwCalprmAxisTypeProps
|
|
2
|
-
from ...AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
3
|
-
from ...AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARFloat, ARNumerical, RefType
|
|
4
1
|
from typing import List
|
|
2
|
+
from ....M2.MSR.DataDictionary.CalibrationParameter import SwCalprmAxisTypeProps
|
|
3
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
4
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARFloat, ARNumerical, RefType
|
|
5
5
|
|
|
6
6
|
class SwGenericAxisParam(ARObject):
|
|
7
7
|
def __init__(self):
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
from typing import List
|
|
2
|
-
from ...AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
3
|
-
from ...AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARFloat
|
|
4
|
-
|
|
5
2
|
from abc import ABCMeta
|
|
3
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
4
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARFloat
|
|
5
|
+
|
|
6
6
|
class SwCalprmAxisTypeProps(ARObject, metaclass = ABCMeta):
|
|
7
7
|
def __init__(self):
|
|
8
8
|
if type(self) == SwCalprmAxisTypeProps:
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
from typing import List
|
|
2
|
-
|
|
3
|
-
from
|
|
4
|
-
from
|
|
5
|
-
from
|
|
6
|
-
from
|
|
7
|
-
from ...AUTOSARTemplates.CommonStructure import ValueSpecification
|
|
2
|
+
from ....M2.MSR.Documentation.Annotation import Annotation
|
|
3
|
+
from ....M2.MSR.DataDictionary.CalibrationParameter import SwCalprmAxisSet
|
|
4
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
5
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARFloat, RefType, ARLiteral
|
|
6
|
+
from ....M2.AUTOSARTemplates.CommonStructure import ValueSpecification
|
|
8
7
|
|
|
9
8
|
class SwDataDefPropsConditional(ARObject):
|
|
10
9
|
'''
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
from
|
|
2
|
-
from
|
|
3
|
-
from
|
|
4
|
-
from
|
|
1
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
2
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.Identifiable import ARElement
|
|
3
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARLiteral, ARNumerical, RefType
|
|
4
|
+
from ....M2.MSR.Documentation.TextModel.MultilanguageData import MultiLanguageOverviewParagraph
|
|
5
5
|
|
|
6
6
|
class SwRecordLayoutV(ARObject):
|
|
7
7
|
def __init__(self):
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
from . import *
|
|
@@ -1,11 +1,9 @@
|
|
|
1
|
-
from
|
|
2
|
-
from
|
|
3
|
-
from .
|
|
4
|
-
from
|
|
5
|
-
|
|
1
|
+
from ....M2.MSR.Documentation.BlockElements import DocumentationBlock
|
|
2
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
3
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARLiteral
|
|
4
|
+
from ....M2.MSR.Documentation.TextModel.MultilanguageData import MultilanguageLongName
|
|
6
5
|
from abc import ABCMeta
|
|
7
6
|
|
|
8
|
-
|
|
9
7
|
class GeneralAnnotation(ARObject, metaclass=ABCMeta):
|
|
10
8
|
def __init__(self):
|
|
11
9
|
if type(self) == ARObject:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
from typing import List
|
|
2
|
-
from .TextModel.MultilanguageData import MultiLanguageParagraph
|
|
3
|
-
from
|
|
2
|
+
from ....M2.MSR.Documentation.TextModel.MultilanguageData import MultiLanguageParagraph
|
|
3
|
+
from ....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
4
4
|
|
|
5
5
|
class DocumentationBlock(ARObject):
|
|
6
6
|
def __init__(self):
|
|
@@ -1,10 +1,7 @@
|
|
|
1
|
-
from armodel.models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
2
|
-
from armodel.models.M2.MSR.Documentation.TextModel.LanguageDataModel import LOverviewParagraph
|
|
3
|
-
from armodel.models.M2.MSR.Documentation.TextModel.LanguageDataModel import LLongName
|
|
4
|
-
|
|
5
|
-
|
|
6
1
|
from typing import List
|
|
7
|
-
|
|
2
|
+
from .....M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
3
|
+
from .....M2.MSR.Documentation.TextModel.LanguageDataModel import LOverviewParagraph
|
|
4
|
+
from .....M2.MSR.Documentation.TextModel.LanguageDataModel import LLongName
|
|
8
5
|
|
|
9
6
|
class MultiLanguageParagraph(ARObject):
|
|
10
7
|
def __init__(self):
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
|
armodel/models/M2/__init__.py
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
from . import *
|
armodel/models/__init__.py
CHANGED
|
@@ -1,7 +1,61 @@
|
|
|
1
|
-
from .
|
|
1
|
+
from .M2.MSR.AsamHdo import *
|
|
2
|
+
from .M2.MSR.AsamHdo.AdminData import *
|
|
3
|
+
from .M2.MSR.AsamHdo.BaseTypes import *
|
|
4
|
+
from .M2.MSR.AsamHdo.ComputationMethod import *
|
|
5
|
+
from .M2.MSR.AsamHdo.SpecialData import *
|
|
6
|
+
from .M2.MSR.AsamHdo.Units import *
|
|
7
|
+
from .M2.MSR.AsamHdo.Constraints.GlobalConstraints import *
|
|
2
8
|
from .M2.MSR.DataDictionary import *
|
|
3
9
|
from .M2.MSR.Documentation import *
|
|
4
|
-
from .M2.MSR.
|
|
10
|
+
from .M2.MSR.Documentation.Annotation import *
|
|
11
|
+
from .M2.MSR.Documentation.BlockElements import *
|
|
12
|
+
from .M2.MSR.Documentation.TextModel import *
|
|
13
|
+
from .M2.MSR.Documentation.TextModel.LanguageDataModel import *
|
|
14
|
+
from .M2.MSR.Documentation.TextModel.MultilanguageData import *
|
|
5
15
|
from .M2.AUTOSARTemplates.AutosarTopLevelStructure import *
|
|
16
|
+
from .M2.AUTOSARTemplates.BswModuleTemplate import *
|
|
17
|
+
from .M2.AUTOSARTemplates.BswModuleTemplate.BswBehavior import *
|
|
18
|
+
from .M2.AUTOSARTemplates.BswModuleTemplate.BswImplementation import *
|
|
19
|
+
from .M2.AUTOSARTemplates.BswModuleTemplate.BswInterfaces import *
|
|
20
|
+
from .M2.AUTOSARTemplates.BswModuleTemplate.BswOverview import *
|
|
6
21
|
from .M2.AUTOSARTemplates.CommonStructure import *
|
|
7
|
-
from .M2.AUTOSARTemplates.
|
|
22
|
+
from .M2.AUTOSARTemplates.CommonStructure.Filter import *
|
|
23
|
+
from .M2.AUTOSARTemplates.CommonStructure.Implementation import *
|
|
24
|
+
from .M2.AUTOSARTemplates.CommonStructure.ImplementationDataTypes import *
|
|
25
|
+
from .M2.AUTOSARTemplates.CommonStructure.InternalBehavior import *
|
|
26
|
+
from .M2.AUTOSARTemplates.CommonStructure.ModeDeclaration import *
|
|
27
|
+
from .M2.AUTOSARTemplates.CommonStructure.ResourceConsumption import *
|
|
28
|
+
from .M2.AUTOSARTemplates.CommonStructure.ResourceConsumption.MemorySectionUsage import *
|
|
29
|
+
from .M2.AUTOSARTemplates.CommonStructure.ServiceNeeds import *
|
|
30
|
+
from .M2.AUTOSARTemplates.CommonStructure.SwcBswMapping import *
|
|
31
|
+
from .M2.AUTOSARTemplates.CommonStructure.TriggerDeclaration import *
|
|
32
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate import *
|
|
33
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.Communication import *
|
|
34
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.Components import *
|
|
35
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.Composition import *
|
|
36
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.EndToEndProtection import *
|
|
37
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.RPTScenario import *
|
|
38
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.SwcImplementation import *
|
|
39
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.DataElements import *
|
|
40
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.AccessCount import *
|
|
41
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.IncludedDataTypes import *
|
|
42
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.InstanceRefsUsage import *
|
|
43
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.ModeDeclarationGroup import *
|
|
44
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.PerInstanceMemory import *
|
|
45
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.ServerCall import *
|
|
46
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.ServiceMapping import *
|
|
47
|
+
from .M2.AUTOSARTemplates.SWComponentTemplate.SwcInternalBehavior.Trigger import *
|
|
48
|
+
from .M2.AUTOSARTemplates.SystemTemplate.DataMapping import *
|
|
49
|
+
from .M2.AUTOSARTemplates.SystemTemplate.InstanceRefs import *
|
|
50
|
+
from .M2.AUTOSARTemplates.SystemTemplate.NetworkManagement import *
|
|
51
|
+
from .M2.AUTOSARTemplates.SystemTemplate.TransportProtocols import *
|
|
52
|
+
from .M2.AUTOSARTemplates.SystemTemplate.Fibex.Fibex4Multiplatform import *
|
|
53
|
+
from .M2.AUTOSARTemplates.SystemTemplate.Fibex.Fibex4Can.CanCommunication import *
|
|
54
|
+
from .M2.AUTOSARTemplates.SystemTemplate.Fibex.Fibex4Can.CanTopology import *
|
|
55
|
+
from .M2.AUTOSARTemplates.SystemTemplate.Fibex.Fibex4Lin.LinCommunication import *
|
|
56
|
+
from .M2.AUTOSARTemplates.SystemTemplate.Fibex.Fibex4Ethernet.EthernetFrame import *
|
|
57
|
+
from .M2.AUTOSARTemplates.SystemTemplate.Fibex.Fibex4Ethernet.ServiceInstances import *
|
|
58
|
+
from .M2.AUTOSARTemplates.SystemTemplate.Fibex.FibexCore.CoreCommunication import *
|
|
59
|
+
from .M2.AUTOSARTemplates.SystemTemplate.Fibex.FibexCore.CoreTopology import *
|
|
60
|
+
from .M2.AUTOSARTemplates.SystemTemplate.Fibex.FibexCore.EcuInstance import *
|
|
61
|
+
from .M2.AUTOSARTemplates.SystemTemplate.Fibex.FibexCore.Timing import *
|
|
@@ -9,7 +9,7 @@ import xml.etree.ElementTree as ET
|
|
|
9
9
|
|
|
10
10
|
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.ArObject import ARObject
|
|
11
11
|
|
|
12
|
-
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARFloat, ARLiteral, ARNumerical
|
|
12
|
+
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import ARFloat, ARLiteral, ARNumerical, Boolean, Integer, TimeValue
|
|
13
13
|
|
|
14
14
|
from ..models.M2.AUTOSARTemplates.AutosarTopLevelStructure import AUTOSAR
|
|
15
15
|
from ..models.M2.AUTOSARTemplates.GenericStructure.GeneralTemplateClasses.PrimitiveTypes import RefType
|
|
@@ -73,7 +73,7 @@ class AbstractARXMLParser:
|
|
|
73
73
|
'''
|
|
74
74
|
|
|
75
75
|
def getChildElementLiteral(self, short_name: str, element: ET.Element, key: str) -> ARLiteral:
|
|
76
|
-
child_element =
|
|
76
|
+
child_element = self.find(element, key)
|
|
77
77
|
if (child_element is not None):
|
|
78
78
|
literal = ARLiteral()
|
|
79
79
|
self.readElementAttributes(child_element, literal)
|
|
@@ -82,7 +82,7 @@ class AbstractARXMLParser:
|
|
|
82
82
|
self._raiseError("The attribute %s of <%s> has not been defined" % (key, short_name))
|
|
83
83
|
|
|
84
84
|
def getChildElementLiteralValueList(self, element: ET.Element, key: str) -> ARFloat:
|
|
85
|
-
child_elements =
|
|
85
|
+
child_elements = self.findall(element, key)
|
|
86
86
|
results = []
|
|
87
87
|
for child_element in child_elements:
|
|
88
88
|
literal = ARLiteral()
|
|
@@ -91,10 +91,27 @@ class AbstractARXMLParser:
|
|
|
91
91
|
return results
|
|
92
92
|
|
|
93
93
|
def getChildElementOptionalLiteral(self, element: ET.Element, key: str) -> ARLiteral:
|
|
94
|
-
child_element =
|
|
94
|
+
child_element = self.find(element, key)
|
|
95
95
|
literal = None
|
|
96
96
|
if (child_element is not None):
|
|
97
|
-
self.logger.debug("
|
|
97
|
+
self.logger.debug("getChildElementOptionalLiteral : %s" % child_element.text)
|
|
98
|
+
literal = ARLiteral()
|
|
99
|
+
self.readElementAttributes(child_element, literal)
|
|
100
|
+
# Patch for empty element <USED-CODE-GENERATOR></USED-CODE-GENERATOR>
|
|
101
|
+
if child_element.text is None:
|
|
102
|
+
literal.setValue("")
|
|
103
|
+
else:
|
|
104
|
+
literal.setValue(child_element.text)
|
|
105
|
+
return literal
|
|
106
|
+
|
|
107
|
+
def getChildElementOptionalRevisionLabelString(self, element: ET.Element, key: str) -> ARLiteral:
|
|
108
|
+
child_element = self.find(element, key)
|
|
109
|
+
literal = None
|
|
110
|
+
if (child_element is not None) and (child_element.text is not None):
|
|
111
|
+
self.logger.debug("getChildElementOptionalRevisionLabelString : %s" % child_element.text)
|
|
112
|
+
m = re.match(r'[0-9]+\.[0-9]+\.[0-9]+([\._;].*)?', child_element.text)
|
|
113
|
+
if not m:
|
|
114
|
+
raise ValueError("Invalid RevisionLabelString <%s>" % child_element.text)
|
|
98
115
|
literal = ARLiteral()
|
|
99
116
|
self.readElementAttributes(child_element, literal)
|
|
100
117
|
# Patch for empty element <USED-CODE-GENERATOR></USED-CODE-GENERATOR>
|
|
@@ -110,7 +127,7 @@ class AbstractARXMLParser:
|
|
|
110
127
|
return False
|
|
111
128
|
|
|
112
129
|
def getChildElementOptionalFloatValue(self, element: ET.Element, key: str) -> ARFloat:
|
|
113
|
-
child_element =
|
|
130
|
+
child_element = self.find(element, key)
|
|
114
131
|
float_value = None
|
|
115
132
|
if (child_element is not None) and (child_element.text is not None):
|
|
116
133
|
float_value = ARFloat()
|
|
@@ -118,26 +135,34 @@ class AbstractARXMLParser:
|
|
|
118
135
|
return float_value
|
|
119
136
|
|
|
120
137
|
def getChildElementFloatValueList(self, element: ET.Element, key: str) -> ARFloat:
|
|
121
|
-
child_elements =
|
|
138
|
+
child_elements = self.findall(element, key)
|
|
122
139
|
results = []
|
|
123
140
|
for child_element in child_elements:
|
|
124
141
|
float_value = ARFloat()
|
|
125
142
|
float_value.setValue(child_element.text)
|
|
126
143
|
results.append(float_value)
|
|
127
144
|
return results
|
|
145
|
+
|
|
146
|
+
def getChildElementOptionalTimeValue(self, element: ET.Element, key: str) -> TimeValue:
|
|
147
|
+
child_element = self.find(element, key)
|
|
148
|
+
time_value = None
|
|
149
|
+
if (child_element is not None) and (child_element.text is not None):
|
|
150
|
+
time_value = TimeValue()
|
|
151
|
+
time_value.setValue(child_element.text)
|
|
152
|
+
return time_value
|
|
128
153
|
|
|
129
|
-
def getChildElementBooleanValue(self, short_name: str, element: ET.Element, key: str) ->
|
|
154
|
+
def getChildElementBooleanValue(self, short_name: str, element: ET.Element, key: str) -> Boolean:
|
|
130
155
|
literal = self.getChildElementLiteral(short_name, element, key)
|
|
131
|
-
bool_value =
|
|
156
|
+
bool_value = Boolean()
|
|
132
157
|
bool_value.timestamp = literal.timestamp
|
|
133
158
|
bool_value.value = self._convertStringToBooleanValue(literal._value)
|
|
134
159
|
return bool_value
|
|
135
160
|
|
|
136
|
-
def getChildElementOptionalBooleanValue(self, element: ET.Element, key: str) ->
|
|
161
|
+
def getChildElementOptionalBooleanValue(self, element: ET.Element, key: str) -> Boolean:
|
|
137
162
|
literal = self.getChildElementOptionalLiteral(element, key)
|
|
138
163
|
if (literal == None):
|
|
139
164
|
return None
|
|
140
|
-
bool_value =
|
|
165
|
+
bool_value = Boolean()
|
|
141
166
|
bool_value.timestamp = literal.timestamp
|
|
142
167
|
bool_value.setValue(literal.getValue())
|
|
143
168
|
return bool_value
|
|
@@ -162,16 +187,25 @@ class AbstractARXMLParser:
|
|
|
162
187
|
'''
|
|
163
188
|
|
|
164
189
|
def getChildElementOptionalNumericalValue(self, element: ET.Element, key: str) -> ARNumerical:
|
|
165
|
-
child_element =
|
|
190
|
+
child_element = self.find(element, key)
|
|
166
191
|
if child_element == None:
|
|
167
192
|
return None
|
|
168
193
|
numerical = ARNumerical()
|
|
169
194
|
self.readElementAttributes(child_element, numerical)
|
|
170
195
|
numerical.setValue(child_element.text)
|
|
171
196
|
return numerical
|
|
197
|
+
|
|
198
|
+
def getChildElementOptionalIntegerValue(self, element: ET.Element, key: str) -> Integer:
|
|
199
|
+
child_element = self.find(element, key)
|
|
200
|
+
if child_element == None:
|
|
201
|
+
return None
|
|
202
|
+
numerical = Integer()
|
|
203
|
+
self.readElementAttributes(child_element, numerical)
|
|
204
|
+
numerical.setValue(child_element.text)
|
|
205
|
+
return numerical
|
|
172
206
|
|
|
173
207
|
def getChildElementNumericalValueList(self, element: ET.Element, key: str) -> List[ARNumerical]:
|
|
174
|
-
child_elements =
|
|
208
|
+
child_elements = self.findall(element, key)
|
|
175
209
|
results = []
|
|
176
210
|
for child_element in child_elements:
|
|
177
211
|
numerical = ARNumerical()
|
|
@@ -180,7 +214,7 @@ class AbstractARXMLParser:
|
|
|
180
214
|
return results
|
|
181
215
|
|
|
182
216
|
def getChildLimitElement(self, element: ET.Element, key: str) -> Limit:
|
|
183
|
-
child_element =
|
|
217
|
+
child_element = self.find(element, key)
|
|
184
218
|
if (child_element is not None):
|
|
185
219
|
limit = Limit()
|
|
186
220
|
self.readElementAttributes(child_element, limit)
|
|
@@ -199,13 +233,13 @@ class AbstractARXMLParser:
|
|
|
199
233
|
return ref
|
|
200
234
|
|
|
201
235
|
def getChildElementRefType(self, short_name: str, element: ET.Element, key: str) -> RefType:
|
|
202
|
-
child_element =
|
|
236
|
+
child_element = self.find(element, key)
|
|
203
237
|
if (child_element is not None):
|
|
204
238
|
return self._getChildElementRefTypeDestAndValue(child_element)
|
|
205
239
|
self._raiseError("The attribute %s of <%s> has not been defined" % (key, short_name))
|
|
206
240
|
|
|
207
241
|
def getChildElementOptionalRefType(self, element:ET.Element, key: str) -> RefType:
|
|
208
|
-
child_element =
|
|
242
|
+
child_element = self.find(element, key)
|
|
209
243
|
if (child_element is not None):
|
|
210
244
|
return self._getChildElementRefTypeDestAndValue(child_element)
|
|
211
245
|
return None
|