53 #ifndef HEADER_INCLUDED__SAGA_API__table_dbase_H
54 #define HEADER_INCLUDED__SAGA_API__table_dbase_H
74 #define DBF_FT_NONE '\0'
75 #define DBF_FT_CHARACTER 'C'
76 #define DBF_FT_DATE 'D'
77 #define DBF_FT_FLOAT 'F'
78 #define DBF_FT_NUMERIC 'N'
79 #define DBF_FT_LOGICAL 'L'
80 #define DBF_FT_MEMO 'M'
104 {
return( m_nFields ); }
107 {
return( iField >= 0 && iField < m_nFields ? m_Fields[iField].Name : NULL ); }
110 {
return( iField >= 0 && iField < m_nFields ? m_Fields[iField].Type :
DBF_FT_NONE ); }
113 {
return( iField >= 0 && iField < m_nFields ? m_Fields[iField].Width : 0 ); }
116 {
return( iField >= 0 && iField < m_nFields ? m_Fields[iField].Decimals : 0 ); }
135 bool asInt (
int iField,
int &Value);
136 bool asDouble (
int iField,
double &Value);
140 bool Set_Value (
int iField,
double Value);
148 char Name[12], Type, Displacement[4], WorkAreaID, ProductionIdx;
150 unsigned char Width, Decimals;
158 char LastUpdate[3], Transaction, LanguageDrvID, ProductionIdx;
160 unsigned char FileType, bEncrypted;
167 bool m_bReadOnly, m_bModified;
171 short m_nHeaderBytes, m_nRecordBytes;
173 int m_nFields, m_nRecords, m_Encoding;
179 TDBF_Field *m_Fields;
182 void Header_Write (
void);
183 bool Header_Read (
void);
185 void Init_Record (
void);
197 #endif // #ifndef HEADER_INCLUDED__SAGA_API__table_dbase_H