Properties

The Model class has the following properties. All properties have getter and setter methods.

Connection settings

Both properties below must be specified when constructing a model.

Property

Type

Description

Host

String

Required. A string that contains the name of the server running ITP/OnLine Server. The name can be specified either in (IPv4) Internet Protocol dotted address notation (a.b.c.d) or as a resolvable host name.

Port

String

Required. A string that contains the port to connect to ITP/OnLine Server. The port can be specified either in numerical format or as a resolvable port name (TCP/IP service name).

Identification

Property

Type

Description

JobId

String

Required. A string that contains the Job Identifier for this job.

UserId

String

Required. The user that is doing this request.

ApplicationId

String

Optional. Additional accounting information.

SessionId

String

This identifier will be initialized by ITP/OnLine Server during a "Start" call. If a single Model instance is used to manage a complete model run, this will automatically ensure that Continue/Cancel/Finish calls pass the right session id. Else, the user of this API is responsible for remembering this value, and setting it before issuing one of these subsequent calls.

Database info

Property

Type

Description

Environment

String

Optional. The environment that the model runs in. If not set, the default environment will be used (if configured).

DBUserId

String

Optional. Database User ID

DBPassword

String

Optional. Database password for the given DBUser. If set, these credentials will initially be passed to the Start and the Continue call. They will override any credentials that have been set in the Connection Configuration file.

Note

The password will not be encrypted.

Processing modes

Property

Type

Description

History

boolean

Optional. If set to True, return a list of all interact answers (in XML format) together with the final document. False by default.

Input and Output files

Property

Type

Description

Info

String

Required. This property contains the path to the file in which all XML data will be returned. The content of the XML file will depend on the call, and on the return value of the call.

Result

String

The UNC path that the final document will be stored at. It contains the value that was passed as a Result argument to the Start method.
If this UNC path is a location accessible from the machine on which the Java API is installed, the API will retrieve the document from ITP/Server and store it at this location. Ensure that the API is able to write to this location. Also see the property DocumentOnServer for alternative use.

Preview

String

Optional. The UNC path that the previews will be stored at. A preview is an intermediate result document, as it is at the moment of an interact. Also see Result. If no preview filename is specified, no previews will be generated. It is allowed to use the same UNC path for both the preview and the final document.

Data

String

Optional. The UNC path to an XML data file. Also see Result.

This XML data can be passed as an input file to ITP/Server. Only used with the ITP XML File Connection.

If the Data property is not set and the ITP Model needs an XML data file, an XML Form will be send out with an INTERACT. In this INTERACT the user is asked to select the XML data file.

DocumentOverwrite

boolean

Optional. Specifies whether existing result documents may be overwritten. True by default.

ResultFormat

String

Optional. The format of the final document. Can be either "NATIVE" or "PDF" (case insensitive). Default is "NATIVE", which means that the word processor format of the model itself gets generated.

PreviewFormat

String

Optional. The format of the previews. Can be either "NATIVE" (the default) or "PDF" (case insensitive).

ResultOnServer

boolean

If True, the Result is relative to the ITP/Server machine. For example, a local path on the ITP/Server machine. In that case, ITP/Server is responsible for storing the result document at that location. The final document will not be transferred to the Java API then. If this value is False, the final document will be transferred and stored on the machine where the API has been installed. False by default.

PreviewOnServer

boolean

Optional. See DocumentOnServer. False by default.

DataOnServer

boolean

Optional. See DocumentOnServer. If True, the API will not transmit any XML data file. False by default.

FileExtension

String

Read only. Contains the extension of the result document. Possible values are;

unknown: Unable to determine the type of the file.
doc: Microsoft Word document.
docx: Microsoft Word Open XML document.
ps: PostScript file.
pdf: PDF document.
sxw: OpenOffice.org/StarOffice document.
odt: OpenOffice.org 2.2 document
lwp: WordPro document.
wpd: WordPerfect document.

ProcessPreviewParams

String

Optional. A string that will be passed to the ProcessPreview exit point. This can be used freely to pass information to the exit point, for example to specify which action it should take.

ProcessResultParams

String

Optional. A string that will be passed to the ProcessResult exit point. This can be used freely to pass information to the exit point, for example to specify which action it should take.

FormVersion

String

Optional. The maximum feature level that is supported by the client of the API. This allows clients to protect themselves against new features in the INTERACT XMLs returned by ITP/Server. Instead of sending back an XML with these features, ITP/Server will return an error