Main Content

autosar.arch.loadModel

Load AUTOSAR architecture model

Since R2020a

Description

archModel = autosar.arch.loadModel(modelName) loads AUTOSAR architecture model modelName into memory without opening the model in the editor. The output argument archModel returns a model handle, which is an autosar.arch.Model object. After you load a model into memory, you can work with it by using architecture functions or open the model in the editor by using the open function. Save changes by using the save function.

example

Examples

collapse all

Load an AUTOSAR architecture model into memory without opening the model in the editor, and return model properties.

modelName = 'autosar_tpc_composition';
archModel = autosar.arch.loadModel(modelName)
archModel = 
  Model with properties:

              Name: 'autosar_tpc_composition'
    SimulinkHandle: 152.1598
        Components: [2x1 autosar.arch.Component]
      Compositions: [1x1 autosar.arch.Composition]
             Ports: [4x1 autosar.arch.ArchPort]
        Connectors: [7x1 autosar.arch.Connector]
        Interfaces: [1x9 Simulink.dictionary.archdata.PortInterface]
          Platform: 'Classic'

Copyright 2022 The MathWorks, Inc..

Input Arguments

collapse all

Name of the AUTOSAR architecture model to load into memory.

Example: 'myArchModel'

Output Arguments

collapse all

Returns an AUTOSAR architecture model handle, which is an autosar.arch.Model object.

Version History

Introduced in R2020a