C# Класс CyPhyMasterInterpreter.AnalysisModelProcessor

Provides the following functionalities: expand a context [design space -> configurations], run interpreters, post jobs to job manager.
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
OriginalCurrentFCOName string

Открытые методы

Метод Описание
DeleteTemporaryObjects ( ) : void

Deletes all temporary objects in the right order.

Expand ( ISIS.GME.Dsml.CyPhyML.Interfaces configuration ) : void

Expands the current context and sets the expanded object.

GetAnalysisModelProcessor ( IMgaModel context ) : AnalysisModelProcessor

Factory method to get a new analysis model processor instance based on a given context.

GetExpandedObject ( ) : MgaModel

Gets the expanded version of the invoked object.

GetInvokedObject ( ) : MgaModel

Gets the object from which the analysis model processor was instantiated.

GetResultsDirectory ( ) : string

Gets the results directory. Project directory/results/ All interpreters will get a subdirectory inside this one.

GetWorkflow ( ) : Queue

Gets the set of Interpreters form the workflow.

PostToJobManager ( JobManagerDispatch manager ) : bool

Posts the generated analysis packages to the JobManager for execution.

RunCAExporter ( IEnumerable cwcs ) : IEnumerable

Runs the Component Assembly exporter. Exports CWC configurations into Component Assemblies.

RunInterpreters ( bool passTraceability, bool verboseConsole ) : void

Runs all interpreters on the expanded context.

SaveDesign ( AVM projectManifest ) : bool

Exports the design into design interchange format AVM Design Model and indexes the file in the project manifest.

SaveDesignSpace ( AVM projectManifest ) : bool

Exports the design space into design interchange format AVM Design Model and indexes the file in the project manifest.

SaveTestBench ( AVM projectManifest ) : bool

Saves the test bench descriptor file to the test bench directory and indexes the newly generated file in the project manifest.

SaveTestBenchManifest ( AVM projectManifest, string configurationName, DateTime analysisStartTime ) : bool

Saves the test bench manifest file to interpreter's output directory and indexes the newly generated file in the project manifest.

ShowInterpreterConfigs ( CyPhyGUIs.IInterpreterConfiguration>.Dictionary interpreterConfigurations, bool firstTimeOnly = true, bool interactive = true ) : void

Shows all configuration dialog boxes for all interpreters that have to be configured. InterpretersToConfiguration

UpdateTestBenchManifestExecutionSteps ( AVM manifest ) : bool

Updates the execution steps in the test bench manifest file based on the Tasks and Execution tasks in the workflow.

Защищенные методы

Метод Описание
AddToTraceabilityAndTemporary ( IMgaObject copied, IMgaObject original, bool recursive = true ) : void

Adds an object ID pair to the traceability map and adds the copied object to the temporary object list keeping track of the object to be deleted.

EnsureOutputDirectory ( ) : void

Ensures that output directory is not null and creates it if it does not exist already.

ExecuteInTransaction ( Action doWork, bool flushUndoQueue = true, bool abort = false ) : void

Helper function to execute an action within a transaction.

GetTemporaryFolderName ( IMgaObject originalObject ) : string

Gets the temporary folder name for a given object in GME.

GetTemporaryObjectName ( IMgaObject originalObject, IMgaObject configuration ) : string

Gets the temporary object name for a given object (context and configuration pair) in GME.

OnInterpreterProgress ( InterpreterProgressEventArgs eventArgs ) : void

Called when run interpreters make progress, like get configuration, initialize, etc.

ThrowIfNotExpanded ( ) : void

Checks if the original model is expanded or not.

Приватные методы

Метод Описание
AddToTraceability ( IMgaObject copied, IMgaObject original, bool recursive = true ) : void

Adds an object ID pair to the traceability map.

CreateOutputDirectory ( ) : string

Create the output directory if it does not exist yet.

GetRandomSubDirectory ( string outputDir ) : string

Gets a randomly named subdirectory inside a given output directory.

The new directory will not start with a number.

Описание методов

AddToTraceabilityAndTemporary() защищенный Метод

Adds an object ID pair to the traceability map and adds the copied object to the temporary object list keeping track of the object to be deleted.
protected AddToTraceabilityAndTemporary ( IMgaObject copied, IMgaObject original, bool recursive = true ) : void
copied IMgaObject Copy of the original object
original IMgaObject Original object
recursive bool Adds traceability recursively, but it does not add to the temporary objects recursively.
Результат void

DeleteTemporaryObjects() публичный Метод

Deletes all temporary objects in the right order.
public DeleteTemporaryObjects ( ) : void
Результат void

EnsureOutputDirectory() защищенный Метод

Ensures that output directory is not null and creates it if it does not exist already.
protected EnsureOutputDirectory ( ) : void
Результат void

ExecuteInTransaction() защищенный Метод

Helper function to execute an action within a transaction.
protected ExecuteInTransaction ( Action doWork, bool flushUndoQueue = true, bool abort = false ) : void
doWork Action Work that has to be done within a transaction.
flushUndoQueue bool Flushes undo queue to keep the memory usage down.
abort bool Aborts the transaction.
Результат void

Expand() публичный абстрактный Метод

