PxMcResolveDefault()
Resolve a memory class default.
- APPLIES TO
-
1.0.0
- SYNOPSIS
-
PxMc_t PxMcResolveDefault (PxMc_t mcid); - ARGUMENTS
|
- RETURN VALUES
-
-
Resolved memory class
-
- ERROR CODES
-
PXERR_MC_ILLMCmcidis not a valid memory class. - DESCRIPTION
-
PxMcResolveDefaultresolves a memory class default. More precisely, it returnsmcid, ifmcidis notPXMcSystemdefaultorPXMcTaskdefault; otherwise it returns the memory class id corresponding to the specified default.
- IMPLEMENTATION GUIDELINES
-
- Before call
-
-
mcidmust be:-
a valid PXROS-HR memory class created with a
PxMcRequestcall (V). The validity ofmcidmay also be checked by thePxMcIsValidmacro (F). -
the symbolic value
PXMcSystemdefaultspecifying the system memory class (V) -
the symbolic value
PXMcTaskdefaultspecifying the task’s memory class (V)
-
-
- After call
-
-
The returned value is the id of type
PxMc_t. This id may be checked with one of the following macros:-
PxmcidIsValid()must be true. -
PxmcidGet()must not be_PXIllegalObjId. -
PxmcidError()must bePXERR_NOERRORotherwise the returned error code has to be interpreted (C).
-
-
- Best Practice
-
-
No restrictions.
-
- SEE ALSO
- USAGE
-
#include "pxdef.h" PxMc_t RetMc = PxMcResolveDefault(mcid) if ((PxmcidError(RetMc) != PXERR_NOERROR) || (PxmcidGet(RetMc) != PxmcidGet(Mc))) { // Report error; }