Returns the numeric repositoryID that uniquely identifies the repository in the EDMdatabase that contains the specified model.
Related functions: edmiMoveModel , edmiMoveModelBN
Header:
#include "sdai.h"
Prototype:
EdmiError edmiGetModelRepository(SdaiModel model,
SdaiRepository *repository);
Arguments:
model |
A numeric modelID that uniquely identifies the model of interest in the EDMdatabase. |
repository |
Address of the variable that will receive the numeric repositoryID that uniquely identifies the repository in the EDMdatabase that contains the specified model. |
Returns:
A completion code of datatype EdmiError is the returned function value. The completion code has the following values:
Completion code = 0 : Operation successfully performed.
Completion code != 0: Error in operation. Completion code is an EDMinterface error code. Use edmiGetErrorText to get the error text corresponding to the error code.
EXAMPLE
SdaiModel model;
SdaiRepository repository;
EdmiError rstat;
. . .
if (rstat = edmiGetModelRepository (model, &repository)) {
/* Error in operation */
printf("\nError: %s in edmiGetModelRepository\n",
edmiGetErrorText(rstat));
goto error;
}
printf ("\nModel: %lu is located in repository: %lu", model, repository);
. . .