Custom Platform Support Development Kit
1.3
|
Defines the interface that represents the dictionary. More...
#include <IFCMDictionary.h>
Public Member Functions | |
virtual FCM::Result _FCMCALL | Add (CStringRep8 pKey, FCMDictRecTypeID type, FCM::PVoid value, FCM::U_Int32 valueLen)=0 |
Inserts a value for a given key into a dictionary. More... | |
virtual FCM::Result _FCMCALL | AddLevel (CStringRep8 pKey, PIFCMDictionary &ppDict)=0 |
Create a dictionary and places it inside another under a given key. Optionally returns the new dict (if ppDict is not NULL). The dict returned is "owned" by outer dict and does not need to be released by the caller. More... | |
virtual FCM::Result _FCMCALL | Remove (CStringRep8 pKey)=0 |
Removes an entry for the given key from a dictionary. For reference counted types, count will simply be decremented. More... | |
virtual FCM::Result _FCMCALL | Get (CStringRep8 pKey, FCMDictRecTypeID type, FCM::PVoid pValue, FCM::U_Int32 &valueLen)=0 |
Returns a value from a dictionary given its key. The param value should be allocated and the allocation length should be passed in param valueLen. If the allocated buffer is less than the value stored in the dictionary then FCM_DICT_ERR_BUFFERTOOSMALL is returned. If the allocated buffer is greater than (or) equal to the length of value in dictionary then value in dictionary is coped into value param and the valueLen param is set to the length of value in dictionary. More... | |
virtual FCM::Result _FCMCALL | Clear ()=0 |
Removes all the values in dictionary. More... | |
virtual FCM::Result _FCMCALL | Count (FCM::U_Int32 &count)=0 |
Fetches the number of entries in the dictionary. More... | |
virtual FCM::Result _FCMCALL | GetNth (FCM::U_Int32 index, StringRep8 &pKey, FCMDictRecTypeID &type, FCM::U_Int32 &valueLen)=0 |
Returns info on the nth entry in a dictionary. More... | |
virtual FCM::Result _FCMCALL | GetInfo (CStringRep8 pKey, FCMDictRecTypeID &type, FCM::U_Int32 &valueLen)=0 |
Returns info on the entry with the given key in a dictionary. More... | |
Public Member Functions inherited from FCM::IFCMUnknown | |
virtual FCM::Result _FCMCALL | QueryInterface (ConstRefFCMIID pInterfaceID, FCM::PPVoid ppvObj)=0 |
Return pointers to supported interfaces on given object. More... | |
virtual FCM::U_Int32 _FCMCALL | AddRef ()=0 |
Increments the reference count on the given object. More... | |
virtual FCM::U_Int32 _FCMCALL | Release ()=0 |
Decrements the reference count on the given object. More... | |
Defines the interface that represents the dictionary.
|
pure virtual |
Inserts a value for a given key into a dictionary.
pKey | (IN) The key for the value being stored. |
type | (IN) The type of value being stored and it should be of type FCMDictRecTypeID. |
value | (IN) The value being stored. |
valueLen | (IN) The length of the value being stored. |
|
pure virtual |
Create a dictionary and places it inside another under a given key. Optionally returns the new dict (if ppDict is not NULL). The dict returned is "owned" by outer dict and does not need to be released by the caller.
pKey | (IN) The key for the dictionary being created. |
ppDict | (OUT) Set with the new dictionary created. |
|
pure virtual |
Removes all the values in dictionary.
|
pure virtual |
Fetches the number of entries in the dictionary.
count | (OUT) Populated with the number of entries in the dictionary. |
|
pure virtual |
Returns a value from a dictionary given its key. The param value should be allocated and the allocation length should be passed in param valueLen. If the allocated buffer is less than the value stored in the dictionary then FCM_DICT_ERR_BUFFERTOOSMALL is returned. If the allocated buffer is greater than (or) equal to the length of value in dictionary then value in dictionary is coped into value param and the valueLen param is set to the length of value in dictionary.
pKey | (IN) The key for value being looked for. |
type | (IN) The type of value being looked for and it should be of type FCMDictRecTypeID. |
pValue | (OUT) The value corresponding to the key is copied into this parameter. |
valueLen | (IN-OUT) The length of buffer allocated for value param.In successful case would conatin the actual length of value in the dictionary. |
|
pure virtual |
Returns info on the entry with the given key in a dictionary.
pKey | (IN) The key of the entry being looked for. |
type | (OUT) The type of the entry with the given key is copied into this parameter. |
valueLen | (OUT) The length of the entry with the given key is copied into this parameter. |
|
pure virtual |
Returns info on the nth entry in a dictionary.
index | (IN) The location of the entry in dictionary for which we need info. Index should range from 1 to Count. |
pKey | (OUT) The key of the nth entry is copied into this parameter. Should be freed using IFCMCalloc interface. |
type | (OUT) The type of the nth entry is copied into this parameter. |
valueLen | (OUT) The length of the nth entry is copied into this parameter. |
|
pure virtual |
Removes an entry for the given key from a dictionary. For reference counted types, count will simply be decremented.
pKey | (IN) The key for value being removed. |