NCBI C++ ToolKit
|
Classes | |
class | CVariantException |
class | CVariant |
CVariant –. More... | |
Enumerations | |
enum | CVariantException::EErrCode { CVariantException::eVariant } |
enum | EDateTimeFormat { eShort , eLong , eLonger , eDateOnly , eTimeOnly , eDateTimeOffset } |
Variables | |
class CDB_Object * | CVariant::m_data |
unique_ptr< I_BlobDescriptor > | CVariant::m_descr |
enum EDateTimeFormat |
Enumerator | |
---|---|
eShort | |
eLong | |
eLonger | |
eDateOnly | |
eTimeOnly | |
eDateTimeOffset |
Definition at line 81 of file variant.hpp.
Enumerator | |
---|---|
eVariant |
Definition at line 62 of file variant.hpp.
Definition at line 763 of file variant.cpp.
References eDB_Text, eDB_VarCharMax, CVariant::GetData(), CVariant::GetType(), str(), and CVariant::x_Inapplicable_Method().
size_t CVariant::Append | ( | const TStringUCS2 & | str | ) |
Definition at line 778 of file variant.cpp.
References eDB_Text, eDB_VarCharMax, CVariant::GetData(), CVariant::GetType(), str(), and CVariant::x_Inapplicable_Method().
size_t CVariant::Append | ( | const void * | buf, |
size_t | len | ||
) |
Definition at line 753 of file variant.cpp.
References buf, CVariant::GetData(), CVariant::GetType(), CDB_Object::IsBlobType(), len, and CVariant::x_Inapplicable_Method().
Referenced by CDbapiTest::Run(), and s_ConvertValue().
Definition at line 721 of file variant.cpp.
References CVariant::GetString(), and CVariant::IsNull().
|
static |
Definition at line 243 of file variant.cpp.
References CVariant::CVariant(), CTime::eEmpty, s_TranslateDateTimeFormat(), and t.
|
static |
Definition at line 236 of file variant.cpp.
References CVariant::CVariant(), CTime::eEmpty, and s_TranslateDateTimeFormat().
Definition at line 70 of file variant.cpp.
References CVariant::CVariant(), and n.
Definition at line 65 of file variant.cpp.
References CVariant::CVariant().
Definition at line 196 of file variant.cpp.
References CVariant::CVariant(), len, and ncbi::grid::netcache::search::fields::size.
Referenced by CResultSet::Init().
Definition at line 125 of file variant.cpp.
References CVariant::CVariant().
Definition at line 130 of file variant.cpp.
References b, and CVariant::CVariant().
Definition at line 171 of file variant.cpp.
References CVariant::CVariant(), and ncbi::grid::netcache::search::fields::size.
Referenced by CResultSet::Init().
|
static |
Definition at line 176 of file variant.cpp.
References CVariant::CVariant(), CNullable< TValue, TNullToValue >::IsNull(), and ncbi::grid::netcache::search::fields::size.
|
private |
|
explicit |
Definition at line 386 of file variant.cpp.
|
explicit |
Definition at line 357 of file variant.cpp.
|
explicit |
Definition at line 394 of file variant.cpp.
CVariant::CVariant | ( | const class CTime & | v, |
EDateTimeFormat | fmt | ||
) |
Definition at line 439 of file variant.cpp.
References CDB_Object::Clone(), CVariant::GetData(), and CVariant::m_data.
Definition at line 389 of file variant.cpp.
|
explicit |
Definition at line 399 of file variant.cpp.
|
explicit |
Definition at line 383 of file variant.cpp.
CVariant::CVariant | ( | EDB_Type | type, |
size_t | size = 0 |
||
) |
Definition at line 260 of file variant.cpp.
References eDB_BigDateTime, eDB_BigInt, eDB_Binary, eDB_Bit, eDB_Char, eDB_DateTime, eDB_Double, eDB_Float, eDB_Image, eDB_Int, eDB_LongBinary, eDB_LongChar, eDB_Numeric, eDB_SmallDateTime, eDB_SmallInt, eDB_Text, eDB_TinyInt, eDB_UnsupportedType, eDB_VarBinary, eDB_VarBinaryMax, eDB_VarChar, eDB_VarCharMax, eRetriable_No, CDB_Object::GetTypeName(), CVariant::m_data, NCBI_THROW, and ncbi::grid::netcache::search::fields::size.
|
explicit |
Definition at line 380 of file variant.cpp.
|
explicit |
Definition at line 374 of file variant.cpp.
|
explicit |
Definition at line 368 of file variant.cpp.
|
explicit |
Definition at line 364 of file variant.cpp.
|
explicit |
Definition at line 377 of file variant.cpp.
Definition at line 49 of file variant.cpp.
Definition at line 217 of file variant.cpp.
References CVariant::CVariant(), and t.
Definition at line 212 of file variant.cpp.
References CVariant::CVariant().
Definition at line 120 of file variant.cpp.
References CVariant::CVariant(), and CNullable< TValue, TNullToValue >::IsNull().
|
static |
Definition at line 115 of file variant.cpp.
References CVariant::CVariant().
Definition at line 110 of file variant.cpp.
References CVariant::CVariant(), and CNullable< TValue, TNullToValue >::IsNull().
|
static |
Definition at line 105 of file variant.cpp.
References CVariant::CVariant().
Referenced by CDbapiTest::Run().
bool CVariant::GetBit | ( | void | ) | const |
Definition at line 680 of file variant.cpp.
References eDB_Bit, CVariant::GetData(), CVariant::IsNull(), and CVariant::x_Verify_AssignType().
Referenced by CVariant::GetString(), operator==(), and s_ConvertValue().
|
inline |
Definition at line 301 of file variant.hpp.
References eRetriable_No, CVariant::m_descr, NCBI_THROW, and NULL.
Referenced by CVariant::GetITDescriptor(), and CRemoteQFB::GetOStream().
size_t CVariant::GetBlobSize | ( | ) | const |
Definition at line 793 of file variant.cpp.
References CVariant::GetData(), CVariant::GetType(), CDB_Object::IsBlobType(), and CVariant::x_Inapplicable_Method().
Referenced by CDbapiTest::Run().
EBulkEnc CVariant::GetBulkInsertionEnc | ( | void | ) | const |
Definition at line 1060 of file variant.cpp.
References eBulkEnc_RawBytes, eDB_Char, eDB_LongChar, eDB_Text, eDB_VarChar, eDB_VarCharMax, CVariant::GetData(), and CVariant::GetType().
Uint1 CVariant::GetByte | ( | void | ) | const |
Definition at line 626 of file variant.cpp.
References eDB_TinyInt, eDB_UnsupportedType, CVariant::GetData(), CVariant::GetType(), CVariant::IsNull(), and CVariant::x_Verify_AssignType().
Referenced by CVariant::GetString(), operator<(), operator==(), and s_ConvertValue().
Definition at line 700 of file variant.cpp.
References CTime::Clear(), eDB_BigDateTime, eDB_DateTime, eDB_SmallDateTime, eDB_UnsupportedType, CVariant::GetData(), CVariant::GetType(), CVariant::IsNull(), NULL, and CVariant::x_Verify_AssignType().
Referenced by CVariant::GetString(), operator<(), operator==(), and s_ConvertValue().
|
inline |
Definition at line 269 of file variant.hpp.
References CVariant::m_data.
Referenced by CVariant::Append(), CDBAPIBulkInsert::Bind(), CVariant::CVariant(), CStatement::ExecuteLast(), CVariant::GetBit(), CVariant::GetBlobSize(), CVariant::GetBulkInsertionEnc(), CVariant::GetByte(), CVariant::GetCTime(), CVariant::GetDouble(), CVariant::GetFloat(), CVariant::GetInt2(), CVariant::GetInt4(), CVariant::GetInt8(), CVariant::GetNumeric(), CVariant::GetString(), CVariant::IsNull(), CVariant::MoveTo(), CVariant::operator=(), CVariant::Read(), CVariant::SetBulkInsertionEnc(), CVariant::SetNull(), CCallableStatement::SetOutputParam(), CCallableStatement::SetParam(), CCursor::SetParam(), and CVariant::Truncate().
double CVariant::GetDouble | ( | void | ) | const |
Definition at line 658 of file variant.cpp.
References eDB_Double, eDB_Float, eDB_Int, eDB_SmallInt, eDB_TinyInt, eDB_UnsupportedType, CVariant::GetData(), CVariant::GetType(), CVariant::IsNull(), and CVariant::x_Verify_AssignType().
Referenced by CVariant::GetString(), operator<(), operator==(), and s_ConvertValue().
|
overridevirtual |
Definition at line 55 of file variant.cpp.
References CVariantException::eVariant, and CException::GetErrCodeString().
float CVariant::GetFloat | ( | void | ) | const |
Definition at line 640 of file variant.cpp.
References eDB_Float, eDB_SmallInt, eDB_TinyInt, eDB_UnsupportedType, CVariant::GetData(), CVariant::GetType(), CVariant::IsNull(), and CVariant::x_Verify_AssignType().
Referenced by CVariant::GetString(), operator<(), operator==(), CDbapiTest::Run(), and s_ConvertValue().
Int2 CVariant::GetInt2 | ( | void | ) | const |
Definition at line 610 of file variant.cpp.
References eDB_SmallInt, eDB_TinyInt, eDB_UnsupportedType, CVariant::GetData(), CVariant::GetType(), CVariant::IsNull(), and CVariant::x_Verify_AssignType().
Referenced by CVariant::GetString(), operator<(), operator==(), and s_ConvertValue().
Int4 CVariant::GetInt4 | ( | void | ) | const |
Definition at line 592 of file variant.cpp.
References eDB_Int, eDB_SmallInt, eDB_TinyInt, eDB_UnsupportedType, CVariant::GetData(), CVariant::GetType(), CVariant::IsNull(), and CVariant::x_Verify_AssignType().
Referenced by CVariant::GetString(), operator<(), operator==(), CDbapiTest::Run(), and s_ConvertValue().
Int8 CVariant::GetInt8 | ( | void | ) | const |
Definition at line 571 of file variant.cpp.
References eDB_BigInt, eDB_Int, eDB_SmallInt, eDB_TinyInt, eDB_UnsupportedType, CVariant::GetData(), CVariant::GetType(), CVariant::IsNull(), and CVariant::x_Verify_AssignType().
Referenced by CVariant::GetString(), operator<(), operator==(), and s_ConvertValue().
|
inline |
Definition at line 237 of file variant.hpp.
References CVariant::GetBlobDescriptor().
CDB_Object * CVariant::GetNonNullData | ( | ) | const |
Definition at line 456 of file variant.cpp.
References eRetriable_No, CVariant::m_data, and NCBI_THROW.
Referenced by CResultSet::x_CacheItems().
string CVariant::GetNumeric | ( | void | ) | const |
Definition at line 690 of file variant.cpp.
References eDB_Numeric, CVariant::GetData(), CVariant::IsNull(), and CVariant::x_Verify_AssignType().
string CVariant::GetString | ( | void | ) | const |
Definition at line 471 of file variant.cpp.
References _ASSERT, CTime::AsString(), b, NStr::BoolToString(), CDB_LongBinary::DataSize(), NStr::DoubleToString(), eDB_BigDateTime, eDB_BigInt, eDB_Binary, eDB_Bit, eDB_Char, eDB_DateTime, eDB_Double, eDB_Float, eDB_Image, eDB_Int, eDB_LongBinary, eDB_LongChar, eDB_Numeric, eDB_SmallDateTime, eDB_SmallInt, eDB_Text, eDB_TinyInt, eDB_UnsupportedType, eDB_VarBinary, eDB_VarBinaryMax, eDB_VarChar, eDB_VarCharMax, CVariant::GetBit(), CVariant::GetByte(), CVariant::GetCTime(), CVariant::GetData(), CVariant::GetDouble(), CVariant::GetFloat(), CVariant::GetInt2(), CVariant::GetInt4(), CVariant::GetInt8(), CVariant::GetType(), NStr::Int8ToString(), NStr::IntToString(), CVariant::IsNull(), n, CDB_Stream::PeekAt(), CDB_VarBinary::Size(), CDB_Stream::Size(), string, CDB_VarBinary::Value(), CDB_LongBinary::Value(), and CVariant::x_Verify_AssignType().
Referenced by CQueryBlobImpl::AsIStream(), CVariant::AsNotNullString(), CQueryBlobImpl::AsVector(), operator<(), operator==(), CDbapiTest::Run(), and s_ConvertValue().
|
inline |
Definition at line 274 of file variant.hpp.
References CDB_Object::GetType(), and CVariant::m_data.
Referenced by CVariant::Append(), CQuery::CField::CField(), CVariant::GetBlobSize(), CVariant::GetBulkInsertionEnc(), CVariant::GetByte(), CVariant::GetCTime(), CVariant::GetDouble(), CVariant::GetFloat(), CVariant::GetInt2(), CVariant::GetInt4(), CVariant::GetInt8(), CVariant::GetString(), CVariant::MoveTo(), operator<(), CVariant::operator=(), operator==(), CVariant::Read(), s_ConvertValue(), CVariant::SetBulkInsertionEnc(), CQueryImpl::SetNullParameter(), CQueryImpl::SetParameter(), CVariant::Truncate(), CVariant::x_Inapplicable_Method(), and CVariant::x_Verify_AssignType().
Definition at line 80 of file variant.cpp.
References CVariant::CVariant(), and n.
Definition at line 75 of file variant.cpp.
References CVariant::CVariant().
bool CVariant::IsNull | ( | void | ) | const |
Definition at line 729 of file variant.cpp.
References CVariant::GetData(), CDB_Object::IsNULL(), and true.
Referenced by CVariant::AsNotNullString(), CVariant::GetBit(), CVariant::GetByte(), CVariant::GetCTime(), CVariant::GetDouble(), CVariant::GetFloat(), CVariant::GetInt2(), CVariant::GetInt4(), CVariant::GetInt8(), CVariant::GetNumeric(), CVariant::GetString(), operator<(), operator==(), CVariant::Read(), and CDbapiTest::Run().
Definition at line 181 of file variant.cpp.
References CVariant::CVariant(), and len.
Referenced by CResultSet::Init().
Definition at line 135 of file variant.cpp.
References CVariant::CVariant(), and len.
Referenced by CResultSet::Init().
|
static |
Definition at line 140 of file variant.cpp.
References CVariant::CVariant(), CNullable< TValue, TNullToValue >::IsNull(), and len.
bool CVariant::MoveTo | ( | size_t | pos | ) | const |
Definition at line 813 of file variant.cpp.
References CVariant::GetData(), CVariant::GetType(), CDB_Object::IsBlobType(), and CVariant::x_Inapplicable_Method().
CVariantException::NCBI_EXCEPTION_DEFAULT | ( | CVariantException | , |
CException | |||
) |
Definition at line 251 of file variant.cpp.
References CVariant::CVariant(), and precision.
Definition at line 336 of file variant.hpp.
References v2.
Definition at line 949 of file variant.cpp.
References eDB_BigDateTime, eDB_BigInt, eDB_Char, eDB_DateTime, eDB_Double, eDB_Float, eDB_Int, eDB_LongChar, eDB_SmallDateTime, eDB_SmallInt, eDB_TinyInt, eDB_VarChar, eRetriable_No, CVariant::GetByte(), CVariant::GetCTime(), CVariant::GetDouble(), CVariant::GetFloat(), CVariant::GetInt2(), CVariant::GetInt4(), CVariant::GetInt8(), CVariant::GetString(), CVariant::GetType(), CDB_Object::GetTypeName(), CVariant::IsNull(), less(), NCBI_THROW, and v2.
Definition at line 348 of file variant.hpp.
References v2.
Definition at line 918 of file variant.cpp.
References eDB_Bit, CVariant::GetData(), and CVariant::x_Verify_AssignType().
Definition at line 884 of file variant.cpp.
References eDB_Char, eDB_LongChar, eDB_UnsupportedType, eDB_VarChar, CVariant::GetData(), CVariant::GetType(), and CVariant::x_Verify_AssignType().
Definition at line 925 of file variant.cpp.
References eDB_BigDateTime, eDB_DateTime, eDB_SmallDateTime, eDB_UnsupportedType, CVariant::GetData(), CVariant::GetType(), and CVariant::x_Verify_AssignType().
Definition at line 943 of file variant.cpp.
References CDB_Object::AssignValue(), and CVariant::m_data.
Definition at line 858 of file variant.cpp.
References eDB_Double, CVariant::GetData(), and CVariant::x_Verify_AssignType().
Definition at line 851 of file variant.cpp.
References eDB_Float, CVariant::GetData(), and CVariant::x_Verify_AssignType().
Definition at line 837 of file variant.cpp.
References eDB_SmallInt, CVariant::GetData(), and CVariant::x_Verify_AssignType().
Definition at line 830 of file variant.cpp.
References eDB_Int, CVariant::GetData(), and CVariant::x_Verify_AssignType().
Definition at line 823 of file variant.cpp.
References eDB_BigInt, CVariant::GetData(), and CVariant::x_Verify_AssignType().
Definition at line 865 of file variant.cpp.
References eDB_Char, eDB_LongChar, eDB_UnsupportedType, eDB_VarChar, CVariant::GetData(), CVariant::GetType(), and CVariant::x_Verify_AssignType().
CVariant & CVariant::operator= | ( | const TStringUCS2 & | v | ) |
Definition at line 903 of file variant.cpp.
References eDB_Char, eDB_LongChar, eDB_UnsupportedType, eDB_VarChar, CVariant::GetData(), CVariant::GetType(), and CVariant::x_Verify_AssignType().
Definition at line 844 of file variant.cpp.
References eDB_TinyInt, CVariant::GetData(), and CVariant::x_Verify_AssignType().
Definition at line 1002 of file variant.cpp.
References eDB_BigDateTime, eDB_BigInt, eDB_Binary, eDB_Bit, eDB_Char, eDB_DateTime, eDB_Double, eDB_Float, eDB_Int, eDB_LongChar, eDB_SmallDateTime, eDB_SmallInt, eDB_TinyInt, eDB_VarBinary, eDB_VarChar, eRetriable_No, CVariant::GetBit(), CVariant::GetByte(), CVariant::GetCTime(), CVariant::GetDouble(), CVariant::GetFloat(), CVariant::GetInt2(), CVariant::GetInt4(), CVariant::GetInt8(), CVariant::GetString(), CVariant::GetType(), CDB_Object::GetTypeName(), CVariant::IsNull(), less(), NCBI_THROW, and v2.
Definition at line 342 of file variant.hpp.
References v2.
Definition at line 354 of file variant.hpp.
References v2.
size_t CVariant::Read | ( | void * | buf, |
size_t | len | ||
) | const |
Definition at line 740 of file variant.cpp.
References buf, CVariant::GetData(), CVariant::GetType(), CDB_Object::IsBlobType(), CVariant::IsNull(), len, and CVariant::x_Inapplicable_Method().
Referenced by CDbapiTest::Run().
|
inline |
Definition at line 311 of file variant.hpp.
References CVariant::m_descr.
Referenced by CRemoteQFB::GetBookmark(), and CVariant::ReleaseITDescriptor().
|
inline |
Definition at line 239 of file variant.hpp.
References CVariant::ReleaseBlobDescriptor().
|
inline |
Definition at line 295 of file variant.hpp.
References CVariant::m_descr.
Referenced by CVariant::SetITDescriptor(), and CResultSet::x_CacheItems().
void CVariant::SetBulkInsertionEnc | ( | EBulkEnc | e | ) |
Definition at line 1080 of file variant.cpp.
References eDB_Char, eDB_LongChar, eDB_Text, eDB_VarChar, eDB_VarCharMax, CVariant::GetData(), and CVariant::GetType().
|
protected |
Definition at line 464 of file variant.cpp.
References CVariant::m_data.
|
inline |
Definition at line 236 of file variant.hpp.
References CVariant::SetBlobDescriptor().
void CVariant::SetNull | ( | ) |
Definition at line 734 of file variant.cpp.
References CDB_Object::AssignNULL(), and CVariant::GetData().
Definition at line 206 of file variant.cpp.
References CVariant::CVariant(), and t.
Definition at line 201 of file variant.cpp.
References CVariant::CVariant().
Definition at line 90 of file variant.cpp.
References CVariant::CVariant(), and n.
Definition at line 85 of file variant.cpp.
References CVariant::CVariant().
Definition at line 100 of file variant.cpp.
References CVariant::CVariant(), and n.
Definition at line 95 of file variant.cpp.
References CVariant::CVariant().
void CVariant::Truncate | ( | size_t | len = kMax_UInt | ) |
Definition at line 803 of file variant.cpp.
References CVariant::GetData(), CVariant::GetType(), CDB_Object::IsBlobType(), len, and CVariant::x_Inapplicable_Method().
Referenced by CDbapiTest::Run(), and s_ConvertValue().
Definition at line 186 of file variant.cpp.
References CVariant::CVariant(), and len.
Referenced by python::CCursor::GetCVariant(), and s_ConvertValue().
Definition at line 191 of file variant.cpp.
References CVariant::CVariant(), and len.
Definition at line 146 of file variant.cpp.
References CVariant::CVariant(), and len.
|
static |
Definition at line 151 of file variant.cpp.
References CVariant::CVariant(), CNullable< TValue, TNullToValue >::IsNull(), and len.
Definition at line 157 of file variant.cpp.
References CVariant::CVariant(), and len.
|
static |
Definition at line 163 of file variant.cpp.
References CVariant::CVariant(), CNullable< TValue, TNullToValue >::IsNull(), and len.
|
inlineprivate |
Definition at line 327 of file variant.hpp.
References eRetriable_No, CVariant::GetType(), CDB_Object::GetTypeName(), and NCBI_THROW.
Referenced by CVariant::Append(), CVariant::GetBlobSize(), CVariant::MoveTo(), CVariant::Read(), and CVariant::Truncate().
Definition at line 317 of file variant.hpp.
References eDB_UnsupportedType, eRetriable_No, CVariant::GetType(), CDB_Object::GetTypeName(), and NCBI_THROW.
Referenced by CVariant::GetBit(), CVariant::GetByte(), CVariant::GetCTime(), CVariant::GetDouble(), CVariant::GetFloat(), CVariant::GetInt2(), CVariant::GetInt4(), CVariant::GetInt8(), CVariant::GetNumeric(), CVariant::GetString(), and CVariant::operator=().
CVariant::~CVariant | ( | void | ) |
Definition at line 447 of file variant.cpp.
References kEmptyStr, CVariant::m_data, and NCBI_CATCH_ALL_X.
|
private |
Definition at line 259 of file variant.hpp.
Referenced by CVariant::CVariant(), CVariant::GetData(), CVariant::GetNonNullData(), CVariant::GetType(), CVariant::operator=(), CVariant::SetData(), and CVariant::~CVariant().
|
mutableprivate |
Definition at line 260 of file variant.hpp.
Referenced by CVariant::GetBlobDescriptor(), CVariant::ReleaseBlobDescriptor(), and CVariant::SetBlobDescriptor().