LibreOffice Module sc (master) 1
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
ScDPOutput Class Reference

#include <dpoutput.hxx>

Collaboration diagram for ScDPOutput:
[legend]

Public Member Functions

 ScDPOutput (ScDocument *pD, css::uno::Reference< css::sheet::XDimensionsSupplier > xSrc, const ScAddress &rPos, bool bFilter, bool bExpandCollapse)
 
 ~ScDPOutput ()
 
void SetPosition (const ScAddress &rPos)
 
void Output ()
 
ScRange GetOutputRange (sal_Int32 nRegionType=css::sheet::DataPilotOutputRangeType::WHOLE)
 Refresh? More...
 
sal_Int32 GetHeaderRows () const
 
bool HasError ()
 
void GetPositionData (const ScAddress &rPos, css::sheet::DataPilotTablePositionData &rPosData)
 
bool GetDataResultPositionData (::std::vector< css::sheet::DataPilotFieldFilter > &rFilters, const ScAddress &rPos)
 Get filtering criteria based on the position of the cell within data field region. More...
 
tools::Long GetHeaderDim (const ScAddress &rPos, css::sheet::DataPilotFieldOrientation &rOrient)
 
bool GetHeaderDrag (const ScAddress &rPos, bool bMouseLeft, bool bMouseTop, tools::Long nDragDim, tools::Rectangle &rPosRect, css::sheet::DataPilotFieldOrientation &rOrient, tools::Long &rDimPos)
 
bool IsFilterButton (const ScAddress &rPos)
 
void GetMemberResultNames (ScDPUniqueStringSet &rNames, tools::Long nDimension)
 
void SetHeaderLayout (bool bUseGrid)
 
bool GetHeaderLayout () const
 

Static Public Member Functions

static void GetDataDimensionNames (OUString &rSourceName, OUString &rGivenName, const css::uno::Reference< css::uno::XInterface > &xDim)
 

Private Member Functions

void DataCell (SCCOL nCol, SCROW nRow, SCTAB nTab, const css::sheet::DataResult &rData)
 
void HeaderCell (SCCOL nCol, SCROW nRow, SCTAB nTab, const css::sheet::MemberResult &rData, bool bColHeader, tools::Long nLevel)
 
void FieldCell (SCCOL nCol, SCROW nRow, SCTAB nTab, const ScDPOutLevelData &rData, bool bInTable)
 
void MultiFieldCell (SCCOL nCol, SCROW nRow, SCTAB nTab, bool bRowField)
 
SCCOL GetColumnsForRowFields () const
 Computes number of columns needed to write row fields. More...
 
void CalcSizes ()
 
sal_Int32 GetPositionType (const ScAddress &rPos)
 Query which sub-area of the table the cell is in. More...
 
void GetRowFieldRange (SCCOL nCol, sal_Int32 &nRowFieldStart, sal_Int32 &nRowFieldEnd) const
 Returns the range of row fields that are contained by table's row fields column nCol. More...
 
sal_Int32 GetRowFieldCompact (SCCOL nColQuery, SCROW nRowQuery) const
 Find row field index from row position in case of compact layout. More...
 

Private Attributes

ScDocumentpDoc
 
css::uno::Reference< css::sheet::XDimensionsSupplier > xSource
 
ScAddress aStartPos
 
std::vector< ScDPOutLevelDatapColFields
 
std::vector< ScDPOutLevelDatapRowFields
 
std::vector< ScDPOutLevelDatapPageFields
 
css::uno::Sequence< css::uno::Sequence< css::sheet::DataResult > > aData
 
OUString aDataDescription
 
std::unique_ptr< sal_uInt32[]> pColNumFmt
 
std::unique_ptr< sal_uInt32[]> pRowNumFmt
 
std::vector< bool > aRowCompactFlags
 
sal_Int32 nColFmtCount
 
sal_Int32 nRowFmtCount
 
sal_uInt32 nSingleNumFmt
 
size_t nRowDims
 
sal_Int32 nColCount
 
sal_Int32 nRowCount
 
sal_Int32 nHeaderSize
 
SCCOL nTabStartCol
 
SCROW nTabStartRow
 
SCCOL nMemberStartCol
 
SCROW nMemberStartRow
 
SCCOL nDataStartCol
 
SCROW nDataStartRow
 
