Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

oofBLOB Class Reference
[Local variables compatible with database fields.]

#include <oof4.h>

Inheritance diagram for oofBLOB:

Inheritance graph
[legend]
Collaboration diagram for oofBLOB:

Collaboration graph
[legend]
List of all members.

Detailed Description

Use to have local non-persistent variable of type dbBLOB.


Public Types

enum  FieldIsStandaloneT { eFieldIsStandalone }
enum  { kKeyLengthAutoCalculated = USHRT_MAX }

Public Member Functions

 oofBLOB ()
 oofBLOB (const oofBLOB &)
 oofBLOB (const dbBLOB &)
virtual ~oofBLOB ()
virtual dbFieldclone () const
oofBLOBoperator= (const oofBLOB &)
oofBLOBoperator= (const dbBLOB &)
virtual OOF_fieldTypes fieldType () const
virtual unsigned long fieldStorageLen () const
virtual bool isEmpty () const
virtual unsigned long length () const
virtual bool fieldIsBlob () const
bool isDirty () const
bool loaded () const
virtual void extract (std::ostream &os) const
char * bodyAddress () const
void reset () const
char * allocRoomFor (unsigned long) const
char * orphanBody () const
void adoptBody (void *body, unsigned long bodyLen) const
void adoptBody (void *body, unsigned long bodyLen, unsigned long usedLen) const
void append (const dbBLOB &)
virtual void append (const void *appendBody, unsigned long bodyLen, unsigned long usedLen=ULONG_MAX)
void setBytes (const void *buf, unsigned long bufLen)
 Copy the incoming buffer into our local buffer in mStorage.

void markDirty () const
void operator+= (const dbBLOB &)
virtual void generateTestData (bool generateRandom, unsigned long seedOrCount)
virtual void postCloneTableCleanup ()
virtual oofString name () const
void index (const OOF_IndexOptions=kIndexed)
void indexPartialKeyLen (unsigned short)
void setName (const char *name)
bool hasDefaultCalculator () const
void useCalculatorOnlyForDefaults ()
bool storesCalculatedValues () const
void storeCalculatedValues ()
bool usingCalculator () const
const char * tableName () const
bool fieldIsStandalone () const
virtual bool fieldIsSameTypeAs (const dbField *) const
virtual void describe (std::ostream &) const
 Provide human-readable information about object.

virtual OOF_fieldTypes nativeType () const
virtual unsigned long fieldMinWrapWidth () const
virtual unsigned long fieldUsualWrapWidth () const
dbTablefieldTable () const
unsigned long fieldDataLen () const
fieldNumT fieldNumber () const
virtual const oofStringfieldName () const
OOF_IndexOptions fieldIndexOptions () const
bool fieldIndexIgnoresNulls () const
bool fieldIndexIsCompressLeading () const
bool fieldIndexIsCompressPadding () const
virtual bool fieldIsIndexed () const
bool fieldIsPartiallyIndexed () const
virtual bool fieldIsKeywordIndexed () const
virtual bool fieldIsUniqueIndexed () const
unsigned short fieldNumIndexes () const
unsigned short fieldKeyLen () const
bool caseSensitive () const
virtual bool fieldIsBinary () const
virtual bool fieldIsVirtual () const
dbFieldequivalentFieldFromTable (dbTable *) const
bool valueIsDuplicate () const
virtual dbQueryClausevalueAsQueryLiteral () const
bool fieldIsJoinKey () const
 Checks if any relationships in field's table use field as join key.

virtual void clear ()
virtual void setString (const char *)
virtual void setNumber (long)
virtual oofString copyString () const
virtual void getChars (char *ioBuff, unsigned long &outLen) const
virtual const char * asChars () const
virtual bool insert (std::istream &, char fieldSep, char recSep)
virtual void copyValueFrom (const dbField *)
virtual void copyValueIfDifferent (const dbField *)
virtual bool validateContents ()
virtual oofWordParserwords () const
void saveDefaultCalculatedValue ()
void saveStoredCalculatedValue ()
bool hidden () const
void hide (bool hideIt=true)

Protected Member Functions

void SetLength (unsigned long len) const
void LoadField () const
void CalculateWith (dbCalculator *adoptedCalculator, bool useOnlyForDefaults)
virtual void CopyCalculatedValueToBuffer ()

Protected Attributes

dbBLOBstoragemStorage
bool mIsTextField
OOF_tableBackendmBackend
dbTablemTable
fieldNumT mFieldNumber
dbCalculatormCalculator
bool mHidden

Friends

void dbBLOBstorage::setChars (const char *str, unsigned long charLen)
void dbBLOBstorage::setBytes (const char *buf, unsigned long bufLen)


Member Enumeration Documentation

anonymous enum [inherited]
 

Enumeration values:
kKeyLengthAutoCalculated 

enum dbField::FieldIsStandaloneT [inherited]
 

Enumeration values:
eFieldIsStandalone 


Constructor & Destructor Documentation

oofBLOB::oofBLOB  ) 
 

oofBLOB::oofBLOB const oofBLOB  ) 
 

oofBLOB::oofBLOB const dbBLOB  ) 
 

virtual oofBLOB::~oofBLOB  )  [inline, virtual]
 


Member Function Documentation

void dbBLOB::adoptBody void *  body,
unsigned long  bodyLen,
unsigned long  usedLen
const [inherited]
 

void dbBLOB::adoptBody void *  body,
unsigned long  bodyLen
const [inherited]
 

char * dbBLOB::allocRoomFor unsigned  long  )  const [inline, inherited]
 

void dbBLOB::append const void *  appendBody,
unsigned long  bodyLen,
unsigned long  usedLen = ULONG_MAX
[virtual, inherited]
 

Reimplemented in dbText.

void dbBLOB::append const dbBLOB  )  [inherited]
 

const char * dbField::asChars  )  const [virtual, inherited]
 

Reimplemented in dbChar, and dbText.

char * dbBLOB::bodyAddress  )  const [inherited]
 

void dbField::CalculateWith dbCalculator adoptedCalculator,
bool  useOnlyForDefaults
[protected, inherited]
 

bool dbField::caseSensitive  )  const [inline, inherited]
 

virtual void dbField::clear  )  [inline, virtual, inherited]
 

Reimplemented in dbChar, dbText, dbFixedBinary, and dbNumericField.

dbField * oofBLOB::clone  )  const [virtual]
 

Reimplemented from dbBLOB.

void dbField::CopyCalculatedValueToBuffer  )  [protected, virtual, inherited]
 

Reimplemented in dbChar, dbText, dbShort, dbUshort, dbBool, dbLong, dbUlong, dbReal, dbDate, dbTime, and dbDateTime.

oofString dbField::copyString  )  const [virtual, inherited]
 

Reimplemented in dbChar, and dbText.

virtual void dbField::copyValueFrom const dbField  )  [inline, virtual, inherited]
 

Reimplemented in dbChar, dbText, dbShort, dbUshort, dbBool, dbLong, dbUlong, dbReal, dbDate, dbTime, and dbDateTime.

virtual void dbField::copyValueIfDifferent const dbField  )  [inline, virtual, inherited]
 

Reimplemented in dbChar, dbText, dbShort, dbUshort, dbBool, dbLong, dbUlong, dbReal, dbDate, dbTime, and dbDateTime.

void dbField::describe std::ostream &  os  )  const [virtual, inherited]
 

Provide human-readable information about object.

Overriden to provide much more detail particularly for dbTable::describe() which provides full schema.

Reimplemented from OOF_PublicBase.

Reimplemented in dbChar, dbFixedBinary, and dbRelRefBase.

dbField * dbField::equivalentFieldFromTable dbTable  )  const [inherited]
 

void dbBLOB::extract std::ostream &  os  )  const [virtual, inherited]
 

Reimplemented from dbField.

Reimplemented in dbText.

