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 INCLUDED_QNAME_TO_STRING_HXX
24 #define INCLUDED_QNAME_TO_STRING_HXX
25 
26 #include <boost/shared_ptr.hpp>
27 #include <map>
28 #include <string>
29 #include <iostream>
30 #include <resourcemodel/WW8ResourceModel.hxx>
31 #include <com/sun/star/beans/XPropertySet.hpp>
32 
33 namespace writerfilter
34 {
35 using namespace ::std;
36 
37 class WRITERFILTER_DLLPUBLIC QNameToString
38 {
39     typedef boost::shared_ptr<QNameToString> Pointer_t;
40     typedef map < Id, string > Map;
41 
42     static Pointer_t pInstance;
43 
44     void init_doctok();
45     void init_ooxml();
46 
47     Map mMap;
48 
49 protected:
50     /**
51        Generated.
52      */
53     QNameToString();
54 
55 public:
56     static Pointer_t Instance();
57 
58     string operator()(Id qName);
59 };
60 
61 class WRITERFILTER_DLLPUBLIC SprmIdToString
62 {
63     typedef boost::shared_ptr<SprmIdToString> Pointer_t;
64 
65     static Pointer_t pInstance;
66 
67     map<sal_uInt32, string> mMap;
68 
69 protected:
70     /**
71        Generated automatically.
72     */
73     SprmIdToString();
74 
75 public:
76     static Pointer_t Instance();
77     string operator()(sal_uInt32 nId);
78 };
79 
80 
81 
82 }
83 
84 #endif // INCLUDED_QNAME_TO_STRING_HXX
85