NCBI C++ ToolKit
Public Types | Public Member Functions | List of all members
CBDB_FieldStringCase Class Reference

Search Toolkit Book for CBDB_FieldStringCase

Case-insensitive (but case preserving) string field type. More...

#include <db/bdb/bdb_types.hpp>

+ Inheritance diagram for CBDB_FieldStringCase:
+ Collaboration diagram for CBDB_FieldStringCase:

Public Types

typedef CBDB_FieldString CParent
 
- Public Types inherited from CBDB_FieldStringBase
enum  EOverflowAction { eThrowOnOverflow , eTruncateOnOverflow , eTruncateOnOverflowLogError }
 
- Public Types inherited from CBDB_Field
enum  ELengthType { eFixedLength , eVariableLength }
 Length based classificator for fields (fixed-variable) More...
 

Public Member Functions

 CBDB_FieldStringCase ()
 
virtual CBDB_FieldConstruct (size_t buf_size) const
 Class factory for string fields. More...
 
 operator const char * () const
 
CBDB_FieldStringCaseoperator= (const CBDB_FieldString &str)
 
CBDB_FieldStringCaseoperator= (const CBDB_FieldStringCase &str)
 
CBDB_FieldStringCaseoperator= (const char *str)
 
CBDB_FieldStringCaseoperator= (const string &str)
 
virtual int Compare (const void *p1, const void *p2, bool) const
 Comparison function. More...
 
virtual BDB_CompareFunction GetCompareFunction (bool) const
 Return address to the type specific comparison function By default it's universal BDB_Compare. More...
 
- Public Member Functions inherited from CBDB_FieldString
 CBDB_FieldString ()
 
 operator const char * () const
 
CBDB_FieldStringoperator= (const CBDB_FieldString &str)
 
CBDB_FieldStringoperator= (const char *str)
 
CBDB_FieldStringoperator= (const string &str)
 
void Set (const char *str, EOverflowAction if_overflow=eThrowOnOverflow)
 
string Get () const
 
virtual string GetString () const
 
bool IsEmpty () const
 
bool IsBlank () const
 
virtual size_t GetDataLength (const void *buf) const
 Return current effective size of the buffer. More...
 
virtual void SetMinVal ()
 Set minimal possible value for the field type. More...
 
virtual void SetMaxVal ()
 Set maximum possible value for the field type. More...
 
virtual void SetString (const char *)
 
virtual void SetStdString (const string &str)
 
virtual void ToString (string &str) const
 
- Public Member Functions inherited from CBDB_Field
 CBDB_Field (ELengthType length_type=eFixedLength)
 
virtual ~CBDB_Field ()
 
bool IsNullable () const
 Return TRUE if field can be NULL. More...
 
void SetNull ()
 Assign field value to NULL. More...
 
bool IsNull () const
 Return TRUE if field is NULL. More...
 
const stringGetName () const
 Return symbolic name for the field. More...
 
const void * GetBuffer () const
 Get pointer to the data. NULL if not yet attached. More...
 
void * GetBuffer ()
 Get pointer to the data. NULL if not yet attached. More...
 
size_t GetBufferSize () const
 Return maximum possible buffer length. More...
 
size_t GetLength () const
 Get length of the actual data. More...
 
- Public Member Functions inherited from IBDB_Field
virtual ~IBDB_Field ()
 
- Public Member Functions inherited from IBDB_FieldConvert
virtual ~IBDB_FieldConvert ()
 
virtual void SetInt (int)
 
virtual void SetUint (unsigned)
 
virtual int GetInt () const
 
virtual unsigned GetUint () const
 
virtual void SetFloat (float)
 
virtual void SetDouble (double)
 

Additional Inherited Members

- Protected Member Functions inherited from CBDB_FieldStringBase
 CBDB_FieldStringBase ()
 
- Protected Member Functions inherited from CBDB_Field
int CompareWith (const CBDB_Field &field) const
 Field comparison function. More...
 
void CopyFrom (const CBDB_Field &src)
 Copies field value from another field. More...
 
bool IsVariableLength () const
 Return TRUE if it is a variable length variable (like string) More...
 
bool IsBufferAttached () const
 Return TRUE if external buffer has already been attached. More...
 
bool IsSameType (const CBDB_Field &field) const
 RTTI based check if fld is of the same type. More...
 
bool IsByteSwapped () const
 Return TRUE if field belongs to a file with an alternative byte order. More...
 
void SetNullable ()
 Mark field as "NULL" capable. More...
 
void SetNotNull ()
 Set "is NULL" flag to FALSE. More...
 
void SetName (const char *name)
 Set symbolic name for the field. More...
 
void SetBufferIdx (unsigned int idx)
 Set field position in the buffer manager. More...
 
void * Unpack ()
 Unpack the buffer which contains this field (using CBDB_BufferManager). More...
 
void SetBuffer (void *buf, size_t buf_size=0)
 Set external buffer pointer and length. More...
 
void SetBufferSize (size_t size)
 Set the buffer size. More...
 
void SetDataSize (size_t size)
 Set data size, taking into account possible extra data for some fields. More...
 
virtual size_t GetExtraDataLength ()
 Hook for defining extra data length. More...
 
void SetBufferManager (CBDB_BufferManager *owner)
 Set CBDB_BufferManager – which works as a memory manager for BDB fields. More...
 
void CopyFrom (const void *src_buf)
 Copy buffer value from the external source. More...
 
- Protected Attributes inherited from CBDB_Field
CBDB_BufferManagerm_BufferManager
 
struct {
   unsigned   CBDB_Field::VariableLength: 1
 
   unsigned   CBDB_Field::Attached: 1
 
   unsigned   CBDB_Field::Nullable: 1
 
m_Flags
 

Detailed Description

Case-insensitive (but case preserving) string field type.

Definition at line 1649 of file bdb_types.hpp.


The documentation for this class was generated from the following file:
Modified on Fri Sep 20 14:58:01 2024 by modify_doxy.py rev. 669887