blob: 537953e41f626c8240df4339c9e726cb10e49313 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
/*
* palm-db-tools: Field definitions for flat-file database objects.
* Copyright (C) 2000 by Tom Dyas (tdyas@users.sourceforge.net)
*/
#ifndef __PALMLIB_FLATFILE_RECORD_H__
#define __PALMLIB_FLATFILE_RECORD_H__
#include <vector>
#include "Field.h"
namespace PalmLib {
namespace FlatFile {
// typedef std::vector<Field> Record;
class Record{
public:
const std::vector<Field> fields() const { return m_Fields; }
void appendField(Field newfield) { m_Fields.push_back(newfield); }
bool created() const { return m_New;}
void created(bool on){ m_New = on;}
bool secret() const { return m_Secret;}
void secret(bool on) { m_Secret = on;}
bool dirty() const { return m_Dirty; }
void dirty( bool on) { m_Dirty = on; }
pi_uint32_t unique_id() const { return m_UID; }
void unique_id(pi_uint32_t id) { m_UID = id; }
private:
std::vector<Field> m_Fields;
bool m_Secret;
bool m_New;
bool m_Dirty;
pi_uint32_t m_UID;
};
}
}
#endif
|