Hi,
instead of translating comments, this time I removed lot's of comments like
// Wang Xu Ming -- 2009-8-17
// DataPilot Migration - Cache&&Performance
<code>
// End Comments
Christina
From 97a63b6dab83a7463e42374346e3d384e19333f4 Mon Sep 17 00:00:00 2001
From: Christina Rossmanith <Christina Rossmanith>
Date: Sat, 8 Jan 2011 23:49:42 +0100
Subject: [PATCH] Removed unnecessary comments
---
sc/inc/document.hxx | 6 ---
sc/inc/dpgroup.hxx | 21 ------------
sc/inc/dpobject.hxx | 3 --
sc/inc/dpsave.hxx | 6 ---
sc/inc/dpsdbtab.hxx | 3 --
sc/inc/dptabdat.hxx | 23 +------------
sc/inc/dptabres.hxx | 59 +---------------------------------
sc/inc/dptabsrc.hxx | 27 ---------------
sc/source/core/data/documen3.cxx | 6 ---
sc/source/core/data/dpcachetable.cxx | 1 -
sc/source/core/data/dpgroup.cxx | 19 -----------
sc/source/core/data/dpobject.cxx | 25 +++-----------
sc/source/core/data/dpoutput.cxx | 27 ---------------
sc/source/core/data/dpsave.cxx | 16 +--------
sc/source/core/data/dpsdbtab.cxx | 3 --
sc/source/core/data/dpshttab.cxx | 6 ---
sc/source/core/data/dptabdat.cxx | 12 -------
sc/source/core/data/dptabres.cxx | 20 +-----------
sc/source/core/data/dptabsrc.cxx | 6 ---
sc/source/core/data/global2.cxx | 3 --
sc/source/filter/excel/xepivot.cxx | 3 --
sc/source/ui/inc/dbfunc.hxx | 3 --
sc/source/ui/view/dbfunc3.cxx | 3 --
23 files changed, 10 insertions(+), 291 deletions(-)
diff --git a/sc/inc/document.hxx b/sc/inc/document.hxx
index 5658c01..0f7d5b8 100644
--- a/sc/inc/document.hxx
+++ b/sc/inc/document.hxx
@@ -246,10 +246,7 @@ private:
ScRangeName* pRangeName;
ScDBCollection* pDBCollection;
ScDPCollection* pDPCollection;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
std::list<ScDPTableDataCache*> m_listDPObjectsCaches;
- // End Comments
ScChartCollection* pChartCollection;
std::auto_ptr< ScTemporaryChartLock > apTemporaryChartLock;
ScPatternAttr* pSelectionAttr; // Attributes of a
block
@@ -491,15 +488,12 @@ public:
SC_DLLPUBLIC ScDPCollection* GetDPCollection();
ScDPObject* GetDPAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab) const;
ScDPObject* GetDPAtBlock( const ScRange& rBlock ) const;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
SC_DLLPUBLIC ScDPTableDataCache* GetDPObjectCache( long nID );
SC_DLLPUBLIC ScDPTableDataCache* GetUsedDPObjectCache ( ScRange rRange );
SC_DLLPUBLIC long AddDPObjectCache( ScDPTableDataCache* pData
);
SC_DLLPUBLIC void RemoveDPObjectCache( long nID );
SC_DLLPUBLIC void RemoveUnusedDPObjectCaches();
SC_DLLPUBLIC long GetNewDPObjectCacheId ();
- // End Comments
SC_DLLPUBLIC ScChartCollection* GetChartCollection() const;
diff --git a/sc/inc/dpgroup.hxx b/sc/inc/dpgroup.hxx
index e59f869..6dcaa67 100644
--- a/sc/inc/dpgroup.hxx
+++ b/sc/inc/dpgroup.hxx
@@ -35,10 +35,7 @@
#include "dptabdat.hxx"
#include "scdllapi.h"
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
#include "dpglobal.hxx"
-// End Comments
class ScDocument;
class SvNumberFormatter;
@@ -77,11 +74,8 @@ public:
sal_Int32 GetDatePart() const { return nDatePart; }
const ScDPNumGroupInfo& GetNumInfo() const { return aNumInfo; }
- // Wang Xu Ming -- 2009-9-8
- // DataPilot Migration - Cache&&Performance
void FillColumnEntries( SCCOL nSourceDim, ScDPTableDataCache* pCahe , std::vector<
SCROW >& rEntries,
const std::vector< SCROW >& rOriginal ) const;
- // End Comments
};
// --------------------------------------------------------------------
@@ -115,10 +109,7 @@ class ScDPGroupDimension
String aGroupName;
ScDPDateGroupHelper* pDateHelper;
ScDPGroupItemVec aItems;
- // Wang Xu Ming -- 2009-9-4
- // DataPilot Migration - Cache&&Performance
mutable ::std::vector< SCROW > maMemberEntries;
- // End Comments
public:
ScDPGroupDimension( long nSource, const String& rNewName );
ScDPGroupDimension( const ScDPGroupDimension& rOther );
@@ -133,10 +124,7 @@ public:
long GetGroupDim() const { return nGroupDim; }
const String& GetName() const { return aGroupName; }
-// Wang Xu Ming -- 2009-9-2
-// DataPilot Migration - Cache&&Performance
const std::vector< SCROW >& GetColumnEntries( const ScDPCacheTable& rCacheTable, const
std::vector< SCROW >& rOriginal ) const;
-// End Comments
const ScDPGroupItem* GetGroupForData( const ScDPItemData& rData ) const; // rData = entry in
original dim.
const ScDPGroupItem* GetGroupForName( const ScDPItemData& rName ) const; // rName = entry in
group dim.
const ScDPGroupItem* GetGroupByIndex( size_t nIndex ) const;
@@ -158,10 +146,7 @@ class SC_DLLPUBLIC ScDPNumGroupDimension
{
ScDPNumGroupInfo aGroupInfo; // settings
ScDPDateGroupHelper* pDateHelper;
-// Wang Xu Ming -- 2009-9-4
-// DataPilot Migration - Cache&&Performance
mutable ::std::vector< SCROW > maMemberEntries;
-// End Comments
mutable bool bHasNonInteger; // initialized in GetNumEntries
mutable sal_Unicode cDecSeparator; // initialized in GetNumEntries
@@ -203,11 +188,8 @@ class ScDPGroupTableData : public ScDPTableData
ScDocument* pDoc;
StringHashSet aGroupNames;
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
void FillGroupValues( SCROW* pItemDataIndex,
long nCount, const long* pDims );
virtual long GetSourceDim( long nDim );
-// End Comments
bool IsNumGroupDimension( long nDimension ) const;
void GetNumGroupInfo( long nDimension, ScDPNumGroupInfo& rInfo,
@@ -227,14 +209,11 @@ public:
ScDocument* GetDocument() { return pDoc; }
virtual long GetColumnCount();
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
virtual long GetMembersCount( long nDim );
virtual const std::vector< SCROW >& GetColumnEntries( long nColumn ) ;
virtual const ScDPItemData* GetMemberById( long nDim, long nId);
virtual long Compare( long nDim, long nDataId1, long nDataId2);
-// End Comments
virtual String getDimensionName(long nColumn);
virtual BOOL getIsDataLayoutDimension(long nColumn);
virtual BOOL IsDateDimension(long nDim);
diff --git a/sc/inc/dpobject.hxx b/sc/inc/dpobject.hxx
index 4a00c6a..5cd7a8e 100644
--- a/sc/inc/dpobject.hxx
+++ b/sc/inc/dpobject.hxx
@@ -120,13 +120,10 @@ private:
long mnCacheId;
public:
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
inline void SetRefresh() { bRefresh = TRUE; }
long GetCacheId() const;
void SetCacheId( long nCacheId );
ULONG RefreshCache();
- // End Comments
ScDPObject( ScDocument* pD );
ScDPObject(const ScDPObject& r);
virtual ~ScDPObject();
diff --git a/sc/inc/dpsave.hxx b/sc/inc/dpsave.hxx
index 30d4ee3..779c9ef 100644
--- a/sc/inc/dpsave.hxx
+++ b/sc/inc/dpsave.hxx
@@ -201,10 +201,7 @@ private:
USHORT nRepeatEmptyMode;
BOOL bFilterButton; // not passed to DataPilotSource
BOOL bDrillDown; // not passed to DataPilotSource
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
long mnCacheId;
- // End Comments
/** if true, all dimensions already have all of their member instances
* created. */
@@ -261,14 +258,11 @@ public:
void WriteToSource( const com::sun::star::uno::Reference<
com::sun::star::sheet::XDimensionsSupplier>& xSource );
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
void Refresh( const com::sun::star::uno::Reference<
com::sun::star::sheet::XDimensionsSupplier>& xSource );
BOOL IsEmpty() const;
inline long GetCacheId() const{ return mnCacheId; }
inline void SetCacheId( long nCacheId ){ mnCacheId = nCacheId; }
- // End Comments
const ScDPDimensionSaveData* GetExistingDimensionData() const { return pDimensionData; }
SC_DLLPUBLIC ScDPDimensionSaveData* GetDimensionData(); // create if not there
void SetDimensionData( const ScDPDimensionSaveData* pNew ); // copied
diff --git a/sc/inc/dpsdbtab.hxx b/sc/inc/dpsdbtab.hxx
index 9baf4b1..0bfc6b1 100644
--- a/sc/inc/dpsdbtab.hxx
+++ b/sc/inc/dpsdbtab.hxx
@@ -59,13 +59,10 @@ struct ScImportSourceDesc
nType == rOther.nType &&
bNative == rOther.bNative; }
- // Wang Xu Ming -- 2009-9-15
- // DataPilot Migration - Cache&&Performance
ScDPTableDataCache* GetExistDPObjectCache( ScDocument* pDoc ) const;
ScDPTableDataCache* CreateCache( ScDocument* pDoc , long nID ) const;
ScDPTableDataCache* GetCache( ScDocument* pDoc, long nID ) const;
long GetCacheId( ScDocument* pDoc, long nID ) const;
- // End Comments
};
class ScDatabaseDPData : public ScDPTableData
diff --git a/sc/inc/dptabdat.hxx b/sc/inc/dptabdat.hxx
index 5c33619..73c4385 100644
--- a/sc/inc/dptabdat.hxx
+++ b/sc/inc/dptabdat.hxx
@@ -32,10 +32,7 @@
#include "address.hxx"
#include "dpoutput.hxx"
#include "dpcachetable.hxx"
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
#include "dptablecache.hxx"
-// End Comments
#include <tools/string.hxx>
#include <vector>
@@ -100,11 +97,8 @@ class SC_DLLPUBLIC ScDPTableData
long nLastHier;
long nLastLevel;
long nLastRet;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
long mnCacheId;
const ScDocument* mpDoc;
- // End Comments
public:
/** This structure stores dimension information used when calculating
@@ -130,10 +124,7 @@ public:
CalcInfo();
};
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
ScDPTableData(ScDocument* pDoc, long nCacheId );
- // End Comments
virtual ~ScDPTableData();
long GetDatePart( long nDateVal, long nHierarchy, long nLevel );
@@ -142,11 +133,8 @@ public:
//! or separate Str and ValueCollection
virtual long GetColumnCount() = 0;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
virtual const std::vector< SCROW >& GetColumnEntries( long nColumn ) ;
long GetCacheId() const;
- // End Comments
virtual String getDimensionName(long nColumn) = 0;
virtual BOOL getIsDataLayoutDimension(long nColumn) = 0;
virtual BOOL IsDateDimension(long nDim) = 0;
@@ -174,26 +162,20 @@ public:
virtual BOOL HasCommonElement( const ScDPItemData& rFirstData, long
nFirstIndex,
const ScDPItemData& rSecondData, long
nSecondIndex ) const;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
virtual long GetMembersCount( long nDim );
virtual const ScDPItemData* GetMemberByIndex( long nDim, long nIndex );
virtual const ScDPItemData* GetMemberById( long nDim, long nId);
virtual SCROW GetIdOfItemData( long nDim, const ScDPItemData& rData );
virtual long GetSourceDim( long nDim );
virtual long Compare( long nDim, long nDataId1, long nDataId2);
- // End Comments
protected:
/** This structure stores vector arrays that hold intermediate data for
each row during cache table iteration. */
struct CalcRowData
{
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
- ::std::vector< SCROW > aColData;
+ ::std::vector< SCROW > aColData;
::std::vector< SCROW > aRowData;
::std::vector< SCROW > aPageData;
- // End Comments
::std::vector<ScDPValueData> aValues;
};
@@ -202,11 +184,8 @@ protected:
void CalcResultsFromCacheTable(const ScDPCacheTable& rCacheTable, CalcInfo& rInfo,
bool bAutoShow);
private:
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
void GetItemData(const ScDPCacheTable& rCacheTable, sal_Int32 nRow,
const ::std::vector<long>& rDims, ::std::vector< SCROW
& rItemData);
- // End Comments
};
#endif
diff --git a/sc/inc/dptabres.hxx b/sc/inc/dptabres.hxx
index 58b176f..fa62f40 100644
--- a/sc/inc/dptabres.hxx
+++ b/sc/inc/dptabres.hxx
@@ -58,10 +58,7 @@ class ScDPResultMember;
class ScDPResultVisibilityData;
struct ScDPValueData;
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
class ScDPItemData;
-// End Comments
//
// Member names that are being processed for InitFrom/LateInitFrom
// (needed for initialization of grouped items)
@@ -70,10 +67,7 @@ class ScDPItemData;
class ScDPInitState
{
long* pIndex; // array
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
SCROW* pData; // array
- // End Comments
long nCount;
public:
@@ -85,11 +79,8 @@ public:
long GetCount() const { return nCount; }
const long* GetSource() const { return pIndex; }
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
const SCROW* GetNameIds() const { return pData; }
SCROW GetNameIdForIndex( long nIndexValue ) const;
-// End Comments
};
typedef ::std::vector<sal_Int32> ScMemberSortOrder;
@@ -238,8 +229,6 @@ class ScDPDataMember;
#define SC_DPMEASURE_ALL -1
#define SC_DPMEASURE_ANY -2
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
struct MemberHashIndexFunc : public std::unary_function< const SCROW &, size_t >
{
@@ -299,7 +288,6 @@ public:
inline BOOL IsRow() const { return mbRow; }
BOOL IsEnd( size_t nPos ) const ;
};
-// End Comments
class ScDPResultData
{
@@ -348,8 +336,6 @@ public:
BOOL IsBaseForGroup( long nDim ) const; // any group
long GetGroupBase( long nGroupDim ) const;
BOOL IsNumOrDateGroup( long nDim ) const;
- // Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
BOOL IsInGroup( const ScDPItemData& rGroupData, long nGroupIndex,
long nBaseDataId, long nBaseIndex ) const;
BOOL IsInGroup( SCROW nGroupDataId, long nGroupIndex,
@@ -359,7 +345,6 @@ public:
ResultMembers* GetDimResultMembers( long nDim , ScDPDimension* pDim , ScDPLevel* pLevel)
const ;
-// End Comments
const ScDPSource* GetSource() const;
};
@@ -368,10 +353,7 @@ class ScDPResultMember
{
private:
const ScDPResultData* pResultData;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
ScDPParentDimData aParentDimData;
- // End Comments
ScDPResultDimension* pChildDimension;
ScDPDataMember* pDataRoot;
BOOL bHasElements;
@@ -383,16 +365,11 @@ private:
USHORT nMemberStep; // step to show
details
public:
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
ScDPResultMember( const ScDPResultData* pData, const ScDPParentDimData& rParentDimData,
BOOL bForceSub ); //! Ref
ScDPResultMember( const ScDPResultData* pData, BOOL bForceSub );
- // End Comments
~ScDPResultMember();
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
void InitFrom( const ::std::vector<ScDPDimension*>& ppDim,
const ::std::vector<ScDPLevel*>& ppLev,
size_t nPos,
@@ -404,7 +381,6 @@ public:
size_t nPos,
ScDPInitState& rInitState);
void CheckShowEmpty( BOOL bShow = FALSE );
- // End Comments
String GetName() const;
void FillItemData( ScDPItemData& rData ) const;
BOOL IsValid() const;
@@ -416,22 +392,16 @@ public:
// BOOL SubTotalEnabled() const;
long GetSubTotalCount( long* pUserSubStart = NULL ) const;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
BOOL IsNamedItem( SCROW nIndex ) const;
bool IsValidEntry( const ::std::vector< SCROW >& aMembers ) const;
- // End Comments
void SetHasElements() { bHasElements = TRUE; }
void SetAutoHidden() { bAutoHidden = TRUE; }
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
void ProcessData( const ::std::vector<SCROW>& aChildMembers,
const ScDPResultDimension* pDataDim,
const ::std::vector<SCROW>& aDataMembers,
const ::std::vector<ScDPValueData>& aValues );
- // End Comments
void FillMemberResults( com::sun::star::uno::Sequence<
com::sun::star::sheet::MemberResult>* pSequences,
long& rPos, long nMeasure, BOOL bRoot,
@@ -461,15 +431,12 @@ public:
ScDPDataMember* GetDataRoot() const { return
pDataRoot; }
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
const ScDPDimension* GetParentDim() const { return aParentDimData.mpParentDim;
} //! Ref
const ScDPLevel* GetParentLevel() const { return aParentDimData.mpParentLevel;
} //! Ref
const ScDPMember* GetDPMember()const { return aParentDimData.mpMemberDesc; }
//! Ref
inline SCROW GetOrder() const { return
aParentDimData.mnOrder; } //! Ref
inline BOOL IsRoot() const { return GetParentLevel() ==
NULL; }
SCROW GetDataId( ) const ;
- // End Comments
ScDPAggData* GetColTotal( long nMeasure ) const;
void FillVisibilityData(ScDPResultVisibilityData& rData) const;
@@ -495,18 +462,12 @@ public:
BOOL IsVisible() const;
BOOL HasData( long nMeasure, const ScDPSubTotalState& rSubState
) const;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
BOOL IsNamedItem( SCROW r ) const;
- // End Comments
BOOL HasHiddenDetails() const;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
void ProcessData( const ::std::vector< SCROW >& aChildMembers, const
::std::vector<ScDPValueData>& aValues,
const ScDPSubTotalState& rSubState );
- // End Comments
- BOOL HasError( long nMeasure, const ScDPSubTotalState& rSubState
) const;
+ BOOL HasError( long nMeasure, const ScDPSubTotalState& rSubState
) const;
double GetAggregate( long nMeasure, const ScDPSubTotalState&
rSubState ) const;
const ScDPAggData* GetConstAggData( long nMeasure, const ScDPSubTotalState& rSubState ) const;
ScDPAggData* GetAggData( long nMeasure, const ScDPSubTotalState& rSubState );
@@ -545,11 +506,8 @@ SV_DECL_PTRARR_DEL(ScDPDataMembers, ScDPDataMemberPtr, SC_DP_RES_GROW,
SC_DP_RES
class ScDPResultDimension
{
public :
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
typedef std::vector <ScDPResultMember *> MemberArray;
typedef std::map < SCROW , ScDPResultMember *> MemberHash;
- // End Comments
private:
const ScDPResultData* pResultData;
MemberArray maMemberArray;
@@ -566,8 +524,6 @@ private:
long nAutoMeasure;
long nAutoCount;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
ScDPResultMember* FindMember( SCROW iData ) const;
ScDPResultMember* AddMember( const ScDPParentDimData& aData );
ScDPResultMember* InsertMember( ScDPParentDimData* pMemberData );
@@ -575,14 +531,11 @@ private:
const ::std::vector< SCROW >&
pItemData,
size_t nPos,
ScDPInitState& rInitState );
- // End Comments
public:
ScDPResultDimension( const ScDPResultData* pData );
~ScDPResultDimension();
// allocates new members
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
void InitFrom( const ::std::vector<ScDPDimension*>& ppDim,
const ::std::vector<ScDPLevel*>& ppLev,
size_t nPos,
@@ -593,11 +546,8 @@ public:
ScDPInitState& rInitState );
void CheckShowEmpty( BOOL bShow = FALSE );
- // End Comments
long GetSize(long nMeasure) const;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
bool IsValidEntry( const ::std::vector<SCROW>& aMembers ) const;
// modifies existing members, allocates data dimensions
@@ -605,7 +555,6 @@ public:
const ScDPResultDimension* pDataDim,
const ::std::vector<SCROW>& aDataMembers,
const ::std::vector<ScDPValueData>& aValues ) const; //!
Test
- // End Comments
void FillMemberResults( com::sun::star::uno::Sequence<
com::sun::star::sheet::MemberResult>* pSequences,
long nStart, long nMeasure );
@@ -675,11 +624,8 @@ public:
~ScDPDataDimension();
void InitFrom( const ScDPResultDimension* pDim ); //
recursive
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
void ProcessData( const ::std::vector< SCROW >& aDataMembers, const
::std::vector<ScDPValueData>& aValues,
const ScDPSubTotalState& rSubState );
- // End Comments
void FillDataRow( const ScDPResultDimension* pRefDim,
com::sun::star::uno::Sequence<com::sun::star::sheet::DataResult>& rSequence,
long nCol, long nMeasure, BOOL bIsSubTotalRow,
@@ -713,10 +659,7 @@ public:
class ScDPResultVisibilityData
{
public:
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
ScDPResultVisibilityData( ScDPSource* pSource);
- // End Comments
~ScDPResultVisibilityData();
void addVisibleMember(const String& rDimName, const ScDPItemData& rMemberItem);
diff --git a/sc/inc/dptabsrc.hxx b/sc/inc/dptabsrc.hxx
index 3fb4984..1486418 100644
--- a/sc/inc/dptabsrc.hxx
+++ b/sc/inc/dptabsrc.hxx
@@ -31,10 +31,7 @@
#include <vector>
#include <hash_map>
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
#include <list>
-// End Comments
#include <memory>
#include <tools/string.hxx>
#include <tools/list.hxx>
@@ -62,10 +59,7 @@
#include <cppuhelper/implbase3.hxx>
#include <cppuhelper/implbase5.hxx>
#include <cppuhelper/implbase6.hxx>
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
#include "dpglobal.hxx"
-// End Comments
#include "dptabdat.hxx"
namespace com { namespace sun { namespace star {
@@ -79,10 +73,7 @@ namespace com { namespace sun { namespace star {
class ScDPResultMember;
class ScDPResultData;
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
class ScDPItemData;
-// End Comments
class ScDPTableData;
// ------------------------------------------------------------------------
@@ -183,13 +174,10 @@ public:
long GetDataDimensionCount();
ScDPDimension* GetDataDimension(long nIndex);
String GetDataDimName(long nIndex);
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
ScDPTableDataCache* GetCache();
const ScDPItemData* GetItemDataById( long nDim, long nId );
long GetDataLayoutDim(){ return pData->GetColumnCount();
}
SCROW GetMemberId( long nDim, const ScDPItemData& rData );
- // End Comments
BOOL IsDataLayoutDimension(long nDim);
USHORT GetDataLayoutOrientation();
@@ -455,10 +443,7 @@ public:
const ::com::sun::star::sheet::DataPilotFieldReference& GetReferenceValue() const;
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
BOOL IsVisible( const ScDPItemData& rData );
-// End Comments
};
class ScDPHierarchies : public cppu::WeakImplHelper2<
@@ -752,12 +737,9 @@ public:
long getMinMembers() const;
sal_Int32 GetIndexFromName( const ::rtl::OUString& rName ) const; // <0 if
not found
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
const std::vector<sal_Int32>& GetGlobalOrder();
const ScDPItemData* GetSrcItemDataByIndex( SCROW nIndex);
SCROW GetSrcItemsCount();
- // End Comments
};
class ScDPMember : public cppu::WeakImplHelper3<
@@ -771,10 +753,7 @@ private:
long nHier;
long nLev;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
SCROW mnDataId;
- // End Comments
// String aCaption; // visible name (changeable by user)
::std::auto_ptr<rtl::OUString> mpLayoutName;
@@ -783,22 +762,16 @@ private:
BOOL bShowDet;
public:
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
ScDPMember( ScDPSource* pSrc, long nD, long nH, long nL,
SCROW nIndex /*const String& rN, double fV, BOOL bHV */);
- // End Comments
virtual ~ScDPMember();
String GetNameStr() const;
void FillItemData( ScDPItemData& rData ) const;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
// const ScDPItemData& GetItemData() const{ return maData; }
const ScDPItemData& GetItemData() const;
inline SCROW GetItemDataId() const { return mnDataId; }
BOOL IsNamedItem( SCROW nIndex ) const;
- // End Comments
SC_DLLPUBLIC const ::rtl::OUString* GetLayoutName() const;
diff --git a/sc/source/core/data/documen3.cxx b/sc/source/core/data/documen3.cxx
index fcbfdcc..b69ab56 100644
--- a/sc/source/core/data/documen3.cxx
+++ b/sc/source/core/data/documen3.cxx
@@ -77,11 +77,8 @@
#include "drwlayer.hxx"
#include "unoreflist.hxx"
#include "listenercalls.hxx"
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
#include "dpshttab.hxx"
#include "dptablecache.hxx"
-// End Comments
#include "tabprotection.hxx"
#include "formulaparserpool.hxx"
#include "clipparam.hxx"
@@ -2034,8 +2031,6 @@ void ScDocument::DecSizeRecalcLevel( SCTAB nTab, bool bUpdateNoteCaptionPos )
pTab[nTab]->DecRecalcLevel( bUpdateNoteCaptionPos );
}
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
ScDPTableDataCache* ScDocument::GetDPObjectCache( long nID )
{
for ( std::list<ScDPTableDataCache*>::iterator iter = m_listDPObjectsCaches.begin();
iter!=m_listDPObjectsCaches.end(); ++iter )
@@ -2135,6 +2130,5 @@ void ScDocument::RemoveUnusedDPObjectCaches()
}
}
-// End Comments
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/core/data/dpcachetable.cxx b/sc/source/core/data/dpcachetable.cxx
index 06c2c2f..9a47b07 100644
--- a/sc/source/core/data/dpcachetable.cxx
+++ b/sc/source/core/data/dpcachetable.cxx
@@ -389,7 +389,6 @@ void ScDPCacheTable::filterTable(const vector<Criterion>& rCriteria, Sequence< S
{
Any any;
bool bRepeatIfEmpty = rRepeatIfEmptyDims.count(nCol) > 0;
- // Wang Xu Ming - DataPilot migration
const ScDPItemData* pData= getCell(nCol, nRow, bRepeatIfEmpty);
if ( pData->IsValue() )
any <<= pData->GetValue();
diff --git a/sc/source/core/data/dpgroup.cxx b/sc/source/core/data/dpgroup.cxx
index d2892a8..9ef31d5 100644
--- a/sc/source/core/data/dpgroup.cxx
+++ b/sc/source/core/data/dpgroup.cxx
@@ -283,10 +283,7 @@ public:
ScDPGroupDateFilter(double fMatchValue, sal_Int32 nDatePart,
const Date* pNullDate, const ScDPNumGroupInfo* pNumInfo);
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
virtual bool match(const ScDPItemData & rCellData) const;
- // End Comments
private:
ScDPGroupDateFilter(); // disabled
@@ -550,11 +547,8 @@ BOOL lcl_DateContained( sal_Int32 nGroupPart, const ScDPItemData& rGroupData,
}
// no approxFloor needed, values were created from integers
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
sal_Int32 nGroupValue = (sal_Int32) rGroupData.GetValue();
sal_Int32 nBaseValue = (sal_Int32) rBaseData.GetValue();
-// End Comments
if ( nBasePart > nGroupPart )
{
// switch, so the base part is the smaller (inner) part
@@ -724,10 +718,7 @@ void ScDPGroupItem::FillGroupFilter( ScDPCacheTable::GroupFilter& rFilter )
cons
{
ScDPItemDataVec::const_iterator itrEnd = aElements.end();
for (ScDPItemDataVec::const_iterator itr = aElements.begin(); itr != itrEnd; ++itr)
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
rFilter.addMatchItem(itr->GetString(), itr->GetValue(), itr->IsValue());
-// End Comments
}
// -----------------------------------------------------------------------
@@ -789,8 +780,6 @@ void ScDPGroupDimension::SetGroupDim( long nDim )
{
nGroupDim = nDim;
}
-// Wang Xu Ming -- 2009-9-2
-// DataPilot Migration - Cache&&Performance
const std::vector< SCROW >& ScDPGroupDimension::GetColumnEntries( const ScDPCacheTable&
rCacheTable, const std::vector< SCROW >& rOriginal ) const
{
if ( maMemberEntries.empty() )
@@ -822,7 +811,6 @@ const std::vector< SCROW >& ScDPGroupDimension::GetColumnEntries( const ScDPCac
return maMemberEntries;
}
-// End Comments
const ScDPGroupItem* ScDPGroupDimension::GetGroupForData( const ScDPItemData& rData ) const
@@ -1086,7 +1074,6 @@ void ScDPGroupTableData::GetNumGroupInfo( long nDimension, ScDPNumGroupInfo&
rIn
rDecimal = pNumGroups[nDimension].GetDecSeparator();
}
}
-// Wang Xu Ming - DataPilot migration
long ScDPGroupTableData::GetMembersCount( long nDim )
{
const std::vector< SCROW >& members = GetColumnEntries( nDim );
@@ -1284,13 +1271,10 @@ void
ScDPGroupTableData::ModifyFilterCriteria(vector<ScDPCacheTable::Criterion>&
for (size_t i = 0; i < nGroupItemCount; ++i)
{
const ScDPGroupItem* pGrpItem = pGrpDim->GetGroupByIndex(i);
- // Wang Xu Ming -- 2009-6-9
- // DataPilot Migration
ScDPItemData aName(
pFilter->getMatchString(),pFilter->getMatchValue(),pFilter->hasValue()) ;
/*aName.aString = pFilter->getMatchString();
aName.fValue = pFilter->getMatchValue();
aName.bHasValue = pFilter->hasValue();*/
- // End Comments
if (!pGrpItem || !pGrpItem->GetName().IsCaseInsEqual(aName))
continue;
@@ -1408,12 +1392,9 @@ void ScDPGroupTableData::FillGroupValues( /*ScDPItemData* pItemData*/ SCROW*
pIt
sal_Int32 nPartValue = lcl_GetDatePartValue(
pData->GetValue(), pDateHelper->GetDatePart(), pDoc->GetFormatTable(),
&pDateHelper->GetNumInfo() );
-// Wang Xu Ming -- 2009-9-7
-// DataPilot Migration - Cache&&Performance
//String aName = lcl_GetDateGroupName( pDateHelper, nPartValue,
pDoc->GetFormatTable() );
ScDPItemData aItemData( pDateHelper->GetDatePart(), String(), nPartValue,
ScDPItemData::MK_DATA|ScDPItemData::MK_VAL|ScDPItemData::MK_DATEPART );
pItemDataIndex[nDim] = GetCacheTable().getCache()->GetAdditionalItemID( aItemData
);
-// End Comments
}
}
}
diff --git a/sc/source/core/data/dpobject.cxx b/sc/source/core/data/dpobject.cxx
index 3e43faf..9756b18 100644
--- a/sc/source/core/data/dpobject.cxx
+++ b/sc/source/core/data/dpobject.cxx
@@ -51,11 +51,8 @@
#include "attrib.hxx"
#include "scitems.hxx"
#include "unonames.hxx"
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
#include "dpglobal.hxx"
#include "globstr.hrc"
-// End Comments
#include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/sheet/GeneralFunction.hpp>
#include <com/sun/star/sheet/DataPilotFieldFilter.hpp>
@@ -175,8 +172,8 @@ ScDPObject::ScDPObject( ScDocument* pD ) :
bAllowMove( FALSE ),
nHeaderRows( 0 ),
mbHeaderLayout(false),
- bRefresh( FALSE ), // Wang Xu Ming - DataPilot migration
- mnCacheId( -1) // Wang Xu Ming - DataPilot migration
+ bRefresh( FALSE ),
+ mnCacheId( -1)
{
}
@@ -198,8 +195,8 @@ ScDPObject::ScDPObject(const ScDPObject& r) :
bAllowMove( FALSE ),
nHeaderRows( r.nHeaderRows ),
mbHeaderLayout( r.mbHeaderLayout ),
- bRefresh( r.bRefresh ), // Wang Xu Ming - DataPilot migration
- mnCacheId ( r.mnCacheId ) // Wang Xu Ming - DataPilot migration
+ bRefresh( r.bRefresh ),
+ mnCacheId ( r.mnCacheId )
{
if (r.pSaveData)
pSaveData = new ScDPSaveData(*r.pSaveData);
@@ -219,7 +216,7 @@ ScDPObject::~ScDPObject()
delete pSheetDesc;
delete pImpDesc;
delete pServDesc;
- mnCacheId = -1; // Wang Xu Ming - DataPilot migration
+ mnCacheId = -1;
InvalidateSource();
}
@@ -244,13 +241,10 @@ void ScDPObject::SetSaveData(const ScDPSaveData& rData)
{
delete pSaveData;
pSaveData = new ScDPSaveData( rData );
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
if ( rData.GetCacheId() >= 0 )
mnCacheId = rData.GetCacheId();
else if ( mnCacheId >= 0 )
pSaveData->SetCacheId( mnCacheId );
- // End Comments
}
InvalidateData(); // re-init source from SaveData
@@ -434,10 +428,7 @@ ScDPTableData* ScDPObject::GetTableData()
DBG_ERROR("no source descriptor");
pSheetDesc = new ScSheetSourceDesc; // dummy defaults
}
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
pData.reset(new ScSheetDPData(pDoc, *pSheetDesc, GetCacheId()));
- // End Comments
}
// grouping (for cell or database data)
@@ -448,11 +439,8 @@ ScDPTableData* ScDPObject::GetTableData()
pData = pGroupData;
}
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
if ( pData )
SetCacheId( pData->GetCacheId()); // resets mpTableData
- // End Comments
mpTableData = pData; // after SetCacheId
}
@@ -2549,8 +2537,6 @@ String ScDPCollection::CreateNewName( USHORT nMin ) const
return String(); // should not happen
}
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
long ScDPObject::GetCacheId() const
{
if ( GetSaveData() )
@@ -2619,7 +2605,6 @@ void ScDPObject::SetCacheId( long nCacheId )
mnCacheId = nCacheId;
}
}
-// End Comments
void ScDPCollection::FreeTable(ScDPObject* pDPObj)
{
diff --git a/sc/source/core/data/dpoutput.cxx b/sc/source/core/data/dpoutput.cxx
index a486c9c..50c7c75 100644
--- a/sc/source/core/data/dpoutput.cxx
+++ b/sc/source/core/data/dpoutput.cxx
@@ -56,11 +56,8 @@
#include "scresid.hxx"
#include "unonames.hxx"
#include "sc.hrc"
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
#include "scdpoutputimpl.hxx"
#include "dpglobal.hxx"
-// End Comments
#include <com/sun/star/beans/XPropertySet.hpp>
#include <vector>
@@ -639,20 +636,14 @@ void ScDPOutput::HeaderCell( SCCOL nCol, SCROW nRow, SCTAB nTab,
if ( nFlags & sheet::MemberResultFlags::SUBTOTAL )
{
// SvxWeightItem aItem( WEIGHT_BOLD ); // weight is in the style
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
OutputImpl outputimp( pDoc, nTab,
nTabStartCol, nTabStartRow, nMemberStartCol, nMemberStartRow,
nDataStartCol, nDataStartRow, nTabEndCol, nTabEndRow );
- // End Comments
//! limit frames to horizontal or vertical?
if (bColHeader)
{
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
//lcl_SetFrame( pDoc,nTab, nCol,nMemberStartRow+(SCROW)nLevel, nCol,nTabEndRow,
SC_DP_FRAME_INNER_BOLD );
outputimp.OutputBlockFrame( nCol,nMemberStartRow+(SCROW)nLevel, nCol,nDataStartRow-1 );
- // End Comments
lcl_SetStyleById( pDoc,nTab, nCol,nMemberStartRow+(SCROW)nLevel, nCol,nDataStartRow-1,
STR_PIVOT_STYLE_TITLE );
@@ -661,11 +652,8 @@ void ScDPOutput::HeaderCell( SCCOL nCol, SCROW nRow, SCTAB nTab,
}
else
{
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
//lcl_SetFrame( pDoc,nTab, nMemberStartCol+(USHORT)nLevel,nRow, nTabEndCol,nRow,
SC_DP_FRAME_INNER_BOLD );
outputimp.OutputBlockFrame( nMemberStartCol+(SCCOL)nLevel,nRow, nDataStartCol-1,nRow );
- // End Comments
lcl_SetStyleById( pDoc,nTab, nMemberStartCol+(SCCOL)nLevel,nRow, nDataStartCol-1,nRow,
STR_PIVOT_STYLE_TITLE );
lcl_SetStyleById( pDoc,nTab, nDataStartCol,nRow, nTabEndCol,nRow,
@@ -870,12 +858,9 @@ void ScDPOutput::Output()
STR_PIVOT_STYLE_INNER );
// output column headers:
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
OutputImpl outputimp( pDoc, nTab,
nTabStartCol, nTabStartRow, nMemberStartCol, nMemberStartRow,
nDataStartCol, nDataStartRow, nTabEndCol, nTabEndRow );
- // End Comments
for (nField=0; nField<nColFieldCount; nField++)
{
SCCOL nHdrCol = nDataStartCol + (SCCOL)nField; //! check for
overflow
@@ -890,8 +875,6 @@ void ScDPOutput::Output()
{
SCCOL nColPos = nDataStartCol + (SCCOL)nCol; //! check
for overflow
HeaderCell( nColPos, nRowPos, nTab, pArray[nCol], TRUE, nField );
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
if ( ( pArray[nCol].Flags & sheet::MemberResultFlags::HASMEMBER ) &&
!( pArray[nCol].Flags & sheet::MemberResultFlags::SUBTOTAL ) )
{
@@ -922,7 +905,6 @@ void ScDPOutput::Output()
}
if ( nField== 0 && nColFieldCount == 1 )
outputimp.OutputBlockFrame( nDataStartCol,nTabStartRow, nTabEndCol,nRowPos-1 );
- // End Comments
}
// output row headers:
@@ -955,8 +937,6 @@ void ScDPOutput::Output()
while ( nEnd+1 < nThisRowCount && ( pArray[nEnd+1].Flags &
sheet::MemberResultFlags::CONTINUE ) )
++nEnd;
SCROW nEndRowPos = nDataStartRow + (SCROW)nEnd; //! check for
overflow
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
// lcl_SetFrame( pDoc,nTab, nColPos,nRowPos, nColPos,nEndRowPos,
SC_DP_FRAME_INNER_BOLD );
//lcl_SetFrame( pDoc,nTab, nColPos,nRowPos, nTabEndCol,nEndRowPos,
SC_DP_FRAME_INNER_BOLD );
outputimp.AddRow( nRowPos );
@@ -969,25 +949,18 @@ void ScDPOutput::Output()
if ( nField == nRowFieldCount - 2 )
outputimp.OutputBlockFrame( nColPos+1, nRowPos, nColPos+1, nEndRowPos );
- // End Comments
lcl_SetStyleById( pDoc, nTab, nColPos,nRowPos, nDataStartCol-1,nEndRowPos,
STR_PIVOT_STYLE_CATEGORY );
}
else
lcl_SetStyleById( pDoc, nTab, nColPos,nRowPos, nDataStartCol-1,nRowPos,
STR_PIVOT_STYLE_CATEGORY );
}
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
else if ( pArray[nRow].Flags & sheet::MemberResultFlags::SUBTOTAL )
outputimp.AddRow( nRowPos );
- // End Comments
}
}
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
outputimp.OutputDataArea();
-// End Comments
}
ScRange ScDPOutput::GetOutputRange( sal_Int32 nRegionType )
diff --git a/sc/source/core/data/dpsave.cxx b/sc/source/core/data/dpsave.cxx
index 64eea08..5502e39 100644
--- a/sc/source/core/data/dpsave.cxx
+++ b/sc/source/core/data/dpsave.cxx
@@ -55,15 +55,12 @@
#include <com/sun/star/sheet/XMembersSupplier.hpp>
#include <com/sun/star/container/XNamed.hpp>
#include <com/sun/star/util/XCloneable.hpp>
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
#include "dptabsrc.hxx"
#include "dpglobal.hxx"
using namespace ScDPGlobal;
#include <com/sun/star/sheet/DataPilotFieldReferenceType.hpp>
#include <com/sun/star/sheet/DataPilotFieldReferenceItemType.hpp>
using namespace com::sun::star::sheet;
-// End Comments
#include <hash_map>
@@ -750,10 +747,7 @@ ScDPSaveData::ScDPSaveData() :
nRepeatEmptyMode( SC_DPSAVEMODE_DONTKNOW ),
bFilterButton( TRUE ),
bDrillDown( TRUE ),
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
mnCacheId( -1),
- // End Comments
mbDimensionMembersBuilt(false),
mpGrandTotalName(NULL)
{
@@ -766,10 +760,7 @@ ScDPSaveData::ScDPSaveData(const ScDPSaveData& r) :
nRepeatEmptyMode( r.nRepeatEmptyMode ),
bFilterButton( r.bFilterButton ),
bDrillDown( r.bDrillDown ),
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
mnCacheId( r.mnCacheId ),
- // End Comments
mbDimensionMembersBuilt(r.mbDimensionMembersBuilt),
mpGrandTotalName(NULL)
{
@@ -793,11 +784,8 @@ ScDPSaveData& ScDPSaveData::operator= ( const ScDPSaveData& r )
{
if ( &r != this )
{
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
this->~ScDPSaveData();
new( this ) ScDPSaveData ( r );
- // End Comments
}
return *this;
}
@@ -809,7 +797,7 @@ BOOL ScDPSaveData::operator== ( const ScDPSaveData& r ) const
nIgnoreEmptyMode != r.nIgnoreEmptyMode ||
nRepeatEmptyMode != r.nRepeatEmptyMode ||
bFilterButton != r.bFilterButton ||
- mnCacheId != r.mnCacheId ||/// Wang Xu Ming -- 2009-6-18 DataPilot Migration
+ mnCacheId != r.mnCacheId ||
bDrillDown != r.bDrillDown ||
mbDimensionMembersBuilt != r.mbDimensionMembersBuilt)
return FALSE;
@@ -1455,7 +1443,7 @@ void ScDPSaveDimension::Refresh( const com::sun::star::uno::Reference<
}
}
}
-// End Comments
+
bool operator == (const ::com::sun::star::sheet::DataPilotFieldSortInfo &l, const
::com::sun::star::sheet::DataPilotFieldSortInfo &r )
{
return l.Field == r.Field && l.IsAscending == r.IsAscending && l.Mode == r.Mode;
diff --git a/sc/source/core/data/dpsdbtab.cxx b/sc/source/core/data/dpsdbtab.cxx
index c956cc7..c31d53d 100644
--- a/sc/source/core/data/dpsdbtab.cxx
+++ b/sc/source/core/data/dpsdbtab.cxx
@@ -77,8 +77,6 @@ using ::com::sun::star::uno::UNO_QUERY;
#define SC_DBPROP_COMMAND "Command"
#define SC_DBPROP_COMMANDTYPE "CommandType"
// -----------------------------------------------------------------------
-// Wang Xu Ming -- 2009-9-15
-// DataPilot Migration - Cache&&Performance
ScDPTableDataCache* ScImportSourceDesc::GetExistDPObjectCache( ScDocument* pDoc ) const
{
ScDPTableDataCache* pCache = NULL;
@@ -236,7 +234,6 @@ long ScDatabaseDPData::GetColumnCount()
return GetCacheTable().getColSize();
}
-// End Comments
String ScDatabaseDPData::getDimensionName(long nColumn)
{
diff --git a/sc/source/core/data/dpshttab.cxx b/sc/source/core/data/dpshttab.cxx
index 0afce0b..902bef0 100644
--- a/sc/source/core/data/dpshttab.cxx
+++ b/sc/source/core/data/dpshttab.cxx
@@ -44,10 +44,7 @@
#include "dpcachetable.hxx"
#include "dpobject.hxx"
#include "globstr.hrc"
-// Wang Xu Ming -- 2009-8-17
-// DataPilot Migration - Cache&&Performance
#include "dpglobal.hxx"
-// End Comments
#include <com/sun/star/sheet/DataPilotFieldFilter.hpp>
#include <vector>
@@ -236,8 +233,6 @@ const ScDPCacheTable& ScSheetDPData::GetCacheTable() const
}
-// Wang Xu Ming -- 2009-8-5
-// DataPilot Migration - Cache&&Performance
ScDPTableDataCache* ScSheetSourceDesc::CreateCache( ScDocument* pDoc , long nID ) const
{
if ( pDoc )
@@ -304,7 +299,6 @@ ULONG ScSheetSourceDesc::CheckValidate( ScDocument* pDoc ) const
}
return 0;
}
-// End Comments
// -----------------------------------------------------------------------
diff --git a/sc/source/core/data/dptabdat.cxx b/sc/source/core/data/dptabdat.cxx
index 6b9a228..ddcbb31 100644
--- a/sc/source/core/data/dptabdat.cxx
+++ b/sc/source/core/data/dptabdat.cxx
@@ -188,8 +188,6 @@ void ScDPTableData::FillRowDataFromCacheTable(sal_Int32 nRow, const ScDPCacheTab
void ScDPTableData::ProcessRowData(CalcInfo& rInfo, CalcRowData& rData, bool bAutoShow)
{
- // Wang Xu Ming -- 2009-6-16
- // DataPilot Migration
if (!bAutoShow)
{
LateInitParams aColParams( rInfo.aColDims, rInfo.aColLevels, FALSE );
@@ -203,7 +201,6 @@ void ScDPTableData::ProcessRowData(CalcInfo& rInfo, CalcRowData& rData, bool bAu
rInfo.pColRoot->LateInitFrom( aColParams, rData.aColData,0, *rInfo.pInitState);
rInfo.pRowRoot->LateInitFrom( aRowParams, rData.aRowData, 0, *rInfo.pInitState);
}
- // End Comments
if ( ( !rInfo.pColRoot->GetChildDimension() ||
rInfo.pColRoot->GetChildDimension()->IsValidEntry(rData.aColData) ) &&
( !rInfo.pRowRoot->GetChildDimension() ||
rInfo.pRowRoot->GetChildDimension()->IsValidEntry(rData.aRowData) ) )
@@ -211,11 +208,8 @@ void ScDPTableData::ProcessRowData(CalcInfo& rInfo, CalcRowData& rData, bool
bAu
//! single process method with ColMembers, RowMembers and data !!!
if (rInfo.pColRoot->GetChildDimension())
{
-// Wang Xu Ming -- 2009-6-10
-// DataPilot Migration
vector</*ScDPItemData*/ SCROW > aEmptyData;
rInfo.pColRoot->GetChildDimension()->ProcessData(rData.aColData, NULL, aEmptyData,
rData.aValues);
-// End Comments
}
rInfo.pRowRoot->ProcessData(rData.aRowData, rInfo.pColRoot->GetChildDimension(),
@@ -237,11 +231,8 @@ void ScDPTableData::CalcResultsFromCacheTable(const ScDPCacheTable&
rCacheTable,
}
}
-// Wang Xu Ming -- 2009-6-10
-// DataPilot Migration
void ScDPTableData::GetItemData(const ScDPCacheTable& rCacheTable, sal_Int32 nRow,
const vector<long>& rDims, vector< SCROW/*ScDPItemData*/>&
rItemData)
-// End Comments
{
sal_Int32 nDimSize = rDims.size();
for (sal_Int32 i = 0; i < nDimSize; ++i)
@@ -266,8 +257,6 @@ void ScDPTableData::GetItemData(const ScDPCacheTable& rCacheTable, sal_Int32 nRo
// -----------------------------------------------------------------------
-// Wang Xu Ming -- 2009-6-8
-// DataPilot Migration
long ScDPTableData::GetMembersCount( long nDim )
{
if ( nDim > MAXCOL )
@@ -326,7 +315,6 @@ long ScDPTableData::GetSourceDim( long nDim )
else
return -1;
}
-// End Comments
// -----------------------------------------------------------------------
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/core/data/dptabres.cxx b/sc/source/core/data/dptabres.cxx
index f7e7eca..f829299 100644
--- a/sc/source/core/data/dptabres.cxx
+++ b/sc/source/core/data/dptabres.cxx
@@ -232,14 +232,12 @@ BOOL ScDPRowMembersOrder::operator()( sal_Int32 nIndex1, sal_Int32 nIndex2 )
con
{
const ScDPResultMember* pMember1 = rDimension.GetMember(nIndex1);
const ScDPResultMember* pMember2 = rDimension.GetMember(nIndex2);
-// Wang Xu Ming -- 3/17/2009
// make the hide item to the largest order.
if ( !pMember1->IsVisible() || !pMember2->IsVisible() )
return pMember1->IsVisible();
const ScDPDataMember* pDataMember1 = pMember1->GetDataRoot() ;
const ScDPDataMember* pDataMember2 = pMember2->GetDataRoot();
-// End Comments
// GetDataRoot can be NULL if there was no data.
// IsVisible == FALSE can happen after AutoShow.
return lcl_IsLess( pDataMember1, pDataMember2, nMeasure, bAscending );
@@ -249,12 +247,10 @@ BOOL ScDPColMembersOrder::operator()( sal_Int32 nIndex1, sal_Int32 nIndex2 )
con
{
ScDPDataMember* pDataMember1 = rDimension.GetMember(nIndex1);
ScDPDataMember* pDataMember2 = rDimension.GetMember(nIndex2);
- // Wang Xu Ming -- 2009-6-17
BOOL bHide1 = pDataMember1 && !pDataMember1->IsVisible();
BOOL bHide2 = pDataMember2 && !pDataMember2->IsVisible();
if ( bHide1 || bHide2 )
return !bHide1;
- // End Comments
return lcl_IsLess( pDataMember1, pDataMember2, nMeasure, bAscending );
}
@@ -1099,7 +1095,6 @@ void ScDPResultMember::InitFrom( const vector<ScDPDimension*>& ppDim, const
vect
// skip child dimension if details are not shown
if ( GetDPMember() && !GetDPMember()->getShowDetails() )
{
- // Wang Xu Ming -- 2009-6-16
// Show DataLayout dimention
nMemberStep = 1;
while ( nPos < ppDim.size() )
@@ -1117,7 +1112,6 @@ void ScDPResultMember::InitFrom( const vector<ScDPDimension*>& ppDim, const
vect
nMemberStep ++;
}
}
- // End Comments
bHasHiddenDetails = TRUE; // only if there is a next dimension
return;
}
@@ -1146,8 +1140,6 @@ void ScDPResultMember::LateInitFrom( LateInitParams& rParams/*const
vector<ScDPD
// skip child dimension if details are not shown
if ( GetDPMember() && !GetDPMember()->getShowDetails() )
{
- // Wang Xu Ming -- 2009-6-16
- // DataPilot Migration
// Show DataLayout dimention
nMemberStep = 1;
while ( !rParams.IsEnd( nPos ) )
@@ -1171,7 +1163,6 @@ void ScDPResultMember::LateInitFrom( LateInitParams& rParams/*const
vector<ScDPD
nMemberStep ++;
}
}
- // End Comments
bHasHiddenDetails = TRUE; // only if there is a next dimension
return;
}
@@ -2658,10 +2649,7 @@ private:
BOOL bIncludeAll;
BOOL bIsBase;
long nGroupBase;
- // Wang Xu Ming -- 2009-8-6
- // DataPilot Migration - Cache&&Performance
SCROW nBaseDataId;
- // End Comments
public:
ScDPGroupCompare( const ScDPResultData* pData, const ScDPInitState& rState, long
nDimension );
~ScDPGroupCompare() {}
@@ -2851,7 +2839,6 @@ void ScDPResultDimension::InitFrom( const vector<ScDPDimension*>& ppDim,
const v
void ScDPResultDimension::LateInitFrom( LateInitParams& rParams/* const vector<ScDPDimension*>&
ppDim, const vector<ScDPLevel*>& ppLev*/,
const vector<SCROW>& pItemData, size_t nPos,
ScDPInitState& rInitState )
-// End Comments
{
if ( rParams.IsEnd( nPos ) )
return;
@@ -3928,8 +3915,6 @@ size_t ScDPResultVisibilityData::MemberHash::operator() (const ScDPItemData&
r)
else
return rtl_ustr_hashCode_WithLength(r.GetString().GetBuffer(), r.GetString().Len());
}
-// Wang Xu Ming -- 2009-6-10
-// DataPilot Migration
SCROW ScDPResultMember::GetDataId( ) const
{
const ScDPMember* pMemberDesc = GetDPMember();
@@ -4051,9 +4036,6 @@ BOOL LateInitParams::IsEnd( size_t nPos ) const
return nPos >= mppDim.size();
}
-// End Comments
-// Wang Xu Ming -- 2009-8-4
-// DataPilot Migration - old defects merge
void ScDPResultDimension::CheckShowEmpty( BOOL bShow )
{
long nCount = maMemberArray.size();
@@ -4086,6 +4068,6 @@ void ScDPResultMember::CheckShowEmpty( BOOL bShow )
pChildDim->CheckShowEmpty( TRUE );
}
}
-}// End Comments
+}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/core/data/dptabsrc.cxx b/sc/source/core/data/dptabsrc.cxx
index 653446d..ff7c1e4 100644
--- a/sc/source/core/data/dptabsrc.cxx
+++ b/sc/source/core/data/dptabsrc.cxx
@@ -304,7 +304,6 @@ void ScDPSource::SetOrientation(long nColumn, USHORT nNew)
// DataPilot Migration - Cache&&Performance
case sheet::DataPilotFieldOrientation_HIDDEN:
break;
- // End Comments
default:
DBG_ERROR( "ScDPSource::SetOrientation: unexpected orientation" );
break;
@@ -2386,7 +2385,6 @@ ScDPMembers::ScDPMembers( ScDPSource* pSrc, long nD, long nH, long nL ) :
{
case SC_DAPI_LEVEL_YEAR:
{
- // Wang Xu Ming - DataPilot migration
const ScDPItemData* pLastNumData = NULL;
for ( SCROW n = 0 ;n <GetSrcItemsCount() ; n-- )
{
@@ -2396,7 +2394,6 @@ ScDPMembers::ScDPMembers( ScDPSource* pSrc, long nD, long nH, long nL ) :
else
pLastNumData = pData;
}
- // End Comments
if ( pLastNumData )
{
@@ -2586,13 +2583,11 @@ ScDPMember* ScDPMembers::getByIndex(long nIndex) const
{
//! cache year range here!
- // Wang Xu Ming - DataPilot migration
double fFirstVal = pSource->GetData()->GetMemberByIndex( nSrcDim, 0
)->GetValue();
long nFirstYear = pSource->GetData()->GetDatePart(
(long)::rtl::math::approxFloor( fFirstVal ),
nHier, nLev );
- // End Comments
nVal = nFirstYear + nIndex;
}
else if ( nHier == SC_DAPI_HIERARCHY_WEEK && nLev == SC_DAPI_LEVEL_WEEKDAY )
@@ -2877,6 +2872,5 @@ const ScDPItemData* ScDPMembers::GetSrcItemDataByIndex( SCROW nIndex)
{
return pSource->GetData()->GetColumnEntries( nDim ).size();
}
-// End Comments
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/core/data/global2.cxx b/sc/source/core/data/global2.cxx
index 19e2eaa..0829b1c 100644
--- a/sc/source/core/data/global2.cxx
+++ b/sc/source/core/data/global2.cxx
@@ -48,10 +48,7 @@
#include "rechead.hxx"
#include "compiler.hxx"
#include "paramisc.hxx"
-// Wang Xu Ming -- 2009-5-18
-// DataPilot Migration
#include "dpglobal.hxx"
-// End Comments
#include "sc.hrc"
#include "globstr.hrc"
diff --git a/sc/source/filter/excel/xepivot.cxx b/sc/source/filter/excel/xepivot.cxx
index 84d3c15..232b699 100644
--- a/sc/source/filter/excel/xepivot.cxx
+++ b/sc/source/filter/excel/xepivot.cxx
@@ -539,8 +539,6 @@ void XclExpPCField::InsertNumDateGroupItems( const ScDPObject& rDPObj, const ScD
{
// get the string collection with original source elements
ScSheetDPData aDPData( GetDocPtr(), *pSrcDesc );
- // Wang Xu Ming - DataPilot migration
- // 2009-05-08
const std::vector< SCROW > aOrignial = aDPData.GetColumnEntries( static_cast< long >(
GetBaseFieldIndex() ) );
// get the string collection with generated grouping elements
ScDPNumGroupDimension aTmpDim( rNumInfo );
@@ -553,7 +551,6 @@ void XclExpPCField::InsertNumDateGroupItems( const ScDPObject& rDPObj, const ScD
if ( pData )
InsertGroupItem( new XclExpPCItem( pData->GetString() ) );
}
-// End Comments
}
}
diff --git a/sc/source/ui/inc/dbfunc.hxx b/sc/source/ui/inc/dbfunc.hxx
index 5054f1f..c43ea21 100644
--- a/sc/source/ui/inc/dbfunc.hxx
+++ b/sc/source/ui/inc/dbfunc.hxx
@@ -86,10 +86,7 @@ public:
bool MakePivotTable( const ScDPSaveData& rData, const ScRange& rDest, BOOL
bNewTable,
const ScDPObject& rSource, BOOL bApi = FALSE );
void DeletePivotTable();
- // Wang Xu Ming -- 2009-6-17
- // DataPilot Migration
ULONG RecalcPivotTable();
- // End Comments
BOOL HasSelectionForDateGroup( ScDPNumGroupInfo& rOldInfo, sal_Int32& rParts );
BOOL HasSelectionForNumGroup( ScDPNumGroupInfo& rOldInfo );
void GroupDataPilot();
diff --git a/sc/source/ui/view/dbfunc3.cxx b/sc/source/ui/view/dbfunc3.cxx
index 6cd757b..50200b9 100644
--- a/sc/source/ui/view/dbfunc3.cxx
+++ b/sc/source/ui/view/dbfunc3.cxx
@@ -737,8 +737,6 @@ ULONG ScDBFunc::RecalcPivotTable()
GetViewData()->GetTabNo() );
if ( pDPObj )
{
- // Wang Xu Ming -- 2009-6-17
- // DataPilot Migration
//ScDBDocFunc aFunc( *pDocSh );
//aFunc.DataPilotUpdate( pDPObj, pDPObj, TRUE, FALSE );
//CursorPosChanged(); // shells may be switched
@@ -752,7 +750,6 @@ ULONG ScDBFunc::RecalcPivotTable()
else if (nErrId <= USHRT_MAX)
ErrorMessage(static_cast<USHORT>(nErrId));
return nErrId;
- // End Comments
}
else
ErrorMessage(STR_PIVOT_NOTFOUND);
--
1.7.0.4
Context
- [Libreoffice] [PATCH] Removed unnecessary comments · Christina Roßmanith
Privacy Policy |
Impressum (Legal Info) |
Copyright information: Unless otherwise specified, all text and images
on this website are licensed under the
Creative Commons Attribution-Share Alike 3.0 License.
This does not include the source code of LibreOffice, which is
licensed under the Mozilla Public License (
MPLv2).
"LibreOffice" and "The Document Foundation" are
registered trademarks of their corresponding registered owners or are
in actual use as trademarks in one or more countries. Their respective
logos and icons are also subject to international copyright laws. Use
thereof is explained in our
trademark policy.