1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 
24 #ifndef CONNECTIVITY_USTRINGDESCRIPTION_IMPL_HXX
25 #define CONNECTIVITY_USTRINGDESCRIPTION_IMPL_HXX
26 
27 #define IMPLEMENT_CONSTASCII_USTRING(name)	\
28 UStringDescription name(connectivity::dbtools::get##name)
29 
UStringDescription(PVFN _fCharFkt)30 UStringDescription::UStringDescription(PVFN _fCharFkt)
31 {
32 	pZeroTerminatedName = (*_fCharFkt)();
33 	nLength = 0;
34 	const sal_Char*	pIter = pZeroTerminatedName;
35 	while((*pIter++) != '\0')
36 		++nLength;
37 }
38 // -------------------------------------------------------------------------
~UStringDescription()39 UStringDescription::~UStringDescription()
40 {
41 }
42 
43 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_QUERYTIMEOUT			);
44 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_MAXFIELDSIZE			);
45 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_MAXROWS				);
46 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_CURSORNAME			);
47 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_RESULTSETCONCURRENCY	);
48 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_RESULTSETTYPE			);
49 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_FETCHDIRECTION		);
50 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_FETCHSIZE				);
51 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ESCAPEPROCESSING		);
52 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_USEBOOKMARKS			);
53 
54 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_NAME);
55 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_TYPE);
56 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_TYPENAME);
57 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_PRECISION);
58 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_SCALE);
59 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ISNULLABLE);
60 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ISAUTOINCREMENT);
61 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ISROWVERSION);
62 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_DESCRIPTION);
63 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_DEFAULTVALUE);
64 
65 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_REFERENCEDTABLE);
66 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_UPDATERULE);
67 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_DELETERULE);
68 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_CATALOG);
69 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ISUNIQUE);
70 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ISPRIMARYKEYINDEX);
71 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ISCLUSTERED);
72 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ISASCENDING);
73 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_SCHEMANAME);
74 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_CATALOGNAME);
75 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_COMMAND);
76 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_CHECKOPTION);
77 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_PASSWORD);
78 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_RELATEDCOLUMN);
79 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ISSEARCHABLE);
80 
81 IMPLEMENT_CONSTASCII_USTRING(STAT_INVALID_INDEX);
82 
83 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_FUNCTION);
84 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_TABLENAME);
85 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_REALNAME);
86 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_DBASEPRECISIONCHANGED);
87 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ISCURRENCY);
88 
89 IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ISBOOKMARKABLE);
90 //============================================================
91 //= error messages
92 //============================================================
93 IMPLEMENT_CONSTASCII_USTRING(ERRORMSG_SEQUENCE);
94 IMPLEMENT_CONSTASCII_USTRING(SQLSTATE_SEQUENCE);
95 IMPLEMENT_CONSTASCII_USTRING(SQLSTATE_GENERAL);
96 //============================================================
97 //= different
98 //============================================================
99 IMPLEMENT_CONSTASCII_USTRING(STR_DELIMITER);
100 
101 #endif // CONNECTIVITY_USTRINGDESCRIPTION_IMPL_HXX
102 
103