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 #ifndef DBA_XMLHELPER_HXX
24 #define DBA_XMLHELPER_HXX
25 
26 #ifndef _XMLOFF_PROPERTYSETMAPPER_HXX
27 #include <xmloff/xmlprmap.hxx>
28 #endif
29 #ifndef _XMLOFF_CONTEXTID_HXX_
30 #include <xmloff/contextid.hxx>
31 #endif
32 #ifndef _XMLOFF_FORMS_CONTROLPROPERTYHDL_HXX_
33 #include <xmloff/controlpropertyhdl.hxx>
34 #endif
35 
36 #include <memory>
37 
38 #define CTF_DB_ROWHEIGHT							(XML_DB_CTF_START + 1)
39 #define CTF_DB_ISVISIBLE							(XML_DB_CTF_START + 2)
40 #define CTF_DB_MASTERPAGENAME						(XML_DB_CTF_START + 3)
41 #define CTF_DB_NUMBERFORMAT							(XML_DB_CTF_START + 4)
42 #define CTF_DB_COLUMN_TEXT_ALIGN					(XML_DB_CTF_START + 5)
43 
44 #define XML_DB_TYPE_EQUAL							(XML_DB_TYPES_START + 1)
45 
46 namespace dbaxml
47 {
48 	class OPropertyHandlerFactory : public ::xmloff::OControlPropertyHandlerFactory
49 	{
50 	protected:
51 		mutable ::std::auto_ptr<XMLConstantsPropertyHandler>	m_pDisplayHandler;
52 		mutable ::std::auto_ptr<XMLPropertyHandler>				m_pTextAlignHandler;
53 	public:
54 		OPropertyHandlerFactory();
55 		virtual ~OPropertyHandlerFactory();
56 
57 		virtual const XMLPropertyHandler* GetPropertyHandler(sal_Int32 _nType) const;
58 	};
59 
60 	class OXMLHelper
61 	{
62 	public:
63 		static UniReference < XMLPropertySetMapper > GetTableStylesPropertySetMapper();
64 		static UniReference < XMLPropertySetMapper > GetColumnStylesPropertySetMapper();
65         static UniReference < XMLPropertySetMapper > GetCellStylesPropertySetMapper();
66         static UniReference < XMLPropertySetMapper > GetRowStylesPropertySetMapper();
67 	};
68 // -----------------------------------------------------------------------------
69 } // dbaxml
70 // -----------------------------------------------------------------------------
71 #endif // DBA_XMLHELPER_HXX
72 
73