File StringList.h

Parent directory (DlSystem)

Definition (DlSystem/StringList.h)

Includes

Full File Listing

Typedefs

typedef void *Snpe_StringList_Handle_t

A typedef to indicate a SNPE StringList handle

Functions

Snpe_StringList_Handle_t Snpe_StringList_Create()

Constructs a StringList and returns a handle to it

Returns

the handle to the created StringList

Snpe_StringList_Handle_t Snpe_StringList_CreateSize(size_t size)

Constructs a StringList and returns a handle to it

Parameters

size[in] : size of list

Returns

the handle to the created StringList

Snpe_StringList_Handle_t Snpe_StringList_CreateCopy(Snpe_StringList_Handle_t other)

Constructs a StringList and returns a handle to it

Parameters

other[in] : StringList handle to be copied from

Returns

the handle to the created StringList

Snpe_ErrorCode_t Snpe_StringList_Delete(Snpe_StringList_Handle_t stringListHandle)

Destroys/frees a StringList

Parameters

stringListHandle[in] : Handle to access the stringList

Returns

SNPE_SUCCESS if Delete operation successful.

Snpe_ErrorCode_t Snpe_StringList_Append(Snpe_StringList_Handle_t stringListHandle, const char *string)

Append a string to the list.

Parameters
  • stringListHandle[in] : Handle to access the stringList

  • str[in] Null-terminated ASCII string to append to the list.

Returns

SNPE_SUCCESS if Append operation successful.

const char *Snpe_StringList_At(Snpe_StringList_Handle_t stringListHandle, size_t idx)

Returns the string at the indicated position, or an empty string if the positions is greater than the size of the list.

Parameters
  • stringListHandle[in] : Handle to access the stringList

  • idx[in] Position in the list of the desired string

Returns

the string at the indicated position

const char **Snpe_StringList_Begin(Snpe_StringList_Handle_t stringListHandle)

Pointer to the first string in the list. Can be used to iterate through the list.

Parameters

stringListHandle[in] : Handle to access the stringList

Returns

Pointer to the first string in the list.

const char **Snpe_StringList_End(Snpe_StringList_Handle_t stringListHandle)

Pointer to one after the last string in the list. Can be used to iterate through the list.

Parameters

stringListHandle[in] : Handle to access the stringList

Returns

Pointer to one after the last string in the list

size_t Snpe_StringList_Size(Snpe_StringList_Handle_t stringListHandle)

Return the number of valid string pointers held by this list.

Parameters

stringListHandle[in] : Handle to access the stringList

Returns

The size of the StringList

Snpe_ErrorCode_t Snpe_StringList_Assign(Snpe_StringList_Handle_t src, Snpe_StringList_Handle_t dst)

Copy-assigns the contents of src into dst

Parameters
  • src – Source StringList handle

  • dst – Destination StringList handle

Returns

SNPE_SUCCESS on successful copy-assignment