Click or drag to resize

IApp Interface

An interface that is the main entry point of the application providing application specific methods and properties e.g. saving/closing projects, application settings etc.

Namespace:  EMInvent.InventSim.COMServer
Assembly:  InventSim (in InventSim.exe) Version: 5.1.12.6+develop
Syntax
public interface IApp

The IApp type exposes the following members.

Properties
  NameDescription
Public propertyActiveProject
Gets or sets the active project in the application. It the project to be set active is not opened in the application, an exception is thrown.
Public propertyIsJobRunning
Indicated whether there is a simulator job running in the application.
Public propertyIsWindowHidden
Gets a value indicating whether the main application window is hidden or not.
Public propertyJobStopStatus
Gets the stop status of the last simulator job.
Public propertyProjectCount
Returns the number of the opened projects.
Top
Methods
  NameDescription
Public methodAddProject
Creates a new empty project.
Public methodCloseAllProjects
Closes all opened projects.
Public methodCloseProject
Closes a certain project without confirmation.
Public methodExit
Closes application. Unsaved projects and COM server connections will be lost.
Public methodGenerateMesh
Starts mesh generation of the active project. InitializeSimulation(IProject) must be called prior to calling this method. Otherwise an exception will be thrown.
Public methodGetOpenedProjectList
Gives an array of currently opened project file names.
Public methodGetProcessID
Returns the thread ID.
Public methodGetProject
Returns an opened project with the specified file name. If there is no such project, an exception is thrown.
Public methodGetWindowHandle
Returns the main window handle.
Public methodHideWindow
Hides the main application window. Does nothing if it already hidden.
Public methodInitializeSimulation
Starts initialization steps of the simulation, in particular performs geometry preprocessing. It is has to be called before calling GenerateMesh(IProject) and Simulate(IProject).
Public methodOpenProject
Opens a project stored in a file.
Public methodRelease
Releases connection to the COM server.
Public methodSaveActiveProjectAs
Saves the active project to a file with the specified file name.
Public methodShowNormalWindow
Shows the main application window in normal state with the specified position and dimensions. Does nothing if it already visible.
Public methodShowWindow
Shows the main application window in the specified state. Does nothing if it already visible.
Public methodSimulate
Starts solving stage of the simulation. InitializeSimulation(IProject) and GenerateMesh(IProject) must be called prior to calling this method. Otherwise an exception will be thrown.
Public methodStartOptimization
Starts optimization asynchronously. Control is returned immediately. Monitor IsJobRunning property to get indication whether the optimization has finished.
Public methodStartSimulation
Starts simulation asynchronously. Control is returned immediately, thus caution should be exercised when trying to get simulation results while simulation is still running. Monitor IsJobRunning property to get indication whether the simulation has finished.
Public methodStartTuning
Starts tuning asynchronously. Control is returned immediately, thus caution should be exercised when trying to apply new variable values while simulation is still running. Monitor IsJobRunning property to get indication whether the simulation has finished.
Public methodStopSimulation
Signals the application to stop the ongoing simulation. Control can be returned before the simulation actually stops. Monitor IsJobRunning property to get indication whether the simulation has finished.
Top
Events
  NameDescription
Public eventOnExiting
The event is raised after the application shuts down. For more information please see OnExiting(Int32).
Public eventOnHide
The event is raised after the main window has been hidden. For more information please see OnHide.
Public eventOnJobStopped
The event is raised after a simulator job finishes. For more information please see OnJobStopped(JobStopStatus, String).
Public eventOnShow
The event is raised after the main window has been shown. For more information please see OnShow.
Top
See Also