File IOBufferDataTypeMap.h¶
↰ Parent directory (DlSystem)
Contents
Definition (DlSystem/IOBufferDataTypeMap.h)¶
Includes¶
DlSystem/DlEnums.h(File DlEnums.h)DlSystem/DlError.h(File DlError.h)DlSystem/SnpeApiExportDefine.h(File SnpeApiExportDefine.h)stddef.h
Included By¶
Functions¶
Full File Listing¶
Typedefs
-
typedef void *Snpe_IOBufferDataTypeMap_Handle_t¶
A typedef to indicate a SNPE IOBufferDataTypeMap handle
Functions
-
Snpe_IOBufferDataTypeMap_Handle_t Snpe_IOBufferDataTypeMap_Create()¶
Creates a new Buffer Data type map
-
Snpe_ErrorCode_t Snpe_IOBufferDataTypeMap_Delete(Snpe_IOBufferDataTypeMap_Handle_t handle)¶
Destroys the map.
- Parameters
handle – [in] : Handle to access the IOBufferDataType map
- Returns
Error code. Returns SNPE_SUCCESS if destruction successful
-
Snpe_ErrorCode_t Snpe_IOBufferDataTypeMap_Add(Snpe_IOBufferDataTypeMap_Handle_t handle, const char *name, Snpe_IOBufferDataType_t bufferDataType)¶
Adds a name and the corresponding buffer data type to the map.
- Parameters
handle – [in] : Handle to access the IOBufferDataType map
name – [in] : The name of the buffer
bufferDataType – [in] : data type of the buffer
Note
If a buffer with the same name already exists, no new buffer is added.
-
Snpe_ErrorCode_t Snpe_IOBufferDataTypeMap_Remove(Snpe_IOBufferDataTypeMap_Handle_t handle, const char *name)¶
Removes a buffer name from the map.
- Parameters
handle – [in] : Handle to access the IOBufferDataType map
name – [in] : The name of the buffer
-
Snpe_IOBufferDataType_t Snpe_IOBufferDataTypeMap_GetBufferDataType(Snpe_IOBufferDataTypeMap_Handle_t handle, const char *name)¶
Returns the type of the named buffer.
- Parameters
handle – [in] : Handle to access the IOBufferDataType map
name – [in] : The name of the buffer
- Returns
The type of the buffer, or UNSPECIFIED if the buffer does not exist
-
Snpe_IOBufferDataType_t Snpe_IOBufferDataTypeMap_GetBufferDataTypeOfFirst(Snpe_IOBufferDataTypeMap_Handle_t handle)¶
Returns the type of the first buffer.
- Parameters
handle – : Handle to access the IOBufferDataType map
- Returns
The type of the first buffer, or SNPE_IO_BUFFER_DATATYPE_UNSPECIFIED if the map is empty.
-
size_t Snpe_IOBufferDataTypeMap_Size(Snpe_IOBufferDataTypeMap_Handle_t handle)¶
Returns the size of the buffer type map.
- Parameters
handle – [in] : Handle to access the IOBufferDataType map
- Returns
The size of the map
-
int Snpe_IOBufferDataTypeMap_Find(Snpe_IOBufferDataTypeMap_Handle_t handle, const char *name)¶
Checks the existence of the named buffer in the map.
- Parameters
handle – [in] : Handle to access the IOBufferDataType map
name – [in] : The name of the buffer
- Returns
1 if the named buffer exists, 0 otherwise.
-
Snpe_ErrorCode_t Snpe_IOBufferDataTypeMap_Clear(Snpe_IOBufferDataTypeMap_Handle_t handle)¶
Resets the map.
-
int Snpe_IOBufferDataTypeMap_Empty(Snpe_IOBufferDataTypeMap_Handle_t handle)¶
Checks whether the map is empty.
- Returns
1 if the map is empty, 0 otherwise.