Purpose
Synopsis
procedure run(mo:Model)
procedure run(mo:Model, plist:string|text)
Arguments
mo
|
Model to be executed
|
plist
|
String composed of model parameter initializations separated by commas
|
Further information
1. This procedure starts the execution of a model in a new thread: when the procedure returns, the model is not necessarily started (this may be delayed depending on the operating system load) and not necessarily terminated (the second model is executing concurrently to the caller).
2. By default the execution starts in the working directory of the Mosel instance (that might be different from the working directory of the calling model). A different initial path can be setup using
setworkdir.
3. When the execution of the model is completed (normal termination, interruption after calling
stop, or runtime error) or could not be started, an event of class
EVENT_END
is sent to the caller. The execution status is returned via the event value but it may also be obtained using
getstatus. The exit code related to the last execution may be retrieved using
getexitcode.
4. An event
EVENT_END is also received after a model has detached itself although its execution may continue (see
detach). In this case the model status is
RT_DETACHED and its associated instance is disconnected.
5. The specified model must have been previously initialized with
load and must not be running. If the same model has to be executed several times concurrently, it must be loaded several times in different model objects.
6. The parameter string
plist may be built and modified using
setmodpar and
resetmodpar. These routines handle transparently the protection of parameter values by adding the appropriate quotes when required.
Related topics
Module
© 2001-2025 Fair Isaac Corporation. All rights reserved. This documentation is the
property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not
convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except
solely for internal evaluation purposes to determine whether to purchase a license to the software
described in this documentation, or as otherwise set forth in a written software license agreement
between you and FICO (or a FICO affiliate). Use of this documentation and the software described in
it must conform strictly to the foregoing permitted uses, and no other use is permitted.