1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: propertyids.hxx,v $
10 * $Revision: 1.20.56.1 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef _CONNECTIVITY_PROPERTYIDS_HXX_
31 #define _CONNECTIVITY_PROPERTYIDS_HXX_
33 // this define has to be set to split the names into different dll's or so's
34 // every dll has his own set of property names
35 #include <rtl/ustring.hxx>
39 #include "connectivity/dbtoolsdllapi.hxx"
43 class OOO_DLLPUBLIC_DBTOOLS OPropertyMap
45 ::std::map
<sal_Int32
, rtl_uString
*> m_aPropertyMap
;
47 ::rtl::OUString
fillValue(sal_Int32 _nIndex
);
53 ::rtl::OUString
getNameByIndex(sal_Int32 _nIndex
) const;
57 namespace connectivity
59 namespace CONNECTIVITY_PROPERTY_NAME_SPACE
61 typedef const sal_Char
* (*PVFN
)();
63 struct OOO_DLLPUBLIC_DBTOOLS UStringDescription
65 const sal_Char
* pZeroTerminatedName
;
68 UStringDescription(PVFN _fCharFkt
);
69 operator ::rtl::OUString() const { return ::rtl::OUString(pZeroTerminatedName
,nLength
,RTL_TEXTENCODING_ASCII_US
); }
70 ~UStringDescription();
78 //------------------------------------------------------------------------------
79 #define DECL_PROP1IMPL(varname, type) \
80 pProperties[nPos++] = ::com::sun::star::beans::Property(::connectivity::OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_##varname), PROPERTY_ID_##varname, ::getCppuType(reinterpret_cast< type*>(NULL)),
81 //------------------------------------------------------------------------------
82 #define DECL_PROP0(varname, type) \
83 DECL_PROP1IMPL(varname, type) 0)
84 //------------------------------------------------------------------------------
85 #define DECL_BOOL_PROP1IMPL(varname) \
86 pProperties[nPos++] = ::com::sun::star::beans::Property(::connectivity::OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_##varname), PROPERTY_ID_##varname, ::getBooleanCppuType(),
87 //------------------------------------------------------------------------------
88 #define DECL_BOOL_PROP0(varname) \
89 DECL_BOOL_PROP1IMPL(varname) 0)
92 #define PROPERTY_ID_QUERYTIMEOUT 1
93 #define PROPERTY_ID_MAXFIELDSIZE 2
94 #define PROPERTY_ID_MAXROWS 3
95 #define PROPERTY_ID_CURSORNAME 4
96 #define PROPERTY_ID_RESULTSETCONCURRENCY 5
97 #define PROPERTY_ID_RESULTSETTYPE 6
98 #define PROPERTY_ID_FETCHDIRECTION 7
99 #define PROPERTY_ID_FETCHSIZE 8
100 #define PROPERTY_ID_ESCAPEPROCESSING 9
101 #define PROPERTY_ID_USEBOOKMARKS 10
103 #define PROPERTY_ID_NAME 11
104 #define PROPERTY_ID_TYPE 12
105 #define PROPERTY_ID_TYPENAME 13
106 #define PROPERTY_ID_PRECISION 14
107 #define PROPERTY_ID_SCALE 15
108 #define PROPERTY_ID_ISNULLABLE 16
109 #define PROPERTY_ID_ISAUTOINCREMENT 17
110 #define PROPERTY_ID_ISROWVERSION 18
111 #define PROPERTY_ID_DESCRIPTION 19
112 #define PROPERTY_ID_DEFAULTVALUE 20
114 #define PROPERTY_ID_REFERENCEDTABLE 21
115 #define PROPERTY_ID_UPDATERULE 22
116 #define PROPERTY_ID_DELETERULE 23
117 #define PROPERTY_ID_CATALOG 24
118 #define PROPERTY_ID_ISUNIQUE 25
119 #define PROPERTY_ID_ISPRIMARYKEYINDEX 26
120 #define PROPERTY_ID_ISCLUSTERED 27
121 #define PROPERTY_ID_ISASCENDING 28
122 #define PROPERTY_ID_SCHEMANAME 29
123 #define PROPERTY_ID_CATALOGNAME 30
125 #define PROPERTY_ID_COMMAND 31
126 #define PROPERTY_ID_CHECKOPTION 32
127 #define PROPERTY_ID_PASSWORD 33
128 #define PROPERTY_ID_RELATEDCOLUMN 34
130 #define PROPERTY_ID_FUNCTION 35
131 #define PROPERTY_ID_TABLENAME 36
132 #define PROPERTY_ID_REALNAME 37
133 #define PROPERTY_ID_DBASEPRECISIONCHANGED 38
134 #define PROPERTY_ID_ISCURRENCY 39
135 #define PROPERTY_ID_ISBOOKMARKABLE 40
137 #define PROPERTY_ID_INVALID_INDEX 41
138 #define PROPERTY_ID_HY010 43
140 #define PROPERTY_ID_DELIMITER 45
141 #define PROPERTY_ID_FORMATKEY 46
142 #define PROPERTY_ID_LOCALE 47
143 #define PROPERTY_ID_IM001 48
145 #define PROPERTY_ID_AUTOINCREMENTCREATION 49
147 #define PROPERTY_ID_PRIVILEGES 50
148 #define PROPERTY_ID_HAVINGCLAUSE 51
150 #define PROPERTY_ID_ISSIGNED 52
151 #define PROPERTY_ID_AGGREGATEFUNCTION 53
152 #define PROPERTY_ID_ISSEARCHABLE 54
154 #define PROPERTY_ID_APPLYFILTER 55
155 #define PROPERTY_ID_FILTER 56
156 #define PROPERTY_ID_MASTERFIELDS 57
157 #define PROPERTY_ID_DETAILFIELDS 58
158 #define PROPERTY_ID_FIELDTYPE 59
159 #define PROPERTY_ID_VALUE 60
160 #define PROPERTY_ID_ACTIVE_CONNECTION 61
162 #endif // _CONNECTIVITY_PROPERTYIDS_HXX_