unsigned long dbField::fieldDataLen  )  const [inline, inherited]
 

bool dbField::fieldIndexIgnoresNulls  )  const [inline, inherited]
 

bool dbField::fieldIndexIsCompressLeading  )  const [inline, inherited]
 

bool dbField::fieldIndexIsCompressPadding  )  const [inline, inherited]
 

OOF_IndexOptions dbField::fieldIndexOptions  )  const [inline, inherited]
 

bool dbField::fieldIsBinary  )  const [virtual, inherited]
 

Reimplemented in dbChar, and dbText.

bool dbBLOB::fieldIsBlob  )  const [virtual, inherited]
 

Reimplemented from dbField.

bool dbField::fieldIsIndexed  )  const [virtual, inherited]
 

bool dbField::fieldIsJoinKey  )  const [inherited]
 

Checks if any relationships in field's table use field as join key.

Relatively expensive because it's iterating over all fields but all the function calls below are inline queries so will compile down well in release mode.

WARNING Doesn't fan out - if any other tables use this field as a join key then they are doing really weird stuff and the application programmer must add their own checks.

This feature originally added to support OOF_repEditSetupVisitor::VisitViewBandBody

bool dbField::fieldIsKeywordIndexed  )  const [virtual, inherited]
 

Reimplemented in dbChar, and dbText.

bool dbField::fieldIsPartiallyIndexed  )  const [inline, inherited]
 

bool dbField::fieldIsSameTypeAs const dbField  )  const [virtual, inherited]
 

Reimplemented in dbChar, dbFixedBinary, dbCompoundField, and dbRelRefBase.

bool dbField::fieldIsStandalone  )  const [inline, inherited]
 

bool dbField::fieldIsUniqueIndexed  )  const [virtual, inherited]
 

bool dbField::fieldIsVirtual  )  const [virtual, inherited]
 

Reimplemented in dbCompoundField, and dbRelRefBase.

unsigned short dbField::fieldKeyLen  )  const [inherited]
 

unsigned long dbField::fieldMinWrapWidth  )  const [virtual, inherited]
 

Reimplemented in dbNumericField.

const oofString & dbField::fieldName  )  const [inline, virtual, inherited]
 

Reimplemented in dbRelRefBase.

fieldNumT dbField::fieldNumber  )  const [inline, inherited]
 

unsigned short dbField::fieldNumIndexes  )  const [inline, inherited]
 

unsigned long dbBLOB::fieldStorageLen  )  const [virtual, inherited]
 

Implements dbField.

dbTable * dbField::fieldTable  )  const [inherited]
 

OOF_fieldTypes dbBLOB::fieldType  )  const [virtual, inherited]
 

Implements dbField.

Reimplemented in dbText.

unsigned long dbField::fieldUsualWrapWidth  )  const [virtual, inherited]
 

Reimplemented in dbChar, and dbText.

void dbBLOB::generateTestData bool  generateRandom,
unsigned long  seedOrCount
[virtual, inherited]
 

Reimplemented from dbField.

Reimplemented in dbText.

void dbField::getChars char *  ioBuff,
unsigned long &  outLen
const [virtual, inherited]
 

Reimplemented in dbChar, and dbText.

bool dbField::hasDefaultCalculator  )  const [inline, inherited]
 

bool OOF_PublicBase::hidden  )  const [inline, inherited]
 

void OOF_PublicBase::hide bool  hideIt = true  )  [inline, inherited]
 

void dbField::index const  OOF_IndexOptions = kIndexed  )  [inherited]
 

void dbField::indexPartialKeyLen unsigned  short  )  [inline, inherited]
 

bool dbField::insert std::istream &  ,
char  fieldSep,
char  recSep
[virtual, inherited]
 

Reimplemented in dbChar, dbText, dbShort, dbUshort, dbBool, dbLong, dbUlong, dbReal, dbDate, dbTime, and dbDateTime.

bool dbBLOB::isDirty  )  const [inline, inherited]
 

Reimplemented from dbField.

