75 #if defined(XB_INDEX_ANY)
84 #define XB_CHAR_FLD 'C'
85 #define XB_LOGICAL_FLD 'L'
86 #define XB_NUMERIC_FLD 'N'
87 #define XB_DATE_FLD 'D'
88 #define XB_MEMO_FLD 'M'
89 #define XB_FLOAT_FLD 'F'
102 #define XB_DONTOVERLAY 0
104 #define XB_CHAREOF '\x1A'
105 #define XB_CHARHDR '\x0D'
175 #if defined(XB_INDEX_ANY)
187 #ifdef XB_MEMO_FIELDS
209 #if defined(XB_INDEX_ANY)
215 xbLong CalcCheckSum(
void );
216 xbShort CloseDatabase(
bool deleteIndexes = 0);
244 xbShort GetFirstRecord(
void );
262 xbLong NoOfRecords(
void );
263 xbLong PhysicalNoOfRecords(
void);
264 xbShort OpenDatabase(
const char * );
266 void (*packStatusFunc)(
xbLong itemNum,
xbLong numItems) = 0,
267 void (*indexStatusFunc)(
xbLong itemNum,
xbLong numItems) = 0);
281 xbShort UndeleteRecord(
void );
285 const char *GetField(
xbShort FieldNo)
const;
286 const char *GetField(
const char *Name)
const;
290 xbShort GetField(
const char *Name,
char *Buf)
const;
291 xbShort GetRawField(
const char *Name,
char *Buf)
const;
292 xbShort GetField(
const char *Name,
char *Buf,
xbShort RecBufSw)
const;
296 char * GetFieldName(
const xbShort );
297 xbShort GetFieldNo(
const char * FieldName )
const;
298 char GetFieldType(
const xbShort FieldNo )
const;
300 xbShort GetLogicalField(
const char * FieldName );
302 char * GetStringField(
const xbShort FieldNo );
303 char * GetStringField(
const char * FieldName );
307 xbShort PutField(
const char *Name,
const char *buf);
308 xbShort PutRawField(
const char *Name,
const char *buf );
309 xbShort ValidLogicalData(
const char * );
310 xbShort ValidNumericData(
const char * );
312 xbLong GetLongField(
const char *FieldName)
const;
317 xbFloat GetFloatField(
const char * FieldName );
322 xbDouble GetDoubleField(
const char *);
330 xbShort ExclusiveUnlock(
void );
334 const xbShort LockType )
const;
357 #ifdef XB_MEMO_FIELDS
359 char * Buf,
const xbShort LockOption );
362 const char * Buf,
const xbShort LockOption );
365 xbShort MemoFieldsPresent(
void )
const;
366 xbLong CalcLastDataBlock();
368 LastDataBlock,
xbLong & Location,
xbLong &PreviousNode );
370 Location,
const xbLong PreviousNode );
373 xbShort DumpMemoFreeChain(
void );
374 void DumpMemoHeader(
void )
const;
375 void DumpMemoBlock(
void )
const;
399 #if defined(XB_INDEX_ANY)
416 #ifdef XB_MEMO_FIELDS
473 void InitVars(
void );
478 #ifdef XB_MEMO_FIELDS
480 xbShort CreateMemoFile(
void );
483 xbShort GetMemoBlockSize(
void ) {
return MemoHeader.BlockSize; }
486 const xbLong Len,
const char * Buf );
489 xbShort UpdateHeadNextNode(
void )
const;
491 xbShort IsType3Dbt(
void )
const {
return( Version==(
char)0x83 ? 1:0 ); }
492 xbShort IsType4Dbt(
void )
const
493 {
return (( Version==(
char)0x8B || Version==(
char)0x8E ) ? 1:0 );}
496 #endif // __XB_DBF_H__
xbShort GetRecordLen(void)
Return record length.
Definition: dbf.h:260
xbIxList * NextIx
Definition: dbf.h:173
char Version
Definition: dbf.h:435
unsigned char FieldLen
Definition: dbf.h:146
void RealDeleteOff(void)
Definition: dbf.h:391
void AutoLockOff(void)
Turn autolock off.
Definition: dbf.h:351
xbXBase class
Definition: xbase.h:138
double xbDouble
xbDouble type
Definition: xtypes.h:76
xbString & GetDbfName(void)
Return Dbf name.
Definition: dbf.h:239
xbULong NoOfRecs
Definition: dbf.h:443
xbShort NoOfFields
Definition: dbf.h:407
xbLong DbfTell(void)
Return the current position in the dbf file.
Definition: dbf.h:222
xbString DatabaseName
Definition: dbf.h:405
xbNtx class
Definition: ntx.h:119
xbNdx class
Definition: ndx.h:136
#define XBDLLEXPORT
Definition: xbase.h:101
unsigned char NoOfDecs
Definition: dbf.h:147
char UpdateDD
Definition: dbf.h:438
xbULong CurRec
Definition: dbf.h:455
class XBDLLEXPORT xbDbf
Definition: xbase.h:119
xbShort AutoLock
Definition: dbf.h:456
unsigned char NoOfDecs
Definition: dbf.h:161
xbString IxName
Definition: dbf.h:174
xbShort GetDbfStatus(void)
Return status.
Definition: dbf.h:243
char * Address
Definition: dbf.h:157
xbString class
Definition: xbstring.h:69
char * Address2
Definition: dbf.h:162
#define XB_NO_ERROR
Definition: retcodes.h:58
xbLong FieldCount(void)
Return number of fields.
Definition: dbf.h:235
xbShort DeleteAllRecords(void)
Delete all records.
Definition: dbf.h:226
xbShort XFV
Definition: dbf.h:406
char * fp
Definition: dbf.h:163
xbUShort HeaderLen
Definition: dbf.h:444
unsigned long int xbULong
xbULong type
Definition: xtypes.h:57
xbIxList struct
Definition: dbf.h:172
xbIndex class
Definition: index.h:67
float xbFloat
xbFloat type
Definition: xtypes.h:72
FILE * fp
Definition: dbf.h:411
xbShort ExclusiveLock(const xbShort)
Definition: dbf.h:340
xbShort RealDelete
Definition: dbf.h:459
xbShort LongFieldLen
Definition: dbf.h:165
Defines a field in an XBase file header (DBF file header)
Definition: dbf.h:154
xbShort GetRealDelete(void)
Return whether "real" deletes are on or off.
Definition: dbf.h:397
char DbfStatus
Definition: dbf.h:408
#define xbLong
Definition: xtypes.h:67
xbIxList * MdxList
Definition: dbf.h:452
short int xbShort
xbShort type
Definition: xtypes.h:65
xbShort GetAutoLock(void)
Return whether or not autolocking is on or off.
Definition: dbf.h:355
char * RecBuf
Definition: dbf.h:413
unsigned char FieldLen
Definition: dbf.h:160
xbXBase * xbase
Definition: dbf.h:205
char * RecBuf2
Definition: dbf.h:414
xbLong GetCurRecNo(void)
Return current record number.
Definition: dbf.h:251
xbShort LockDatabase(const xbShort, const xbShort, const xbLong)
Definition: dbf.h:338
char UpdateMM
Definition: dbf.h:437
char * GetRecordBuf(void)
Return a pointer to the record buffer.
Definition: dbf.h:256
xbIxList * NdxList
Definition: dbf.h:453
char Type
Definition: dbf.h:143
xbMH struct
Definition: dbf.h:201
xbUShort RecordLen
Definition: dbf.h:445
unsigned short int xbUShort
xbUShort type
Definition: xtypes.h:61
char UpdateYY
Definition: dbf.h:436
xbULong RealNumRecs
Definition: dbf.h:449
void AutoLockOn(void)
Turn autolock on.
Definition: dbf.h:347
void RealDeleteOn(void)
Turn on "real" deletes.
Definition: dbf.h:388
Used to define the fields in a database (DBF file).
Definition: dbf.h:141
void ResetNoOfRecs(void)
Set number of records to zero????
Definition: dbf.h:275
xbULong FirstFreeRec
Definition: dbf.h:448
char Type
Definition: dbf.h:156
xbShort ExclusiveUnlock(void)
Definition: dbf.h:341
xbShort UndeleteAllRecords(void)
Undelete all records.
Definition: dbf.h:280
xbSchemaRec * SchemaPtr
Definition: dbf.h:412
xbIxList * FreeIxList
Definition: dbf.h:454