summaryrefslogtreecommitdiff
path: root/libsql/osqltable.h
authormickeyl <mickeyl>2003-08-10 15:42:26 (UTC)
committer mickeyl <mickeyl>2003-08-10 15:42:26 (UTC)
commit90dbd3e9e7139c1280e71f9c77ed4362b8d0f367 (patch) (unidiff)
tree22f0947337ea9b21a1d8f56d04ce3292c9d6f19e /libsql/osqltable.h
parent616e919ff6aea6a30e18edb37128c229e806beae (diff)
downloadopie-90dbd3e9e7139c1280e71f9c77ed4362b8d0f367.zip
opie-90dbd3e9e7139c1280e71f9c77ed4362b8d0f367.tar.gz
opie-90dbd3e9e7139c1280e71f9c77ed4362b8d0f367.tar.bz2
libsql is now a part of libopie2
Diffstat (limited to 'libsql/osqltable.h') (more/less context) (ignore whitespace changes)
-rw-r--r--libsql/osqltable.h95
1 files changed, 0 insertions, 95 deletions
diff --git a/libsql/osqltable.h b/libsql/osqltable.h
deleted file mode 100644
index 87f7e74..0000000
--- a/libsql/osqltable.h
+++ b/dev/null
@@ -1,95 +0,0 @@
1#ifndef OSQL_TABLE_H
2#define OSQL_TABLE_H
3
4#include <qstring.h>
5#include <qvaluelist.h>
6#include <qvariant.h>
7
8/**
9 * OSQLTableItem saves one column of a complete
10 * table
11 */
12class OSQLTableItem {
13public:
14 typedef QValueList<OSQLTableItem> ValueList;
15 /**
16 * Type kinds ( to be extended )
17 */
18 enum Type { Undefined=-1, Integer=0, BigInteger =1,
19 Float = 2, VarChar = 4 };
20 /**
21 * A constructor
22 * @param type the Type of the Column
23 * @param fieldName the Name of the Column
24 * @param var a Variant
25 */
26 OSQLTableItem();
27 OSQLTableItem( enum Type type,
28 const QString& fieldName,
29 const QVariant& var= QVariant() );
30
31 /**
32 * copy c'tor
33 */
34 OSQLTableItem( const OSQLTableItem& );
35
36 /**
37 * d'tor
38 */
39 ~OSQLTableItem();
40
41 OSQLTableItem& operator=( const OSQLTableItem& );
42
43 /**
44 * the fieldName
45 */
46 QString fieldName() const;
47
48 /**
49 * the field Type
50 */
51 Type type() const;
52 QVariant more() const;
53private:
54 class OSQLTableItemPrivate;
55 OSQLTableItemPrivate* d;
56 Type m_type;
57 QString m_field;
58 QVariant m_var;
59};
60
61/**
62 * A OSQLTable consists of OSQLTableItems
63 */
64class OSQLTable {
65public:
66 typedef QValueList<OSQLTable> ValueList;
67
68 /**
69 * @param tableName the Name of the Table
70 */
71 OSQLTable(const QString& tableName);
72
73 /**
74 * d'tor
75 */
76 ~OSQLTable();
77
78 /**
79 * setColumns sets the Columns of the Table
80 */
81 void setColumns( const OSQLTableItem::ValueList& );
82
83 /**
84 * returns all columns of the table
85 */
86 OSQLTableItem::ValueList columns() const;
87
88 QString tableName()const;
89
90private:
91 QString m_table;
92 OSQLTableItem::ValueList m_list;
93};
94
95#endif