CCBValue* CCBValue::create(Array *pArrValue) { CCBValue *ret = new CCBValue(); if (ret) { ret->_arrValue = pArrValue; ret->mType = kArrayValue; ret->autorelease(); } return ret; }
CCBValue* CCBValue::create(unsigned char byte) { CCBValue *ret = new CCBValue(); if (ret) { ret->mValue.nValue = byte; ret->mType = kUnsignedCharValue; ret->autorelease(); } return ret; }
CCBValue* CCBValue::create(const char *pStringValue) { CCBValue *ret = new CCBValue(); if (ret) { ret->_value = pStringValue; ret->mType = kStringValue; ret->autorelease(); } return ret; }
CCBValue* CCBValue::create(float fValue) { CCBValue *ret = new CCBValue(); if (ret) { ret->mValue.fValue = fValue; ret->mType = kFloatValue; ret->autorelease(); } return ret; }
CCBValue* CCBValue::create(bool vValue) { CCBValue *ret = new CCBValue(); if (ret) { ret->mValue.nValue = vValue ? 1 : 0; ret->mType = kBoolValue; ret->autorelease(); } return ret; }
CCBValue* CCBValue::create(bool vValue) { CCBValue *ret = new CCBValue(); if (ret) { ret->m_tValue.intValue = vValue ? 1 : 0; ret->m_eType = Type::BOOL; ret->autorelease(); } return ret; }
CCBValue* CCBValue::create(int nValue) { CCBValue *ret = new CCBValue(); if (ret) { ret->mValue.nValue = nValue; ret->mType = kIntValue; ret->autorelease(); } return ret; }
CCBValue* CCBValue::create(float fValue) { CCBValue *ret = new CCBValue(); if (ret) { ret->m_tValue.floatValue = fValue; ret->m_eType = Type::FLOAT; ret->autorelease(); } return ret; }
CCBValue* CCBValue::create(int nValue) { CCBValue *ret = new CCBValue(); if (ret) { ret->m_tValue.intValue = nValue; ret->m_eType = Type::INT; ret->autorelease(); } return ret; }
CCBValue* CCBValue::create(Array *pArrValue) { CCBValue *ret = new CCBValue(); if (ret) { ret->m_pArrValue = pArrValue; ret->m_eType = Type::ARRAY; ret->autorelease(); } return ret; }
CCBValue* CCBValue::create(const char *pStringValue) { CCBValue *ret = new CCBValue(); if (ret) { ret->m_sStrValue = pStringValue; ret->m_eType = Type::STRING; ret->autorelease(); } return ret; }
CCBValue* CCBValue::create(unsigned char byte) { CCBValue *ret = new CCBValue(); if (ret) { ret->m_tValue.intValue = byte; ret->m_eType = Type::UNSIGNED_CHAR; ret->autorelease(); } return ret; }