2011-06-14 14:31:25 +08:00
|
|
|
|
|
|
|
class CCMutableDictionary : public CCObject
|
|
|
|
{
|
2012-02-02 14:26:38 +08:00
|
|
|
TOLUA_TEMPLATE_BIND(K V, std::string CCObject*)
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
unsigned int count();
|
|
|
|
std::vector<std::string> allKeys();
|
|
|
|
std::vector<std::string> allKeysForObject(V object);
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
V objectForKey(K key);
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
bool setObject(V pObject, K key);
|
|
|
|
void removeObjectForKey(K key);
|
|
|
|
bool begin();
|
|
|
|
void endToLua();
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
V next(K* key = NULL);
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
void endToLua();
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
void removeAllObjects();
|
2011-06-14 14:31:25 +08:00
|
|
|
|
2012-02-02 14:26:38 +08:00
|
|
|
static CCMutableDictionary<K, V>* dictionaryWithDictionary(CCMutableDictionary<K, V>* srcDict);
|
2011-06-14 14:31:25 +08:00
|
|
|
};
|
|
|
|
|
|
|
|
typedef CCMutableDictionary<std::string, CCString*> CCStringToStringDictionary;
|