Version 6.4.0.0.beta1, tag libreoffice-6.4.0.0.beta1
[LibreOffice.git] / odk / examples / DevelopersGuide / Database / DriverSkeleton / propertyids.hxx
blobfa3a5ffd2f3068c270f92e625737eecdc8c9dfa0
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*************************************************************************
4 * The Contents of this file are made available subject to the terms of
5 * the BSD license.
7 * Copyright 2000, 2010 Oracle and/or its affiliates.
8 * All rights reserved.
10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions
12 * are met:
13 * 1. Redistributions of source code must retain the above copyright
14 * notice, this list of conditions and the following disclaimer.
15 * 2. Redistributions in binary form must reproduce the above copyright
16 * notice, this list of conditions and the following disclaimer in the
17 * documentation and/or other materials provided with the distribution.
18 * 3. Neither the name of Sun Microsystems, Inc. nor the names of its
19 * contributors may be used to endorse or promote products derived
20 * from this software without specific prior written permission.
22 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
23 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
24 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
25 * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
26 * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
27 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
28 * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
29 * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
30 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
31 * TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
32 * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
34 *************************************************************************/
36 #ifndef INCLUDED_EXAMPLES_DATABASE_DRIVERSKELETON_PROPERTYIDS_HXX
37 #define INCLUDED_EXAMPLES_DATABASE_DRIVERSKELETON_PROPERTYIDS_HXX
39 // this define has to be set to split the names into different dll's or so's
40 // every dll has his own set of property names
41 #include <rtl/ustring.hxx>
42 #include <map>
44 namespace connectivity
46 namespace skeleton
48 class OPropertyMap
50 ::std::map<sal_Int32 , rtl_uString*> m_aPropertyMap;
52 ::rtl::OUString fillValue(sal_Int32 _nIndex);
53 public:
54 OPropertyMap()
57 ~OPropertyMap();
58 ::rtl::OUString getNameByIndex(sal_Int32 _nIndex) const;
60 static OPropertyMap& getPropMap()
62 static OPropertyMap s_aPropMap;
63 return s_aPropMap;
68 typedef const sal_Char* (*PVFN)();
70 struct UStringDescription
72 const sal_Char* pZeroTerminatedName;
73 sal_Int32 nLength;
75 UStringDescription(PVFN _fCharFkt);
76 operator ::rtl::OUString() const { return ::rtl::OUString(pZeroTerminatedName,nLength,RTL_TEXTENCODING_ASCII_US); }
77 ~UStringDescription();
78 private:
79 UStringDescription();
85 #define PROPERTY_ID_QUERYTIMEOUT 1
86 #define PROPERTY_ID_MAXFIELDSIZE 2
87 #define PROPERTY_ID_MAXROWS 3
88 #define PROPERTY_ID_CURSORNAME 4
89 #define PROPERTY_ID_RESULTSETCONCURRENCY 5
90 #define PROPERTY_ID_RESULTSETTYPE 6
91 #define PROPERTY_ID_FETCHDIRECTION 7
92 #define PROPERTY_ID_FETCHSIZE 8
93 #define PROPERTY_ID_ESCAPEPROCESSING 9
94 #define PROPERTY_ID_USEBOOKMARKS 10
95 // Column
96 #define PROPERTY_ID_NAME 11
97 #define PROPERTY_ID_TYPE 12
98 #define PROPERTY_ID_TYPENAME 13
99 #define PROPERTY_ID_PRECISION 14
100 #define PROPERTY_ID_SCALE 15
101 #define PROPERTY_ID_ISNULLABLE 16
102 #define PROPERTY_ID_ISAUTOINCREMENT 17
103 #define PROPERTY_ID_ISROWVERSION 18
104 #define PROPERTY_ID_DESCRIPTION 19
105 #define PROPERTY_ID_DEFAULTVALUE 20
107 #define PROPERTY_ID_REFERENCEDTABLE 21
108 #define PROPERTY_ID_UPDATERULE 22
109 #define PROPERTY_ID_DELETERULE 23
110 #define PROPERTY_ID_CATALOG 24
111 #define PROPERTY_ID_ISUNIQUE 25
112 #define PROPERTY_ID_ISPRIMARYKEYINDEX 26
113 #define PROPERTY_ID_ISCLUSTERED 27
114 #define PROPERTY_ID_ISASCENDING 28
115 #define PROPERTY_ID_SCHEMANAME 29
116 #define PROPERTY_ID_CATALOGNAME 30
118 #define PROPERTY_ID_COMMAND 31
119 #define PROPERTY_ID_CHECKOPTION 32
120 #define PROPERTY_ID_PASSWORD 33
121 #define PROPERTY_ID_RELATEDCOLUMN 34
123 #define PROPERTY_ID_FUNCTION 35
124 #define PROPERTY_ID_TABLENAME 36
125 #define PROPERTY_ID_REALNAME 37
126 #define PROPERTY_ID_DBASEPRECISIONCHANGED 38
127 #define PROPERTY_ID_ISCURRENCY 39
128 #define PROPERTY_ID_ISBOOKMARKABLE 40
130 #define PROPERTY_ID_INVALID_INDEX 41
131 #define PROPERTY_ID_ERRORMSG_SEQUENCE 42
132 #define PROPERTY_ID_HY010 43
133 #define PROPERTY_ID_HY0000 44
134 #define PROPERTY_ID_DELIMITER 45
135 #define PROPERTY_ID_FORMATKEY 46
136 #define PROPERTY_ID_LOCALE 47
137 #define PROPERTY_ID_IM001 48
139 #define PROPERTY_ID_AUTOINCREMENTCREATION 49
141 #define PROPERTY_ID_PRIVILEGES 50
143 #endif // INCLUDED_EXAMPLES_DATABASE_DRIVERSKELETON_PROPERTYIDS_HXX
145 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */