Wasabi ExpressPlay SDK for iOS  1.10
Typedefs | Functions
SHI_Properties Class

An indexed collection of typed name/value pairs. More...

Typedefs

typedef struct SHI_Properties SHI_Properties
 A SHI_Properties object represents a list of name/value pairs. More...
 

Functions

SHI_PUBLIC_API SHI_Result SHI_Properties_GetProperty (SHI_Properties *self, const char *name, SHI_DataType type, SHI_Data **property)
 Gets the value of a property. More...
 
SHI_PUBLIC_API SHI_Result SHI_Properties_SetProperty (SHI_Properties *self, const char *name, SHI_DataType type, const SHI_DataValue *value)
 Sets the value of a property. More...
 
SHI_PUBLIC_API SHI_Cardinal SHI_Properties_GetPropertyCount (SHI_Properties *self)
 Gets the number of properties in the list. More...
 
SHI_PUBLIC_API SHI_Result SHI_Properties_GetPropertyNames (SHI_Properties *self, SHI_Data **names)
 Gets an array containing the names of all the properties in the list. More...
 

Detailed Description

An indexed collection of typed name/value pairs.

Typedef Documentation

A SHI_Properties object represents a list of name/value pairs.

The list may contain read-only properties and/or read-write properties. Read-only properties cannot be set. Read-write properties can be set/updated by calling the SHI_Properties_SetProperty method.

Function Documentation

SHI_PUBLIC_API SHI_Result SHI_Properties_GetProperty ( SHI_Properties self,
const char *  name,
SHI_DataType  type,
SHI_Data **  property 
)

Gets the value of a property.

If this method succeeds, the SHI_Data object returned must be released before the property list is released. If no property with the specified name exists in the list, or if a property with that name exists, but with a different data type than the specified type, this method returns SHI_ERROR_NO_SUCH_ITEM.

Parameters
selfThe SHI_Properties from which a property value will be obtained.
nameName of the property.
typeData type of the property. If the type is unknown, this parameter can be set to SHI_DATA_TYPE_UNKNOWN.
propertyAddress of a SHI_Data pointer that will be set to refer to a SHI_Data object containing the property. If this pointer is NULL, no property is returned. (This may be used to test whether or not a certain property exists, without obtaining its value.)
SHI_PUBLIC_API SHI_Cardinal SHI_Properties_GetPropertyCount ( SHI_Properties self)

Gets the number of properties in the list.

Parameters
selfThe SHI_Properties list.
Returns
The number of properties in the list.
SHI_PUBLIC_API SHI_Result SHI_Properties_GetPropertyNames ( SHI_Properties self,
SHI_Data **  names 
)

Gets an array containing the names of all the properties in the list.

The SHI_Data object returned must be released before this list is released.

Parameters
selfThe SHI_Properties whose property names will be returned.
namesAddress of a SHI_Data pointer that will be set to refer to a SHI_Data object containing the list of names. The SHI_Data will be set to have value type SHI_DATA_TYPE_ARRAY. The elements in the array are of type SHI_DATA_TYPE_STRING.
SHI_PUBLIC_API SHI_Result SHI_Properties_SetProperty ( SHI_Properties self,
const char *  name,
SHI_DataType  type,
const SHI_DataValue value 
)

Sets the value of a property.

This method returns SHI_ERROR_NO_SUCH_ITEM if no property with the specified name exists in the list, or if a property with that name exists, but with a different data type than the specified type. This method fails with error code SHI_ERROR_NOT_SUPPORTED if the property list is read-only, or if the value of the property with the specified name is read-only.

Parameters
selfThe SHI_Properties for which a property value will be set.
nameName of the property.
typeData type of the property.
valuePointer to a SHI_DataValue to be used to set the property value.