LibreOffice Module sc (master)
1
|
Represents a data item in a pivot cache. More...
#include <xipivot.hxx>
Public Member Functions | |
XclImpPCItem (XclImpStream &rStrm) | |
void | WriteToSource (XclImpRoot &rRoot, const ScAddress &rScPos) const |
Inserts the item data into the passed document. More... | |
![]() | |
XclPCItem () | |
virtual | ~XclPCItem () |
XclPCItem (XclPCItem const &)=default | |
XclPCItem (XclPCItem &&)=default | |
XclPCItem & | operator= (XclPCItem const &)=default |
XclPCItem & | operator= (XclPCItem &&)=default |
void | SetEmpty () |
Sets the item to 'empty' type. More... | |
void | SetText (const OUString &rText) |
Sets the item to 'text' type and adds the passed text. More... | |
void | SetDouble (double fValue, const OUString &rText=OUString()) |
Sets the item to 'double' type and adds the passed value. More... | |
void | SetDateTime (const DateTime &rDateTime, const OUString &rText=OUString()) |
Sets the item to 'date/time' type and adds the passed date. More... | |
void | SetInteger (sal_Int16 nValue) |
Sets the item to 'integer' type and adds the passed value. More... | |
void | SetError (sal_uInt16 nError) |
Sets the item to 'error' type and adds the passed Excel error code. More... | |
void | SetBool (bool bValue, const OUString &rText=OUString()) |
Sets the item to 'boolean' type and adds the passed Boolean value. More... | |
const OUString & | ConvertToText () const |
Returns the text representation of the item. More... | |
bool | IsEqual (const XclPCItem &rItem) const |
Returns true, if the passed term equals this item. More... | |
bool | IsEmpty () const |
Returns true, if the item type is 'empty'. More... | |
const OUString * | GetText () const |
Returns pointer to text, if the item type is 'text', otherwise 0. More... | |
const double * | GetDouble () const |
Returns pointer to value, if the item type is 'double', otherwise 0. More... | |
const DateTime * | GetDateTime () const |
Returns pointer to date, if the item type is 'date/time', otherwise 0. More... | |
const sal_Int16 * | GetInteger () const |
Returns pointer to integer, if the item type is 'integer', otherwise 0. More... | |
const sal_uInt16 * | GetError () const |
Returns pointer to error code, if the item type is 'error', otherwise 0. More... | |
const bool * | GetBool () const |
Returns pointer to Boolean value, if the item type is 'boolean', otherwise 0. More... | |
XclPCItemType | GetType () const |
Returns the type of the item. More... | |
Private Member Functions | |
void | ReadSxdouble (XclImpStream &rStrm) |
Reads an SXDOUBLE record describing a floating-point item. More... | |
void | ReadSxboolean (XclImpStream &rStrm) |
Reads an SXBOOLEAN record describing a boolean item. More... | |
void | ReadSxerror (XclImpStream &rStrm) |
Reads an SXERROR record describing an error code item. More... | |
void | ReadSxinteger (XclImpStream &rStrm) |
Reads an SXINTEGER record describing an integer item. More... | |
void | ReadSxstring (XclImpStream &rStrm) |
Reads an SXSTRING record describing a text item. More... | |
void | ReadSxdatetime (XclImpStream &rStrm) |
Reads an SXDATETIME record describing a date/time item. More... | |
void | ReadSxempty (XclImpStream &rStrm) |
Reads an SXEMPTY record describing an empty item. More... | |
Represents a data item in a pivot cache.
Definition at line 34 of file xipivot.hxx.
|
explicit |
Definition at line 67 of file xipivot.cxx.
References EXC_ID_SXBOOLEAN, EXC_ID_SXDATETIME, EXC_ID_SXDOUBLE, EXC_ID_SXEMPTY, EXC_ID_SXERROR, EXC_ID_SXINTEGER, EXC_ID_SXSTRING, and XclImpStream::GetRecId().
|
private |
Reads an SXBOOLEAN record describing a boolean item.
Definition at line 136 of file xipivot.cxx.
References XclImpStream::GetRecSize(), and XclImpStream::ReaduInt16().
|
private |
Reads an SXDATETIME record describing a date/time item.
Definition at line 160 of file xipivot.cxx.
References XclImpStream::GetRecSize(), XclImpStream::ReaduInt16(), and XclImpStream::ReaduInt8().
|
private |
Reads an SXDOUBLE record describing a floating-point item.
Definition at line 130 of file xipivot.cxx.
References XclImpStream::GetRecSize(), and XclImpStream::ReadDouble().
|
private |
Reads an SXEMPTY record describing an empty item.
Definition at line 174 of file xipivot.cxx.
References XclImpStream::GetRecSize().
|
private |
Reads an SXERROR record describing an error code item.
Definition at line 142 of file xipivot.cxx.
References XclImpStream::GetRecSize(), XclImpStream::ReaduInt16(), and SetError().
|
private |
Reads an SXINTEGER record describing an integer item.
Definition at line 148 of file xipivot.cxx.
References XclImpStream::GetRecSize(), and XclImpStream::ReadInt16().
|
private |
Reads an SXSTRING record describing a text item.
Definition at line 154 of file xipivot.cxx.
References XclImpStream::GetRecSize(), and XclImpStream::ReadUniString().
void XclImpPCItem::WriteToSource | ( | XclImpRoot & | rRoot, |
const ScAddress & | rScPos | ||
) | const |
Inserts the item data into the passed document.
Definition at line 95 of file xipivot.cxx.
References XclTools::ErrorToEnum(), ExcelToSc::GetBoolErr(), GetDateTime(), ScDocumentImport::getDoc(), XclImpRoot::GetDocImport(), XclRoot::GetDoubleFromDateTime(), GetError(), XclImpRoot::GetOldFmlaConverter(), ScDocumentImport::setFormulaCell(), ScFormulaCell::SetHybridDouble(), ScDocumentImport::setNumericCell(), and ScDocumentImport::setStringCell().