sdaiValidateAggrSize
Note: This function can only be used with the EDMmodelChecker license key fully installed.
Checks whether the actual number of elements in all aggregates owned by the specified instance are according to the specifications found in the EXPRESS schema that defines the actual aggregates.
This operation is applicable only to application instances.
The model that holds the actual aggregate must be open before this function can be successfully performed.
Related functions: sdaiValidateInstance edmiValidateInstance , edmiValidateInstanceType , edmiValidateInstanceTypeBN , edmiValidateModel , edmiValidateModelBN
Header:
#include "sdai.h"
Prototype:
SdaiLogical sdaiValidateAggrSize(SdaiAppInstance instance);
Arguments:
instance |
A numeric instanceID that uniquely identifies the instance of interest in the EDMdatabase, that is the instance that owns all aggregates to be checked. |
Returns:
A SdaiLogical value that has the following value:
sdaiTRUE : The number of elements in all aggregates owned by the specified instance are according to the specification found in the EXPRESS schema that defines the actual aggregates.
sdaiFALSE: At least one of the aggregates owned by the specified instance has more or less number of elements according to the specification found in the Express schema that defines the actual aggregates.
sdaiUNKNOWN: Use sdaiErrorQuery to check for error in operation.
Examples:
SdaiAppInstance anInst;
SdaiLogical result;
...
result = sdaiValidateAggrSize(anInst);
switch (result) {
case sdaiTRUE:
. . . /* No aggregate size violation */
break;
case sdaiFALSE:
. . . /* Aggregate size violation detected */
break;
default:
. . . /* Unset elements or possibly errors in operation */
}
. . .