SCCOL nTabEndCol
 
SCROW nTabEndRow
 
bool bDoFilter:1
 
bool bResultsError:1
 
bool bSizesValid:1
 
bool bSizeOverflow:1
 
bool mbHeaderLayout:1
 
bool mbHasCompactRowField:1
 
bool mbExpandCollapse:1
 

Detailed Description

Definition at line 46 of file dpoutput.hxx.

Constructor & Destructor Documentation

◆ ScDPOutput()

ScDPOutput::ScDPOutput ( ScDocument pD,
css::uno::Reference< css::sheet::XDimensionsSupplier >  xSrc,
const ScAddress rPos,
bool  bFilter,
bool  bExpandCollapse 
)

◆ ~ScDPOutput()

ScDPOutput::~ScDPOutput ( )

Definition at line 707 of file dpoutput.cxx.

Member Function Documentation

◆ CalcSizes()

void ScDPOutput::CalcSizes ( )
private

◆ DataCell()

void ScDPOutput::DataCell ( SCCOL  nCol,
SCROW  nRow,
SCTAB  nTab,
const css::sheet::DataResult &  rData 
)
private

◆ FieldCell()

void ScDPOutput::FieldCell ( SCCOL  nCol,
SCROW  nRow,
SCTAB  nTab,
const ScDPOutLevelData rData,
bool  bInTable 
)
private

◆ GetColumnsForRowFields()

SCCOL ScDPOutput::GetColumnsForRowFields ( ) const
private

Computes number of columns needed to write row fields.

Definition at line 880 of file dpoutput.cxx.

References aRowCompactFlags, mbHasCompactRowField, and pRowFields.

Referenced by CalcSizes().

◆ GetDataDimensionNames()

void ScDPOutput::GetDataDimensionNames ( OUString &  rSourceName,
OUString &  rGivenName,
const css::uno::Reference< css::uno::XInterface > &  xDim 
)
static

◆ GetDataResultPositionData()

bool ScDPOutput::GetDataResultPositionData ( ::std::vector< css::sheet::DataPilotFieldFilter > &  rFilters,
const ScAddress rPos 
)

Get filtering criteria based on the position of the cell within data field region.

Definition at line 1573 of file dpoutput.cxx.

References aStartPos, CalcSizes(), ScAddress::Col(), Flags, ScUnoHelpFunctions::GetLongProperty(), nDataStartCol, nDataStartRow, nTabEndCol, nTabEndRow, pColFields, pRowFields, ScAddress::Row(), SC_UNO_DP_DATAFIELDCOUNT, ScAddress::Tab(), and xSource.

Referenced by GetPositionData().

◆ GetHeaderDim()

tools::Long ScDPOutput::GetHeaderDim ( const ScAddress rPos,
css::sheet::DataPilotFieldOrientation &  rOrient 
)

◆ GetHeaderDrag()

bool ScDPOutput::GetHeaderDrag ( const ScAddress rPos,
bool  bMouseLeft,
bool  bMouseTop,
tools::Long  nDragDim,
tools::Rectangle rPosRect,
css::sheet::DataPilotFieldOrientation &  rOrient,
tools::Long rDimPos 
)

◆ GetHeaderLayout()

bool ScDPOutput::GetHeaderLayout ( ) const
inline

Definition at line 139 of file dpoutput.hxx.

References mbHeaderLayout.

Referenced by CalcSizes().

◆ GetHeaderRows()

sal_Int32 ScDPOutput::GetHeaderRows ( ) const

Definition at line 1256 of file dpoutput.cxx.

References bDoFilter, and pPageFields.

◆ GetMemberResultNames()

void ScDPOutput::GetMemberResultNames ( ScDPUniqueStringSet rNames,
tools::Long  nDimension 
)

Definition at line 1273 of file dpoutput.cxx.

References pColFields, and pRowFields.

◆ GetOutputRange()

ScRange ScDPOutput::GetOutputRange ( sal_Int32  nRegionType = css::sheet::DataPilotOutputRangeType::WHOLE)

◆ GetPositionData()

void ScDPOutput::GetPositionData ( const ScAddress rPos,
css::sheet::DataPilotTablePositionData &  rPosData 
)

◆ GetPositionType()

sal_Int32 ScDPOutput::GetPositionType ( const ScAddress rPos)
private

