...
Code Block | ||||
---|---|---|---|---|
| ||||
EdmiError edmiGetInstanceContainers(SdaiAppInstance currInst,
SdaiOptions options,
SdaiContainer *containerId,
SdaiInteger *numberOfContainers,
SdaiContainer **containerIds);
|
Returns a buffer with containerIds of all the instance containers of given type in which a given instanceId is contained.
...
Arguments
...
Type | Name | Comment | |
SdaiAppInstance | currInst | A numeric instanceID that uniquely identifies the instance of interest in the EDMdatabase. | |
SdaiOptions | options | Specifies what type of instance containers to search for. The option value may be a bitwise OR of any combination of the options listed below. | If this parameter is unset, the default behaviour is that the <containerId> parameter will receive the id of any lockable container in which the instance is located. |
SdaiContainer | containerId | Variable that will receive the the Id of the lockable container in which the instance Id is located. No instance may be contained by more than one lockable instance container at the same time. Hence, only a single container Id may result when | searcing searching for lockable containers. If the instance is not located in any lockable containers, this parameter will be unset. |
SdaiInteger | numberOfContainers | The total number of instance container ids returned in the <containerIds> buffer. | |
SdaiContainer | containerIds | Variable that will receive a pointer to a buffer of container ids in which the instance given in <currInst> is located. When searching for lockable containers, the id of the container will be returned in this buffer as well as in the parameter <containerId> |
...
Return Value
...
Insert excerpt | ||||||
---|---|---|---|---|---|---|
|
Options
...
Option | Comment |
---|---|
CONTAINER | Search for all plain instance containers. |
LOCK_CONTAINER | Search for any lockable instance container. |
MODEL_CONTAINER | Search for all plain instance model containers. |
MODEL_LOCK_CONTAINER | Search for any lockable instance model container. |
...
Example
...
Code Block | ||
---|---|---|
| ||
EdmiError rstat;
SdaiInstance instId;
SdaiContainer contId;
SdaiContainer *pConts;
. . .
if (rstat = edmiGetInstanceContainers(instId, 0,
&contId, &nCont, &pConts)) {
printf("\nError %d in edmiGetInstanceContainers: %s", rstat,
edmiGetErrorText(rstat));
goto err;
}
if (contId) {
printf("\nInstance %d is locked in container %d", instId, contId);
} else {
printf("\nInstance %d is unlocked");
}
. . . |
See also
Filter by label (Content by label) | ||||||
---|---|---|---|---|---|---|
|