Skip to main content

ModelCenter APIs 2026 R1 SP03

ModelCenter

Last update: 30.07.2026

constructor()

constructor(optionStr: String)

default constructor. A ModelCenter session is started and attached to Java

Throws

ModelCenterException

constructor(pstrm: Long, f: JFrame)

Connects this Java object to the specified session of ModelCenter. The resulting session is not currently attached to any thread. As soon as any call is made to ModelCenter, this object is attached to that thread. All subsequent calls must then be made on that thread. To create a new, unattached instance, call newInstance().

Parameters

pstrm A pointer to a stream generated by CoMarshalInterThreadInterfaceInStream() containing information about an IDispatch interface to ModelCenter. The caller should add a COM reference. The reference will be removed when this object is finalized (or closed)
f the JFrame that represents the ModelCenter window

constructor(pstrm: Long, f: JFrame, addRef: Boolean)

Connects this Java object to the specified session of ModelCenter. The resulting session is not currently attached to any thread. As soon as any call is made to ModelCenter, this object is attached to that thread. All subsequent calls must then be made on that thread. To create a new, unattached instance, call newInstance().

Parameters

pstrm A pointer to a stream generated by CoMarshalInterThreadInterfaceInStream() containing information about an IDispatch interface to ModelCenter. The caller should add a COM reference. The reference will be removed when this object is finalized (or closed)
f the JFrame that represents the ModelCenter window
addRef whether to add a reference count on this acquisition or not

Connect with Ansys