LibreOffice Module sc (master)  1
xlpivot.hxx
Go to the documentation of this file.
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 #pragma once
21 
22 #include <com/sun/star/sheet/DataPilotFieldOrientation.hpp>
23 #include <tools/datetime.hxx>
24 #include "ftools.hxx"
25 #include "xladdress.hxx"
26 #include <dpobject.hxx>
27 
28 #include <optional>
29 
30 class XclImpStream;
31 class XclExpStream;
32 enum class ScGeneralFunction;
33 
34 // Constants and Enumerations =================================================
35 
36 // misc -----------------------------------------------------------------------
37 
38 #define EXC_STORAGE_PTCACHE "_SX_DB_CUR"
39 
40 // strings
41 const sal_uInt16 EXC_PT_NOSTRING = 0xFFFF;
42 const sal_uInt16 EXC_PT_MAXSTRLEN = 0xFFFE;
43 
44 // pivot cache fields
45 const size_t EXC_PC_MAXFIELDCOUNT = 0xFFFE;
46 const sal_uInt16 EXC_PC_NOFIELD = 0xFFFF;
47 const sal_Int32 EXC_PC_MAXSTRLEN = 255;
48 
49 // pivot cache items
50 const size_t EXC_PC_MAXITEMCOUNT = 32500;
51 const sal_uInt16 EXC_PC_NOITEM = 0xFFFF;
52 
53 // pivot table fields
54 const sal_uInt16 EXC_PT_MAXFIELDCOUNT = 0xFFFE;
56 const sal_uInt16 EXC_PT_MAXPAGECOUNT = 256;
57 const sal_uInt16 EXC_PT_MAXDATACOUNT = 256;
58 
59 // pivot table items
60 const sal_uInt16 EXC_PT_MAXITEMCOUNT = 32500;
61 
62 const sal_uInt16 EXC_PT_AUTOFMT_HEADER = 0x810;
63 const sal_uInt16 EXC_PT_AUTOFMT_ZERO = 0;
64 const sal_uInt32 EXC_PT_AUTOFMT_FLAGS = 0x20;
65 
68 {
77 };
78 
81 {
89 };
90 
91 // (0x0051,0x0052) DCONREF, DCONNAME ------------------------------------------
92 
93 const sal_uInt16 EXC_ID_DCONREF = 0x0051;
94 const sal_uInt16 EXC_ID_DCONNAME = 0x0052;
95 
96 // (0x00B0) SXVIEW ------------------------------------------------------------
97 
98 const sal_uInt16 EXC_ID_SXVIEW = 0x00B0;
99 
100 const sal_uInt16 EXC_SXVIEW_ROWGRAND = 0x0001;
101 const sal_uInt16 EXC_SXVIEW_COLGRAND = 0x0002;
102 const sal_uInt16 EXC_SXVIEW_DEFAULTFLAGS = 0x0208;
103 
104 const sal_uInt16 EXC_SXVIEW_DATALAST = 0xFFFF;
105 const sal_uInt16 EXC_SXVIEW_AUTOFMT = 0x0001;
106 
107 // (0x00B1) SXVD --------------------------------------------------------------
108 const sal_uInt16 EXC_ID_SXVD = 0x00B1;
109 
110 const sal_uInt16 EXC_SXVD_AXIS_NONE = 0x0000;
111 const sal_uInt16 EXC_SXVD_AXIS_ROW = 0x0001;
112 const sal_uInt16 EXC_SXVD_AXIS_COL = 0x0002;
113 const sal_uInt16 EXC_SXVD_AXIS_PAGE = 0x0004;
114 const sal_uInt16 EXC_SXVD_AXIS_DATA = 0x0008;
117 
118 const sal_uInt16 EXC_SXVD_SUBT_NONE = 0x0000;
119 const sal_uInt16 EXC_SXVD_SUBT_DEFAULT = 0x0001;
120 const sal_uInt16 EXC_SXVD_SUBT_SUM = 0x0002;
121 const sal_uInt16 EXC_SXVD_SUBT_COUNT = 0x0004;
122 const sal_uInt16 EXC_SXVD_SUBT_AVERAGE = 0x0008;
123 const sal_uInt16 EXC_SXVD_SUBT_MAX = 0x0010;
124 const sal_uInt16 EXC_SXVD_SUBT_MIN = 0x0020;
125 const sal_uInt16 EXC_SXVD_SUBT_PROD = 0x0040;
126 const sal_uInt16 EXC_SXVD_SUBT_COUNTNUM = 0x0080;
127 const sal_uInt16 EXC_SXVD_SUBT_STDDEV = 0x0100;
128 const sal_uInt16 EXC_SXVD_SUBT_STDDEVP = 0x0200;
129 const sal_uInt16 EXC_SXVD_SUBT_VAR = 0x0400;
130 const sal_uInt16 EXC_SXVD_SUBT_VARP = 0x0800;
131 
133 
134 // (0x00B2) SXVI --------------------------------------------------------------
135 const sal_uInt16 EXC_ID_SXVI = 0x00B2;
136 
137 const sal_uInt16 EXC_SXVI_TYPE_PAGE = 0x00FE;
138 const sal_uInt16 EXC_SXVI_TYPE_NULL = 0x00FF;
139 const sal_uInt16 EXC_SXVI_TYPE_DATA = 0x0000;
140 const sal_uInt16 EXC_SXVI_TYPE_DEFAULT = 0x0001;
141 const sal_uInt16 EXC_SXVI_TYPE_SUM = 0x0002;
142 const sal_uInt16 EXC_SXVI_TYPE_COUNT = 0x0003;
143 const sal_uInt16 EXC_SXVI_TYPE_AVERAGE = 0x0004;
144 const sal_uInt16 EXC_SXVI_TYPE_MAX = 0x0005;
145 const sal_uInt16 EXC_SXVI_TYPE_MIN = 0x0006;
146 const sal_uInt16 EXC_SXVI_TYPE_PROD = 0x0007;
147 const sal_uInt16 EXC_SXVI_TYPE_COUNTNUM = 0x0008;
148 const sal_uInt16 EXC_SXVI_TYPE_STDDEV = 0x0009;
149 const sal_uInt16 EXC_SXVI_TYPE_STDDEVP = 0x000A;
150 const sal_uInt16 EXC_SXVI_TYPE_VAR = 0x000B;
151 const sal_uInt16 EXC_SXVI_TYPE_VARP = 0x000C;
152 const sal_uInt16 EXC_SXVI_TYPE_GRAND = 0x000D;
153 
154 const sal_uInt16 EXC_SXVI_DEFAULTFLAGS = 0x0000;
155 const sal_uInt16 EXC_SXVI_HIDDEN = 0x0001;
156 const sal_uInt16 EXC_SXVI_HIDEDETAIL = 0x0002;
157 const sal_uInt16 EXC_SXVI_FORMULA = 0x0004;
158 const sal_uInt16 EXC_SXVI_MISSING = 0x0008;
159 
161 
162 // (0x00B4) SXIVD -------------------------------------------------------------
163 const sal_uInt16 EXC_ID_SXIVD = 0x00B4;
164 const sal_uInt16 EXC_SXIVD_DATA = 0xFFFE;
165 
166 // (0x00B5) SXLI --------------------------------------------------------------
167 const sal_uInt16 EXC_ID_SXLI = 0x00B5;
168 const sal_uInt16 EXC_SXLI_DEFAULTFLAGS = 0x0000;
169 
170 // (0x00B6) SXPI --------------------------------------------------------------
171 const sal_uInt16 EXC_ID_SXPI = 0x00B6;
172 const sal_uInt16 EXC_SXPI_ALLITEMS = 0x7FFD;
173 
174 // (0x00C5) SXDI --------------------------------------------------------------
175 const sal_uInt16 EXC_ID_SXDI = 0x00C5;
176 
177 const sal_uInt16 EXC_SXDI_FUNC_SUM = 0x0000;
178 const sal_uInt16 EXC_SXDI_FUNC_COUNT = 0x0001;
179 const sal_uInt16 EXC_SXDI_FUNC_AVERAGE = 0x0002;
180 const sal_uInt16 EXC_SXDI_FUNC_MAX = 0x0003;
181 const sal_uInt16 EXC_SXDI_FUNC_MIN = 0x0004;
182 const sal_uInt16 EXC_SXDI_FUNC_PRODUCT = 0x0005;
183 const sal_uInt16 EXC_SXDI_FUNC_COUNTNUM = 0x0006;
184 const sal_uInt16 EXC_SXDI_FUNC_STDDEV = 0x0007;
185 const sal_uInt16 EXC_SXDI_FUNC_STDDEVP = 0x0008;
186 const sal_uInt16 EXC_SXDI_FUNC_VAR = 0x0009;
187 const sal_uInt16 EXC_SXDI_FUNC_VARP = 0x000A;
188 
189 const sal_uInt16 EXC_SXDI_REF_NORMAL = 0x0000;
190 const sal_uInt16 EXC_SXDI_REF_DIFF = 0x0001;
191 const sal_uInt16 EXC_SXDI_REF_PERC = 0x0002;
192 const sal_uInt16 EXC_SXDI_REF_PERC_DIFF = 0x0003;
193 const sal_uInt16 EXC_SXDI_REF_RUN_TOTAL = 0x0004;
194 const sal_uInt16 EXC_SXDI_REF_PERC_ROW = 0x0005;
195 const sal_uInt16 EXC_SXDI_REF_PERC_COL = 0x0006;
196 const sal_uInt16 EXC_SXDI_REF_PERC_TOTAL = 0x0007;
197 const sal_uInt16 EXC_SXDI_REF_INDEX = 0x0008;
198 
199 const sal_uInt16 EXC_SXDI_PREVITEM = 0x7FFB;
200 const sal_uInt16 EXC_SXDI_NEXTITEM = 0x7FFC;
201 
202 // (0x00C6) SXDB --------------------------------------------------------------
203 const sal_uInt16 EXC_ID_SXDB = 0x00C6;
204 
205 const sal_uInt16 EXC_SXDB_SAVEDATA = 0x0001;
206 const sal_uInt16 EXC_SXDB_INVALID = 0x0002;
207 const sal_uInt16 EXC_SXDB_REFRESH_LOAD = 0x0004;
208 const sal_uInt16 EXC_SXDB_OPT_CACHE = 0x0008;
209 const sal_uInt16 EXC_SXDB_BG_QUERY = 0x0010;
210 const sal_uInt16 EXC_SXDB_ENABLE_REFRESH = 0x0020;
212 
213 const sal_uInt16 EXC_SXDB_BLOCKRECS = 0x1FFF;
214 
215 const sal_uInt16 EXC_SXDB_SRC_SHEET = 0x0001;
216 const sal_uInt16 EXC_SXDB_SRC_EXTERN = 0x0002;
217 const sal_uInt16 EXC_SXDB_SRC_CONSOLID = 0x0004;
218 const sal_uInt16 EXC_SXDB_SRC_SCENARIO = 0x0008;
219 
220 // (0x00C7) SXFIELD -----------------------------------------------------------
221 const sal_uInt16 EXC_ID_SXFIELD = 0x00C7;
222 
223 const sal_uInt16 EXC_SXFIELD_HASITEMS = 0x0001;
224 const sal_uInt16 EXC_SXFIELD_POSTPONE = 0x0002;
225 const sal_uInt16 EXC_SXFIELD_CALCED = 0x0004;
226 const sal_uInt16 EXC_SXFIELD_HASCHILD = 0x0008;
227 const sal_uInt16 EXC_SXFIELD_NUMGROUP = 0x0010;
228 const sal_uInt16 EXC_SXFIELD_16BIT = 0x0200;
229 
230 const sal_uInt16 EXC_SXFIELD_DATA_MASK = 0x0DE0;
231 // known data types
232 const sal_uInt16 EXC_SXFIELD_DATA_NONE = 0x0000;
233 const sal_uInt16 EXC_SXFIELD_DATA_STR = 0x0480;
234 const sal_uInt16 EXC_SXFIELD_DATA_INT = 0x0520;
235 const sal_uInt16 EXC_SXFIELD_DATA_DBL = 0x0560;
236 const sal_uInt16 EXC_SXFIELD_DATA_STR_INT = 0x05A0;
237 const sal_uInt16 EXC_SXFIELD_DATA_STR_DBL = 0x05E0;
238 const sal_uInt16 EXC_SXFIELD_DATA_DATE = 0x0900;
239 const sal_uInt16 EXC_SXFIELD_DATA_DATE_EMP = 0x0980;
240 const sal_uInt16 EXC_SXFIELD_DATA_DATE_NUM = 0x0D00;
241 const sal_uInt16 EXC_SXFIELD_DATA_DATE_STR = 0x0D80;
242 
243 const sal_uInt16 EXC_SXFIELD_INDEX_MIN = 0;
244 const sal_uInt16 EXC_SXFIELD_INDEX_MAX = 1;
245 const sal_uInt16 EXC_SXFIELD_INDEX_STEP = 2;
246 
247 // (0x00C8) SXINDEXLIST -------------------------------------------------------
248 const sal_uInt16 EXC_ID_SXINDEXLIST = 0x00C8;
249 
250 // (0x00C9) SXDOUBLE ----------------------------------------------------------
251 const sal_uInt16 EXC_ID_SXDOUBLE = 0x00C9;
252 
253 // (0x00CA) SXBOOLEAN ---------------------------------------------------------
254 const sal_uInt16 EXC_ID_SXBOOLEAN = 0x00CA;
255 
256 // (0x00CB) SXERROR -----------------------------------------------------------
257 const sal_uInt16 EXC_ID_SXERROR = 0x00CB;
258 
259 // (0x00CC) SXINTEGER ---------------------------------------------------------
260 const sal_uInt16 EXC_ID_SXINTEGER = 0x00CC;
261 
262 // (0x00CD) SXSTRING ----------------------------------------------------------
263 const sal_uInt16 EXC_ID_SXSTRING = 0x00CD;
264 
265 // (0x00CE) SXDATETIME --------------------------------------------------------
266 const sal_uInt16 EXC_ID_SXDATETIME = 0x00CE;
267 
268 // (0x00CF) SXEMPTY -----------------------------------------------------------
269 const sal_uInt16 EXC_ID_SXEMPTY = 0x00CF;
270 
271 // (0x00D5) SXIDSTM -----------------------------------------------------------
272 const sal_uInt16 EXC_ID_SXIDSTM = 0x00D5;
273 
274 // (0x00D8) SXNUMGROUP --------------------------------------------------------
275 const sal_uInt16 EXC_ID_SXNUMGROUP = 0x00D8;
276 
277 const sal_uInt16 EXC_SXNUMGROUP_AUTOMIN = 0x0001;
278 const sal_uInt16 EXC_SXNUMGROUP_AUTOMAX = 0x0002;
279 
280 const sal_uInt16 EXC_SXNUMGROUP_TYPE_SEC = 1;
281 const sal_uInt16 EXC_SXNUMGROUP_TYPE_MIN = 2;
282 const sal_uInt16 EXC_SXNUMGROUP_TYPE_HOUR = 3;
283 const sal_uInt16 EXC_SXNUMGROUP_TYPE_DAY = 4;
284 const sal_uInt16 EXC_SXNUMGROUP_TYPE_MONTH = 5;
285 const sal_uInt16 EXC_SXNUMGROUP_TYPE_QUART = 6;
286 const sal_uInt16 EXC_SXNUMGROUP_TYPE_YEAR = 7;
287 const sal_uInt16 EXC_SXNUMGROUP_TYPE_NUM = 8;
288 
289 // (0x00D9) SXGROUPINFO -------------------------------------------------------
290 const sal_uInt16 EXC_ID_SXGROUPINFO = 0x00D9;
291 
292 // (0x00DC) SXEXT -------------------------------------------------------------
293 const sal_uInt16 EXC_ID_SXEXT = 0x00DC;
294 
295 // (0x00E3) SXVS --------------------------------------------------------------
296 const sal_uInt16 EXC_ID_SXVS = 0x00E3;
297 
298 const sal_uInt16 EXC_SXVS_UNKNOWN = 0x0000;
299 const sal_uInt16 EXC_SXVS_SHEET = 0x0001;
300 const sal_uInt16 EXC_SXVS_EXTERN = 0x0002;
301 const sal_uInt16 EXC_SXVS_CONSOLID = 0x0004;
302 const sal_uInt16 EXC_SXVS_PIVOTTAB = 0x0008;
303 const sal_uInt16 EXC_SXVS_SCENARIO = 0x0010;
304 
305 // (0x00F0) SXRULE ------------------------------------------------------------
306 const sal_uInt16 EXC_ID_SXRULE = 0x00F0;
307 
308 // (0x00F1) SXEX --------------------------------------------------------------
309 const sal_uInt16 EXC_ID_SXEX = 0x00F1;
310 
311 const sal_uInt32 EXC_SXEX_DRILLDOWN = 0x00020000;
312 const sal_uInt32 EXC_SXEX_DEFAULTFLAGS = 0x004F0200;
313 
314 // (0x00F2) SXFILT ------------------------------------------------------------
315 const sal_uInt16 EXC_ID_SXFILT = 0x00F2;
316 
317 // (0x00F5) -------------------------------------------------------------------
318 const sal_uInt16 EXC_ID_00F5 = 0x00F5;
319 
320 // (0x00F6) SXNAME ------------------------------------------------------------
321 const sal_uInt16 EXC_ID_SXNAME = 0x00F6;
322 
323 // (0x00F8) SXPAIR ------------------------------------------------------------
324 const sal_uInt16 EXC_ID_SXPAIR = 0x00F8;
325 
326 // (0x00F9) SXFMLA ------------------------------------------------------------
327 const sal_uInt16 EXC_ID_SXFMLA = 0x00F9;
328 
329 // (0x0100) SXVDEX ------------------------------------------------------------
330 const sal_uInt16 EXC_ID_SXVDEX = 0x0100;
331 
332 const sal_uInt32 EXC_SXVDEX_SHOWALL = 0x00000001;
333 const sal_uInt32 EXC_SXVDEX_SORT = 0x00000200;
334 const sal_uInt32 EXC_SXVDEX_SORT_ASC = 0x00000400;
335 const sal_uInt32 EXC_SXVDEX_AUTOSHOW = 0x00000800;
336 const sal_uInt32 EXC_SXVDEX_AUTOSHOW_ASC = 0x00001000;
337 const sal_uInt32 EXC_SXVDEX_LAYOUT_REPORT = 0x00200000;
338 const sal_uInt32 EXC_SXVDEX_LAYOUT_BLANK = 0x00400000;
339 const sal_uInt32 EXC_SXVDEX_LAYOUT_TOP = 0x00800000;
341 
342 const sal_uInt16 EXC_SXVDEX_SORT_OWN = 0xFFFF;
343 const sal_uInt16 EXC_SXVDEX_SHOW_NONE = 0xFFFF;
344 const sal_uInt16 EXC_SXVDEX_FORMAT_NONE = 0x0000;
345 
346 // (0x0103) SXFORMULA ---------------------------------------------------------
347 const sal_uInt16 EXC_ID_SXFORMULA = 0x0103;
348 
349 // (0x0122) SXDBEX ------------------------------------------------------------
350 const sal_uInt16 EXC_ID_SXDBEX = 0x0122;
351 const double EXC_SXDBEX_CREATION_DATE = 51901.029652778;
352 
353 // (0x01BB) SXFDBTYPE ---------------------------------------------------------
354 const sal_uInt16 EXC_ID_SXFDBTYPE = 0x01BB;
355 const sal_uInt16 EXC_SXFDBTYPE_DEFAULT = 0x0000;
356 
357 // (0x0810) SXVIEWEX9 ---------------------------------------------------------
358 const sal_uInt16 EXC_ID_SXVIEWEX9 = 0x0810;
359 
360 // (0x0864) SXADDL ("Pivot Table Additional Info") ----------------------------
361 const sal_uInt16 EXC_ID_SXADDL = 0x0864;
362 
363 // Pivot cache
364 
367 {
368 public:
369  explicit XclPCItem();
370  virtual ~XclPCItem();
371 
372  XclPCItem(XclPCItem const &) = default;
373  XclPCItem(XclPCItem &&) = default;
374  XclPCItem & operator =(XclPCItem const &) = default;
375  XclPCItem & operator =(XclPCItem &&) = default;
376 
378  void SetEmpty();
380  void SetText( const OUString& rText );
382  void SetDouble( double fValue, const OUString& rText = OUString() );
384  void SetDateTime( const DateTime& rDateTime, const OUString& rText = OUString() );
386  void SetInteger( sal_Int16 nValue );
388  void SetError( sal_uInt16 nError );
390  void SetBool( bool bValue, const OUString& rText = OUString() );
391 
393  const OUString& ConvertToText() const { return maText; }
394 
396  bool IsEqual( const XclPCItem& rItem ) const;
397 
399  bool IsEmpty() const;
401  const OUString* GetText() const;
403  const double* GetDouble() const;
405  const DateTime* GetDateTime() const;
407  const sal_Int16* GetInteger() const;
409  const sal_uInt16* GetError() const;
411  const bool* GetBool() const;
412 
414  XclPCItemType GetType() const;
415 
416 private:
418  OUString maText;
420  union
421  {
422  double mfValue;
423  sal_Int16 mnValue;
424  sal_uInt16 mnError;
425  bool mbValue;
426  };
427 };
428 
429 inline bool operator==( const XclPCItem& rLeft, const XclPCItem& rRight ) { return rLeft.IsEqual( rRight ); }
430 inline bool operator!=( const XclPCItem& rLeft, const XclPCItem& rRight ) { return !(rLeft == rRight); }
431 
432 // Field settings =============================================================
433 
436 {
437  OUString maName;
438  sal_uInt16 mnFlags;
439  sal_uInt16 mnGroupChild;
440  sal_uInt16 mnGroupBase;
441  sal_uInt16 mnVisItems;
442  sal_uInt16 mnGroupItems;
443  sal_uInt16 mnBaseItems;
444  sal_uInt16 mnOrigItems;
445 
446  explicit XclPCFieldInfo();
447 };
448 
450 XclExpStream& operator<<( XclExpStream& rStrm, const XclPCFieldInfo& rInfo );
451 
452 // Numeric grouping field settings ============================================
453 
456 {
457  sal_uInt16 mnFlags;
458 
459  explicit XclPCNumGroupInfo();
460 
461  void SetNumType();
462 
463  sal_Int32 GetScDateType() const;
464  void SetScDateType( sal_Int32 nScType );
465 
466  sal_uInt16 GetXclDataType() const;
467  void SetXclDataType( sal_uInt16 nXclType );
468 };
469 
471 XclExpStream& operator<<( XclExpStream& rStrm, const XclPCNumGroupInfo& rInfo );
472 
473 // Base class for pivot cache fields ==========================================
474 
477 {
478 public:
479  explicit XclPCField( XclPCFieldType eFieldType, sal_uInt16 nFieldIdx );
480  virtual ~XclPCField();
481 
483  sal_uInt16 GetFieldIndex() const { return mnFieldIdx; }
484 
486  bool IsSupportedField() const;
487 
489  bool IsStandardField() const;
490 
492  bool IsStdGroupField() const;
494  bool IsNumGroupField() const;
496  bool IsDateGroupField() const;
498  bool IsGroupField() const;
499 
501  bool IsGroupBaseField() const;
503  bool IsGroupChildField() const;
504 
506  bool HasOrigItems() const;
508  bool HasInlineItems() const;
510  bool HasPostponedItems() const;
512  bool Has16BitIndexes() const;
513 
514 protected:
517  sal_uInt16 mnFieldIdx;
520 };
521 
522 // Pivot cache settings =======================================================
523 
525 struct XclPCInfo
526 {
527  sal_uInt32 mnSrcRecs;
528  sal_uInt16 mnStrmId;
529  sal_uInt16 mnFlags;
530  sal_uInt16 mnBlockRecs;
531  sal_uInt16 mnStdFields;
532  sal_uInt16 mnTotalFields;
533  sal_uInt16 mnSrcType;
534  OUString maUserName;
535 
536  explicit XclPCInfo();
537 };
538 
539 XclImpStream& operator>>( XclImpStream& rStrm, XclPCInfo& rInfo );
540 XclExpStream& operator<<( XclExpStream& rStrm, const XclPCInfo& rInfo );
541 
542 // Pivot table
543 
544 // cached name ================================================================
545 
548 {
549  OUString maName;
550  bool mbUseCache;
551 
552  explicit XclPTCachedName() : mbUseCache( true ) {}
553 };
554 
555 XclImpStream& operator>>( XclImpStream& rStrm, XclPTCachedName& rCachedName );
556 XclExpStream& operator<<( XclExpStream& rStrm, const XclPTCachedName& rCachedName );
557 
560 {
562 
564  bool HasVisName() const { return !maVisName.mbUseCache; }
566  const OUString* GetVisName() const;
568  void SetVisName( const OUString& rName );
569 };
570 
571 // Field item settings ========================================================
572 
575 {
576  sal_uInt16 mnType;
577  sal_uInt16 mnFlags;
578  sal_uInt16 mnCacheIdx;
579 
580  explicit XclPTItemInfo();
581 };
582 
584 XclExpStream& operator<<( XclExpStream& rStrm, const XclPTItemInfo& rInfo );
585 
586 // General field settings =====================================================
587 
588 typedef ::std::vector< ScGeneralFunction > XclPTSubtotalVec;
589 
592 {
593  sal_uInt16 mnAxes;
594  sal_uInt16 mnSubtCount;
595  sal_uInt16 mnSubtotals;
596  sal_uInt16 mnItemCount;
597  sal_uInt16 mnCacheIdx;
598 
599  explicit XclPTFieldInfo();
600 
604  css::sheet::DataPilotFieldOrientation GetApiOrient( sal_uInt16 nMask ) const;
606  void AddApiOrient( css::sheet::DataPilotFieldOrientation eOrient );
607 
609  void GetSubtotals( XclPTSubtotalVec& rSubtotals ) const;
611  void SetSubtotals( const XclPTSubtotalVec& rSubtotals );
612 };
613 
615 XclExpStream& operator<<( XclExpStream& rStrm, const XclPTFieldInfo& rInfo );
616 
617 // Extended field settings ====================================================
618 
621 {
622  sal_uInt32 mnFlags;
623  sal_uInt16 mnSortField;
624  sal_uInt16 mnShowField;
625  sal_uInt16 mnNumFmt;
626  std::optional<OUString> mpFieldTotalName;
627 
628  explicit XclPTFieldExtInfo();
629 
631  sal_Int32 GetApiSortMode() const;
633  void SetApiSortMode( sal_Int32 nSortMode );
634 
636  sal_Int32 GetApiAutoShowMode() const;
638  void SetApiAutoShowMode( sal_Int32 nShowMode );
639 
641  sal_Int32 GetApiAutoShowCount() const;
643  void SetApiAutoShowCount( sal_Int32 nShowCount );
644 
646  sal_Int32 GetApiLayoutMode() const;
648  void SetApiLayoutMode( sal_Int32 nLayoutMode );
649 };
650 
652 XclExpStream& operator<<( XclExpStream& rStrm, const XclPTFieldExtInfo& rInfo );
653 
654 // Page field settings ========================================================
655 
658 {
659  sal_uInt16 mnField;
660  sal_uInt16 mnSelItem;
661  sal_uInt16 mnObjId;
662 
663  explicit XclPTPageFieldInfo();
664 };
665 
667 XclExpStream& operator<<( XclExpStream& rStrm, const XclPTPageFieldInfo& rInfo );
668 
669 // Data field settings ========================================================
670 
673 {
674  sal_uInt16 mnField;
675  sal_uInt16 mnAggFunc;
676  sal_uInt16 mnRefType;
677  sal_uInt16 mnRefField;
678  sal_uInt16 mnRefItem;
679  sal_uInt16 mnNumFmt;
680 
681  explicit XclPTDataFieldInfo();
682 
686  void SetApiAggFunc( ScGeneralFunction eAggFunc );
687 
689  sal_Int32 GetApiRefType() const;
691  void SetApiRefType( sal_Int32 nRefType );
692 
694  sal_Int32 GetApiRefItemType() const;
696  void SetApiRefItemType( sal_Int32 nRefItemType );
697 };
698 
700 XclExpStream& operator<<( XclExpStream& rStrm, const XclPTDataFieldInfo& rInfo );
701 
702 // Pivot table settings =======================================================
703 
705 struct XclPTInfo
706 {
707  OUString maTableName;
708  OUString maDataName;
711  sal_uInt16 mnFirstHeadRow;
712  sal_uInt16 mnCacheIdx;
713  sal_uInt16 mnDataAxis;
714  sal_uInt16 mnDataPos;
715  sal_uInt16 mnFields;
716  sal_uInt16 mnRowFields;
717  sal_uInt16 mnColFields;
718  sal_uInt16 mnPageFields;
719  sal_uInt16 mnDataFields;
720  sal_uInt16 mnDataRows;
721  sal_uInt16 mnDataCols;
722  sal_uInt16 mnFlags;
723  sal_uInt16 mnAutoFmtIdx;
724 
725  explicit XclPTInfo();
726 };
727 
728 XclImpStream& operator>>( XclImpStream& rStrm, XclPTInfo& rInfo );
729 XclExpStream& operator<<( XclExpStream& rStrm, const XclPTInfo& rInfo );
730 
731 // Extended pivot table settings ==============================================
732 
735 {
736  sal_uInt16 mnSxformulaRecs;
737  sal_uInt16 mnSxselectRecs;
738  sal_uInt16 mnPagePerRow;
739  sal_uInt16 mnPagePerCol;
740  sal_uInt32 mnFlags;
741 
742  explicit XclPTExtInfo();
743 };
744 
746 XclExpStream& operator<<( XclExpStream& rStrm, const XclPTExtInfo& rInfo );
747 
748 // Pivot table autoformat settings ==============================================
749 
752 {
753  sal_uInt32 mbReport;
757 
758  explicit XclPTViewEx9Info();
759  void Init( const ScDPObject& rDPObj );
760 };
761 
763 XclExpStream& operator<<( XclExpStream& rStrm, const XclPTViewEx9Info& rInfo );
764 
766 struct XclPTAddl
767 {
769  explicit XclPTAddl();
770 };
771 
773 
774 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
const sal_uInt16 EXC_PC_NOFIELD
Definition: xlpivot.hxx:46
sal_uInt32 mnFlags
Definition: xlpivot.hxx:622
const sal_uInt16 EXC_SXDI_REF_RUN_TOTAL
Definition: xlpivot.hxx:193
XclPCItemType meType
Definition: xlpivot.hxx:417
sal_uInt16 mnRefItem
Index to SXVD of referred field used for the results.
Definition: xlpivot.hxx:678
void SetApiLayoutMode(sal_Int32 nLayoutMode)
Sets the layout mode represented by the passed API constant.
Definition: xlpivot.cxx:625
const sal_uInt32 EXC_SXVDEX_SORT
Definition: xlpivot.hxx:333
bool IsStdGroupField() const
Returns true, if this field is a grouping field.
Definition: xlpivot.cxx:303
XclPTInfo()
Index to pivot table autoformat.
Definition: xlpivot.cxx:834
const sal_uInt16 EXC_SXVDEX_FORMAT_NONE
Definition: xlpivot.hxx:344
const sal_uInt16 EXC_ID_SXPI
Definition: xlpivot.hxx:171
const sal_uInt16 EXC_SXFIELD_16BIT
Definition: xlpivot.hxx:228
sal_uInt16 mnRefType
Data aggregation function.
Definition: xlpivot.hxx:676
sal_uInt16 mnFlags
Type of the item (e.g. data, function, grand total).
Definition: xlpivot.hxx:577
const sal_uInt32 EXC_SXVDEX_LAYOUT_BLANK
Definition: xlpivot.hxx:338
A name for various pivot table info structs.
Definition: xlpivot.hxx:547
const sal_uInt16 EXC_SXDI_FUNC_STDDEVP
Definition: xlpivot.hxx:185
const size_t EXC_PC_MAXFIELDCOUNT
Definition: xlpivot.hxx:45
XclPTFieldInfo()
Index into cache for field name (not part of record).
Definition: xlpivot.cxx:460
bool IsGroupField() const
Returns true, if this field is a grouping field of any type.
Definition: xlpivot.cxx:318
const sal_uInt16 EXC_SXFIELD_DATA_DBL
Only integers, opt. with doubles.
Definition: xlpivot.hxx:235
const sal_uInt16 EXC_ID_00F5
Definition: xlpivot.hxx:318
XclPCInfo()
Name of user who last modified the cache.
Definition: xlpivot.cxx:356
void SetApiAggFunc(ScGeneralFunction eAggFunc)
Sets the aggregation function represented by the passed API enum.
Definition: xlpivot.cxx:731
const double * GetDouble() const
Returns pointer to value, if the item type is 'double', otherwise 0.
Definition: xlpivot.cxx:140
const sal_uInt16 EXC_SXFIELD_DATA_NONE
Definition: xlpivot.hxx:232
const OUString * GetVisName() const
Returns the name, if set explicitly (maVisName.mbUseCache is false).
Definition: xlpivot.cxx:420
Pivot table autoformat settings (SXVIEWEX9 record).
Definition: xlpivot.hxx:751
const sal_uInt16 EXC_ID_SXIVD
Definition: xlpivot.hxx:163
const sal_uInt16 EXC_PT_AUTOFMT_ZERO
Definition: xlpivot.hxx:63
void SetScDateType(sal_Int32 nScType)
Definition: xlpivot.cxx:242
const sal_uInt16 EXC_SXVS_EXTERN
Definition: xlpivot.hxx:300
const sal_uInt16 EXC_SXNUMGROUP_TYPE_QUART
Definition: xlpivot.hxx:285
const sal_uInt16 EXC_SXDI_FUNC_STDDEV
Definition: xlpivot.hxx:184
const sal_uInt16 EXC_SXVIEW_DEFAULTFLAGS
Definition: xlpivot.hxx:102
std::optional< OUString > mpFieldTotalName
Definition: xlpivot.hxx:626
const sal_uInt16 EXC_SXDB_SRC_EXTERN
Definition: xlpivot.hxx:216
const sal_uInt16 EXC_SXNUMGROUP_TYPE_MIN
Definition: xlpivot.hxx:281
This class is used to export Excel record streams.
Definition: xestream.hxx:72
sal_uInt16 mnSrcType
Number of all fields (standard, grouped, calculated).
Definition: xlpivot.hxx:533
const sal_uInt32 EXC_SXVDEX_AUTOSHOW
Definition: xlpivot.hxx:335
XclPTViewEx9Info()
classic : 10 08 00 00 00 00 00 00 20 00 00 00 01 00 00 00 00 default : 10 08 00 00 00 00 00 00 20 00 ...
Definition: xlpivot.cxx:969
XclPCFieldType
Specifies the type of a pivot cache field.
Definition: xlpivot.hxx:80
void SetError(sal_uInt16 nError)
Sets the item to 'error' type and adds the passed Excel error code.
Definition: xlpivot.cxx:88
bool mbUseCache
The visible name, if used.
Definition: xlpivot.hxx:550
const sal_uInt16 EXC_ID_SXVS
Definition: xlpivot.hxx:296
const sal_uInt16 EXC_SXDB_BG_QUERY
Definition: xlpivot.hxx:209
sal_uInt16 mnAggFunc
Base field for this data info.
Definition: xlpivot.hxx:675
sal_uInt16 mnCacheIdx
Number of items of this field.
Definition: xlpivot.hxx:597
sal_uInt16 mnRefField
Result reference type.
Definition: xlpivot.hxx:677
const sal_uInt16 EXC_SXPI_ALLITEMS
Definition: xlpivot.hxx:172
Extended information about a pivot table (SXEX record).
Definition: xlpivot.hxx:734
const sal_uInt16 EXC_SXDI_PREVITEM
Definition: xlpivot.hxx:199
const sal_uInt16 EXC_SXVI_HIDDEN
Definition: xlpivot.hxx:155
const sal_uInt16 EXC_SXVI_TYPE_STDDEVP
Definition: xlpivot.hxx:149
sal_Int32 GetApiLayoutMode() const
Returns the API constant representing the layout mode.
Definition: xlpivot.cxx:616
const sal_uInt16 EXC_SXNUMGROUP_TYPE_YEAR
Definition: xlpivot.hxx:286
void SetDateTime(const DateTime &rDateTime, const OUString &rText=OUString())
Sets the item to 'date/time' type and adds the passed date.
Definition: xlpivot.cxx:74
Contains data for a pivot cache field (SXFIELD record).
Definition: xlpivot.hxx:435
sal_uInt8 mnAutoFormat
2 for report* fmts ?
Definition: xlpivot.hxx:754
const sal_uInt32 EXC_SXVDEX_LAYOUT_TOP
Definition: xlpivot.hxx:339
const bool * GetBool() const
Returns pointer to Boolean value, if the item type is 'boolean', otherwise 0.
Definition: xlpivot.cxx:160
bool operator==(const XclPCItem &rLeft, const XclPCItem &rRight)
Definition: xlpivot.hxx:429
sal_Int16 mnValue
Value of a floating-point item.
Definition: xlpivot.hxx:423
const sal_uInt16 EXC_SXVI_DEFAULTFLAGS
Definition: xlpivot.hxx:154
sal_uInt16 mnColFields
Number of row fields.
Definition: xlpivot.hxx:717
XclPCItem()
Definition: xlpivot.cxx:45
void SetApiRefItemType(sal_Int32 nRefItemType)
Sets the result reference item type represented by the passed API constant.
Definition: xlpivot.cxx:798
XclPCItem & operator=(XclPCItem const &)=default
const sal_uInt16 EXC_SXVD_AXIS_ROWCOLPAGE
Definition: xlpivot.hxx:116
const sal_uInt16 EXC_SXFIELD_DATA_DATE
Only strings and doubles, nothing else.
Definition: xlpivot.hxx:238
sal_uInt16 mnFieldIdx
Type of this pivot cache field.
Definition: xlpivot.hxx:517
const sal_uInt16 EXC_ID_SXRULE
Definition: xlpivot.hxx:306
XclImpStream & operator>>(XclImpStream &rStrm, XclPCFieldInfo &rInfo)
Definition: xlpivot.cxx:183
sal_uInt16 mnCacheIdx
Several flags.
Definition: xlpivot.hxx:578
const sal_uInt16 EXC_SXFIELD_DATA_DATE_EMP
Only dates, nothing else.
Definition: xlpivot.hxx:239
virtual ~XclPCItem()
Definition: xlpivot.cxx:51
sal_uInt16 mnGroupItems
Number of visible items for this field.
Definition: xlpivot.hxx:442
Numeric grouping field.
Definition: xlpivot.hxx:85
void SetText(const OUString &rText)
Sets the item to 'text' type and adds the passed text.
Definition: xlpivot.cxx:61
void GetSubtotals(XclPTSubtotalVec &rSubtotals) const
Returns a vector of all set subtotal functions.
Definition: xlpivot.cxx:499
const sal_uInt16 EXC_SXVD_AXIS_COL
Definition: xlpivot.hxx:112
DateTime maDateTime
Text representation of the item.
Definition: xlpivot.hxx:419
XclAddress maDataXclPos
Output range.
Definition: xlpivot.hxx:710
const sal_uInt16 EXC_PT_NOSTRING
Definition: xlpivot.hxx:41
Standard field without grouping.
Definition: xlpivot.hxx:83
void SetSubtotals(const XclPTSubtotalVec &rSubtotals)
Sets the subtotal functions contained in the passed sequence.
Definition: xlpivot.cxx:518
const sal_uInt16 EXC_SXVDEX_SHOW_NONE
Definition: xlpivot.hxx:343
const sal_uInt16 EXC_ID_SXINDEXLIST
List index for step item in groupings.
Definition: xlpivot.hxx:248
sal_uInt16 mnGroupChild
Various flags.
Definition: xlpivot.hxx:439
const sal_uInt16 EXC_SXDI_REF_PERC_TOTAL
Definition: xlpivot.hxx:196
const sal_uInt16 EXC_SXDI_REF_PERC_DIFF
Definition: xlpivot.hxx:192
Represents a field in a pivot cache.
Definition: xlpivot.hxx:476
const sal_uInt16 EXC_ID_DCONNAME
Definition: xlpivot.hxx:94
void SetBool(bool bValue, const OUString &rText=OUString())
Sets the item to 'boolean' type and adds the passed Boolean value.
Definition: xlpivot.cxx:106
void Init(const ScDPObject &rDPObj)
Definition: xlpivot.cxx:976
void SetApiSortMode(sal_Int32 nSortMode)
Sets the sorting mode represented by the passed API constant.
Definition: xlpivot.cxx:587
sal_uInt16 mnFlags
Number of columns containing data.
Definition: xlpivot.hxx:722
sal_uInt16 mnVisItems
Base field if this field contains grouping info.
Definition: xlpivot.hxx:441
const sal_uInt16 EXC_SXVI_TYPE_DATA
Definition: xlpivot.hxx:139
sal_Int32 GetApiSortMode() const
Returns the API constant representing the sorting mode.
Definition: xlpivot.cxx:579
const sal_uInt16 EXC_SXVD_SUBT_COUNTNUM
Definition: xlpivot.hxx:126
const sal_uInt16 EXC_ID_SXLI
Definition: xlpivot.hxx:167
const sal_uInt16 EXC_SXVD_SUBT_STDDEV
Definition: xlpivot.hxx:127
const sal_uInt16 EXC_SXVD_SUBT_DEFAULT
Definition: xlpivot.hxx:119
sal_uInt32 mbReport
Definition: xlpivot.hxx:753
const sal_uInt16 EXC_SXVI_HIDEDETAIL
Definition: xlpivot.hxx:156
XclPTDataFieldInfo()
Number format of the results.
Definition: xlpivot.cxx:700
ScGeneralFunction GetApiAggFunc() const
Returns the API enum representing the aggregation function.
Definition: xlpivot.cxx:710
Base struct for named info structs.
Definition: xlpivot.hxx:559
sal_uInt16 mnFields
Position of data fields.
Definition: xlpivot.hxx:715
const sal_uInt16 EXC_ID_SXGROUPINFO
Definition: xlpivot.hxx:290
Special state, not used in Excel files.
Definition: xlpivot.hxx:70
ScfUInt16Vec maGroupOrder
Own field index in pivot cache.
Definition: xlpivot.hxx:518
const sal_uInt16 EXC_SXFIELD_INDEX_STEP
List index for maximum item in groupings.
Definition: xlpivot.hxx:245
const sal_uInt16 EXC_SXDI_FUNC_MIN
Definition: xlpivot.hxx:181
const sal_uInt16 EXC_SXDI_FUNC_VAR
Definition: xlpivot.hxx:186
const sal_uInt16 EXC_PT_MAXDATACOUNT
Definition: xlpivot.hxx:57
Contains data for a numeric grouping field (SXNUMGROUP record).
Definition: xlpivot.hxx:455
const sal_uInt16 EXC_SXVI_TYPE_VARP
Definition: xlpivot.hxx:151
const sal_uInt16 EXC_SXVS_SHEET
Definition: xlpivot.hxx:299
sal_uInt16 mnSubtCount
Flags for axes this field is part of.
Definition: xlpivot.hxx:594
const sal_uInt32 EXC_PT_AUTOFMT_FLAGS
Definition: xlpivot.hxx:64
const sal_uInt16 EXC_PT_MAXITEMCOUNT
Definition: xlpivot.hxx:60
const sal_uInt16 EXC_SXDB_DEFAULTFLAGS
Definition: xlpivot.hxx:211
sal_uInt16 mnStdFields
Records in a source database block.
Definition: xlpivot.hxx:531
const sal_uInt16 EXC_SXVI_TYPE_DEFAULT
Definition: xlpivot.hxx:140
Contains extended data for a pivot table field (SXVDEX record).
Definition: xlpivot.hxx:620
sal_uInt16 mnDataRows
Number of data fields.
Definition: xlpivot.hxx:720
const sal_uInt16 EXC_SXVS_CONSOLID
Definition: xlpivot.hxx:301
const sal_uInt16 EXC_SXVI_TYPE_PAGE
Definition: xlpivot.hxx:137
const sal_uInt16 EXC_SXVD_AXIS_DATA
Definition: xlpivot.hxx:114
const sal_uInt16 EXC_SXFIELD_INDEX_MAX
List index for minimum item in groupings.
Definition: xlpivot.hxx:244
void AddApiOrient(css::sheet::DataPilotFieldOrientation eOrient)
Adds the axis orientation represented by the passed API enum.
Definition: xlpivot.cxx:485
sal_uInt16 mnDataFields
Number of page fields.
Definition: xlpivot.hxx:719
const sal_uInt16 EXC_PC_NOITEM
Definition: xlpivot.hxx:51
const sal_uInt16 EXC_SXNUMGROUP_TYPE_HOUR
Definition: xlpivot.hxx:282
const sal_uInt16 EXC_SXNUMGROUP_TYPE_DAY
Definition: xlpivot.hxx:283
String data.
Definition: xlpivot.hxx:72
const sal_uInt16 EXC_ID_SXNAME
Unknown record.
Definition: xlpivot.hxx:321
16-bit integer value.
Definition: xlpivot.hxx:75
const sal_uInt32 EXC_SXVDEX_LAYOUT_REPORT
Definition: xlpivot.hxx:337
const sal_uInt16 EXC_SXNUMGROUP_AUTOMAX
Definition: xlpivot.hxx:278
sal_uInt16 mnCacheIdx
First heading row.
Definition: xlpivot.hxx:712
sal_uInt16 mnShowField
Index to data field sorting bases on.
Definition: xlpivot.hxx:624
sal_Int32 GetScDateType() const
Definition: xlpivot.cxx:225
const sal_uInt16 EXC_ID_SXEXT
Definition: xlpivot.hxx:293
sal_uInt16 mnGroupBase
Field containing grouping info for this field.
Definition: xlpivot.hxx:440
const sal_uInt32 EXC_SXEX_DRILLDOWN
Definition: xlpivot.hxx:311
OUString maGrandTotalName
0 == gridlayout, 0x10 == modern
Definition: xlpivot.hxx:756
const sal_uInt16 EXC_SXVD_SUBT_NONE
Definition: xlpivot.hxx:118
Contains data for a pivot table page field (part of SXPI record).
Definition: xlpivot.hxx:657
Standard grouping field.
Definition: xlpivot.hxx:84
void SetInteger(sal_Int16 nValue)
Sets the item to 'integer' type and adds the passed value.
Definition: xlpivot.cxx:81
sal_uInt16 mnNumFmt
Index to SXVI of referred item of the used field.
Definition: xlpivot.hxx:679
First date grouping field (opt. with child grouping field).
Definition: xlpivot.hxx:86
const sal_uInt16 EXC_SXDI_NEXTITEM
Definition: xlpivot.hxx:200
sal_uInt16 mnField
Definition: xlpivot.hxx:659
XclPTCachedName maVisName
Definition: xlpivot.hxx:561
::std::vector< ScGeneralFunction > XclPTSubtotalVec
Definition: xlpivot.hxx:588
const sal_uInt16 EXC_SXNUMGROUP_TYPE_NUM
Definition: xlpivot.hxx:287
const sal_uInt16 EXC_SXVD_SUBT_MIN
Definition: xlpivot.hxx:124
const DateTime * GetDateTime() const
Returns pointer to date, if the item type is 'date/time', otherwise 0.
Definition: xlpivot.cxx:145
sal_uInt16 mnStrmId
Records in source database.
Definition: xlpivot.hxx:528
const sal_uInt16 EXC_SXDI_REF_INDEX
Definition: xlpivot.hxx:197
const OUString * GetText() const
Returns pointer to text, if the item type is 'text', otherwise 0.
Definition: xlpivot.cxx:135
sal_uInt16 mnPagePerRow
Number of SXSELECT records.
Definition: xlpivot.hxx:738
const sal_uInt16 EXC_ID_SXSTRING
Definition: xlpivot.hxx:263
const sal_uInt16 EXC_ID_SXDATETIME
Definition: xlpivot.hxx:266
Floating-point value.
Definition: xlpivot.hxx:73
Contains data for a pivot table field (SXVD record).
Definition: xlpivot.hxx:591
const sal_uInt16 EXC_SXVD_SUBT_SUM
Definition: xlpivot.hxx:120
const size_t EXC_PC_MAXITEMCOUNT
Definition: xlpivot.hxx:50
sal_uInt16 mnFlags
Definition: xlpivot.hxx:457
void SetXclDataType(sal_uInt16 nXclType)
Definition: xlpivot.cxx:265
const sal_uInt16 EXC_SXFIELD_NUMGROUP
Definition: xlpivot.hxx:227
const sal_uInt16 EXC_SXVIEW_DATALAST
Definition: xlpivot.hxx:104
const sal_uInt16 EXC_SXFDBTYPE_DEFAULT
Definition: xlpivot.hxx:355
const sal_uInt16 EXC_SXDI_FUNC_COUNTNUM
Definition: xlpivot.hxx:183
const sal_uInt16 EXC_SXDB_SRC_SCENARIO
Definition: xlpivot.hxx:218
const sal_uInt32 EXC_SXEX_DEFAULTFLAGS
Definition: xlpivot.hxx:312
const sal_uInt16 EXC_SXDI_REF_NORMAL
Definition: xlpivot.hxx:189
sal_uInt16 mnOrigItems
Number of items in the base field.
Definition: xlpivot.hxx:444
const sal_uInt16 EXC_SXDB_REFRESH_LOAD
Definition: xlpivot.hxx:207
const sal_uInt16 EXC_SXFIELD_HASCHILD
Definition: xlpivot.hxx:226
sal_uInt16 mnFlags
Stream identifier.
Definition: xlpivot.hxx:529
void SetApiAutoShowCount(sal_Int32 nShowCount)
Sets the number of items to be shown in AutoShow mode.
Definition: xlpivot.cxx:611
const sal_uInt16 EXC_SXVDEX_SORT_OWN
Definition: xlpivot.hxx:342
bool HasVisName() const
The displayed name of the item.
Definition: xlpivot.hxx:564
const sal_uInt16 EXC_SXFIELD_HASITEMS
Definition: xlpivot.hxx:223
const sal_uInt16 EXC_SXDI_FUNC_COUNT
Definition: xlpivot.hxx:178
sal_uInt32 mnSrcRecs
Definition: xlpivot.hxx:527
Additional date grouping field.
Definition: xlpivot.hxx:87
const sal_uInt16 EXC_ID_SXFMLA
Definition: xlpivot.hxx:327
const sal_uInt16 EXC_SXFIELD_CALCED
Definition: xlpivot.hxx:225
sal_uInt16 mnBlockRecs
Flags for the cache.
Definition: xlpivot.hxx:530
const sal_uInt16 EXC_SXDB_SAVEDATA
Definition: xlpivot.hxx:205
const sal_uInt16 EXC_ID_SXVI
Definition: xlpivot.hxx:135
bool IsEmpty() const
Returns true, if the item type is 'empty'.
Definition: xlpivot.cxx:130
const double EXC_SXDBEX_CREATION_DATE
Definition: xlpivot.hxx:351
const sal_uInt16 EXC_SXVI_TYPE_GRAND
Definition: xlpivot.hxx:152
const sal_uInt16 EXC_SXNUMGROUP_AUTOMIN
Definition: xlpivot.hxx:277
sal_uInt16 GetXclDataType() const
Definition: xlpivot.cxx:260
const sal_uInt16 EXC_SXDI_FUNC_MAX
Definition: xlpivot.hxx:180
const sal_uInt16 EXC_SXVIEW_COLGRAND
Definition: xlpivot.hxx:101
const sal_uInt16 EXC_ID_SXDOUBLE
Definition: xlpivot.hxx:251
sal_uInt16 mnSubtotals
Number of subtotal functions.
Definition: xlpivot.hxx:595
const sal_uInt16 EXC_ID_SXINTEGER
Definition: xlpivot.hxx:260
sal_uInt16 mnDataCols
Number of rows containing data.
Definition: xlpivot.hxx:721
const sal_uInt16 EXC_SXNUMGROUP_TYPE_MONTH
Definition: xlpivot.hxx:284
XclPCField(XclPCFieldType eFieldType, sal_uInt16 nFieldIdx)
Definition: xlpivot.cxx:283
const sal_uInt16 EXC_SXVD_SUBT_VAR
Definition: xlpivot.hxx:129
sal_uInt16 mnSelItem
Base field for this page info.
Definition: xlpivot.hxx:660
const sal_uInt16 EXC_ID_SXEMPTY
Definition: xlpivot.hxx:269
sal_uInt16 mnRowFields
Number of all fields.
Definition: xlpivot.hxx:716
sal_uInt16 mnPageFields
Number of column fields.
Definition: xlpivot.hxx:718
Contains data for a pivot table data item (SXVI record).
Definition: xlpivot.hxx:574
Calculated field.
Definition: xlpivot.hxx:88
sal_uInt16 mnSortField
Several flags and number of items for AutoShow.
Definition: xlpivot.hxx:623
const sal_uInt16 EXC_SXFIELD_DATA_DATE_STR
Dates with integers or doubles without strings.
Definition: xlpivot.hxx:241
const sal_uInt16 EXC_ID_SXDB
Definition: xlpivot.hxx:203
sal_uInt16 mnType
Definition: xlpivot.hxx:576
const sal_uInt16 EXC_ID_SXDBEX
Definition: xlpivot.hxx:350
void SetEmpty()
Sets the item to 'empty' type.
Definition: xlpivot.cxx:55
const sal_uInt16 EXC_SXVD_SUBT_AVERAGE
Definition: xlpivot.hxx:122
const sal_Int16 * GetInteger() const
Returns pointer to integer, if the item type is 'integer', otherwise 0.
Definition: xlpivot.cxx:150
sal_uInt16 mnDataPos
Orientation of data fields.
Definition: xlpivot.hxx:714
const sal_uInt16 EXC_SXDI_REF_PERC_ROW
Definition: xlpivot.hxx:194
const sal_uInt16 EXC_SXDI_FUNC_PRODUCT
Definition: xlpivot.hxx:182
const sal_uInt16 EXC_ID_SXIDSTM
Definition: xlpivot.hxx:272
sal_Int32 GetApiRefItemType() const
Returns the API constant representing the result reference item type.
Definition: xlpivot.cxx:786
const sal_uInt16 EXC_SXVD_AXIS_ROWCOL
Definition: xlpivot.hxx:115
Contains data for a pivot table data field (SXDI record).
Definition: xlpivot.hxx:672
XclPCItemType
Data type of a pivot cache item.
Definition: xlpivot.hxx:67
A 2D cell address struct with Excel column and row indexes.
Definition: xladdress.hxx:29
XclPTPageFieldInfo()
Escher object ID of dropdown listbox.
Definition: xlpivot.cxx:675
bool mbCompactMode
Definition: xlpivot.hxx:768
const sal_uInt32 EXC_SXVDEX_AUTOSHOW_ASC
Definition: xlpivot.hxx:336
XclPCItemType GetType() const
Returns the type of the item.
Definition: xlpivot.cxx:165
const sal_uInt16 EXC_SXFIELD_DATA_INT
Only strings, nothing else.
Definition: xlpivot.hxx:234
const sal_uInt16 EXC_ID_SXFORMULA
Definition: xlpivot.hxx:347
bool IsGroupChildField() const
Returns true, if this field is a child field in a grouping (it has a base field). ...
Definition: xlpivot.cxx:328
Empty cell.
Definition: xlpivot.hxx:71
const sal_uInt16 EXC_SXDI_FUNC_AVERAGE
Definition: xlpivot.hxx:179
const sal_uInt32 EXC_SXVDEX_SORT_ASC
Definition: xlpivot.hxx:334
const sal_uInt16 EXC_SXVI_TYPE_STDDEV
Definition: xlpivot.hxx:148
XclPCNumGroupInfo()
Various flags.
Definition: xlpivot.cxx:214
sal_uInt16 GetFieldIndex() const
Returns the index of this field in the containing pivot cache.
Definition: xlpivot.hxx:483
const sal_uInt16 EXC_SXVD_AXIS_PAGE
Definition: xlpivot.hxx:113
XclPTExtInfo()
Flags for the entire pivot table.
Definition: xlpivot.cxx:905
XclRange maOutXclRange
The visible name of the data field.
Definition: xlpivot.hxx:709
OUString maName
Definition: xlpivot.hxx:549
const sal_uInt16 EXC_ID_DCONREF
Definition: xlpivot.hxx:93
bool IsStandardField() const
Returns true, if this is a standard field build directly from source data.
Definition: xlpivot.cxx:298
const sal_uInt16 EXC_SXVS_PIVOTTAB
Definition: xlpivot.hxx:302
const sal_uInt16 EXC_SXVD_DEFAULT_CACHE
Definition: xlpivot.hxx:132
const sal_uInt16 EXC_SXVI_TYPE_SUM
Definition: xlpivot.hxx:141
Boolean value.
Definition: xlpivot.hxx:76
bool Has16BitIndexes() const
Returns true, if the item indexes in the SXINDEXLIST record are stored as 16-bit values.
Definition: xlpivot.cxx:348
sal_uInt16 mnTotalFields
Number of standard pivot cache fields.
Definition: xlpivot.hxx:532
const sal_uInt16 EXC_SXDB_SRC_CONSOLID
Definition: xlpivot.hxx:217
XclPTCachedName()
true = Use name in cache instead of maName.
Definition: xlpivot.hxx:552
bool IsGroupBaseField() const
Returns true, if this field has a child field in a grouping.
Definition: xlpivot.cxx:323
XclPCFieldInfo maFieldInfo
Definition: xlpivot.hxx:515
const sal_uInt16 EXC_ID_SXDI
Definition: xlpivot.hxx:175
const sal_uInt16 EXC_ID_SXVD
Definition: xlpivot.hxx:108
const sal_uInt16 EXC_SXVI_TYPE_PROD
Definition: xlpivot.hxx:146
sal_uInt16 mnPagePerCol
Number of page fields per row.
Definition: xlpivot.hxx:739
const sal_uInt16 EXC_SXFIELD_DATA_STR_INT
Only doubles, nothing else.
Definition: xlpivot.hxx:236
const sal_uInt16 EXC_ID_SXVIEW
Definition: xlpivot.hxx:98
virtual ~XclPCField()
Definition: xlpivot.cxx:289
const sal_uInt16 EXC_SXVD_SUBT_STDDEVP
Definition: xlpivot.hxx:128
OUString maDataName
The name of the pivot table.
Definition: xlpivot.hxx:708
const sal_uInt16 EXC_SXDI_FUNC_SUM
Definition: xlpivot.hxx:177
const sal_uInt32 EXC_SXVDEX_DEFAULTFLAGS
Definition: xlpivot.hxx:340
const sal_uInt16 EXC_SXDI_REF_DIFF
Definition: xlpivot.hxx:190
::std::vector< sal_uInt16 > ScfUInt16Vec
Definition: ftools.hxx:255
const sal_uInt16 EXC_ID_SXBOOLEAN
Definition: xlpivot.hxx:254
const sal_uInt16 EXC_SXVI_TYPE_NULL
Definition: xlpivot.hxx:138
sal_uInt16 mnSxformulaRecs
Definition: xlpivot.hxx:736
Contains data for a pivot cache (SXDB record).
Definition: xlpivot.hxx:525
const sal_uInt16 * GetError() const
Returns pointer to error code, if the item type is 'error', otherwise 0.
Definition: xlpivot.cxx:155
const sal_uInt16 EXC_PT_MAXFIELDCOUNT
Definition: xlpivot.hxx:54
unsigned char sal_uInt8
const sal_uInt16 EXC_SXFIELD_DATA_STR_DBL
Only strings and integers, opt. with doubles.
Definition: xlpivot.hxx:237
XclExpStream & operator<<(XclExpStream &rStrm, const XclPCFieldInfo &rInfo)
Definition: xlpivot.cxx:199
const sal_uInt16 EXC_SXIVD_DATA
Definition: xlpivot.hxx:164
ScGeneralFunction
the css::sheet::GeneralFunction enum is extended by constants in GeneralFunction2, which causes some type-safety issues.
const sal_uInt16 EXC_SXVD_SUBT_MAX
Definition: xlpivot.hxx:123
const sal_uInt16 EXC_SXFIELD_POSTPONE
Definition: xlpivot.hxx:224
const sal_uInt16 EXC_SXVI_TYPE_COUNT
Definition: xlpivot.hxx:142
sal_Int32 GetApiRefType() const
Returns the API constant representing the result reference type.
Definition: xlpivot.cxx:750
const sal_uInt16 EXC_ID_SXFILT
Definition: xlpivot.hxx:315
Contains data for a pivot table (SXVIEW record).
Definition: xlpivot.hxx:705
const sal_uInt16 EXC_ID_SXPAIR
Definition: xlpivot.hxx:324
const OUString & ConvertToText() const
Returns the text representation of the item.
Definition: xlpivot.hxx:393
const sal_uInt16 EXC_PT_MAXROWCOLCOUNT
Definition: xlpivot.hxx:55
sal_uInt16 mnFlags
Name of the pivot cache field.
Definition: xlpivot.hxx:438
const sal_uInt16 EXC_PT_MAXSTRLEN
Definition: xlpivot.hxx:42
bool operator!=(const XclPCItem &rLeft, const XclPCItem &rRight)
Definition: xlpivot.hxx:430
Additional pivot table settings (SXADDL record).
Definition: xlpivot.hxx:766
const sal_uInt16 EXC_SXVS_UNKNOWN
Definition: xlpivot.hxx:298
OUString maText
Type of the item.
Definition: xlpivot.hxx:418
const sal_uInt16 EXC_SXVI_TYPE_VAR
Definition: xlpivot.hxx:150
const sal_uInt16 EXC_ID_SXEX
Definition: xlpivot.hxx:309
const sal_uInt16 EXC_SXVI_DEFAULT_CACHE
Definition: xlpivot.hxx:160
sal_uInt16 mnObjId
Index to selected item.
Definition: xlpivot.hxx:661
const sal_uInt16 EXC_ID_SXNUMGROUP
Definition: xlpivot.hxx:275
Date/time.
Definition: xlpivot.hxx:74
css::sheet::DataPilotFieldOrientation GetApiOrient(sal_uInt16 nMask) const
Returns the API enum representing the orientation (first of row/col/page/data).
Definition: xlpivot.cxx:469
sal_uInt16 mnError
Value of an integer item.
Definition: xlpivot.hxx:424
sal_uInt16 mnSxselectRecs
Number of SXFORMULA records.
Definition: xlpivot.hxx:737
const sal_uInt32 EXC_SXVDEX_SHOWALL
Definition: xlpivot.hxx:332
const sal_uInt16 EXC_SXVI_TYPE_MIN
Definition: xlpivot.hxx:145
void SetApiRefType(sal_Int32 nRefType)
Sets the result reference type represented by the passed API constant.
Definition: xlpivot.cxx:769
const sal_uInt16 EXC_ID_SXADDL
Definition: xlpivot.hxx:361
const sal_uInt16 EXC_ID_SXFDBTYPE
Definition: xlpivot.hxx:354
void SetVisName(const OUString &rName)
Sets the visible name and enables usage of cache if name is empty.
Definition: xlpivot.cxx:425
bool HasPostponedItems() const
Returns true, if the items are stored separately after the last field.
Definition: xlpivot.cxx:343
bool IsDateGroupField() const
Returns true, if this field is a date/time grouping field.
Definition: xlpivot.cxx:313
const sal_uInt16 EXC_SXFIELD_INDEX_MIN
Dates and strings, opt. with integers or doubles.
Definition: xlpivot.hxx:243
const sal_uInt16 EXC_SXVD_AXIS_NONE
Definition: xlpivot.hxx:110
void SetApiAutoShowMode(sal_Int32 nShowMode)
Sets the AutoShow mode represented by the passed API constant.
Definition: xlpivot.cxx:601
bool HasOrigItems() const
Returns true, if the field is based on a column in the source data area.
Definition: xlpivot.cxx:333
const sal_uInt16 EXC_ID_SXFIELD
Definition: xlpivot.hxx:221
sal_Int32 GetApiAutoShowCount() const
Returns the number of items to be shown in AutoShow mode.
Definition: xlpivot.cxx:606
bool HasInlineItems() const
Returns true, if any items are stored after the SXFIELD record.
Definition: xlpivot.cxx:338
const sal_uInt16 EXC_SXVI_TYPE_MAX
Definition: xlpivot.hxx:144
const sal_uInt16 EXC_SXDB_ENABLE_REFRESH
Definition: xlpivot.hxx:210
const sal_uInt16 EXC_SXDB_OPT_CACHE
Definition: xlpivot.hxx:208
XclPCNumGroupInfo maNumGroupInfo
Order of items in a grouping field (SXGROUPINFO record).
Definition: xlpivot.hxx:519
XclPCFieldInfo()
Number of original source data items.
Definition: xlpivot.cxx:172
bool mbValue
Error code of an error item.
Definition: xlpivot.hxx:425
const sal_uInt16 EXC_SXVD_AXIS_ROW
Definition: xlpivot.hxx:111
const sal_uInt16 EXC_SXDB_SRC_SHEET
Definition: xlpivot.hxx:215
const sal_uInt16 EXC_SXDB_INVALID
Definition: xlpivot.hxx:206
bool IsNumGroupField() const
Returns true, if this field is a numeric grouping field.
Definition: xlpivot.cxx:308
sal_uInt16 mnField
Definition: xlpivot.hxx:674
OUString maTableName
Definition: xlpivot.hxx:707
const sal_uInt16 EXC_PT_MAXPAGECOUNT
Definition: xlpivot.hxx:56
const sal_uInt16 EXC_SXVIEW_AUTOFMT
Definition: xlpivot.hxx:105
const sal_uInt16 EXC_SXVD_SUBT_VARP
Definition: xlpivot.hxx:130
const sal_uInt16 EXC_SXDI_REF_PERC_COL
Definition: xlpivot.hxx:195
bool IsEqual(const XclPCItem &rItem) const
Returns true, if the passed term equals this item.
Definition: xlpivot.cxx:113
const sal_uInt16 EXC_SXNUMGROUP_TYPE_SEC
Definition: xlpivot.hxx:280
This class is used to import record oriented streams.
Definition: xistream.hxx:277
const sal_uInt16 EXC_ID_SXVDEX
Definition: xlpivot.hxx:330
const sal_uInt16 EXC_SXVIEW_ROWGRAND
Definition: xlpivot.hxx:100
void SetDouble(double fValue, const OUString &rText=OUString())
Sets the item to 'double' type and adds the passed value.
Definition: xlpivot.cxx:67
sal_uInt16 mnBaseItems
Number of special items in a grouping field.
Definition: xlpivot.hxx:443
const sal_uInt16 EXC_ID_SXERROR
Definition: xlpivot.hxx:257
const sal_uInt16 EXC_SXFIELD_DATA_STR
Special state for groupings.
Definition: xlpivot.hxx:233
XclPTItemInfo()
Index into cache for item name.
Definition: xlpivot.cxx:433
XclPCFieldType meFieldType
Pivot cache field info (SXFIELD record).
Definition: xlpivot.hxx:516
bool IsSupportedField() const
Returns true, if the type of the field is supported by Calc.
Definition: xlpivot.cxx:293
const sal_uInt16 EXC_SXFIELD_DATA_DATE_NUM
Dates and empty strings, nothing else (?).
Definition: xlpivot.hxx:240
OUString maName
Definition: xlpivot.hxx:437
const sal_uInt16 EXC_SXVI_TYPE_AVERAGE
Definition: xlpivot.hxx:143
const sal_uInt16 EXC_SXVD_SUBT_PROD
Definition: xlpivot.hxx:125
const sal_uInt16 EXC_SXVI_FORMULA
Definition: xlpivot.hxx:157
const sal_uInt16 EXC_SXVS_SCENARIO
Definition: xlpivot.hxx:303
const sal_uInt16 EXC_ID_SXVIEWEX9
Definition: xlpivot.hxx:358
sal_uInt32 mnFlags
Number of page fields per column.
Definition: xlpivot.hxx:740
const sal_uInt16 EXC_SXVI_MISSING
Definition: xlpivot.hxx:158
const sal_uInt16 EXC_SXDI_REF_PERC
Definition: xlpivot.hxx:191
const sal_uInt16 EXC_PT_AUTOFMT_HEADER
Definition: xlpivot.hxx:62
const sal_uInt16 EXC_SXVI_TYPE_COUNTNUM
Definition: xlpivot.hxx:147
const sal_uInt16 EXC_SXDB_BLOCKRECS
Definition: xlpivot.hxx:213
A 2D cell range address struct with Excel column and row indexes.
Definition: xladdress.hxx:57
const sal_uInt16 EXC_SXDI_FUNC_VARP
Definition: xlpivot.hxx:187
OUString maUserName
Database type.
Definition: xlpivot.hxx:534
const sal_Int32 EXC_PC_MAXSTRLEN
Definition: xlpivot.hxx:47
sal_uInt16 mnItemCount
Bitfield for subtotal functions.
Definition: xlpivot.hxx:596
sal_uInt16 mnAxes
Definition: xlpivot.hxx:593
sal_uInt16 mnFirstHeadRow
First cell containing data.
Definition: xlpivot.hxx:711
sal_Int16 nValue
const sal_uInt16 EXC_SXFIELD_DATA_MASK
Definition: xlpivot.hxx:230
const sal_uInt16 EXC_SXVD_SUBT_COUNT
Definition: xlpivot.hxx:121
double mfValue
Definition: xlpivot.hxx:422
const sal_uInt16 EXC_SXLI_DEFAULTFLAGS
Definition: xlpivot.hxx:168
sal_Int32 GetApiAutoShowMode() const
Returns the API constant representing the AutoShow mode.
Definition: xlpivot.cxx:595
sal_uInt16 mnAutoFmtIdx
Flags for the entire pivot table.
Definition: xlpivot.hxx:723
sal_uInt8 mnGridLayout
AutoFormat ID.
Definition: xlpivot.hxx:755
Represents a data item of any type in a pivot cache.
Definition: xlpivot.hxx:366
sal_uInt16 mnDataAxis
0-based index of the pivot cache.
Definition: xlpivot.hxx:713
sal_uInt16 mnNumFmt
Index to data field AutoShow bases on.
Definition: xlpivot.hxx:625