Query which sub-area of the table the cell is in.

See css.sheet.DataPilotTablePositionType for the interpretation of the return value.

Definition at line 949 of file dpoutput.cxx.

References aStartPos, CalcSizes(), ScAddress::Col(), COLUMN_HEADER, nDataStartCol, nDataStartRow, nTabEndCol, nTabEndRow, nTabStartCol, nTabStartRow, ScAddress::Row(), ROW_HEADER, and ScAddress::Tab().

Referenced by GetPositionData().

◆ GetRowFieldCompact()

sal_Int32 ScDPOutput::GetRowFieldCompact ( SCCOL  nColQuery,
SCROW  nRowQuery 
) const
private

Find row field index from row position in case of compact layout.

Definition at line 1436 of file dpoutput.cxx.

References GetRowFieldRange(), mbHasCompactRowField, nDataStartRow, nTabStartCol, and pRowFields.

Referenced by GetPositionData().

◆ GetRowFieldRange()

void ScDPOutput::GetRowFieldRange ( SCCOL  nCol,
sal_Int32 &  nRowFieldStart,
sal_Int32 &  nRowFieldEnd 
) const
private

Returns the range of row fields that are contained by table's row fields column nCol.

Definition at line 1389 of file dpoutput.cxx.

References aRowCompactFlags, mbHasCompactRowField, and SAL_WARN.

Referenced by GetRowFieldCompact().

◆ HasError()

bool ScDPOutput::HasError ( )

Definition at line 1249 of file dpoutput.cxx.

References bResultsError, bSizeOverflow, and CalcSizes().

◆ HeaderCell()

void ScDPOutput::HeaderCell ( SCCOL  nCol,
SCROW  nRow,
SCTAB  nTab,
const css::sheet::MemberResult &  rData,
bool  bColHeader,
tools::Long  nLevel 
)
private

◆ IsFilterButton()

bool ScDPOutput::IsFilterButton ( const ScAddress rPos)

Definition at line 1719 of file dpoutput.cxx.

References aStartPos, bDoFilter, ScAddress::Col(), ScAddress::Row(), and ScAddress::Tab().

◆ MultiFieldCell()

void ScDPOutput::MultiFieldCell ( SCCOL  nCol,
SCROW  nRow,
SCTAB  nTab,
bool  bRowField 
)
private

◆ Output()

void ScDPOutput::Output ( )

◆ SetHeaderLayout()

void ScDPOutput::SetHeaderLayout ( bool  bUseGrid)

Definition at line 1299 of file dpoutput.cxx.

References bSizesValid, and mbHeaderLayout.

◆ SetPosition()

void ScDPOutput::SetPosition ( const ScAddress rPos)

Definition at line 711 of file dpoutput.cxx.

References aStartPos, bSizeOverflow, and bSizesValid.

Member Data Documentation

◆ aData

css::uno::Sequence< css::uno::Sequence< css::sheet::DataResult> > ScDPOutput::aData
private

Definition at line 55 of file dpoutput.hxx.

Referenced by CalcSizes(), GetPositionData(), Output(), and ScDPOutput().

◆ aDataDescription

OUString ScDPOutput::aDataDescription
private

Definition at line 56 of file dpoutput.hxx.

Referenced by Output(), and ScDPOutput().

◆ aRowCompactFlags

std::vector<bool> ScDPOutput::aRowCompactFlags
private

Definition at line 63 of file dpoutput.hxx.

Referenced by GetColumnsForRowFields(), GetRowFieldRange(), Output(), and ScDPOutput().

◆ aStartPos

ScAddress ScDPOutput::aStartPos
private

◆ bDoFilter

bool ScDPOutput::bDoFilter
private

◆ bResultsError

bool ScDPOutput::bResultsError
private

Definition at line 82 of file dpoutput.hxx.

Referenced by HasError(), Output(), and ScDPOutput().

◆ bSizeOverflow

bool ScDPOutput::bSizeOverflow
private

Definition at line 84 of file dpoutput.hxx.

Referenced by CalcSizes(), HasError(), Output(), and SetPosition().

◆ bSizesValid

bool ScDPOutput::bSizesValid
private

Definition at line 83 of file dpoutput.hxx.

Referenced by CalcSizes(), DataCell(), SetHeaderLayout(), and SetPosition().