Expands the current context and sets the expanded object.
public abstract Expand ( ISIS.GME.Dsml.CyPhyML.Interfaces configuration ) : void
configuration ISIS.GME.Dsml.CyPhyML.Interfaces Top level system under test will be redirected to this object.
Результат void

GetAnalysisModelProcessor() публичный статический Метод

Factory method to get a new analysis model processor instance based on a given context.
If context is null. If context is not supported.
public static GetAnalysisModelProcessor ( IMgaModel context ) : AnalysisModelProcessor
context IMgaModel Model context
Результат AnalysisModelProcessor

GetExpandedObject() публичный абстрактный Метод

Gets the expanded version of the invoked object.
public abstract GetExpandedObject ( ) : MgaModel
Результат MgaModel

GetInvokedObject() публичный абстрактный Метод

Gets the object from which the analysis model processor was instantiated.
public abstract GetInvokedObject ( ) : MgaModel
Результат MgaModel

GetResultsDirectory() публичный Метод

Gets the results directory. Project directory/results/ All interpreters will get a subdirectory inside this one.
public GetResultsDirectory ( ) : string
Результат string

GetTemporaryFolderName() защищенный статический Метод

Gets the temporary folder name for a given object in GME.
protected static GetTemporaryFolderName ( IMgaObject originalObject ) : string
originalObject IMgaObject Object to get the temporary folder name.
Результат string

GetTemporaryObjectName() защищенный статический Метод

Gets the temporary object name for a given object (context and configuration pair) in GME.
protected static GetTemporaryObjectName ( IMgaObject originalObject, IMgaObject configuration ) : string
originalObject IMgaObject Object to get the temporary object name.
configuration IMgaObject Configuration generated from design space.
Результат string

GetWorkflow() публичный абстрактный Метод

Gets the set of Interpreters form the workflow.
public abstract GetWorkflow ( ) : Queue
Результат Queue

OnInterpreterProgress() защищенный Метод

Called when run interpreters make progress, like get configuration, initialize, etc.
protected OnInterpreterProgress ( InterpreterProgressEventArgs eventArgs ) : void
eventArgs InterpreterProgressEventArgs Interpreter event arguments.
Результат void

PostToJobManager() публичный абстрактный Метод

Posts the generated analysis packages to the JobManager for execution.
public abstract PostToJobManager ( JobManagerDispatch manager ) : bool
manager JobManagerDispatch JobManager instance to post the job to.
Результат bool

RunCAExporter() публичный Метод

Runs the Component Assembly exporter. Exports CWC configurations into Component Assemblies.
public RunCAExporter ( IEnumerable cwcs ) : IEnumerable
cwcs IEnumerable Set of CWCs to export.
Результат IEnumerable

RunInterpreters() публичный Метод

Runs all interpreters on the expanded context.
public RunInterpreters ( bool passTraceability, bool verboseConsole ) : void
passTraceability bool If true passes traceability information for the interpreters.
verboseConsole bool Passes value to the interpreter if they can write verbose (debug) messages to the console or not.
Результат void

SaveDesign() публичный Метод

Exports the design into design interchange format AVM Design Model and indexes the file in the project manifest.
public SaveDesign ( AVM projectManifest ) : bool
projectManifest AVM Given project manifest object.
Результат bool

SaveDesignSpace() публичный Метод

Exports the design space into design interchange format AVM Design Model and indexes the file in the project manifest.
public SaveDesignSpace ( AVM projectManifest ) : bool
projectManifest AVM Given project manifest object.
Результат bool

SaveTestBench() публичный абстрактный Метод

Saves the test bench descriptor file to the test bench directory and indexes the newly generated file in the project manifest.
public abstract SaveTestBench ( AVM projectManifest ) : bool
projectManifest AVM Manifest object of the project.
Результат bool

SaveTestBenchManifest() публичный абстрактный Метод

Saves the test bench manifest file to interpreter's output directory and indexes the newly generated file in the project manifest.
public abstract SaveTestBenchManifest ( AVM projectManifest, string configurationName, DateTime analysisStartTime ) : bool
projectManifest AVM Manifest object of the project.
configurationName string
analysisStartTime DateTime
Результат bool

ShowInterpreterConfigs() публичный Метод

Shows all configuration dialog boxes for all interpreters that have to be configured. InterpretersToConfiguration
public ShowInterpreterConfigs ( CyPhyGUIs.IInterpreterConfiguration>.Dictionary interpreterConfigurations, bool firstTimeOnly = true, bool interactive = true ) : void
interpreterConfigurations CyPhyGUIs.IInterpreterConfiguration>.Dictionary Map that stores the configurations.
firstTimeOnly bool If true shows the configurations at the first time only, otherwise it shows always.
interactive bool
Результат void

ThrowIfNotExpanded() защищенный Метод

Checks if the original model is expanded or not.
If Expand was not called before.
protected ThrowIfNotExpanded ( ) : void
Результат void

UpdateTestBenchManifestExecutionSteps() публичный абстрактный Метод

Updates the execution steps in the test bench manifest file based on the Tasks and Execution tasks in the workflow.
public abstract UpdateTestBenchManifestExecutionSteps ( AVM manifest ) : bool
manifest AVM
Результат bool

Описание свойств

OriginalCurrentFCOName защищенное свойство

protected string OriginalCurrentFCOName
Результат string