OpenScheduler

Syntax

OpenSchedulerResult OpenScheduler(OdId tOb, OpenSchedulerArg tArg)

Parameters

tOb. Moniker of the object that is a scheduled tasks container.

tArg. Parameters of container opening.

Description

The OpenScheduler operation opens a scheduled tasks container and returns context that enables the user to work with its contents.

Comments

The operation gets access to the container and the tasks created in this container. To execute the operation, in the tOb parameter specify moniker of the object that is a scheduled tasks container, and in the tArg parameter specify parameters of opening. The object moniker can be obtained on executing the GetObjects operation. In the tArg.metaGet field specify the pattern that will be sued to get container metadata on opening. If the tArg.metaGet field is not defined, the operation results only in the opened scheduled tasks container instance moniker.

Use the GeScheduler and SetScheduler operations to further work with the dictionary structure. To close an instance of scheduled tasks container, use the CloseScheduler operation.

Example

Below is the example of opening a scheduled tasks container instance. The request contains the moniker of the repository object that is scheduled tasks container. The response contains the moniker of opened instance of scheduled tasks container.

The example uses the FindObjectById function, which code is given in the Getting Object Description by Its Identifier example.

SOAP request:

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<OpenScheduler xmlns="http://www.fsight.ru/PP.SOM.Som">
<tOb xmlns="">
  <id>S1!M!6445</id>
  </tOb>
  <tArg xmlns="" />
  </OpenScheduler>
  </s:Body>
  </s:Envelope>

SOAP response:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<OpenSchedulerResult xmlns="http://www.fsight.ru/PP.SOM.Som" xmlns:q1="http://www.fsight.ru/PP.SOM.Som" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<id xmlns="">
  <id>S1!M!6445</id>
  </id>
  </OpenSchedulerResult>
  </soapenv:Body>
  </soapenv:Envelope>

JSON request:

{
"OpenScheduler" :
{
"tOb" :
{
"id" : "S1!M!6445"
},
"tArg" : ""
}
}

JSON response:

{
"OpenSchedulerResult" :
{
"id" :
{
"id" : "S1!M!6445"
}
}
}
public static OpenSchedulerResult OpenTasksContainern(MbId mb, string id)
{
var somClient = new SomPortTypeClient(); //Proxy object for operation execution
//Operation execution parameters
var tOpen = new OpenScheduler()
{
tArg = new OpenSchedulerArg(),
tOb = new OdId() { id = mb.id + "!" + FindObjectById(mb, id).k }
};
//Open scheduled tasks container
var tResult = somClient.OpenScheduler(tOpen);
return tResult;
}

See also:

Working with Modeling Container