LibreOffice Module sc (master) 1
XclExpChangeTrack.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 <memory>
23#include <stack>
24#include <tools/datetime.hxx>
25#include <chgtrack.hxx>
26#include <document.hxx>
27#include "xelink.hxx"
28#include "xestring.hxx"
29#include "excrecds.hxx"
30#include "xlformula.hxx"
31#include "xeformula.hxx"
32
33class ExcXmlRecord : public ExcRecord
34{
35public:
36 virtual std::size_t GetLen() const override;
37 virtual sal_uInt16 GetNum() const override;
38 virtual void Save( XclExpStream& rStrm ) override;
39};
40
41// XclExpUserBView - one UserBView record for each user
42
44{
45private:
48
49 virtual void SaveCont( XclExpStream& rStrm ) override;
50
51public:
52 XclExpUserBView( const OUString& rUsername, const sal_uInt8* pGUID );
53
54 const sal_uInt8* GetGUID() const { return aGUID; }
55
56 virtual sal_uInt16 GetNum() const override;
57 virtual std::size_t GetLen() const override;
58};
59
60// XclExpUserBViewList - list of UserBView records
61
63{
64private:
65 std::vector<XclExpUserBView> aViews;
66
67public:
68
69 typedef std::vector<XclExpUserBView>::const_iterator const_iterator;
70
71 XclExpUserBViewList( const ScChangeTrack& rChangeTrack );
72 virtual ~XclExpUserBViewList() override;
73
74 const_iterator cbegin () { return aViews.cbegin(); }
75 const_iterator cend () { return aViews.cend(); }
76
77 virtual void Save( XclExpStream& rStrm ) override;
78};
79
80// XclExpUsersViewBegin - begin of view block (one per sheet)
81
83{
84private:
86 sal_uInt32 nCurrTab;
87
88 virtual void SaveCont( XclExpStream& rStrm ) override;
89
90public:
91 XclExpUsersViewBegin( const sal_uInt8* pGUID, sal_uInt32 nTab );
92 virtual sal_uInt16 GetNum() const override;
93 virtual std::size_t GetLen() const override;
94};
95
96// XclExpUsersViewEnd - end of view block (one per sheet)
97
99{
100private:
101 virtual void SaveCont( XclExpStream& rStrm ) override;
102
103public:
104 virtual sal_uInt16 GetNum() const override;
105 virtual std::size_t GetLen() const override;
106};
107
108// dummy record for "User Names" stream
109
111{
112private:
113 virtual void SaveCont( XclExpStream& rStrm ) override;
114
115public:
116 virtual sal_uInt16 GetNum() const override;
117 virtual std::size_t GetLen() const override;
118};
119
120// dummy record for "User Names" stream
121
123{
124private:
125 virtual void SaveCont( XclExpStream& rStrm ) override;
126
127public:
128 virtual sal_uInt16 GetNum() const override;
129 virtual std::size_t GetLen() const override;
130};
131
132// dummy record for "User Names" stream
133
135{
136private:
137 virtual void SaveCont( XclExpStream& rStrm ) override;
138
139public:
140 virtual sal_uInt16 GetNum() const override;
141 virtual std::size_t GetLen() const override;
142};
143
144// dummy record for "User Names" stream
145
147{
148private:
149 virtual void SaveCont( XclExpStream& rStrm ) override;
150
151public:
152 virtual sal_uInt16 GetNum() const override;
153 virtual std::size_t GetLen() const override;
154};
155
156// dummy record without content
157
159{
160private:
161 sal_uInt16 nRecNum;
162
163public:
164 XclExpChTrEmpty( sal_uInt16 nNum ) : nRecNum( nNum ) {}
165 virtual ~XclExpChTrEmpty() override;
166
167 virtual sal_uInt16 GetNum() const override;
168 virtual std::size_t GetLen() const override;
169};
170
171// dummy record for "Revision Log" stream
172
174{
175private:
176 virtual void SaveCont( XclExpStream& rStrm ) override;
177
178public:
179 virtual ~XclExpChTr0x0195() override;
180
181 virtual sal_uInt16 GetNum() const override;
182 virtual std::size_t GetLen() const override;
183};
184
185// dummy record for "Revision Log" stream
186
188{
189private:
192
193 virtual void SaveCont( XclExpStream& rStrm ) override;
194
195public:
196 inline XclExpChTr0x0194( const ScChangeTrack& rChangeTrack );
197 virtual ~XclExpChTr0x0194() override;
198
199 virtual sal_uInt16 GetNum() const override;
200 virtual std::size_t GetLen() const override;
201};
202
204 sUsername( rChangeTrack.GetUser() ),
205 aDateTime( rChangeTrack.GetFixDateTime() )
206{
207}
208
209// XclExpChTrHeader - header record, includes action count
210
212{
213private:
215 sal_uInt32 nCount;
216
217 virtual void SaveCont( XclExpStream& rStrm ) override;
218
219public:
221 virtual ~XclExpChTrHeader() override;
222
223 void SetGUID( const sal_uInt8* pGUID ) { memcpy( aGUID, pGUID, 16 ); }
224 void SetCount( sal_uInt32 nNew ) { nCount = nNew; }
225
226 virtual sal_uInt16 GetNum() const override;
227 virtual std::size_t GetLen() const override;
228
229 virtual void SaveXml( XclExpXmlStream& rStrm ) override;
230};
231
233{
235public:
236 void SetGUID( const sal_uInt8* pGUID );
237
238 virtual void SaveXml( XclExpXmlStream& rStrm ) override;
239};
240
242class XclExpChTrAction;
243
245{
246 OUString maUserName;
249 sal_Int32 mnLogNumber;
250 sal_uInt32 mnMinAction;
251 sal_uInt32 mnMaxAction;
252
253 std::vector<sal_uInt16> maTabBuffer;
254 std::vector<std::unique_ptr<XclExpChTrAction>> maActions;
255
256public:
258 OUString aUserName, const DateTime& rDateTime, const sal_uInt8* pGUID,
259 sal_Int32 nLogNumber, const XclExpChTrTabIdBuffer& rBuf );
260
261 virtual void SaveXml( XclExpXmlStream& rStrm ) override;
262
263 void AppendAction( std::unique_ptr<XclExpChTrAction> pAction );
264};
265
266// XclExpChTrInfo - header of action group of a user
267
269{
270private:
274
275 virtual void SaveCont( XclExpStream& rStrm ) override;
276
277public:
278 XclExpChTrInfo( const OUString& rUsername, const DateTime& rDateTime,
279 const sal_uInt8* pGUID );
280
281 virtual ~XclExpChTrInfo() override;
282
283 virtual sal_uInt16 GetNum() const override;
284 virtual std::size_t GetLen() const override;
285};
286
287// XclExpChTrTabIdBuffer - buffer for tab id's
288
290{
291private:
292 std::unique_ptr<sal_uInt16[]>
294 sal_uInt16* pLast;
295 sal_uInt16 nBufSize;
296 sal_uInt16 nLastId;
297
298public:
299 XclExpChTrTabIdBuffer( sal_uInt16 nCount );
302
303 void InitFill( sal_uInt16 nIndex );
304 void InitFillup();
305
306 sal_uInt16 GetId( sal_uInt16 nIndex ) const;
307 void Remove();
308
309 sal_uInt16 GetBufferCount() const
310 { return static_cast< sal_uInt16 >( (pLast - pBuffer.get()) + 1 ); }
311 void GetBufferCopy( sal_uInt16* pDest ) const
312 { memcpy( pDest, pBuffer.get(), sizeof(sal_uInt16) * GetBufferCount() ); }
313};
314
315// XclExpChTrTabId - tab id record
316
318{
319private:
320 std::unique_ptr<sal_uInt16[]> pBuffer;
321 sal_uInt16 nTabCount;
322
323 void Clear() { pBuffer.reset(); }
324
325 virtual void SaveCont( XclExpStream& rStrm ) override;
326
327public:
328 XclExpChTrTabId( sal_uInt16 nCount ) : nTabCount( nCount ) {}
329 XclExpChTrTabId( const XclExpChTrTabIdBuffer& rBuffer );
330 virtual ~XclExpChTrTabId() override;
331
332 void Copy( const XclExpChTrTabIdBuffer& rBuffer );
333
334 virtual sal_uInt16 GetNum() const override;
335 virtual std::size_t GetLen() const override;
336};
337
338// XclExpChTrAction - base class for action records
339
341{
342private:
343 OUString sUsername;
345 sal_uInt32 nIndex; // action number
346 std::unique_ptr<XclExpChTrAction>
347 pAddAction; // additional record for this action
349
350protected:
351 const XclExpTabInfo& rTabInfo; // for table num export (sc num -> xcl num)
352 const XclExpChTrTabIdBuffer& rIdBuffer; // for table num export (xcl num -> tab id)
353 sal_uInt32 nLength; // this is not the record size
354 sal_uInt16 nOpCode; // EXC_CHTR_OP_***
356
357 XclExpChTrAction( const XclExpChTrAction& rCopy );
358
359 void SetAddAction( XclExpChTrAction* pAction );
361 const ScChangeAction& rAction,
362 const XclExpRoot& rRoot,
363 const ScChangeTrack& rChangeTrack );
364
365 static inline void Write2DAddress( XclExpStream& rStrm, const ScAddress& rAddress );
366 static inline void Write2DRange( XclExpStream& rStrm, const ScRange& rRange );
367 inline sal_uInt16 GetTabId( SCTAB nTabId ) const;
368 inline void WriteTabId( XclExpStream& rStrm, SCTAB nTabId ) const;
369
370 // save header data, call SaveActionData()
371 virtual void SaveCont( XclExpStream& rStrm ) override;
372 static std::size_t GetHeaderByteCount() { return 12; }
373
374 // override to save action data without header, called by SaveCont()
375 virtual void SaveActionData( XclExpStream& rStrm ) const = 0;
376 // override to get action size without header, called by GetLen()
377 virtual std::size_t GetActionByteCount() const = 0;
378
379 // do something before writing the record
380 virtual void PrepareSaveAction( XclExpStream& rStrm ) const;
381 // do something after writing the record
382 virtual void CompleteSaveAction( XclExpStream& rStrm ) const;
383
384 bool GetAccepted() const { return bAccepted; }
385
386public:
388 const ScChangeAction& rAction,
389 const XclExpRoot& rRoot,
390 const XclExpChTrTabIdBuffer& rTabIdBuffer,
391 sal_uInt16 nNewOpCode = EXC_CHTR_OP_UNKNOWN );
392 virtual ~XclExpChTrAction() override;
393
394 const OUString& GetUsername() const { return sUsername; }
395 const DateTime& GetDateTime() const { return aDateTime; }
397 bool ForceInfoRecord() const { return bForceInfo; }
398
399 // set own index & return new index
400 // could override to use more indexes per action
401 void SetIndex( sal_uInt32& rIndex );
402
403 virtual void Save( XclExpStream& rStrm ) override;
404 virtual std::size_t GetLen() const override;
405
407 sal_uInt32 GetActionNumber() const { return nIndex; }
408};
409
410inline void XclExpChTrAction::Write2DAddress( XclExpStream& rStrm, const ScAddress& rAddress )
411{
412 rStrm << static_cast<sal_uInt16>(rAddress.Row())
413 << static_cast<sal_uInt16>(rAddress.Col());
414}
415
416inline void XclExpChTrAction::Write2DRange( XclExpStream& rStrm, const ScRange& rRange )
417{
418 rStrm << static_cast<sal_uInt16>(rRange.aStart.Row())
419 << static_cast<sal_uInt16>(rRange.aEnd.Row())
420 << static_cast<sal_uInt16>(rRange.aStart.Col())
421 << static_cast<sal_uInt16>(rRange.aEnd.Col());
422}
423
424inline sal_uInt16 XclExpChTrAction::GetTabId( SCTAB nTab ) const
425{
426 return rIdBuffer.GetId( rTabInfo.GetXclTab( nTab ) );
427}
428
429inline void XclExpChTrAction::WriteTabId( XclExpStream& rStrm, SCTAB nTab ) const
430{
431 rStrm << GetTabId( nTab );
432}
433
434// XclExpChTrData - cell content itself
435
437{
438 std::unique_ptr<XclExpString> pString;
443 double fValue;
444 sal_Int32 nRKValue;
445 sal_uInt16 nType;
446 std::size_t nSize;
447
450 void Clear();
451
452 void WriteFormula(
453 XclExpStream& rStrm,
454 const XclExpChTrTabIdBuffer& rTabIdBuffer );
455 void Write(
456 XclExpStream& rStrm,
457 const XclExpChTrTabIdBuffer& rTabIdBuffer );
458};
459
460// XclExpChTrCellContent - changed cell content
461
462class XclExpChTrCellContent final : public XclExpChTrAction, protected XclExpRoot
463{
464 std::unique_ptr<XclExpChTrData> pOldData;
465 std::unique_ptr<XclExpChTrData> pNewData;
466 sal_uInt16 nOldLength; // this is not the record size
468
469 static void MakeEmptyChTrData( std::unique_ptr<XclExpChTrData>& rpData );
470
471 void GetCellData(
472 const XclExpRoot& rRoot, const ScCellValue& rScCell, std::unique_ptr<XclExpChTrData>& rpData,
473 sal_uInt32& rXclLength1, sal_uInt16& rXclLength2 );
474
475 virtual void SaveActionData( XclExpStream& rStrm ) const override;
476
477public:
479 const ScChangeActionContent& rAction,
480 const XclExpRoot& rRoot,
481 const XclExpChTrTabIdBuffer& rTabIdBuffer );
482 virtual ~XclExpChTrCellContent() override;
483
484 virtual sal_uInt16 GetNum() const override;
485 virtual std::size_t GetActionByteCount() const override;
486
487 virtual void SaveXml( XclExpXmlStream& rStrm ) override;
488};
489
490// XclExpChTrInsert - insert/delete columns/rows
491
493{
495
496protected:
498
499 XclExpChTrInsert( const XclExpChTrInsert& rCopy );
500
501 virtual void SaveActionData( XclExpStream& rStrm ) const override;
502 virtual void PrepareSaveAction( XclExpStream& rStrm ) const override;
503 virtual void CompleteSaveAction( XclExpStream& rStrm ) const override;
504
505public:
507 const ScChangeAction& rAction,
508 const XclExpRoot& rRoot,
509 const XclExpChTrTabIdBuffer& rTabIdBuffer,
510 const ScChangeTrack& rChangeTrack );
511 virtual ~XclExpChTrInsert() override;
512
513 virtual sal_uInt16 GetNum() const override;
514 virtual std::size_t GetActionByteCount() const override;
515
516 virtual void SaveXml( XclExpXmlStream& rStrm ) override;
517};
518
519// XclExpChTrInsertTab - insert table
520
522{
523private:
525
526protected:
527 virtual void SaveActionData( XclExpStream& rStrm ) const override;
528
529public:
531 const ScChangeAction& rAction,
532 const XclExpRoot& rRoot,
533 const XclExpChTrTabIdBuffer& rTabIdBuffer );
534 virtual ~XclExpChTrInsertTab() override;
535
536 virtual sal_uInt16 GetNum() const override;
537 virtual std::size_t GetActionByteCount() const override;
538
539 virtual void SaveXml( XclExpXmlStream& rStrm ) override;
540};
541
542// XclExpChTrMoveRange - move cell range
543
545{
548
549 virtual void SaveActionData( XclExpStream& rStrm ) const override;
550 virtual void PrepareSaveAction( XclExpStream& rStrm ) const override;
551 virtual void CompleteSaveAction( XclExpStream& rStrm ) const override;
552
553public:
555 const ScChangeActionMove& rAction,
556 const XclExpRoot& rRoot,
557 const XclExpChTrTabIdBuffer& rTabIdBuffer,
558 const ScChangeTrack& rChangeTrack );
559 virtual ~XclExpChTrMoveRange() override;
560
561 virtual sal_uInt16 GetNum() const override;
562 virtual std::size_t GetActionByteCount() const override;
563
564 virtual void SaveXml( XclExpXmlStream& rStrm ) override;
565};
566
567// XclExpChTr0x019A - additional data for delete action
568
570{
571protected:
572 virtual void SaveActionData( XclExpStream& rStrm ) const override;
573
574public:
575 XclExpChTr0x014A( const XclExpChTrInsert& rAction );
576 virtual ~XclExpChTr0x014A() override;
577
578 virtual sal_uInt16 GetNum() const override;
579 virtual std::size_t GetActionByteCount() const override;
580
581 virtual void SaveXml( XclExpXmlStream& rStrm ) override;
582};
583
584// XclExpChangeTrack - exports the "Revision Log" stream
585
587{
588 typedef std::vector<std::unique_ptr<ExcRecord>> RecListType;
589 RecListType maRecList; // list of "Revision Log" stream records
590 std::stack<XclExpChTrAction*> aActionStack;
592 std::vector<std::unique_ptr<XclExpChTrTabIdBuffer>>
594
595 ScDocumentUniquePtr xTempDoc; // empty document
596
598 void PushActionRecord( const ScChangeAction& rAction );
599
601
602public:
603 XclExpChangeTrack( const XclExpRoot& rRoot );
604 virtual ~XclExpChangeTrack() override;
605
606 void Write();
607 void WriteXml( XclExpXmlStream& rStrm );
608};
609
610/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual sal_uInt16 GetNum() const override
virtual void Save(XclExpStream &rStrm) override
Writes the record header and calls WriteBody().
virtual std::size_t GetLen() const override
SCROW Row() const
Definition: address.hxx:274
SCCOL Col() const
Definition: address.hxx:279
ScAddress aEnd
Definition: address.hxx:498
ScAddress aStart
Definition: address.hxx:497
virtual ~XclExpChTr0x014A() override
virtual void SaveActionData(XclExpStream &rStrm) const override
virtual std::size_t GetActionByteCount() const override
XclExpChTr0x014A(const XclExpChTrInsert &rAction)
virtual void SaveXml(XclExpXmlStream &rStrm) override
virtual sal_uInt16 GetNum() const override
virtual sal_uInt16 GetNum() const override
virtual void SaveCont(XclExpStream &rStrm) override
virtual std::size_t GetLen() const override
virtual sal_uInt16 GetNum() const override
virtual void SaveCont(XclExpStream &rStrm) override
virtual std::size_t GetLen() const override
virtual std::size_t GetLen() const override
XclExpChTr0x0194(const ScChangeTrack &rChangeTrack)
virtual ~XclExpChTr0x0194() override
virtual sal_uInt16 GetNum() const override
virtual void SaveCont(XclExpStream &rStrm) override
virtual std::size_t GetLen() const override
virtual void SaveCont(XclExpStream &rStrm) override
virtual ~XclExpChTr0x0195() override
virtual sal_uInt16 GetNum() const override
virtual void SaveCont(XclExpStream &rStrm) override
virtual sal_uInt16 GetNum() const override
virtual std::size_t GetLen() const override
virtual void SaveCont(XclExpStream &rStrm) override
virtual std::size_t GetLen() const override
virtual sal_uInt16 GetNum() const override
virtual void PrepareSaveAction(XclExpStream &rStrm) const
bool GetAccepted() const
bool ForceInfoRecord() const
virtual ~XclExpChTrAction() override
const OUString & GetUsername() const
void SetIndex(sal_uInt32 &rIndex)
const XclExpChTrTabIdBuffer & GetTabIdBuffer() const
std::unique_ptr< XclExpChTrAction > pAddAction
void WriteTabId(XclExpStream &rStrm, SCTAB nTabId) const
sal_uInt16 GetTabId(SCTAB nTabId) const
virtual void SaveActionData(XclExpStream &rStrm) const =0
const XclExpTabInfo & rTabInfo
virtual std::size_t GetActionByteCount() const =0
void AddDependentContents(const ScChangeAction &rAction, const XclExpRoot &rRoot, const ScChangeTrack &rChangeTrack)
virtual std::size_t GetLen() const override
static std::size_t GetHeaderByteCount()
void SetAddAction(XclExpChTrAction *pAction)
XclExpChTrAction(const XclExpChTrAction &rCopy)
virtual void CompleteSaveAction(XclExpStream &rStrm) const
const XclExpChTrTabIdBuffer & rIdBuffer
virtual void SaveCont(XclExpStream &rStrm) override
static void Write2DRange(XclExpStream &rStrm, const ScRange &rRange)
sal_uInt32 GetActionNumber() const
const DateTime & GetDateTime() const
virtual void Save(XclExpStream &rStrm) override
Writes the record header and calls WriteBody().
static void Write2DAddress(XclExpStream &rStrm, const ScAddress &rAddress)
XclExpChTrAction * GetAddAction()
void GetCellData(const XclExpRoot &rRoot, const ScCellValue &rScCell, std::unique_ptr< XclExpChTrData > &rpData, sal_uInt32 &rXclLength1, sal_uInt16 &rXclLength2)
std::unique_ptr< XclExpChTrData > pOldData
virtual ~XclExpChTrCellContent() override
virtual std::size_t GetActionByteCount() const override
virtual sal_uInt16 GetNum() const override
virtual void SaveActionData(XclExpStream &rStrm) const override
static void MakeEmptyChTrData(std::unique_ptr< XclExpChTrData > &rpData)
std::unique_ptr< XclExpChTrData > pNewData
XclExpChTrCellContent(const ScChangeActionContent &rAction, const XclExpRoot &rRoot, const XclExpChTrTabIdBuffer &rTabIdBuffer)
virtual void SaveXml(XclExpXmlStream &rStrm) override
virtual sal_uInt16 GetNum() const override
virtual std::size_t GetLen() const override
XclExpChTrEmpty(sal_uInt16 nNum)
virtual ~XclExpChTrEmpty() override
virtual sal_uInt16 GetNum() const override
void SetCount(sal_uInt32 nNew)
virtual std::size_t GetLen() const override
virtual void SaveXml(XclExpXmlStream &rStrm) override
virtual void SaveCont(XclExpStream &rStrm) override
virtual ~XclExpChTrHeader() override
void SetGUID(const sal_uInt8 *pGUID)
virtual std::size_t GetLen() const override
virtual sal_uInt16 GetNum() const override
XclExpChTrInfo(const OUString &rUsername, const DateTime &rDateTime, const sal_uInt8 *pGUID)
virtual ~XclExpChTrInfo() override
virtual void SaveCont(XclExpStream &rStrm) override
sal_uInt8 aGUID[16]
XclExpString sUsername
virtual void SaveActionData(XclExpStream &rStrm) const override
virtual ~XclExpChTrInsertTab() override
virtual sal_uInt16 GetNum() const override
virtual std::size_t GetActionByteCount() const override
virtual void SaveXml(XclExpXmlStream &rStrm) override
XclExpChTrInsertTab(const ScChangeAction &rAction, const XclExpRoot &rRoot, const XclExpChTrTabIdBuffer &rTabIdBuffer)
virtual void SaveActionData(XclExpStream &rStrm) const override
virtual void SaveXml(XclExpXmlStream &rStrm) override
XclExpChTrInsert(const XclExpChTrInsert &rCopy)
virtual ~XclExpChTrInsert() override
virtual sal_uInt16 GetNum() const override
virtual void CompleteSaveAction(XclExpStream &rStrm) const override
virtual void PrepareSaveAction(XclExpStream &rStrm) const override
virtual std::size_t GetActionByteCount() const override
virtual std::size_t GetActionByteCount() const override
virtual sal_uInt16 GetNum() const override
virtual void PrepareSaveAction(XclExpStream &rStrm) const override
XclExpChTrMoveRange(const ScChangeActionMove &rAction, const XclExpRoot &rRoot, const XclExpChTrTabIdBuffer &rTabIdBuffer, const ScChangeTrack &rChangeTrack)
virtual void CompleteSaveAction(XclExpStream &rStrm) const override
virtual void SaveActionData(XclExpStream &rStrm) const override
virtual void SaveXml(XclExpXmlStream &rStrm) override
virtual ~XclExpChTrMoveRange() override
XclExpChTrTabIdBuffer(sal_uInt16 nCount)
sal_uInt16 GetBufferCount() const
void InitFill(sal_uInt16 nIndex)
void GetBufferCopy(sal_uInt16 *pDest) const
sal_uInt16 GetId(sal_uInt16 nIndex) const
std::unique_ptr< sal_uInt16[]> pBuffer
virtual void SaveCont(XclExpStream &rStrm) override
virtual ~XclExpChTrTabId() override
virtual sal_uInt16 GetNum() const override
virtual std::size_t GetLen() const override
void Copy(const XclExpChTrTabIdBuffer &rBuffer)
std::unique_ptr< sal_uInt16[]> pBuffer
XclExpChTrTabId(sal_uInt16 nCount)
void PushActionRecord(const ScChangeAction &rAction)
XclExpChTrTabIdBuffer * pTabIdBuffer
virtual ~XclExpChangeTrack() override
std::stack< XclExpChTrAction * > aActionStack
void WriteXml(XclExpXmlStream &rStrm)
XclExpChangeTrack(const XclExpRoot &rRoot)
ScDocumentUniquePtr xTempDoc
std::vector< std::unique_ptr< XclExpChTrTabIdBuffer > > maBuffers
ScChangeTrack * CreateTempChangeTrack()
std::vector< std::unique_ptr< ExcRecord > > RecListType
Access to global data from other classes.
Definition: xeroot.hxx:113
This class is used to export Excel record streams.
Definition: xestream.hxx:73
This class stores an unformatted or formatted string for Excel export.
Definition: xestring.hxx:48
Stores the correct Excel sheet index for each Calc sheet.
Definition: xelink.hxx:62
sal_uInt16 GetXclTab(SCTAB nScTab) const
Returns the Excel sheet index for a given Calc sheet.
Definition: xelink.cxx:814
const_iterator cbegin()
virtual ~XclExpUserBViewList() override
const_iterator cend()
XclExpUserBViewList(const ScChangeTrack &rChangeTrack)
virtual void Save(XclExpStream &rStrm) override
Writes the record header and calls WriteBody().
std::vector< XclExpUserBView >::const_iterator const_iterator
std::vector< XclExpUserBView > aViews
XclExpString sUsername
sal_uInt8 aGUID[16]
const sal_uInt8 * GetGUID() const
XclExpUserBView(const OUString &rUsername, const sal_uInt8 *pGUID)
virtual std::size_t GetLen() const override
virtual sal_uInt16 GetNum() const override
virtual void SaveCont(XclExpStream &rStrm) override
XclExpUsersViewBegin(const sal_uInt8 *pGUID, sal_uInt32 nTab)
virtual void SaveCont(XclExpStream &rStrm) override
virtual sal_uInt16 GetNum() const override
virtual std::size_t GetLen() const override
virtual void SaveCont(XclExpStream &rStrm) override
virtual sal_uInt16 GetNum() const override
virtual std::size_t GetLen() const override
std::vector< std::unique_ptr< XclExpChTrAction > > maActions
void AppendAction(std::unique_ptr< XclExpChTrAction > pAction)
std::vector< sal_uInt16 > maTabBuffer
virtual void SaveXml(XclExpXmlStream &rStrm) override
XclExpXmlChTrHeader(OUString aUserName, const DateTime &rDateTime, const sal_uInt8 *pGUID, sal_Int32 nLogNumber, const XclExpChTrTabIdBuffer &rBuf)
void SetGUID(const sal_uInt8 *pGUID)
virtual void SaveXml(XclExpXmlStream &rStrm) override
int nCount
std::unique_ptr< ScDocument, o3tl::default_delete< ScDocument > > ScDocumentUniquePtr
Definition: document.hxx:2717
#define EXC_CHTR_OP_UNKNOWN
Definition: excdefs.hxx:76
void SvStream & rStrm
Store arbitrary cell value of any kind.
Definition: cellvalue.hxx:32
XclTokenArrayRef mxTokArr
XclExpStringRef mpFormattedString
void Write(XclExpStream &rStrm, const XclExpChTrTabIdBuffer &rTabIdBuffer)
std::unique_ptr< XclExpString > pString
void WriteFormula(XclExpStream &rStrm, const XclExpChTrTabIdBuffer &rTabIdBuffer)
XclExpRefLog maRefLog
const ScFormulaCell * mpFormulaCell
unsigned char sal_uInt8
sal_Int16 SCTAB
Definition: types.hxx:22
::std::vector< XclExpRefLogEntry > XclExpRefLog
Vector containing a log for all external references in a formula, used i.e.
Definition: xeformula.hxx:43
std::shared_ptr< XclExpString > XclExpStringRef
Definition: xeroot.hxx:35
std::shared_ptr< XclTokenArray > XclTokenArrayRef
Definition: xlformula.hxx:416