PxOpoolSetName()
Assign a name to an object pool.
- APPLIES TO
-
1.0.0
- SYNOPSIS
-
PxError_t PxOpoolSetName (PxOpool_t opool, const PxChar_t *buffer, PxUInt_t bufsize); - ARGUMENTS
|
|
|
|
|
- RETURN VALUES
-
-
PXROS-HR error code
-
- ERROR CODES
-
PXERR_NAME_BUFOVERFLOWThe name has been truncated
PXERR_PROT_PERMISSIONThe name is not readable for the calling task
PXERR_SERVICE_NOT_CONFIGUREDService has not been configured
PXERR_OBJ_ILLOBJThe passed object pool handle is not valid
PXERR_GLOBAL_ILLEGAL_COREThe object pool is not on the same core
- DESCRIPTION
-
PxOpoolSetNameassigns a name to the object poolopoolby copyingbufsizecharacters from memory pointed to bybuffer. If thebufziseis grater than the internal buffer for the object name, the name is truncated. The name is null terminated.
- SEE ALSO
- USAGE
-
#include "pxdef.h" const char opoolName[13] = "OBJPOOL-NAME"; // 12 characters + zero-terminator PxError_t err = PxOpoolSetName(opool, opoolName, 13); if (err != PXERR_NOERROR) { // Report error } char retOpoolName[13]; PxError_t err = PxOpoolGetName(opool, retOpoolName, 13); if (err != PXERR_NOERROR) { // Report error }