LibreOffice Module sc (master) 1
|
#include <dpsave.hxx>
Public Types | |
typedef std::unordered_set< OUString > | MemberSetType |
typedef std::vector< ScDPSaveMember * > | MemberList |
Public Member Functions | |
ScDPSaveDimension (OUString aName, bool bDataLayout) | |
ScDPSaveDimension (const ScDPSaveDimension &r) | |
~ScDPSaveDimension () | |
bool | operator== (const ScDPSaveDimension &r) const |
const MemberList & | GetMembers () const |
void | AddMember (std::unique_ptr< ScDPSaveMember > pMember) |
void | SetDupFlag (bool bSet) |
bool | GetDupFlag () const |
const OUString & | GetName () const |
bool | IsDataLayout () const |
void | SetName (const OUString &rNew) |
void | SetOrientation (css::sheet::DataPilotFieldOrientation nNew) |
void | SetSubTotals (std::vector< ScGeneralFunction > &&rFuncs) |
tools::Long | GetSubTotalsCount () const |
ScGeneralFunction | GetSubTotalFunc (tools::Long nIndex) const |
bool | HasShowEmpty () const |
void | SetShowEmpty (bool bSet) |
bool | GetShowEmpty () const |
void | SetRepeatItemLabels (bool bSet) |
bool | GetRepeatItemLabels () const |
void | SetFunction (ScGeneralFunction nNew) |
ScGeneralFunction | GetFunction () const |
void | SetUsedHierarchy (tools::Long nNew) |
tools::Long | GetUsedHierarchy () const |
void | SetLayoutName (const OUString &rName) |
const std::optional< OUString > & | GetLayoutName () const |
void | RemoveLayoutName () |
void | SetSubtotalName (const OUString &rName) |
const std::optional< OUString > & | GetSubtotalName () const |
void | RemoveSubtotalName () |
bool | IsMemberNameInUse (const OUString &rName) const |
const css::sheet::DataPilotFieldReference * | GetReferenceValue () const |
void | SetReferenceValue (const css::sheet::DataPilotFieldReference *pNew) |
const css::sheet::DataPilotFieldSortInfo * | GetSortInfo () const |
void | SetSortInfo (const css::sheet::DataPilotFieldSortInfo *pNew) |
const css::sheet::DataPilotFieldAutoShowInfo * | GetAutoShowInfo () const |
void | SetAutoShowInfo (const css::sheet::DataPilotFieldAutoShowInfo *pNew) |
const css::sheet::DataPilotFieldLayoutInfo * | GetLayoutInfo () const |
void | SetLayoutInfo (const css::sheet::DataPilotFieldLayoutInfo *pNew) |
void | SetCurrentPage (const OUString *pPage) |
OUString | GetCurrentPage () const |
css::sheet::DataPilotFieldOrientation | GetOrientation () const |
ScDPSaveMember * | GetExistingMemberByName (const OUString &rName) |
ScDPSaveMember * | GetMemberByName (const OUString &rName) |
Get a member object by its name. More... | |
void | SetMemberPosition (const OUString &rName, sal_Int32 nNewPos) |
void | WriteToSource (const css::uno::Reference< css::uno::XInterface > &xDim) |
void | UpdateMemberVisibility (const std::unordered_map< OUString, bool > &rData) |
bool | HasInvisibleMember () const |
void | RemoveObsoleteMembers (const MemberSetType &rMembers) |
void | Dump (int nIndent=0) const |
Private Attributes | |
OUString | aName |
std::optional< OUString > | mpLayoutName |
std::optional< OUString > | mpSubtotalName |
bool | bIsDataLayout |
bool | bDupFlag |
css::sheet::DataPilotFieldOrientation | nOrientation |
ScGeneralFunction | nFunction |
tools::Long | nUsedHierarchy |
sal_uInt16 | nShowEmptyMode |
bool | bRepeatItemLabels |
at level More... | |
bool | bSubTotalDefault |
at level More... | |
std::vector< ScGeneralFunction > | maSubTotalFuncs |
at level More... | |
std::unique_ptr< css::sheet::DataPilotFieldReference > | pReferenceValue |
std::unique_ptr< css::sheet::DataPilotFieldSortInfo > | pSortInfo |
std::unique_ptr< css::sheet::DataPilotFieldAutoShowInfo > | pAutoShowInfo |
std::unique_ptr< css::sheet::DataPilotFieldLayoutInfo > | pLayoutInfo |
std::unordered_map< OUString, std::unique_ptr< ScDPSaveMember > > | maMemberHash |
MemberList | maMemberList |
Definition at line 93 of file dpsave.hxx.
typedef std::vector<ScDPSaveMember*> ScDPSaveDimension::MemberList |
Definition at line 115 of file dpsave.hxx.
typedef std::unordered_set<OUString> ScDPSaveDimension::MemberSetType |
Definition at line 114 of file dpsave.hxx.
ScDPSaveDimension::ScDPSaveDimension | ( | OUString | aName, |
bool | bDataLayout | ||
) |
Definition at line 183 of file dpsave.cxx.
ScDPSaveDimension::ScDPSaveDimension | ( | const ScDPSaveDimension & | r | ) |
Definition at line 196 of file dpsave.cxx.
References aName, ScDPSaveMember::GetName(), maMemberHash, maMemberList, pAutoShowInfo, pLayoutInfo, pReferenceValue, and pSortInfo.
ScDPSaveDimension::~ScDPSaveDimension | ( | ) |
Definition at line 227 of file dpsave.cxx.
References maMemberHash, pAutoShowInfo, pLayoutInfo, pReferenceValue, and pSortInfo.
void ScDPSaveDimension::AddMember | ( | std::unique_ptr< ScDPSaveMember > | pMember | ) |
Definition at line 294 of file dpsave.cxx.
References maMemberHash, and maMemberList.
Referenced by ScDBFunc::DataPilotSort(), and lcl_MoveToEnd().
void ScDPSaveDimension::Dump | ( | int | nIndent = 0 | ) | const |
|
inline |
Definition at line 190 of file dpsave.hxx.
Referenced by ScDataPilotFieldObj::getAutoShowInfo(), XclExpPTField::SetPropertiesFromDim(), and ScXMLExportDataPilot::WriteAutoShowInfo().
OUString ScDPSaveDimension::GetCurrentPage | ( | ) | const |
Definition at line 440 of file dpsave.cxx.
References maMemberList.
Referenced by ScXMLExportDataPilot::WriteDimension().
|
inline |
Definition at line 136 of file dpsave.hxx.
ScDPSaveMember * ScDPSaveDimension::GetExistingMemberByName | ( | const OUString & | rName | ) |
Definition at line 450 of file dpsave.cxx.
References maMemberHash.
Referenced by XclImpPTItem::ConvertItem(), ScDBFunc::DataPilotInput(), ScDBFunc::DataPilotSort(), and lcl_MoveToEnd().
|
inline |
Definition at line 165 of file dpsave.hxx.
Referenced by XclExpXmlPivotTables::SavePivotTableXml(), XclExpPTField::SetDataPropertiesFromDim(), and ScXMLExportDataPilot::WriteDimension().
|
inline |
Definition at line 194 of file dpsave.hxx.
Referenced by ScDataPilotFieldObj::getLayoutInfo(), XclExpXmlPivotTables::SavePivotTableXml(), XclExpPTField::SetPropertiesFromDim(), and ScXMLExportDataPilot::WriteLayoutInfo().
const std::optional< OUString > & ScDPSaveDimension::GetLayoutName | ( | ) | const |
Definition at line 386 of file dpsave.cxx.
References mpLayoutName.
Referenced by XclExpXmlPivotTables::SavePivotTableXml(), ScDPShowDetailDlg::ScDPShowDetailDlg(), XclExpPTField::SetDataPropertiesFromDim(), XclExpPTField::SetPropertiesFromDim(), XclExpPivotTable::SetPropertiesFromDP(), and ScXMLExportDataPilot::WriteDimension().
ScDPSaveMember * ScDPSaveDimension::GetMemberByName | ( | const OUString & | rName | ) |
Get a member object by its name.
If one doesn't exist, create a new object and return it. This class manages the life cycle of all member objects belonging to it, so don't delete the returned instance.
rName | member name |
Definition at line 458 of file dpsave.cxx.
References maMemberHash, and maMemberList.
Referenced by ScPivotLayoutDialog::ApplyLabelData(), oox::xls::PivotTableField::convertRowColPageField(), ScDBFunc::SetDataPilotDetails(), SetMemberPosition(), and ScDataPilotItemObj::setPropertyValue().
|
inline |
Definition at line 128 of file dpsave.hxx.
References maMemberList.
Referenced by ScDBFunc::DataPilotSort(), XclExpPTField::SetPropertiesFromDim(), and ScXMLExportDataPilot::WriteMembers().
|
inline |
Definition at line 139 of file dpsave.hxx.
References aName.
Referenced by ScXMLDataPilotTableContext::AddDimension(), ScDPSaveData::CheckDuplicateName(), ScDPObject::ConvertOrientation(), ScDBFunc::DataPilotInput(), XclExpPivotTable::GetFieldAcc(), oox::xls::PivotCacheItem::getFormattedName(), XclImpPTItem::GetItemName(), XclExpXmlPivotTables::SavePivotTableXml(), ScXMLExportDataPilot::WriteDimension(), and ScXMLExportDataPilot::WriteGroupDimElements().
|
inline |
Definition at line 202 of file dpsave.hxx.
Referenced by ScGridWindow::AcceptPrivateDrop(), ScXMLDataPilotTableContext::AddDimension(), ScDataPilotFieldObj::createDateGroup(), ScDataPilotFieldObj::createNameGroup(), ScDBFunc::DateGroupDataPilot(), ScDPSaveData::GetAllDimensionsByOrientation(), ScDataPilotFieldObj::getOrientation(), ScDBFunc::GroupDataPilot(), ScDBFunc::HasSelectionForDrillDown(), lcl_FillDPFieldPopupData(), XclExpXmlPivotTables::SavePivotTableXml(), ScDPShowDetailDlg::ScDPShowDetailDlg(), ScXMLDataPilotTableContext::SetButtons(), ScDBFunc::SetDataPilotDetails(), XclExpPivotTable::SetFieldPropertiesFromDim(), ScDataPilotFieldObj::setFunction(), ScDataPilotFieldObj::setOrientation(), ScDPSaveData::SetPosition(), XclExpPTField::SetPropertiesFromDim(), ScDataPilotFieldObj::setSubtotals(), and ScXMLExportDataPilot::WriteDimension().
|
inline |
Definition at line 181 of file dpsave.hxx.
Referenced by ScDataPilotFieldObj::getReference(), XclExpPTField::SetDataPropertiesFromDim(), and ScXMLExportDataPilot::WriteFieldReference().
|
inline |
Definition at line 161 of file dpsave.hxx.
Referenced by ScDataPilotFieldObj::getRepeatItemLabels(), and ScXMLExportDataPilot::WriteLevels().
|
inline |
Definition at line 157 of file dpsave.hxx.
Referenced by ScDataPilotFieldObj::getShowEmpty(), XclExpPTField::SetPropertiesFromDim(), and ScXMLExportDataPilot::WriteLevels().
|
inline |
Definition at line 186 of file dpsave.hxx.
Referenced by ScDataPilotFieldObj::getSortInfo(), XclExpPTField::SetPropertiesFromDim(), and ScXMLExportDataPilot::WriteSortInfo().
|
inline |
Definition at line 152 of file dpsave.hxx.
References nIndex.
Referenced by ScDBFunc::DataPilotInput(), XclExpXmlPivotTables::SavePivotTableXml(), XclExpPTField::SetPropertiesFromDim(), and ScXMLExportDataPilot::WriteSubTotals().
const std::optional< OUString > & ScDPSaveDimension::GetSubtotalName | ( | ) | const |
Definition at line 360 of file dpsave.cxx.
References mpSubtotalName.
Referenced by XclExpPTField::SetPropertiesFromDim(), ScXMLExportDataPilot::WriteSubTotals(), and WriteToSource().
|
inline |
Definition at line 149 of file dpsave.hxx.
Referenced by ScDBFunc::DataPilotInput(), XclExpXmlPivotTables::SavePivotTableXml(), XclExpPTField::SetPropertiesFromDim(), and ScXMLExportDataPilot::WriteSubTotals().
|
inline |
Definition at line 169 of file dpsave.hxx.
Referenced by ScXMLExportDataPilot::WriteDimension().
bool ScDPSaveDimension::HasInvisibleMember | ( | ) | const |
Definition at line 624 of file dpsave.cxx.
References maMemberList.
Referenced by XclImpPivotTable::ApplyMergeFlags(), ScDPSaveData::HasInvisibleMember(), and ScXMLDataPilotTableContext::SetButtons().
bool ScDPSaveDimension::HasShowEmpty | ( | ) | const |
Definition at line 330 of file dpsave.cxx.
References nShowEmptyMode, and SC_DPSAVEMODE_DONTKNOW.
Referenced by XclExpPTField::SetPropertiesFromDim(), and ScXMLExportDataPilot::WriteLevels().
|
inline |
Definition at line 142 of file dpsave.hxx.
Referenced by ScXMLDataPilotTableContext::AddDimension(), XclImpPivotTable::ApplyMergeFlags(), XclExpPivotTable::GetFieldAcc(), XclExpXmlPivotTables::SavePivotTableXml(), ScXMLDataPilotTableContext::SetButtons(), ScDataPilotFieldObj::setName(), and ScXMLExportDataPilot::WriteDimension().
bool ScDPSaveDimension::IsMemberNameInUse | ( | const OUString & | rName | ) | const |
Definition at line 370 of file dpsave.cxx.
References maMemberList.
Referenced by ScDBFunc::DataPilotInput().
bool ScDPSaveDimension::operator== | ( | const ScDPSaveDimension & | r | ) | const |
Definition at line 236 of file dpsave.cxx.
References a, aName, bDupFlag, bIsDataLayout, bRepeatItemLabels, bSubTotalDefault, maMemberHash, maMemberList, maSubTotalFuncs, nFunction, nOrientation, nShowEmptyMode, nUsedHierarchy, pAutoShowInfo, pReferenceValue, and pSortInfo.
void ScDPSaveDimension::RemoveLayoutName | ( | ) |
Definition at line 391 of file dpsave.cxx.
References mpLayoutName.
Referenced by ScDPObject::ConvertOrientation(), and ScDBFunc::DataPilotInput().
void ScDPSaveDimension::RemoveObsoleteMembers | ( | const MemberSetType & | rMembers | ) |
Definition at line 630 of file dpsave.cxx.
References maMemberHash, and maMemberList.
void ScDPSaveDimension::RemoveSubtotalName | ( | ) |
Definition at line 365 of file dpsave.cxx.
References mpSubtotalName.
Referenced by ScDPObject::ConvertOrientation().
void ScDPSaveDimension::SetAutoShowInfo | ( | const css::sheet::DataPilotFieldAutoShowInfo * | pNew | ) |
Definition at line 412 of file dpsave.cxx.
References pAutoShowInfo.
Referenced by ScPivotLayoutDialog::ApplyLabelData(), and XclImpPTField::ConvertRCPField().
void ScDPSaveDimension::SetCurrentPage | ( | const OUString * | pPage | ) |
Definition at line 428 of file dpsave.cxx.
References bVisible, and maMemberList.
Referenced by XclImpPTField::ConvertFieldInfo(), and ScDataPilotFieldObj::setUseCurrentPage().
|
inline |
Definition at line 133 of file dpsave.hxx.
Referenced by ScXMLDataPilotTableContext::AddDimension(), and ScDPSaveData::CheckDuplicateName().
void ScDPSaveDimension::SetFunction | ( | ScGeneralFunction | nNew | ) |
Definition at line 345 of file dpsave.cxx.
References nFunction.
Referenced by XclImpPTField::ConvertDataFieldInfo(), ScDPObject::ConvertOrientation(), and ScDataPilotFieldObj::setFunction().
void ScDPSaveDimension::SetLayoutInfo | ( | const css::sheet::DataPilotFieldLayoutInfo * | pNew | ) |
Definition at line 420 of file dpsave.cxx.
References pLayoutInfo.
Referenced by ScPivotLayoutDialog::ApplyLabelData(), and XclImpPTField::ConvertRCPField().
void ScDPSaveDimension::SetLayoutName | ( | const OUString & | rName | ) |
Definition at line 381 of file dpsave.cxx.
References mpLayoutName.
Referenced by XclImpPivotTable::Convert(), XclImpPTField::ConvertDataFieldInfo(), ScDPObject::ConvertOrientation(), XclImpPTField::ConvertRCPField(), ScDBFunc::DataPilotInput(), and ScDataPilotFieldObj::setName().
void ScDPSaveDimension::SetMemberPosition | ( | const OUString & | rName, |
sal_Int32 | nNewPos | ||
) |
Definition at line 470 of file dpsave.cxx.
References GetMemberByName(), and maMemberList.
Referenced by ScDataPilotItemObj::setPropertyValue().
void ScDPSaveDimension::SetName | ( | const OUString & | rNew | ) |
Definition at line 311 of file dpsave.cxx.
References aName.
Referenced by ScDPSaveData::CheckDuplicateName(), and ScDBFunc::DataPilotInput().
void ScDPSaveDimension::SetOrientation | ( | css::sheet::DataPilotFieldOrientation | nNew | ) |
Definition at line 319 of file dpsave.cxx.
References nOrientation.
Referenced by XclImpPTField::ConvertDataField(), ScDPObject::ConvertOrientation(), XclImpPTField::ConvertRCPField(), XclImpPTField::ConvertRowColField(), ScDataPilotFieldObj::createDateGroup(), ScDataPilotFieldObj::createNameGroup(), ScDBFunc::DateGroupDataPilot(), ScGridWindow::DPTestMouse(), ScDBFunc::GroupDataPilot(), ScDBFunc::SetDataPilotDetails(), and ScDataPilotFieldObj::setOrientation().
void ScDPSaveDimension::SetReferenceValue | ( | const css::sheet::DataPilotFieldReference * | pNew | ) |
Definition at line 396 of file dpsave.cxx.
References pReferenceValue.
Referenced by XclImpPTField::ConvertDataFieldInfo(), and ScDPObject::ConvertOrientation().
void ScDPSaveDimension::SetRepeatItemLabels | ( | bool | bSet | ) |
Definition at line 340 of file dpsave.cxx.
References bRepeatItemLabels.
Referenced by ScPivotLayoutDialog::ApplyLabelData().
void ScDPSaveDimension::SetShowEmpty | ( | bool | bSet | ) |
Definition at line 335 of file dpsave.cxx.
References nShowEmptyMode.
Referenced by ScPivotLayoutDialog::ApplyLabelData(), XclImpPTField::ConvertFieldInfo(), and ScDPObject::ConvertOrientation().
void ScDPSaveDimension::SetSortInfo | ( | const css::sheet::DataPilotFieldSortInfo * | pNew | ) |
Definition at line 404 of file dpsave.cxx.
References pSortInfo.
Referenced by ScPivotLayoutDialog::ApplyLabelData(), XclImpPTField::ConvertRCPField(), ScDBFunc::DataPilotMove(), and ScDBFunc::DataPilotSort().
void ScDPSaveDimension::SetSubtotalName | ( | const OUString & | rName | ) |
Definition at line 355 of file dpsave.cxx.
References mpSubtotalName.
Referenced by ScDPObject::ConvertOrientation(), XclImpPTField::ConvertRCPField(), and ScDBFunc::DataPilotInput().
void ScDPSaveDimension::SetSubTotals | ( | std::vector< ScGeneralFunction > && | rFuncs | ) |
Definition at line 324 of file dpsave.cxx.
References bSubTotalDefault, and maSubTotalFuncs.
Referenced by ScDPObject::ConvertOrientation(), XclImpPTField::ConvertRCPField(), ScDataPilotFieldObj::setFunction(), and ScDataPilotFieldObj::setSubtotals().
void ScDPSaveDimension::SetUsedHierarchy | ( | tools::Long | nNew | ) |
Definition at line 350 of file dpsave.cxx.
References nUsedHierarchy.
Referenced by ScPivotLayoutDialog::ApplyLabelData().
void ScDPSaveDimension::UpdateMemberVisibility | ( | const std::unordered_map< OUString, bool > & | rData | ) |
Definition at line 613 of file dpsave.cxx.
References maMemberList.
Referenced by ScGridWindow::UpdateDPFromFieldPopupMenu().
void ScDPSaveDimension::WriteToSource | ( | const css::uno::Reference< css::uno::XInterface > & | xDim | ) |
Definition at line 479 of file dpsave.cxx.
References aSeq, bRepeatItemLabels, bSubTotalDefault, GetSubtotalName(), i, lcl_SetBoolProperty(), maMemberHash, maMemberList, maSubTotalFuncs, mpLayoutName, nCount, nFunction, nOrientation, nShowEmptyMode, nUsedHierarchy, pAutoShowInfo, pLayoutInfo, pReferenceValue, pSortInfo, SC_DPSAVEMODE_DONTKNOW, SC_UNO_DP_AUTOSHOW, SC_UNO_DP_FIELD_SUBTOTALNAME, SC_UNO_DP_FUNCTION2, SC_UNO_DP_HAS_HIDDEN_MEMBER, SC_UNO_DP_LAYOUT, SC_UNO_DP_LAYOUTNAME, SC_UNO_DP_ORIENTATION, SC_UNO_DP_REFVALUE, SC_UNO_DP_REPEATITEMLABELS, SC_UNO_DP_SHOWEMPTY, SC_UNO_DP_SORTING, SC_UNO_DP_SUBTOTAL2, SC_UNO_DP_USEDHIERARCHY, and ScUnoHelpFunctions::SetOptionalPropertyValue().
|
private |
Definition at line 96 of file dpsave.hxx.
Referenced by operator==(), and SetName().
|
private |
Definition at line 100 of file dpsave.hxx.
Referenced by operator==().
|
private |
Definition at line 99 of file dpsave.hxx.
Referenced by operator==().
|
private |
at level
Definition at line 105 of file dpsave.hxx.
Referenced by operator==(), SetRepeatItemLabels(), and WriteToSource().
|
private |
at level
Definition at line 106 of file dpsave.hxx.
Referenced by operator==(), SetSubTotals(), and WriteToSource().
|
private |
Definition at line 118 of file dpsave.hxx.
Referenced by AddMember(), GetExistingMemberByName(), GetMemberByName(), operator==(), RemoveObsoleteMembers(), ScDPSaveDimension(), WriteToSource(), and ~ScDPSaveDimension().
|
private |
Definition at line 119 of file dpsave.hxx.
Referenced by AddMember(), GetCurrentPage(), GetMemberByName(), HasInvisibleMember(), IsMemberNameInUse(), operator==(), RemoveObsoleteMembers(), ScDPSaveDimension(), SetCurrentPage(), SetMemberPosition(), UpdateMemberVisibility(), and WriteToSource().
|
private |
at level
Definition at line 107 of file dpsave.hxx.
Referenced by operator==(), SetSubTotals(), and WriteToSource().
|
private |
Definition at line 97 of file dpsave.hxx.
Referenced by GetLayoutName(), RemoveLayoutName(), SetLayoutName(), and WriteToSource().
|
private |
Definition at line 98 of file dpsave.hxx.
Referenced by GetSubtotalName(), RemoveSubtotalName(), and SetSubtotalName().
|
private |
Definition at line 102 of file dpsave.hxx.
Referenced by operator==(), SetFunction(), and WriteToSource().
|
private |
Definition at line 101 of file dpsave.hxx.
Referenced by operator==(), SetOrientation(), and WriteToSource().
|
private |
Definition at line 104 of file dpsave.hxx.
Referenced by HasShowEmpty(), operator==(), SetShowEmpty(), and WriteToSource().
|
private |
Definition at line 103 of file dpsave.hxx.
Referenced by operator==(), SetUsedHierarchy(), and WriteToSource().
|
private |
Definition at line 110 of file dpsave.hxx.
Referenced by operator==(), ScDPSaveDimension(), SetAutoShowInfo(), WriteToSource(), and ~ScDPSaveDimension().
|
private |
Definition at line 111 of file dpsave.hxx.
Referenced by ScDPSaveDimension(), SetLayoutInfo(), WriteToSource(), and ~ScDPSaveDimension().
|
private |
Definition at line 108 of file dpsave.hxx.
Referenced by operator==(), ScDPSaveDimension(), SetReferenceValue(), WriteToSource(), and ~ScDPSaveDimension().
|
private |
Definition at line 109 of file dpsave.hxx.
Referenced by operator==(), ScDPSaveDimension(), SetSortInfo(), WriteToSource(), and ~ScDPSaveDimension().