TpVariant 类
V0.2.1TpUtils
2025-11-14
介绍
泛类型
基础信息
| 头文件: | include <TpVariant.h> |
|---|---|
| Cmake: | None |
| 发布版本: | V0.2.1 |
| 继承类: | |
| 派生类: |
Public 类型
enum TpVariant::VariantType
| 名称 | 值 | 描述 |
|---|---|---|
| EmptyVar | 0 | 类型为定义 |
| BoolVar | 1 | bool类型 |
| Int4Var | 2 | int32_t 类型 |
| Uint4Var | 3 | uint32_t 类型 |
| Int8Var | 4 | int64_t 类型 |
| Uint8Var | 5 | uint64_t 类型 |
| Real4Var | 6 | float 类型 |
| Real8Var | 7 | double 类型 |
| BstrVar | 8 | const char* 类型 |
| RectVar | 9 | |
| SizeVar | 10 | |
| PointVar | 11 | |
| Int1Var | 12 | int8_t 类型 |
| Uint1Var | 13 | uint8_t 类型 |
| Int2Var | 14 | int16_t 类型 |
| Uint2Var | 15 | uint16_t 类型 |
| VectorVar | 16 | |
| CustomVar | 17 | |
| SetVar | 1 << 8 |
Public 成员函数
| TpVariant() | ||
|---|---|---|
| TpVariant(bool bValue) | ||
| TpVariant(int8_t nValue) | ||
| TpVariant(uint8_t nValue) | ||
| TpVariant(int16_t nValue) | ||
| TpVariant(uint16_t nValue) | ||
| TpVariant(int32_t nValue) | ||
| TpVariant(uint32_t uValue) | ||
| TpVariant(int64_t nValue) | ||
| TpVariant(uint64_t uValue) | ||
| TpVariant(float fValue) | ||
| TpVariant(double dValue) | ||
| TpVariant(const char *pChar) | ||
| TpVariant(const std::string &strChar) | ||
| TpVariant(const TpString &strChar) | ||
| TpVariant(const TpRect &value) | ||
| TpVariant(const TpSize &value) | ||
| TpVariant(const TpPoint &value) | ||
| TpVariant(const TpVector< bool > &valueVector) | ||
| TpVariant(const TpVector< int8_t > &valueVector) | ||
| TpVariant(const TpVector< uint8_t > &valueVector) | ||
| TpVariant(const TpVector< int16_t > &valueVector) | ||
| TpVariant(const TpVector< uint16_t > &valueVector) | ||
| TpVariant(const TpVector< int32_t > &valueVector) | ||
| TpVariant(const TpVector< uint32_t > &valueVector) | ||
| TpVariant(const TpVector< int64_t > &valueVector) | ||
| TpVariant(const TpVector< uint64_t > &valueVector) | ||
| TpVariant(const TpVector< float > &valueVector) | ||
| TpVariant(const TpVector< double > &valueVector) | ||
| TpVariant(const TpVector< std::string > &valueVector) | ||
| TpVariant(const std::set< bool > &valueSet) | ||
| TpVariant(const std::set< int8_t > &valueSet) | ||
| TpVariant(const std::set< uint8_t > &valueSet) | ||
| TpVariant(const std::set< int16_t > &valueSet) | ||
| TpVariant(const std::set< uint16_t > &valueSet) | ||
| TpVariant(const std::set< int32_t > &valueSet) | ||
| TpVariant(const std::set< uint32_t > &valueSet) | ||
| TpVariant(const std::set< int64_t > &valueSet) | ||
| TpVariant(const std::set< uint64_t > &valueSet) | ||
| TpVariant(const std::set< float > &valueSet) | ||
| TpVariant(const std::set< double > &valueSet) | ||
| TpVariant(const std::set< std::string > &valueSet) | ||
| TpVariant(const VariantValue &value) | ||
| TpVariant(const TpVariant &other) | ||
| TpVariant(TpVector< TpVariant > *vectorVal) | ||
| TpVariant(const T &value) | ||
| ~TpVariant() | ||
| isNull() | ||
| TpVariant & TpVariant::operator= | operator=(bool bValue) | |
| TpVariant & TpVariant::operator= | operator=(int8_t nValue) | |
| TpVariant & TpVariant::operator= | operator=(uint8_t uValue) | |
| TpVariant & TpVariant::operator= | operator=(int16_t nValue) | |
| TpVariant & TpVariant::operator= | operator=(uint16_t uValue) | |
| TpVariant & TpVariant::operator= | operator=(int32_t nValue) | |
| TpVariant & TpVariant::operator= | operator=(uint32_t uValue) | |
| TpVariant & TpVariant::operator= | operator=(int64_t nValue) | |
| TpVariant & TpVariant::operator= | operator=(uint64_t uValue) | |
| TpVariant & TpVariant::operator= | operator=(float fValue) | |
| TpVariant & TpVariant::operator= | operator=(double dValue) | |
| TpVariant & TpVariant::operator= | operator=(TpRect value) | |
| TpVariant & TpVariant::operator= | operator=(TpSize value) | |
| TpVariant & TpVariant::operator= | operator=(TpPoint value) | |
| TpVariant & TpVariant::operator= | operator=(const char *pChar) | |
| TpVariant & TpVariant::operator= | operator=(const std::string &strChar) | |
| TpVariant & TpVariant::operator= | operator=(TpVector< TpVariant > *vectorVal) | |
| TpVariant & TpVariant::operator= | operator=(const TpVector< bool > &valueVector) | |
| TpVariant & TpVariant::operator= | operator=(const TpVector< int8_t > &valueVector) | |
| TpVariant & TpVariant::operator= | operator=(const TpVector< uint8_t > &valueVector) | |
| TpVariant & TpVariant::operator= | operator=(const TpVector< int16_t > &valueVector) | |
| TpVariant & TpVariant::operator= | operator=(const TpVector< uint16_t > &valueVector) | |
| TpVariant & TpVariant::operator= | operator=(const TpVector< int32_t > &valueVector) | |
| TpVariant & TpVariant::operator= | operator=(const TpVector< uint32_t > &valueVector) | |
| TpVariant & TpVariant::operator= | operator=(const TpVector< int64_t > &valueVector) | |
| TpVariant & TpVariant::operator= | operator=(const TpVector< uint64_t > &valueVector) | |
| TpVariant & TpVariant::operator= | operator=(const TpVector< float > &valueVector) | |
| TpVariant & TpVariant::operator= | operator=(const TpVector< double > &valueVector) | |
| TpVariant & TpVariant::operator= | operator=(const TpVector< std::string > &valueVector) | |
| TpVariant & TpVariant::operator= | operator=(const std::set< bool > &valueSet) | |
| TpVariant & TpVariant::operator= | operator=(const std::set< int8_t > &valueSet) | |
| TpVariant & TpVariant::operator= | operator=(const std::set< uint8_t > &valueSet) | |
| TpVariant & TpVariant::operator= | operator=(const std::set< int16_t > &valueSet) | |
| TpVariant & TpVariant::operator= | operator=(const std::set< uint16_t > &valueSet) | |
| TpVariant & TpVariant::operator= | operator=(const std::set< int32_t > &valueSet) | |
| TpVariant & TpVariant::operator= | operator=(const std::set< uint32_t > &valueSet) | |
| TpVariant & TpVariant::operator= | operator=(const std::set< int64_t > &valueSet) | |
| TpVariant & TpVariant::operator= | operator=(const std::set< uint64_t > &valueSet) | |
| TpVariant & TpVariant::operator= | operator=(const std::set< float > &valueSet) | |
| TpVariant & TpVariant::operator= | operator=(const std::set< double > &valueSet) | |
| TpVariant & TpVariant::operator= | operator=(const std::set< std::string > &valueSet) | |
| TpVariant & TpVariant::operator= | operator=(const VariantValue &value) | |
| TpVariant & TpVariant::operator= | operator=(const TpVariant &other) | |
| TpVariant & TpVariant::operator= | operator=(const T &value) | |
| operator==(const TpVariant &value) | ||
| operator!=(const VariantValue &value) | ||
| operator!=(const TpVariant &value) | ||
| operator bool() const | ||
| operator int8_t() const | ||
| operator uint8_t() const | ||
| operator int16_t() const | ||
| operator uint16_t() const | ||
| operator int32_t() const | ||
| operator uint32_t() const | ||
| operator int64_t() const | ||
| operator uint64_t() const | ||
| operator float() const | ||
| operator double() const | ||
| operator const char *() const | ||
| operator TpString() const | ||
| operator TpRect() const | ||
| operator TpSize() const | ||
| operator TpPoint() const | ||
| isVector() const | ||
| const TpVector< TpVariant > * TpVariant::toVectorPtr | toVectorPtr() const | |
| isCustom() const | ||
| toCustom() const | ||
| isBool() const | ||
| isInt8() const | ||
| isUint8() const | ||
| isInt16() const | ||
| isUint16() const | ||
| isInt32() const | ||
| isUint32() const | ||
| isInt64() const | ||
| isUint64() const | ||
| isFloat() const | ||
| isDouble() const | ||
| isConstChar() const | ||
| isString() const | ||
| isRect() const | ||
| isSize() const | ||
| isPoint() const | ||
| toBool(const bool &defaultValue=false) const | ||
| toInt8(const int8_t &defaultValue=0) const | ||
| toUInt8(const uint8_t &defaultValue=0) const | ||
| toInt16(const int16_t &defaultValue=0) const | ||
| toUInt16(const uint16_t &defaultValue=0) const | ||
| toInt32(const int32_t &defaultValue=0) const | ||
| toUInt32(const uint32_t &defaultValue=0) const | ||
| toInt64(const int64_t &defaultValue=0) const | ||
| toUint64(const uint64_t &defaultValue=0) const | ||
| toFloat(const float &defaultValue=0) const | ||
| toDouble(const double &defaultValue=0) const | ||
| TpString | toString(const TpString &defaultValue="") const | |
| TpRect | toRect(const TpRect &defaultValue=TpRect()) const | |
| TpSize | toSize(const TpSize &defaultValue=TpSize()) const | |
| TpPoint | toPoint(const TpPoint &defaultValue=TpPoint()) const | |
| TpVector< bool > | ToBoolArray() const | |
| TpVector< int8_t > | ToInt8Array() const | |
| TpVector< uint8_t > | ToUint8Array() const | |
| TpVector< int16_t > | ToInt16Array() const | |
| TpVector< uint16_t > | ToUint16Array() const | |
| TpVector< int32_t > | ToInt32Array() const | |
| TpVector< uint32_t > | ToUint32Array() const | |
| TpVector< int64_t > | ToInt64Array() const | |
| TpVector< uint64_t > | ToUint64Array() const | |
| TpVector< float > | ToFloatArray() const | |
| TpVector< double > | ToDoubleArray() const | |
| TpVector< std::string > | ToStringArray() const | |
| ToBoolSet() | ||
| ToInt8Set() | ||
| ToUint8Set() | ||
| ToInt16Set() | ||
| ToUint16Set() | ||
| ToInt32Set() | ||
| ToUint32Set() | ||
| ToInt64Set() | ||
| ToUint64Set() | ||
| ToFloatSet() | ||
| ToDoubleSet() | ||
| ToStringSet() | ||
| getVariantType() const | ||
| variantTypeName() const |