◆ mbExpandCollapse

bool ScDPOutput::mbExpandCollapse
private

Definition at line 87 of file dpoutput.hxx.

Referenced by Output().

◆ mbHasCompactRowField

bool ScDPOutput::mbHasCompactRowField
private

◆ mbHeaderLayout

bool ScDPOutput::mbHeaderLayout
private

Definition at line 85 of file dpoutput.hxx.

Referenced by GetHeaderLayout(), and SetHeaderLayout().

◆ nColCount

sal_Int32 ScDPOutput::nColCount
private

Definition at line 70 of file dpoutput.hxx.

Referenced by CalcSizes(), and Output().

◆ nColFmtCount

sal_Int32 ScDPOutput::nColFmtCount
private

Definition at line 64 of file dpoutput.hxx.

Referenced by DataCell(), and ScDPOutput().

◆ nDataStartCol

SCCOL ScDPOutput::nDataStartCol
private

◆ nDataStartRow

SCROW ScDPOutput::nDataStartRow
private

◆ nHeaderSize

sal_Int32 ScDPOutput::nHeaderSize
private

Definition at line 72 of file dpoutput.hxx.

Referenced by CalcSizes().

◆ nMemberStartCol

SCCOL ScDPOutput::nMemberStartCol
private

Definition at line 75 of file dpoutput.hxx.

Referenced by CalcSizes(), HeaderCell(), Output(), and ScDPOutput().

◆ nMemberStartRow

SCROW ScDPOutput::nMemberStartRow
private

Definition at line 76 of file dpoutput.hxx.

Referenced by CalcSizes(), GetHeaderDrag(), HeaderCell(), Output(), and ScDPOutput().

◆ nRowCount

sal_Int32 ScDPOutput::nRowCount
private

Definition at line 71 of file dpoutput.hxx.

Referenced by CalcSizes(), and Output().

◆ nRowDims

size_t ScDPOutput::nRowDims
private

Definition at line 67 of file dpoutput.hxx.

Referenced by Output(), and ScDPOutput().

◆ nRowFmtCount

sal_Int32 ScDPOutput::nRowFmtCount
private

Definition at line 65 of file dpoutput.hxx.

Referenced by DataCell(), and ScDPOutput().

◆ nSingleNumFmt

sal_uInt32 ScDPOutput::nSingleNumFmt
private

Definition at line 66 of file dpoutput.hxx.

Referenced by DataCell(), and ScDPOutput().

◆ nTabEndCol

SCCOL ScDPOutput::nTabEndCol
private

◆ nTabEndRow

SCROW ScDPOutput::nTabEndRow
private

◆ nTabStartCol

SCCOL ScDPOutput::nTabStartCol
private

◆ nTabStartRow

SCROW ScDPOutput::nTabStartRow
private

◆ pColFields

std::vector<ScDPOutLevelData> ScDPOutput::pColFields
private

◆ pColNumFmt

std::unique_ptr<sal_uInt32[]> ScDPOutput::pColNumFmt
private

Definition at line 60 of file dpoutput.hxx.

Referenced by DataCell(), and ScDPOutput().

◆ pDoc

ScDocument* ScDPOutput::pDoc
private

Definition at line 49 of file dpoutput.hxx.

Referenced by CalcSizes(), DataCell(), FieldCell(), HeaderCell(), MultiFieldCell(), and Output().

◆ pPageFields

std::vector<ScDPOutLevelData> ScDPOutput::pPageFields
private

Definition at line 54 of file dpoutput.hxx.

Referenced by CalcSizes(), GetHeaderDim(), GetHeaderDrag(), GetHeaderRows(), Output(), and ScDPOutput().

◆ pRowFields

std::vector<ScDPOutLevelData> ScDPOutput::pRowFields
private

◆ pRowNumFmt

std::unique_ptr<sal_uInt32[]> ScDPOutput::pRowNumFmt
private

Definition at line 62 of file dpoutput.hxx.

Referenced by DataCell(), and ScDPOutput().

◆ xSource

css::uno::Reference< css::sheet::XDimensionsSupplier> ScDPOutput::xSource
private

Definition at line 50 of file dpoutput.hxx.

Referenced by GetDataResultPositionData(), GetPositionData(), and ScDPOutput().


The documentation for this class was generated from the following files: