Public Member Functions | List of all members
Job Class Reference

Job class(JMAG-Designer) is used when selecting multiple studies to run analyses.
The class can be created from Study or AnalysisGroup class.
. More...

Public Member Functions

void ExportJobSystemFiles (String &xmlPath, bool allCase=false)
 Exports the JMAG JobSystem execution file. More...
 
bool IsCanceled ()
 Returns True if the job is canceled. More...
 
bool IsFinished ()
 Returns True if the job has finished. More...
 
bool IsValid ()
 Returns True if an object is valid. More...
 
void SetSubValue (int index, String &name, Variant &value)
 Specifies a property value for SubJob. More...
 
void SetTargetStudyList (StringList &var)
 Specifies the study list to run. More...
 
void SetValue (String &name, Variant &value)
 Specifies the value of a property. More...
 
void Submit (bool allCase=false)
 Runs jobs. More...
 
void WaitForFinished ()
 Waits for the job to finish running.
 

Detailed Description

Job class(JMAG-Designer) is used when selecting multiple studies to run analyses.
The class can be created from Study or AnalysisGroup class.
.

Example of creating the class object:

app.GetModel(0).GetStudy(0).CreateJob()

For more information about the properties for this command, see Properties Used for the Job Settings .

Member Function Documentation

void Job::ExportJobSystemFiles ( String &  xmlPath,
bool  allCase = false 
)

Exports the JMAG JobSystem execution file.

Parameters
xmlPathXML file name
allCaseRun type (True: all cases/False: current case)
bool Job::IsCanceled ( )

Returns True if the job is canceled.

Returns
Whether or not the Job is canceled
bool Job::IsFinished ( )

Returns True if the job has finished.

Returns
Whether or not the Job has finished
bool Job::IsValid ( )

Returns True if an object is valid.

Returns
Whether or not the Job objects in the list are valid
void Job::SetSubValue ( int  index,
String &  name,
Variant &  value 
)

Specifies a property value for SubJob.

Parameters
indexSubJob index
nameProperty name. See Properties Used for the Job Settings .
valueProperty value

SubJob is created by direct coupled analysis.
For example, if two magnetic field analysis input files are specified for one thermal analysis input file as a coupled pair, “Job” and “SubJob” will be created.

void Job::SetTargetStudyList ( StringList &  var)

Specifies the study list to run.

Parameters
verList of names or indexes of studies
void Job::SetValue ( String &  name,
Variant &  value 
)

Specifies the value of a property.

Parameters
nameProperty name. See Properties Used for the Job Settings .
valueProperty value
void Job::Submit ( bool  allCase = false)

Runs jobs.

Parameters
allCaseRun type (True: runs analysis for all cases/False: runs analysis for current case)