bool dbBLOB::isEmpty  )  const [virtual, inherited]
 

Reimplemented from dbField.

unsigned long dbBLOB::length  )  const [virtual, inherited]
 

Reimplemented in dbText.

bool dbBLOB::loaded  )  const [inline, inherited]
 

void dbBLOB::LoadField  )  const [protected, inherited]
 

void dbBLOB::markDirty  )  const [inline, inherited]
 

oofString dbField::name  )  const [virtual, inherited]
 

Reimplemented from OOF_PublicBase.

OOF_fieldTypes dbField::nativeType  )  const [virtual, inherited]
 

Reimplemented in dbText, dbBool, dbDate, dbTime, dbDateTime, and dbRelRefBase.

void dbBLOB::operator+= const dbBLOB  )  [inherited]
 

oofBLOB & oofBLOB::operator= const dbBLOB  ) 
 

Reimplemented from dbBLOB.

oofBLOB & oofBLOB::operator= const oofBLOB  ) 
 

char * dbBLOB::orphanBody  )  const [inline, inherited]
 

virtual void dbField::postCloneTableCleanup  )  [inline, virtual, inherited]
 

Reimplemented in dbRelRefBase.

void dbBLOB::reset  )  const [inline, inherited]
 

void dbField::saveDefaultCalculatedValue  )  [inherited]
 

void dbField::saveStoredCalculatedValue  )  [inherited]
 

void dbBLOB::setBytes const void *  buf,
unsigned long  bufLen
[inherited]
 

Copy the incoming buffer into our local buffer in mStorage.

Use adoptBody to avoid copying.

void dbBLOB::SetLength unsigned long  len  )  const [protected, inherited]
 

void dbField::setName const char *  name  )  [inherited]
 

virtual void dbField::setNumber long   )  [inline, virtual, inherited]
 

Reimplemented in dbChar, dbText, dbShort, dbUshort, dbBool, dbLong, dbUlong, dbReal, dbDate, and dbDateTime.

virtual void dbField::setString const char *   )  [inline, virtual, inherited]
 

Reimplemented in dbChar, dbText, dbFixedBinary, dbShort, dbUshort, dbBool, dbLong, dbUlong, dbReal, dbDate, and dbDateTime.

void dbField::storeCalculatedValues  )  [inline, inherited]
 

bool dbField::storesCalculatedValues  )  const [inline, inherited]
 

const char * dbField::tableName  )  const [inherited]
 

void dbField::useCalculatorOnlyForDefaults  )  [inline, inherited]
 

bool dbField::usingCalculator  )  const [inherited]
 

bool dbField::validateContents  )  [virtual, inherited]
 

dbQueryClause * dbField::valueAsQueryLiteral  )  const [virtual, inherited]
 

Reimplemented in dbChar, dbText, dbShort, dbUshort, dbBool, dbLong, dbUlong, dbReal, dbDate, dbTime, and dbDateTime.

bool dbField::valueIsDuplicate  )  const [inherited]
 

oofWordParser * dbField::words  )  const [virtual, inherited]
 

Reimplemented in dbChar, and dbText.


Friends And Related Function Documentation

void dbBLOBstorage::setBytes const char *  buf,
unsigned long  bufLen
[friend, inherited]
 

void dbBLOBstorage::setChars const char *  str,
unsigned long  charLen
[friend, inherited]
 


Member Data Documentation

OOF_tableBackend* dbField::mBackend [protected, inherited]
 

dbCalculator* dbField::mCalculator [protected, inherited]
 

fieldNumT dbField::mFieldNumber [protected, inherited]
 

bool OOF_PublicBase::mHidden [protected, inherited]
 

bool dbBLOB::mIsTextField [protected, inherited]
 

dbBLOBstorage* dbBLOB::mStorage [protected, inherited]
 

dbTable* dbField::mTable [protected, inherited]
 


The documentation for this class was generated from the following files:
Generated on Thu Jan 1 21:29:41 2004 for OOFILE by doxygen 1.3.5