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: xmldpimp.hxx,v $
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 SC_XMLDPIMP_HXX
31 #define SC_XMLDPIMP_HXX
33 #include <xmloff/xmlictxt.hxx>
34 #include <xmloff/xmlimp.hxx>
35 #include <com/sun/star/sheet/DataPilotFieldReference.hpp>
36 #include <com/sun/star/sheet/DataPilotFieldSortInfo.hpp>
37 #include <com/sun/star/sheet/DataPilotFieldAutoShowInfo.hpp>
38 #include <com/sun/star/sheet/DataPilotFieldLayoutInfo.hpp>
41 #include "dpobject.hxx"
43 #include "queryparam.hxx"
48 class ScDPSaveNumGroupDimension
;
49 class ScDPSaveGroupDimension
;
60 class ScXMLDataPilotTablesContext
: public SvXMLImportContext
63 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
64 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
68 ScXMLDataPilotTablesContext( ScXMLImport
& rImport
, USHORT nPrfx
,
69 const ::rtl::OUString
& rLName
,
70 const ::com::sun::star::uno::Reference
<
71 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
73 virtual ~ScXMLDataPilotTablesContext();
75 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
76 const ::rtl::OUString
& rLocalName
,
77 const ::com::sun::star::uno::Reference
<
78 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
80 virtual void EndElement();
83 class ScXMLDataPilotTableContext
: public SvXMLImportContext
85 typedef ::std::hash_set
< ::rtl::OUString
, ::rtl::OUStringHash
> StringSet
;
86 StringSet maHiddenMemberFields
;
90 ::rtl::OUString maDisplayName
;
95 ScDPObject
* pDPObject
;
96 ScDPSaveData
* pDPSave
;
97 ScDPDimensionSaveData
* pDPDimSaveData
;
98 GrandTotalItem maRowGrandTotal
;
99 GrandTotalItem maColGrandTotal
;
100 rtl::OUString sDataPilotTableName
;
101 rtl::OUString sApplicationData
;
102 rtl::OUString sGrandTotal
;
103 rtl::OUString sDatabaseName
;
104 rtl::OUString sSourceObject
;
105 rtl::OUString sServiceName
;
106 rtl::OUString sServiceSourceName
;
107 rtl::OUString sServiceSourceObject
;
108 rtl::OUString sServiceUsername
;
109 rtl::OUString sServicePassword
;
110 rtl::OUString sButtons
;
111 ScRange aSourceCellRangeAddress
;
112 ScRange aTargetRangeAddress
;
113 ScRange aFilterSourceRange
;
114 ScAddress aFilterOutputPosition
;
115 ScQueryParam aSourceQueryParam
;
116 ScMySourceType nSourceType
;
117 sal_uInt32 mnRowFieldCount
;
118 sal_uInt32 mnColFieldCount
;
119 sal_uInt32 mnPageFieldCount
;
120 sal_uInt32 mnDataFieldCount
;
122 sal_Bool bIgnoreEmptyRows
;
123 sal_Bool bIdentifyCategories
;
124 sal_Bool bUseRegularExpression
;
125 sal_Bool bIsCaseSensitive
;
126 sal_Bool bSkipDuplicates
;
127 sal_Bool bFilterCopyOutputData
;
128 sal_Bool bTargetRangeAddress
;
129 sal_Bool bSourceCellRange
;
130 sal_Bool bShowFilter
;
132 sal_Bool bHeaderGridLayout
;
134 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
135 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
139 ScXMLDataPilotTableContext( ScXMLImport
& rImport
, USHORT nPrfx
,
140 const ::rtl::OUString
& rLName
,
141 const ::com::sun::star::uno::Reference
<
142 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
144 virtual ~ScXMLDataPilotTableContext();
146 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
147 const ::rtl::OUString
& rLocalName
,
148 const ::com::sun::star::uno::Reference
<
149 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
151 virtual void EndElement();
153 void SetGrandTotal(::xmloff::token::XMLTokenEnum eOrientation
, bool bVisible
, const ::rtl::OUString
& rDisplayName
);
154 void SetDatabaseName(const rtl::OUString
& sValue
) { sDatabaseName
= sValue
; }
155 void SetSourceObject(const rtl::OUString
& sValue
) { sSourceObject
= sValue
; }
156 void SetNative(const sal_Bool bValue
) { bIsNative
= bValue
; }
157 void SetServiceName(const rtl::OUString
& sValue
) { sServiceName
= sValue
; }
158 void SetServiceSourceName(const rtl::OUString
& sValue
) { sServiceSourceName
= sValue
; }
159 void SetServiceSourceObject(const rtl::OUString
& sValue
) { sServiceSourceObject
= sValue
; }
160 void SetServiceUsername(const rtl::OUString
& sValue
) { sServiceUsername
= sValue
; }
161 void SetServicePassword(const rtl::OUString
& sValue
) { sServicePassword
= sValue
; }
162 void SetSourceCellRangeAddress(const ScRange
& aValue
) { aSourceCellRangeAddress
= aValue
; bSourceCellRange
= sal_True
; }
163 void SetSourceQueryParam(const ScQueryParam
& aValue
) { aSourceQueryParam
= aValue
; }
164 // void SetFilterUseRegularExpressions(const sal_Bool bValue) { aSourceQueryParam.bRegExp = bValue; }
165 void SetFilterOutputPosition(const ScAddress
& aValue
) { aFilterOutputPosition
= aValue
; }
166 void SetFilterCopyOutputData(const sal_Bool bValue
) { bFilterCopyOutputData
= bValue
; }
167 void SetFilterSourceRange(const ScRange
& aValue
) { aFilterSourceRange
= aValue
; }
168 // void SetFilterIsCaseSensitive(const sal_Bool bValue) { aSourceQueryParam.bCaseSens = bValue; }
169 // void SetFilterSkipDuplicates(const sal_Bool bValue) { aSourceQueryParam.bDuplicate = !bValue; }
170 void AddDimension(ScDPSaveDimension
* pDim
, bool bHasHiddenMember
);
171 void AddGroupDim(const ScDPSaveNumGroupDimension
& aNumGroupDim
);
172 void AddGroupDim(const ScDPSaveGroupDimension
& aGroupDim
);
176 class ScXMLDPSourceSQLContext
: public SvXMLImportContext
178 ScXMLDataPilotTableContext
* pDataPilotTable
;
180 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
181 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
185 ScXMLDPSourceSQLContext( ScXMLImport
& rImport
, USHORT nPrfx
,
186 const ::rtl::OUString
& rLName
,
187 const ::com::sun::star::uno::Reference
<
188 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
189 ScXMLDataPilotTableContext
* pDataPilotTable
);
191 virtual ~ScXMLDPSourceSQLContext();
193 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
194 const ::rtl::OUString
& rLocalName
,
195 const ::com::sun::star::uno::Reference
<
196 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
198 virtual void EndElement();
201 class ScXMLDPSourceTableContext
: public SvXMLImportContext
203 ScXMLDataPilotTableContext
* pDataPilotTable
;
205 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
206 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
210 ScXMLDPSourceTableContext( ScXMLImport
& rImport
, USHORT nPrfx
,
211 const ::rtl::OUString
& rLName
,
212 const ::com::sun::star::uno::Reference
<
213 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
214 ScXMLDataPilotTableContext
* pDataPilotTable
);
216 virtual ~ScXMLDPSourceTableContext();
218 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
219 const ::rtl::OUString
& rLocalName
,
220 const ::com::sun::star::uno::Reference
<
221 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
223 virtual void EndElement();
226 class ScXMLDPSourceQueryContext
: public SvXMLImportContext
228 ScXMLDataPilotTableContext
* pDataPilotTable
;
230 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
231 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
235 ScXMLDPSourceQueryContext( ScXMLImport
& rImport
, USHORT nPrfx
,
236 const ::rtl::OUString
& rLName
,
237 const ::com::sun::star::uno::Reference
<
238 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
239 ScXMLDataPilotTableContext
* pDataPilotTable
);
241 virtual ~ScXMLDPSourceQueryContext();
243 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
244 const ::rtl::OUString
& rLocalName
,
245 const ::com::sun::star::uno::Reference
<
246 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
248 virtual void EndElement();
251 class ScXMLSourceServiceContext
: public SvXMLImportContext
253 ScXMLDataPilotTableContext
* pDataPilotTable
;
255 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
256 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
260 ScXMLSourceServiceContext( ScXMLImport
& rImport
, USHORT nPrfx
,
261 const ::rtl::OUString
& rLName
,
262 const ::com::sun::star::uno::Reference
<
263 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
264 ScXMLDataPilotTableContext
* pDataPilotTable
);
266 virtual ~ScXMLSourceServiceContext();
268 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
269 const ::rtl::OUString
& rLocalName
,
270 const ::com::sun::star::uno::Reference
<
271 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
273 virtual void EndElement();
276 class ScXMLDataPilotGrandTotalContext
: public SvXMLImportContext
278 enum Orientation
{ COLUMN
, ROW
, BOTH
, NONE
};
280 ScXMLImport
& GetScImport();
282 ScXMLDataPilotTableContext
* mpTableContext
;
283 ::rtl::OUString maDisplayName
;
284 Orientation meOrientation
;
288 ScXMLDataPilotGrandTotalContext(
289 ScXMLImport
& rImport
, USHORT nPrefix
, const ::rtl::OUString
& rLName
,
290 const ::com::sun::star::uno::Reference
<
291 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
292 ScXMLDataPilotTableContext
* pTableContext
);
294 virtual ~ScXMLDataPilotGrandTotalContext();
296 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
297 const ::rtl::OUString
& rLocalName
,
298 const ::com::sun::star::uno::Reference
<
299 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
301 virtual void EndElement();
304 class ScXMLSourceCellRangeContext
: public SvXMLImportContext
306 ScXMLDataPilotTableContext
* pDataPilotTable
;
308 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
309 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
313 ScXMLSourceCellRangeContext( ScXMLImport
& rImport
, USHORT nPrfx
,
314 const ::rtl::OUString
& rLName
,
315 const ::com::sun::star::uno::Reference
<
316 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
317 ScXMLDataPilotTableContext
* pDataPilotTable
);
319 virtual ~ScXMLSourceCellRangeContext();
321 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
322 const ::rtl::OUString
& rLocalName
,
323 const ::com::sun::star::uno::Reference
<
324 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
326 virtual void EndElement();
329 struct ScXMLDataPilotGroup
331 ::std::vector
<rtl::OUString
> aMembers
;
335 class ScXMLDataPilotFieldContext
: public SvXMLImportContext
337 ScXMLDataPilotTableContext
* pDataPilotTable
;
338 ScDPSaveDimension
* pDim
;
340 ::std::vector
<ScXMLDataPilotGroup
> aGroups
;
341 rtl::OUString sGroupSource
;
342 rtl::OUString sSelectedPage
;
347 sal_Int32 nUsedHierarchy
;
348 sal_Int32 nGroupPart
;
350 sal_Int16 nOrientation
;
351 sal_Bool bShowEmpty
:1;
352 sal_Bool bSelectedPage
:1;
353 sal_Bool bIsGroupField
:1;
354 sal_Bool bDateValue
:1;
355 sal_Bool bAutoStart
:1;
357 bool mbHasHiddenMember
:1;
359 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
360 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
364 ScXMLDataPilotFieldContext( ScXMLImport
& rImport
, USHORT nPrfx
,
365 const ::rtl::OUString
& rLName
,
366 const ::com::sun::star::uno::Reference
<
367 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
368 ScXMLDataPilotTableContext
* pDataPilotTable
);
370 virtual ~ScXMLDataPilotFieldContext();
372 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
373 const ::rtl::OUString
& rLocalName
,
374 const ::com::sun::star::uno::Reference
<
375 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
377 virtual void EndElement();
379 void SetShowEmpty(const sal_Bool bValue
) { if (pDim
) pDim
->SetShowEmpty(bValue
); }
380 void SetSubTotals(const sal_uInt16
* pFunctions
, const sal_Int16 nCount
) { if(pDim
) pDim
->SetSubTotals(nCount
, pFunctions
); }
381 void AddMember(ScDPSaveMember
* pMember
);
382 void SetSubTotalName(const ::rtl::OUString
& rName
);
383 void SetFieldReference(const com::sun::star::sheet::DataPilotFieldReference
& aRef
) { if (pDim
) pDim
->SetReferenceValue(&aRef
); }
384 void SetAutoShowInfo(const com::sun::star::sheet::DataPilotFieldAutoShowInfo
& aInfo
) { if (pDim
) pDim
->SetAutoShowInfo(&aInfo
); }
385 void SetSortInfo(const com::sun::star::sheet::DataPilotFieldSortInfo
& aInfo
) { if (pDim
) pDim
->SetSortInfo(&aInfo
); }
386 void SetLayoutInfo(const com::sun::star::sheet::DataPilotFieldLayoutInfo
& aInfo
) { if (pDim
) pDim
->SetLayoutInfo(&aInfo
); }
387 void SetGrouping(const rtl::OUString
& rGroupSource
, const double& rStart
, const double& rEnd
, const double& rStep
,
388 sal_Int32 nPart
, sal_Bool bDate
, sal_Bool bAutoSt
, sal_Bool bAutoE
)
390 bIsGroupField
= sal_True
;
391 sGroupSource
= rGroupSource
;
397 bAutoStart
= bAutoSt
;
400 void AddGroup(const ::std::vector
<rtl::OUString
>& rMembers
, const rtl::OUString
& rName
);
403 class ScXMLDataPilotFieldReferenceContext
: public SvXMLImportContext
405 // com::sun::star::sheet::DataPilotFieldReference aReference;
407 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
408 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
412 ScXMLDataPilotFieldReferenceContext( ScXMLImport
& rImport
, USHORT nPrfx
,
413 const ::rtl::OUString
& rLName
,
414 const ::com::sun::star::uno::Reference
<
415 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
416 ScXMLDataPilotFieldContext
* pDataPilotField
);
418 virtual ~ScXMLDataPilotFieldReferenceContext();
421 class ScXMLDataPilotLevelContext
: public SvXMLImportContext
423 ScXMLDataPilotFieldContext
* pDataPilotField
;
425 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
426 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
430 ScXMLDataPilotLevelContext( ScXMLImport
& rImport
, USHORT nPrfx
,
431 const ::rtl::OUString
& rLName
,
432 const ::com::sun::star::uno::Reference
<
433 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
434 ScXMLDataPilotFieldContext
* pDataPilotField
);
436 virtual ~ScXMLDataPilotLevelContext();
438 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
439 const ::rtl::OUString
& rLocalName
,
440 const ::com::sun::star::uno::Reference
<
441 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
443 virtual void EndElement();
446 class ScXMLDataPilotDisplayInfoContext
: public SvXMLImportContext
448 // com::sun::star::sheet::DataPilotFieldAutoShowInfo aInfo;
450 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
451 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
455 ScXMLDataPilotDisplayInfoContext( ScXMLImport
& rImport
, USHORT nPrfx
,
456 const ::rtl::OUString
& rLName
,
457 const ::com::sun::star::uno::Reference
<
458 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
459 ScXMLDataPilotFieldContext
* pDataPilotField
);
461 virtual ~ScXMLDataPilotDisplayInfoContext();
464 class ScXMLDataPilotSortInfoContext
: public SvXMLImportContext
466 // com::sun::star::sheet::DataPilotFieldSortInfo aInfo;
468 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
469 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
473 ScXMLDataPilotSortInfoContext( ScXMLImport
& rImport
, USHORT nPrfx
,
474 const ::rtl::OUString
& rLName
,
475 const ::com::sun::star::uno::Reference
<
476 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
477 ScXMLDataPilotFieldContext
* pDataPilotField
);
479 virtual ~ScXMLDataPilotSortInfoContext();
482 class ScXMLDataPilotLayoutInfoContext
: public SvXMLImportContext
484 // com::sun::star::sheet::DataPilotFieldLayoutInfo aInfo;
486 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
487 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
491 ScXMLDataPilotLayoutInfoContext( ScXMLImport
& rImport
, USHORT nPrfx
,
492 const ::rtl::OUString
& rLName
,
493 const ::com::sun::star::uno::Reference
<
494 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
495 ScXMLDataPilotFieldContext
* pDataPilotField
);
497 virtual ~ScXMLDataPilotLayoutInfoContext();
500 class ScXMLDataPilotSubTotalsContext
: public SvXMLImportContext
502 ScXMLDataPilotFieldContext
* pDataPilotField
;
504 sal_Int16 nFunctionCount
;
505 sal_uInt16
* pFunctions
;
506 ::rtl::OUString maDisplayName
;
508 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
509 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
513 ScXMLDataPilotFieldContext
* GetDataPilotField() { return pDataPilotField
; }
515 ScXMLDataPilotSubTotalsContext( ScXMLImport
& rImport
, USHORT nPrfx
,
516 const ::rtl::OUString
& rLName
,
517 const ::com::sun::star::uno::Reference
<
518 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
519 ScXMLDataPilotFieldContext
* pDataPilotField
);
521 virtual ~ScXMLDataPilotSubTotalsContext();
523 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
524 const ::rtl::OUString
& rLocalName
,
525 const ::com::sun::star::uno::Reference
<
526 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
528 virtual void EndElement();
529 void AddFunction(sal_Int16 nFunction
);
530 void SetDisplayName(const ::rtl::OUString
& rName
);
533 class ScXMLDataPilotSubTotalContext
: public SvXMLImportContext
535 ScXMLDataPilotSubTotalsContext
* pDataPilotSubTotals
;
537 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
538 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
542 ScXMLDataPilotSubTotalContext( ScXMLImport
& rImport
, USHORT nPrfx
,
543 const ::rtl::OUString
& rLName
,
544 const ::com::sun::star::uno::Reference
<
545 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
546 ScXMLDataPilotSubTotalsContext
* pDataPilotSubTotals
);
548 virtual ~ScXMLDataPilotSubTotalContext();
550 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
551 const ::rtl::OUString
& rLocalName
,
552 const ::com::sun::star::uno::Reference
<
553 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
555 virtual void EndElement();
558 class ScXMLDataPilotMembersContext
: public SvXMLImportContext
560 ScXMLDataPilotFieldContext
* pDataPilotField
;
562 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
563 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
567 ScXMLDataPilotMembersContext( ScXMLImport
& rImport
, USHORT nPrfx
,
568 const ::rtl::OUString
& rLName
,
569 const ::com::sun::star::uno::Reference
<
570 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
571 ScXMLDataPilotFieldContext
* pDataPilotField
);
573 virtual ~ScXMLDataPilotMembersContext();
575 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
576 const ::rtl::OUString
& rLocalName
,
577 const ::com::sun::star::uno::Reference
<
578 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
580 virtual void EndElement();
583 class ScXMLDataPilotMemberContext
: public SvXMLImportContext
585 ScXMLDataPilotFieldContext
* pDataPilotField
;
588 rtl::OUString maDisplayName
;
590 sal_Bool bDisplayDetails
;
593 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
594 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
598 ScXMLDataPilotMemberContext( ScXMLImport
& rImport
, USHORT nPrfx
,
599 const ::rtl::OUString
& rLName
,
600 const ::com::sun::star::uno::Reference
<
601 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
602 ScXMLDataPilotFieldContext
* pDataPilotField
);
604 virtual ~ScXMLDataPilotMemberContext();
606 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
607 const ::rtl::OUString
& rLocalName
,
608 const ::com::sun::star::uno::Reference
<
609 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
611 virtual void EndElement();
614 class ScXMLDataPilotGroupsContext
: public SvXMLImportContext
616 ScXMLDataPilotFieldContext
* pDataPilotField
;
618 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
619 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
623 ScXMLDataPilotGroupsContext( ScXMLImport
& rImport
, USHORT nPrfx
,
624 const ::rtl::OUString
& rLName
,
625 const ::com::sun::star::uno::Reference
<
626 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
627 ScXMLDataPilotFieldContext
* pDataPilotField
);
629 virtual ~ScXMLDataPilotGroupsContext();
631 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
632 const ::rtl::OUString
& rLocalName
,
633 const ::com::sun::star::uno::Reference
<
634 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
636 virtual void EndElement();
639 class ScXMLDataPilotGroupContext
: public SvXMLImportContext
641 ScXMLDataPilotFieldContext
* pDataPilotField
;
644 ::std::vector
<rtl::OUString
> aMembers
;
646 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
647 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
651 ScXMLDataPilotGroupContext( ScXMLImport
& rImport
, USHORT nPrfx
,
652 const ::rtl::OUString
& rLName
,
653 const ::com::sun::star::uno::Reference
<
654 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
655 ScXMLDataPilotFieldContext
* pDataPilotField
);
657 virtual ~ScXMLDataPilotGroupContext();
659 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
660 const ::rtl::OUString
& rLocalName
,
661 const ::com::sun::star::uno::Reference
<
662 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
664 virtual void EndElement();
666 void AddMember(const rtl::OUString
& sMember
) { aMembers
.push_back(sMember
); }
669 class ScXMLDataPilotGroupMemberContext
: public SvXMLImportContext
671 ScXMLDataPilotGroupContext
* pDataPilotGroup
;
675 const ScXMLImport
& GetScImport() const { return (const ScXMLImport
&)GetImport(); }
676 ScXMLImport
& GetScImport() { return (ScXMLImport
&)GetImport(); }
680 ScXMLDataPilotGroupMemberContext( ScXMLImport
& rImport
, USHORT nPrfx
,
681 const ::rtl::OUString
& rLName
,
682 const ::com::sun::star::uno::Reference
<
683 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
,
684 ScXMLDataPilotGroupContext
* pDataPilotGroup
);
686 virtual ~ScXMLDataPilotGroupMemberContext();
688 virtual SvXMLImportContext
*CreateChildContext( USHORT nPrefix
,
689 const ::rtl::OUString
& rLocalName
,
690 const ::com::sun::star::uno::Reference
<
691 ::com::sun::star::xml::sax::XAttributeList
>& xAttrList
);
693 virtual void EndElement();