LibreOffice Module sc (master) 1
|
#include <dptabres.hxx>
Public Types | |
typedef std::vector< std::unique_ptr< ScDPResultMember > > | MemberArray |
typedef std::map< SCROW, ScDPResultMember * > | MemberHash |
Public Member Functions | |
ScDPResultDimension (const ScDPResultData *pData) | |
~ScDPResultDimension () | |
void | InitFrom (const ::std::vector< ScDPDimension * > &ppDim, const ::std::vector< ScDPLevel * > &ppLev, size_t nPos, ScDPInitState &rInitState, bool bInitChild=true) |
void | LateInitFrom (LateInitParams &rParams, const ::std::vector< SCROW > &pItemData, size_t nPos, ScDPInitState &rInitState) |
void | CheckShowEmpty (bool bShow=false) |
tools::Long | GetSize (tools::Long nMeasure) const |
bool | IsValidEntry (const ::std::vector< SCROW > &aMembers) const |
void | ProcessData (const ::std::vector< SCROW > &aMembers, const ScDPResultDimension *pDataDim, const ::std::vector< SCROW > &aDataMembers, const ::std::vector< ScDPValue > &aValues) const |
void | FillMemberResults (css::uno::Sequence< css::sheet::MemberResult > *pSequences, tools::Long nStart, tools::Long nMeasure) |
Test. More... | |
void | FillDataResults (const ScDPResultMember *pRefMember, ScDPResultFilterContext &rFilterCxt, css::uno::Sequence< css::uno::Sequence< css::sheet::DataResult > > &rSequence, tools::Long nMeasure) const |
void | UpdateDataResults (const ScDPResultMember *pRefMember, tools::Long nMeasure) const |
void | UpdateRunningTotals (const ScDPResultMember *pRefMember, tools::Long nMeasure, ScDPRunningTotalState &rRunning, ScDPRowTotals &rTotals) const |
void | SortMembers (ScDPResultMember *pRefMember) |
tools::Long | GetSortedIndex (tools::Long nUnsorted) const |
void | DoAutoShow (ScDPResultMember *pRefMember) |
void | ResetResults () |
ScDPDataMember * | GetRowReferenceMember (const ScDPRelativePos *pMemberPos, const OUString *pName, const sal_Int32 *pRowIndexes, const sal_Int32 *pColIndexes) const |
void | DumpState (const ScDPResultMember *pRefMember, ScDocument *pDoc, ScAddress &rPos) const |
void | Dump (int nIndent) const |
tools::Long | GetMemberCount () const |
const ScDPResultMember * | GetMember (tools::Long n) const |
ScDPResultMember * | GetMember (tools::Long n) |
const ScMemberSortOrder & | GetMemberOrder () const |
ScMemberSortOrder & | GetMemberOrder () |
bool | IsDataLayout () const |
const OUString & | GetName () const |
bool | IsSortByData () const |
bool | IsSortAscending () const |
tools::Long | GetSortMeasure () const |
bool | IsAutoShow () const |
bool | IsAutoTopItems () const |
tools::Long | GetAutoMeasure () const |
tools::Long | GetAutoCount () const |
ScDPResultDimension * | GetFirstChildDimension () const |
void | FillVisibilityData (ScDPResultVisibilityData &rData) const |
Static Public Member Functions | |
static ScDPDataMember * | GetColReferenceMember (const ScDPRelativePos *pMemberPos, const OUString *pName, sal_Int32 nRefDimPos, const ScDPRunningTotalState &rRunning) |
Private Member Functions | |
ScDPResultMember * | FindMember (SCROW iData) const |
ScDPResultMember * | AddMember (const ScDPParentDimData &aData) |
ScDPResultMember * | InsertMember (const ScDPParentDimData *pMemberData) |
void | InitWithMembers (LateInitParams &rParams, const ::std::vector< SCROW > &pItemData, size_t nPos, ScDPInitState &rInitState) |
Private Attributes | |
const ScDPResultData * | pResultData |
MemberArray | maMemberArray |
MemberHash | maMemberHash |
OUString | aDimensionName |
tools::Long | nSortMeasure |
or ptr to IntDimension? More... | |
ScMemberSortOrder | aMemberOrder |
bool | bIsDataLayout:1 |
bool | bSortByData:1 |
or ptr to IntDimension? More... | |
bool | bSortAscending:1 |
bool | bAutoShow:1 |
bool | bAutoTopItems:1 |
bool | bInitialized:1 |
tools::Long | nAutoMeasure |
tools::Long | nAutoCount |
Definition at line 486 of file dptabres.hxx.
typedef std::vector<std::unique_ptr<ScDPResultMember> > ScDPResultDimension::MemberArray |
Definition at line 489 of file dptabres.hxx.
Definition at line 490 of file dptabres.hxx.
ScDPResultDimension::ScDPResultDimension | ( | const ScDPResultData * | pData | ) |
Definition at line 2755 of file dptabres.cxx.
References pData.
ScDPResultDimension::~ScDPResultDimension | ( | ) |
Definition at line 2769 of file dptabres.cxx.
|
private |
Definition at line 3974 of file dptabres.cxx.
References aData, and ScDPResultMember::GetDataId().
Referenced by InitFrom(), and LateInitFrom().
void ScDPResultDimension::CheckShowEmpty | ( | bool | bShow = false | ) |
Definition at line 4084 of file dptabres.cxx.
References ScDPResultMember::CheckShowEmpty(), i, maMemberArray, and nCount.
Referenced by ScDPResultMember::CheckShowEmpty().
void ScDPResultDimension::DoAutoShow | ( | ScDPResultMember * | pRefMember | ) |
Definition at line 3152 of file dptabres.cxx.
References bAutoShow, bAutoTopItems, bIsDataLayout, ScDPResultMember::DoAutoShow(), ScDPResultMember::GetDataRoot(), i, ScDPResultMember::IsVisible(), lcl_IsEqual(), maMemberArray, nAutoCount, nAutoMeasure, nCount, nPos, and ScDPResultMember::SetAutoHidden().
void ScDPResultDimension::Dump | ( | int | nIndent | ) | const |
void ScDPResultDimension::DumpState | ( | const ScDPResultMember * | pRefMember, |
ScDocument * | pDoc, | ||
ScAddress & | rPos | ||
) | const |
void ScDPResultDimension::FillDataResults | ( | const ScDPResultMember * | pRefMember, |
ScDPResultFilterContext & | rFilterCxt, | ||
css::uno::Sequence< css::uno::Sequence< css::sheet::DataResult > > & | rSequence, | ||
tools::Long | nMeasure | ||
) | const |
Definition at line 3072 of file dptabres.cxx.
References aMemberOrder, bIsDataLayout, ScDPResultMember::FillDataResults(), ScDPResultData::GetMeasureCount(), GetName(), i, ScDPResultMember::IsVisible(), ScDPResultFilterContext::maFilters, maMemberArray, nCount, pResultData, and SC_DPMEASURE_ALL.
void ScDPResultDimension::FillMemberResults | ( | css::uno::Sequence< css::sheet::MemberResult > * | pSequences, |
tools::Long | nStart, | ||
tools::Long | nMeasure | ||
) |
Test.
Definition at line 3045 of file dptabres.cxx.
References aMemberOrder, bIsDataLayout, ScDPResultMember::FillMemberResults(), ScDPResultData::GetMeasureDimensionName(), ScDPResultData::GetMeasureString(), i, ScDPResultMember::IsVisible(), maMemberArray, nCount, nPos, pResultData, and SUBTOTAL_FUNC_NONE.
void ScDPResultDimension::FillVisibilityData | ( | ScDPResultVisibilityData & | rData | ) | const |
Definition at line 3523 of file dptabres.cxx.
References ScDPResultVisibilityData::addVisibleMember(), ScDPResultMember::FillItemData(), ScDPResultMember::FillVisibilityData(), GetName(), IsDataLayout(), ScDPResultMember::IsValid(), and maMemberArray.
|
private |
Definition at line 2773 of file dptabres.cxx.
References bIsDataLayout, i, ScDPResultMember::IsNamedItem(), maMemberArray, maMemberHash, nCount, and SAL_WARN_IF.
Referenced by IsValidEntry(), LateInitFrom(), and ProcessData().
|
inline |
Definition at line 593 of file dptabres.hxx.
References nAutoCount.
Referenced by ScDPDataDimension::DoAutoShow().
|
inline |
Definition at line 592 of file dptabres.hxx.
References nAutoMeasure.
Referenced by ScDPDataDimension::DoAutoShow().
|
static |
Definition at line 3350 of file dptabres.cxx.
References ScDPResultMember::GetChildDimension(), ScDPDataMember::GetChildDimension(), ScDPRunningTotalState::GetColSorted(), ScDPResultMember::GetDataRoot(), GetMember(), ScDPDataDimension::GetMember(), GetMemberCount(), ScDPDataDimension::GetMemberCount(), ScDPDataMember::GetName(), ScDPRunningTotalState::GetRowResRoot(), ScDPRunningTotalState::GetRowSorted(), ScDPDataDimension::GetSortedIndex(), ScDPDataMember::HasHiddenDetails(), ScDPDataMember::IsVisible(), ScDPRelativePos::nBasePos, ScDPRelativePos::nDirection, and pName.
Referenced by ScDPDataMember::UpdateRunningTotals().
ScDPResultDimension * ScDPResultDimension::GetFirstChildDimension | ( | ) | const |
Definition at line 3515 of file dptabres.cxx.
References maMemberArray.
Referenced by ScDPResultMember::FillMemberResults().
ScDPResultMember * ScDPResultDimension::GetMember | ( | tools::Long | n | ) |
Definition at line 3510 of file dptabres.cxx.
References maMemberArray, and n.
const ScDPResultMember * ScDPResultDimension::GetMember | ( | tools::Long | n | ) | const |
Definition at line 3506 of file dptabres.cxx.
References maMemberArray, and n.
Referenced by ScDPDataDimension::DoAutoShow(), ScDPDataDimension::FillDataRow(), GetColReferenceMember(), GetRowReferenceMember(), ScDPDataDimension::InitFrom(), ScDPDataDimension::SortMembers(), ScDPDataDimension::UpdateDataRow(), ScDPDataDimension::UpdateRunningTotals(), and ScDPDataMember::UpdateRunningTotals().
tools::Long ScDPResultDimension::GetMemberCount | ( | ) | const |
Definition at line 3501 of file dptabres.cxx.
References maMemberArray.
Referenced by ScDPDataDimension::DoAutoShow(), ScDPDataDimension::FillDataRow(), GetColReferenceMember(), GetRowReferenceMember(), ScDPDataDimension::InitFrom(), ScDPDataDimension::SortMembers(), ScDPDataDimension::UpdateDataRow(), and ScDPDataDimension::UpdateRunningTotals().
|
inline |
Definition at line 581 of file dptabres.hxx.
References aMemberOrder.
|
inline |
Definition at line 580 of file dptabres.hxx.
References aMemberOrder.
Referenced by ScDPDataDimension::FillDataRow(), ScDPDataDimension::GetSortedIndex(), ScDPDataDimension::SortMembers(), and ScDPDataDimension::UpdateRunningTotals().
|
inline |
Definition at line 584 of file dptabres.hxx.
References aDimensionName.
Referenced by FillDataResults(), ScDPDataDimension::FillDataRow(), FillVisibilityData(), IsValidEntry(), and ScDPDataMember::UpdateRunningTotals().
ScDPDataMember * ScDPResultDimension::GetRowReferenceMember | ( | const ScDPRelativePos * | pMemberPos, |
const OUString * | pName, | ||
const sal_Int32 * | pRowIndexes, | ||
const sal_Int32 * | pColIndexes | ||
) | const |
Definition at line 3260 of file dptabres.cxx.
References ScDPResultMember::GetChildDimension(), ScDPDataMember::GetChildDimension(), ScDPResultMember::GetDataRoot(), GetMember(), ScDPDataDimension::GetMember(), GetMemberCount(), ScDPResultMember::GetName(), GetSortedIndex(), ScDPResultMember::HasHiddenDetails(), ScDPResultMember::IsVisible(), maMemberArray, ScDPRelativePos::nBasePos, ScDPRelativePos::nDirection, and pName.
Referenced by ScDPDataMember::UpdateRunningTotals().
tools::Long ScDPResultDimension::GetSize | ( | tools::Long | nMeasure | ) | const |
Definition at line 2984 of file dptabres.cxx.
References bIsDataLayout, ScDPResultData::GetMeasureCount(), GetSize(), maMemberArray, pResultData, and SC_DPMEASURE_ALL.
Referenced by GetSize().
tools::Long ScDPResultDimension::GetSortedIndex | ( | tools::Long | nUnsorted | ) | const |
Definition at line 3223 of file dptabres.cxx.
References aMemberOrder.
Referenced by GetRowReferenceMember().
|
inline |
Definition at line 588 of file dptabres.hxx.
References nSortMeasure.
Referenced by ScDPDataDimension::SortMembers().
void ScDPResultDimension::InitFrom | ( | const ::std::vector< ScDPDimension * > & | ppDim, |
const ::std::vector< ScDPLevel * > & | ppLev, | ||
size_t | nPos, | ||
ScDPInitState & | rInitState, | ||
bool | bInitChild = true |
||
) |
Definition at line 2799 of file dptabres.cxx.
References aData, AddMember(), ScDPInitState::AddMember(), aDimensionName, bAutoShow, bAutoTopItems, bInitialized, bIsDataLayout, bSortAscending, bSortByData, ScDPLevel::GetAutoMeasure(), ScDPLevel::GetAutoShow(), ScDPMembers::getByIndex(), ScDPMembers::getCount(), ScDPResultMember::GetDataId(), ScDPDimension::GetDimension(), ScDPLevel::GetGlobalOrder(), ScDPDimension::getIsDataLayoutDimension(), ScDPLevel::GetMembersObject(), ScDPDimension::getName(), ScDPLevel::GetSortInfo(), ScDPLevel::GetSortMeasure(), i, ScDPResultMember::InitFrom(), nAutoCount, nAutoMeasure, nPos, nSortMeasure, pResultData, and ScDPInitState::RemoveMember().
|
private |
Definition at line 3999 of file dptabres.cxx.
References ScDPInitState::AddMember(), ResultMembers::FindMember(), ScDPResultMember::GetDataId(), LateInitParams::GetDim(), ScDPDimension::GetDimension(), LateInitParams::GetLevel(), LateInitParams::IsEnd(), ScDPResultMember::LateInitFrom(), ScDPParentDimData::mpMemberDesc, nPos, and ScDPInitState::RemoveMember().
Referenced by LateInitFrom().
|
private |
Definition at line 3984 of file dptabres.cxx.
References ScDPMember::GetItemDataId(), ScDPParentDimData::mnOrder, and ScDPParentDimData::mpMemberDesc.
|
inline |
Definition at line 590 of file dptabres.hxx.
References bAutoShow.
Referenced by ScDPDataDimension::DoAutoShow().
|
inline |
Definition at line 591 of file dptabres.hxx.
References bAutoTopItems.
Referenced by ScDPDataDimension::DoAutoShow().
|
inline |
Definition at line 583 of file dptabres.hxx.
References bIsDataLayout.
Referenced by ScDPDataDimension::FillDataRow(), ScDPResultMember::FillMemberResults(), FillVisibilityData(), and ScDPDataDimension::InitFrom().
|
inline |
Definition at line 587 of file dptabres.hxx.
References bSortAscending.
Referenced by ScDPDataDimension::SortMembers().
|
inline |
Definition at line 586 of file dptabres.hxx.
References bSortByData.
Referenced by ScDPDataDimension::SortMembers().
bool ScDPResultDimension::IsValidEntry | ( | const ::std::vector< SCROW > & | aMembers | ) | const |
Definition at line 3007 of file dptabres.cxx.
References FindMember(), GetName(), ScDPResultMember::IsValidEntry(), and SAL_INFO.
Referenced by ScDPResultMember::IsValidEntry(), and ScDPTableData::ProcessRowData().
void ScDPResultDimension::LateInitFrom | ( | LateInitParams & | rParams, |
const ::std::vector< SCROW > & | pItemData, | ||
size_t | nPos, | ||
ScDPInitState & | rInitState | ||
) |
Definition at line 2867 of file dptabres.cxx.
References aData, AddMember(), ScDPInitState::AddMember(), aDimensionName, bAutoShow, bAutoTopItems, bInitialized, bIsDataLayout, bSortAscending, bSortByData, FindMember(), ScDPLevel::GetAutoMeasure(), ScDPLevel::GetAutoShow(), ScDPMembers::getByIndex(), ScDPMembers::getCount(), ScDPResultMember::GetDataId(), LateInitParams::GetDim(), ScDPDimension::GetDimension(), ScDPResultData::GetDimResultMembers(), ScDPLevel::GetGlobalOrder(), LateInitParams::GetInitAllChild(), ScDPDimension::getIsDataLayoutDimension(), LateInitParams::GetLevel(), ScDPLevel::GetMembersObject(), ScDPDimension::getName(), ScDPLevel::getShowEmpty(), ScDPLevel::GetSortInfo(), ScDPLevel::GetSortMeasure(), i, InitWithMembers(), LateInitParams::IsEnd(), ResultMembers::IsHasHideDetailsMembers(), ScDPResultMember::IsNamedItem(), LateInitParams::IsRow(), ScDPResultMember::LateInitFrom(), maMemberArray, nAutoCount, nAutoMeasure, nCount, nPos, nSortMeasure, pResultData, ScDPInitState::RemoveMember(), SAL_INFO, SAL_WARN, ResultMembers::SetHasHideDetailsMembers(), and LateInitParams::SetInitAllChildren().
void ScDPResultDimension::ProcessData | ( | const ::std::vector< SCROW > & | aMembers, |
const ScDPResultDimension * | pDataDim, | ||
const ::std::vector< SCROW > & | aDataMembers, | ||
const ::std::vector< ScDPValue > & | aValues | ||
) | const |
Definition at line 3021 of file dptabres.cxx.
References FindMember(), and ScDPResultMember::ProcessData().
Referenced by ScDPTableData::ProcessRowData().
void ScDPResultDimension::ResetResults | ( | ) |
Definition at line 3212 of file dptabres.cxx.
References bIsDataLayout, i, maMemberArray, nCount, and ScDPResultMember::ResetResults().
void ScDPResultDimension::SortMembers | ( | ScDPResultMember * | pRefMember | ) |
Definition at line 3123 of file dptabres.cxx.
References aMemberOrder, bIsDataLayout, bSortAscending, bSortByData, i, ScDPResultMember::IsVisible(), maMemberArray, nCount, nPos, nSortMeasure, and ScDPResultMember::SortMembers().
void ScDPResultDimension::UpdateDataResults | ( | const ScDPResultMember * | pRefMember, |
tools::Long | nMeasure | ||
) | const |
Definition at line 3101 of file dptabres.cxx.
References bIsDataLayout, ScDPResultData::GetMeasureCount(), i, ScDPResultMember::IsVisible(), maMemberArray, nCount, pResultData, SC_DPMEASURE_ALL, and ScDPResultMember::UpdateDataResults().
void ScDPResultDimension::UpdateRunningTotals | ( | const ScDPResultMember * | pRefMember, |
tools::Long | nMeasure, | ||
ScDPRunningTotalState & | rRunning, | ||
ScDPRowTotals & | rTotals | ||
) | const |
Definition at line 3228 of file dptabres.cxx.
References ScDPRunningTotalState::AddRowIndex(), aMemberOrder, bIsDataLayout, ScDPResultData::GetMeasureCount(), i, ScDPResultMember::IsVisible(), maMemberArray, nCount, pResultData, ScDPRunningTotalState::RemoveRowIndex(), SC_DPMEASURE_ALL, and ScDPResultMember::UpdateRunningTotals().
|
private |
Definition at line 495 of file dptabres.hxx.
Referenced by GetName(), InitFrom(), and LateInitFrom().
|
private |
Definition at line 497 of file dptabres.hxx.
Referenced by FillDataResults(), FillMemberResults(), GetMemberOrder(), GetSortedIndex(), SortMembers(), and UpdateRunningTotals().
|
private |
Definition at line 501 of file dptabres.hxx.
Referenced by DoAutoShow(), InitFrom(), IsAutoShow(), and LateInitFrom().
|
private |
Definition at line 502 of file dptabres.hxx.
Referenced by DoAutoShow(), InitFrom(), IsAutoTopItems(), and LateInitFrom().
|
private |
Definition at line 503 of file dptabres.hxx.
Referenced by InitFrom(), and LateInitFrom().
|
private |
Definition at line 498 of file dptabres.hxx.
Referenced by DoAutoShow(), FillDataResults(), FillMemberResults(), FindMember(), GetSize(), InitFrom(), IsDataLayout(), LateInitFrom(), ResetResults(), SortMembers(), UpdateDataResults(), and UpdateRunningTotals().
|
private |
Definition at line 500 of file dptabres.hxx.
Referenced by InitFrom(), IsSortAscending(), LateInitFrom(), and SortMembers().
|
private |
or ptr to IntDimension?
Definition at line 499 of file dptabres.hxx.
Referenced by InitFrom(), IsSortByData(), LateInitFrom(), and SortMembers().
|
private |
Definition at line 493 of file dptabres.hxx.
Referenced by CheckShowEmpty(), DoAutoShow(), FillDataResults(), FillMemberResults(), FillVisibilityData(), FindMember(), GetFirstChildDimension(), GetMember(), GetMemberCount(), GetRowReferenceMember(), GetSize(), LateInitFrom(), ResetResults(), SortMembers(), UpdateDataResults(), and UpdateRunningTotals().
|
private |
Definition at line 494 of file dptabres.hxx.
Referenced by FindMember().
|
private |
Definition at line 505 of file dptabres.hxx.
Referenced by DoAutoShow(), GetAutoCount(), InitFrom(), and LateInitFrom().
|
private |
Definition at line 504 of file dptabres.hxx.
Referenced by DoAutoShow(), GetAutoMeasure(), InitFrom(), and LateInitFrom().
|
private |
or ptr to IntDimension?
Definition at line 496 of file dptabres.hxx.
Referenced by GetSortMeasure(), InitFrom(), LateInitFrom(), and SortMembers().
|
private |
Definition at line 492 of file dptabres.hxx.
Referenced by FillDataResults(), FillMemberResults(), GetSize(), InitFrom(), LateInitFrom(), UpdateDataResults(), and UpdateRunningTotals().