Branch data Line data Source code
1 : : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : : /*
3 : : * This file is part of the LibreOffice project.
4 : : *
5 : : * This Source Code Form is subject to the terms of the Mozilla Public
6 : : * License, v. 2.0. If a copy of the MPL was not distributed with this
7 : : * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 : : *
9 : : * This file incorporates work covered by the following license notice:
10 : : *
11 : : * Licensed to the Apache Software Foundation (ASF) under one or more
12 : : * contributor license agreements. See the NOTICE file distributed
13 : : * with this work for additional information regarding copyright
14 : : * ownership. The ASF licenses this file to you under the Apache
15 : : * License, Version 2.0 (the "License"); you may not use this file
16 : : * except in compliance with the License. You may obtain a copy of
17 : : * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 : : */
19 : :
20 : : #include <comphelper/TypeGeneration.hxx>
21 : : #include <com/sun/star/script/XLibraryContainer.hpp>
22 : : #include <com/sun/star/style/LineSpacingMode.hpp>
23 : : #include <com/sun/star/style/ParagraphAdjust.hpp>
24 : : #include <com/sun/star/style/DropCapFormat.hpp>
25 : : #include <com/sun/star/style/LineSpacing.hpp>
26 : : #include <com/sun/star/style/TabStop.hpp>
27 : : #include <com/sun/star/style/TabAlign.hpp>
28 : : #include <com/sun/star/style/PageStyleLayout.hpp>
29 : : #include <com/sun/star/style/BreakType.hpp>
30 : : #include <com/sun/star/text/XModule.hpp>
31 : : #include <com/sun/star/text/XTextRangeMover.hpp>
32 : : #include <com/sun/star/text/XFootnotesSettingsSupplier.hpp>
33 : : #include <com/sun/star/text/XFootnote.hpp>
34 : : #include <com/sun/star/text/XFootnotesSupplier.hpp>
35 : : #include <com/sun/star/text/XEndnotesSupplier.hpp>
36 : : #include <com/sun/star/text/XEndnotesSettingsSupplier.hpp>
37 : : #include <com/sun/star/text/FootnoteNumbering.hpp>
38 : : #include <com/sun/star/text/XTextSectionsSupplier.hpp>
39 : : #include <com/sun/star/text/XTextSection.hpp>
40 : : #include <com/sun/star/text/SectionFileLink.hpp>
41 : : #include <com/sun/star/text/RelOrientation.hpp>
42 : : #include <com/sun/star/text/VertOrientation.hpp>
43 : : #include <com/sun/star/text/HorizontalAdjust.hpp>
44 : : #include <com/sun/star/text/DocumentStatistic.hpp>
45 : : #include <com/sun/star/text/HoriOrientation.hpp>
46 : : #include <com/sun/star/text/HoriOrientationFormat.hpp>
47 : : #include <com/sun/star/text/NotePrintMode.hpp>
48 : : #include <com/sun/star/text/SizeType.hpp>
49 : : #include <com/sun/star/text/VertOrientationFormat.hpp>
50 : : #include <com/sun/star/text/WrapTextMode.hpp>
51 : : //undef to prevent error (from sfx2/docfile.cxx)
52 : : #undef SEQUENCE
53 : : #include <com/sun/star/text/SetVariableType.hpp>
54 : : #include <com/sun/star/text/XTextFieldsSupplier.hpp>
55 : : #include <com/sun/star/text/UserDataPart.hpp>
56 : : #include <com/sun/star/text/ChapterFormat.hpp>
57 : : #include <com/sun/star/text/XTextField.hpp>
58 : : #include <com/sun/star/text/PlaceholderType.hpp>
59 : : #include <com/sun/star/text/TemplateDisplayFormat.hpp>
60 : : #include <com/sun/star/text/UserFieldFormat.hpp>
61 : : #include <com/sun/star/text/PageNumberType.hpp>
62 : : #include <com/sun/star/text/ReferenceFieldPart.hpp>
63 : : #include <com/sun/star/text/FilenameDisplayFormat.hpp>
64 : : #include <com/sun/star/text/XDependentTextField.hpp>
65 : : #include <com/sun/star/text/GraphicCrop.hpp>
66 : : #include <com/sun/star/text/XTextGraphicObjectsSupplier.hpp>
67 : : #include <com/sun/star/text/XTextTableCursor.hpp>
68 : : #include <com/sun/star/text/XTextTablesSupplier.hpp>
69 : : #include <com/sun/star/text/TableColumnSeparator.hpp>
70 : : #include <com/sun/star/text/XTextTable.hpp>
71 : : #include <com/sun/star/text/XDocumentIndexMark.hpp>
72 : : #include <com/sun/star/text/XDocumentIndexesSupplier.hpp>
73 : : #include <com/sun/star/text/XDocumentIndex.hpp>
74 : : #include <com/sun/star/text/XTextColumns.hpp>
75 : : #include <com/sun/star/text/TextColumnSequence.hpp>
76 : : #include <com/sun/star/text/XTextFramesSupplier.hpp>
77 : : #include <com/sun/star/text/XTextFrame.hpp>
78 : : #include <com/sun/star/beans/PropertyValues.hpp>
79 : : #include <com/sun/star/beans/XPropertySet.hpp>
80 : : #include <com/sun/star/beans/PropertyValue.hpp>
81 : : #include <com/sun/star/beans/PropertyState.hpp>
82 : : #include <com/sun/star/beans/XPropertySetInfo.hpp>
83 : : #include <com/sun/star/beans/XMultiPropertySet.hpp>
84 : : #include <com/sun/star/beans/XFastPropertySet.hpp>
85 : : #include <com/sun/star/beans/XVetoableChangeListener.hpp>
86 : : #include <com/sun/star/beans/XPropertyState.hpp>
87 : : #include <com/sun/star/beans/XPropertyStateChangeListener.hpp>
88 : : #include <com/sun/star/beans/PropertyAttribute.hpp>
89 : : #include <com/sun/star/beans/XPropertiesChangeListener.hpp>
90 : : #include <com/sun/star/beans/XPropertyChangeListener.hpp>
91 : : #include <com/sun/star/beans/XPropertyAccess.hpp>
92 : : #include <com/sun/star/beans/XPropertyContainer.hpp>
93 : : #include <com/sun/star/beans/NamedValue.hpp>
94 : : #include <com/sun/star/beans/PropertyStateChangeEvent.hpp>
95 : : #include <com/sun/star/beans/PropertyChangeEvent.hpp>
96 : : #include <com/sun/star/text/TextContentAnchorType.hpp>
97 : : #include <com/sun/star/awt/FontSlant.hpp>
98 : : #include <com/sun/star/awt/Size.hpp>
99 : : #include <com/sun/star/awt/XBitmap.hpp>
100 : : #include <com/sun/star/style/GraphicLocation.hpp>
101 : : #include <com/sun/star/style/VerticalAlignment.hpp>
102 : : #include <com/sun/star/container/XIndexReplace.hpp>
103 : : #include <com/sun/star/container/XIndexContainer.hpp>
104 : : #include <com/sun/star/table/ShadowFormat.hpp>
105 : : #include <com/sun/star/table/BorderLine.hpp>
106 : : #include <com/sun/star/table/TableBorder.hpp>
107 : : #include <com/sun/star/table/TableBorder2.hpp>
108 : : #include <com/sun/star/table/TableBorderDistances.hpp>
109 : : #include <com/sun/star/container/XNameContainer.hpp>
110 : : #include <com/sun/star/lang/Locale.hpp>
111 : : #include <com/sun/star/drawing/PointSequenceSequence.hpp>
112 : : #include <com/sun/star/i18n/XForbiddenCharacters.hpp>
113 : : #include <com/sun/star/drawing/ColorMode.hpp>
114 : : #include <com/sun/star/util/DateTime.hpp>
115 : : #include <com/sun/star/util/Date.hpp>
116 : : #include <com/sun/star/sdbc/XResultSet.hpp>
117 : : #include <com/sun/star/sdbc/XConnection.hpp>
118 : : #include <com/sun/star/frame/XModel.hpp>
119 : : // #i28749#
120 : : #include <com/sun/star/drawing/HomogenMatrix3.hpp>
121 : : #include <com/sun/star/graphic/XGraphic.hpp>
122 : : #include <com/sun/star/embed/XEmbeddedObject.hpp>
123 : : #include <com/sun/star/drawing/LineStyle.hpp>
124 : :
125 : : using ::rtl::OUString;
126 : : using namespace ::com::sun::star;
127 : : using namespace ::com::sun::star::container;
128 : : using namespace ::com::sun::star::lang;
129 : : using namespace ::com::sun::star::awt;
130 : : using namespace ::com::sun::star::text;
131 : : using namespace ::com::sun::star::uno;
132 : : using namespace ::com::sun::star::beans;
133 : : using namespace ::com::sun::star::drawing;
134 : : using namespace ::com::sun::star::i18n;
135 : : using namespace ::comphelper;
136 : :
137 : : namespace comphelper
138 : : {
139 : 66456 : void GenerateCppuType (
140 : : CppuTypes eType, const com::sun::star::uno::Type*& pType )
141 : : {
142 [ + + + + : 66456 : switch( eType )
+ + + + +
+ + + + +
+ + + + +
+ + + + +
+ + + + +
+ + + + +
+ + + + +
+ + + + +
+ + + + -
+ + + + +
+ + + + +
- - - + +
+ + + + +
+ - ]
143 : : {
144 : 15968 : case CPPUTYPE_BOOLEAN: pType = &::getBooleanCppuType(); break;
145 : 1570 : case CPPUTYPE_INT8: pType = &::getCppuType( (sal_Int8*)0 ); break;
146 : 13936 : case CPPUTYPE_INT16: pType = &::getCppuType( (sal_Int16*)0 ); break;
147 : 9953 : case CPPUTYPE_INT32: pType = &::getCppuType( (sal_Int32*)0 ); break;
148 : :
149 : 27 : case CPPUTYPE_DOUBLE: pType = &::getCppuType( (double*)0 ); break;
150 : 2745 : case CPPUTYPE_FLOAT: pType = &::getCppuType( (float*)0 ); break;
151 : 9915 : case CPPUTYPE_OUSTRING: pType = &::getCppuType( (OUString*)0 ); break;
152 : 1122 : case CPPUTYPE_FONTSLANT: pType = &::getCppuType( (FontSlant*)0 ); break;
153 : 1203 : case CPPUTYPE_LOCALE: pType = &::getCppuType( (Locale*)0 ); break;
154 : 345 : case CPPUTYPE_PROPERTYVALUE:pType = &::getCppuType( (Sequence<PropertyValue>*)0 ); break;
155 : 2 : case CPPUTYPE_PROPERTYVALUES: pType = &::getCppuType( (Sequence<PropertyValues>*)0 ); break;
156 : 2148 : case CPPUTYPE_BORDERLINE: pType = &::getCppuType( (table::BorderLine*)0 ); break;
157 : 341 : case CPPUTYPE_BREAK: pType = &::getCppuType( (style::BreakType*)0 ); break;
158 : 599 : case CPPUTYPE_GRAPHICLOC: pType = &::getCppuType( (style::GraphicLocation*)0 ); break;
159 : 325 : case CPPUTYPE_DROPCAPFMT: pType = &::getCppuType( (style::DropCapFormat*)0 ); break;
160 : 325 : case CPPUTYPE_LINESPACE: pType = &::getCppuType( (style::LineSpacing*)0 ); break;
161 : :
162 : 161 : case CPPUTYPE_AWTSIZE: pType = &::getCppuType( (awt::Size*)0 ); break;
163 : 539 : case CPPUTYPE_SHADOWFMT: pType = &::getCppuType( (table::ShadowFormat*)0 ); break;
164 : 30 : case CPPUTYPE_TBLCOLSEP: pType = &::getCppuType( (Sequence<text::TableColumnSeparator>*)0 ); break;
165 : 25 : case CPPUTYPE_PNTSEQSEQ: pType = &::getCppuType( (PointSequenceSequence*)0 ); break;
166 : 10 : case CPPUTYPE_DOCIDXMRK: pType = &::getCppuType( (Sequence< Reference< XDocumentIndexMark > >*)0 ); break;
167 : 121 : case CPPUTYPE_SEQINT8: pType = &::getCppuType( (Sequence<sal_Int8>*)0 ); break;
168 : 284 : case CPPUTYPE_SEQTABSTOP: pType = &::getCppuType( (Sequence<style::TabStop>*)0 ); break;
169 : 163 : case CPPUTYPE_SEQANCHORTYPE:pType = &::getCppuType( (Sequence<text::TextContentAnchorType>*)0 ); break;
170 : 46 : case CPPUTYPE_SEQDEPTXTFLD: pType = &::getCppuType( (Sequence<Reference<XDependentTextField> >*)0); break;
171 : 216 : case CPPUTYPE_TXTCNTANCHOR: pType = &::getCppuType( (text::TextContentAnchorType*)0 ); break;
172 : 309 : case CPPUTYPE_WRAPTXTMODE: pType = &::getCppuType( (text::WrapTextMode*)0 ); break;
173 : :
174 : 13 : case CPPUTYPE_COLORMODE: pType = &::getCppuType( (drawing::ColorMode*)0 ); break;
175 : 43 : case CPPUTYPE_PAGESTYLELAY: pType = &::getCppuType( (style::PageStyleLayout*)0 ); break;
176 : 10 : case CPPUTYPE_VERTALIGN: pType = &::getCppuType( (style::VerticalAlignment*)0 ); break;
177 : 20 : case CPPUTYPE_TABLEBORDER: pType = &::getCppuType( (table::TableBorder*)0 ); break;
178 : 20 : case CPPUTYPE_TABLEBORDER2: pType = &::getCppuType( (table::TableBorder2*)0 ); break;
179 : 13 : case CPPUTYPE_GRFCROP: pType = &::getCppuType( (text::GraphicCrop*)0 ); break;
180 : 10 : case CPPUTYPE_SECTFILELNK: pType = &::getCppuType( (text::SectionFileLink*)0 ); break;
181 : 6 : case CPPUTYPE_PAGENUMTYPE: pType = &::getCppuType( (text::PageNumberType*)0); break;
182 : 29 : case CPPUTYPE_DATETIME: pType = &::getCppuType( (util::DateTime*)0 ); break;
183 : 9 : case CPPUTYPE_DATE: pType = &::getCppuType( (util::Date*)0 ); break;
184 : :
185 : 9 : case CPPUTYPE_REFINTERFACE: pType = &::getCppuType( (Reference<XInterface>*)0 ); break;
186 : 192 : case CPPUTYPE_REFIDXREPL: pType = &::getCppuType( (Reference<container::XIndexReplace>*)0 ); break;
187 : 751 : case CPPUTYPE_REFNAMECNT: pType = &::getCppuType( (Reference<container::XNameContainer>*)0 ); break;
188 : 229 : case CPPUTYPE_REFTEXTFRAME: pType = &::getCppuType( (Reference<text::XTextFrame>*)0 ); break;
189 : 237 : case CPPUTYPE_REFTEXTSECTION: pType = &::getCppuType( (Reference<text::XTextSection>*)0 ); break;
190 : 190 : case CPPUTYPE_REFFOOTNOTE: pType = &::getCppuType( (Reference<text::XFootnote>*)0 ); break;
191 : 359 : case CPPUTYPE_REFTEXT: pType = &::getCppuType( (Reference<text::XText>*)0 ); break;
192 : 111 : case CPPUTYPE_REFTEXTCOL: pType = &::getCppuType( (Reference<text::XTextColumns>*)0 ); break;
193 : 92 : case CPPUTYPE_REFFORBCHARS: pType = &::getCppuType( (Reference<XForbiddenCharacters>*)0 ); break;
194 : 40 : case CPPUTYPE_REFIDXCNTNR: pType = &::getCppuType( (Reference<XIndexContainer>*)0 ); break;
195 : 263 : case CPPUTYPE_REFTEXTCNTNT: pType = &::getCppuType( (Reference<XTextContent>*)0 ); break;
196 : 0 : case CPPUTYPE_REFBITMAP: pType = &::getCppuType( (Reference<awt::XBitmap>*)0 ); break;
197 : 95 : case CPPUTYPE_REFNMREPLACE: pType = &::getCppuType( (Reference<container::XNameReplace>*)0 ); break;
198 : 161 : case CPPUTYPE_REFCELL: pType = &::getCppuType( (Reference<table::XCell>*)0 ); break;
199 : 171 : case CPPUTYPE_REFDOCINDEX: pType = &::getCppuType( (Reference<text::XDocumentIndex>*)0 ); break;
200 : 95 : case CPPUTYPE_REFDOCIDXMRK: pType = &::getCppuType( (Reference<text::XDocumentIndexMark>*)0 ); break;
201 : 95 : case CPPUTYPE_REFTXTFIELD: pType = &::getCppuType( (Reference<text::XTextField>*)0 ); break;
202 : 28 : case CPPUTYPE_REFTXTRANGE: pType = &::getCppuType( (Reference<text::XTextRange>*)0 ); break;
203 : 161 : case CPPUTYPE_REFTXTTABLE: pType = &::getCppuType( (Reference<text::XTextTable>*)0 ); break;
204 : 84 : case CPPUTYPE_AWTPOINT: pType = &::getCppuType( (awt::Point*)0 ); break;
205 : 146 : case CPPUTYPE_REFLIBCONTAINER: pType = &::getCppuType( (Reference< script::XLibraryContainer >*)0); break;
206 : 139 : case CPPUTYPE_OUSTRINGS: pType = &::getCppuType( (Sequence< ::rtl::OUString >*)0); break;
207 : 0 : case CPPUTYPE_SEQANY: pType = &::getCppuType( (Sequence< uno::Any >*)0); break;
208 : 0 : case CPPUTYPE_REFRESULTSET: pType = &::getCppuType( (Reference< sdbc::XResultSet >*)0); break;
209 : 0 : case CPPUTYPE_REFCONNECTION: pType = &::getCppuType( (Reference< sdbc::XConnection >*)0); break;
210 : 12 : case CPPUTYPE_REFMODEL: pType = &::getCppuType( (Reference< frame::XModel >*)0); break;
211 : 12 : case CPPUTYPE_REFCOMPONENT: pType = &::getCppuType( (Reference< lang::XComponent >*)0 ); break;
212 : : // #i28749#
213 : : case CPPUTYPE_TRANSFORMATIONINHORIL2R:
214 : : {
215 : 28 : pType = &::getCppuType( (drawing::HomogenMatrix3*)0 );
216 : : }
217 : 28 : break;
218 : 58 : case CPPUTYPE_SEQNAMEDVALUE: pType = &::getCppuType( (Sequence<beans::NamedValue>*)0 ); break;
219 : 25 : case CPPUTYPE_REFXGRAPHIC: pType = &::getCppuType( (Reference< graphic::XGraphic >*)0); break;
220 : 20 : case CPPUTYPE_TABLEBORDERDISTANCES: pType = &::getCppuType( (table::TableBorderDistances*)0 ); break;
221 : 12 : case CPPUTPYE_REFEMBEDDEDOBJECT: pType = &embed::XEmbeddedObject::static_type(); break;
222 : 40 : case CPPUTYPE_LINESTYLE: pType = &::getCppuType( (drawing::LineStyle*)0 ); break;
223 : : default:
224 : : OSL_FAIL( "Unknown CPPU type" );
225 : : }
226 : 66456 : }
227 : : }
228 : :
229 : : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|