LibreOffice Module sc (master) 1
|
#include <externallinkbuffer.hxx>
Public Member Functions | |
ExternalLink (const WorkbookHelper &rHelper) | |
void | importExternalReference (const AttributeList &rAttribs) |
Imports the externalReference element containing the relation identifier. More... | |
void | importExternalBook (const ::oox::core::Relations &rRelations, const AttributeList &rAttribs) |
Imports the externalBook element describing an externally linked document. More... | |
void | importSheetName (const AttributeList &rAttribs) |
Imports the sheetName element containing the sheet name in an externally linked document. More... | |
void | importDefinedName (const AttributeList &rAttribs) |
Imports the definedName element describing an external name. More... | |
void | importDdeLink (const AttributeList &rAttribs) |
Imports the ddeLink element describing a DDE link. More... | |
ExternalNameRef | importDdeItem (const AttributeList &rAttribs) |
Imports the ddeItem element describing an item of a DDE link. More... | |
void | importOleLink (const ::oox::core::Relations &rRelations, const AttributeList &rAttribs) |
Imports the oleLink element describing an OLE link. More... | |
ExternalNameRef | importOleItem (const AttributeList &rAttribs) |
Imports the oleItem element describing an object of an OLE link. More... | |
void | importExternalBook (const ::oox::core::Relations &rRelations, SequenceInputStream &rStrm) |
Imports the EXTERNALBOOK record describing an externally linked document, DDE link, or OLE link. More... | |
void | importExtSheetNames (SequenceInputStream &rStrm) |
Imports the EXTSHEETNAMES record containing the sheet names in an externally linked document. More... | |
ExternalNameRef | importExternalName (SequenceInputStream &rStrm) |
Imports the EXTERNALNAME record describing an external name. More... | |
void | importExternalRef (SequenceInputStream &rStrm) |
Imports the EXTERNALREF record from the passed stream. More... | |
void | importExternalSelf (SequenceInputStream &rStrm) |
Imports the EXTERNALSELF record from the passed stream. More... | |
void | importExternalSame (SequenceInputStream &rStrm) |
Imports the EXTERNALSAME record from the passed stream. More... | |
void | importExternalAddin (SequenceInputStream &rStrm) |
Imports the EXTERNALADDIN record from the passed stream. More... | |
void | setSelfLinkType () |
Sets the link type to 'self reference'. More... | |
ExternalLinkType | getLinkType () const |
Returns the type of this external link. More... | |
const OUString & | getRelId () const |
Returns the relation identifier for the external link fragment. More... | |
const OUString & | getClassName () const |
Returns the class name of this external link. More... | |
const OUString & | getTargetUrl () const |
Returns the target URL of this external link. More... | |
css::sheet::ExternalLinkInfo | getLinkInfo () const |
Returns the link info needed by the XML formula parser. More... | |
FunctionLibraryType | getFuncLibraryType () const |
Returns the type of the external library if this is a library link. More... | |
sal_Int32 | getDocumentLinkIndex () const |
Returns the token index of the external document. More... | |
sal_Int32 | getSheetCacheIndex (sal_Int32 nTabId) const |
Returns the external sheet cache index or for the passed sheet. More... | |
css::uno::Reference< css::sheet::XExternalSheetCache > | getSheetCache (sal_Int32 nTabId) const |
Returns the sheet cache of the external sheet with the passed index. More... | |
void | getSheetRange (LinkSheetRange &orSheetRange, sal_Int32 nTabId1, sal_Int32 nTabId2) const |
Returns the internal sheet range or range of external sheet caches for the passed sheet range (BIFF only). More... | |
ExternalNameRef | getNameByIndex (sal_Int32 nIndex) const |
Returns the external name with the passed zero-based index. More... | |
Public Member Functions inherited from oox::xls::WorkbookHelper | |
WorkbookHelper (WorkbookGlobals &rBookGlob) | |
virtual | ~WorkbookHelper () |
WorkbookHelper (WorkbookHelper const &)=default | |
WorkbookHelper (WorkbookHelper &&)=default | |
WorkbookHelper & | operator= (WorkbookHelper const &)=delete |
WorkbookHelper & | operator= (WorkbookHelper &&)=delete |
::oox::core::FilterBase & | getBaseFilter () const |
Returns the base filter object (base class of all filters). More... | |
SegmentProgressBar & | getProgressBar () const |
Returns the filter progress bar. More... | |
sal_Int16 | getCurrentSheetIndex () const |
Returns the index of the current Calc sheet, if filter currently processes a sheet. More... | |
bool | isGeneratorKnownGood () const |
Returns true when reading a file generated by a known good generator. More... | |
bool | hasCalculatedFormulaCells () const |
Returns true if any formula cell is calculated. More... | |
void | setCalculatedFormulaCells () |
Set if any formula cell is calculated. More... | |
void | setVbaProjectStorage (const StorageRef &rxVbaPrjStrg) |
Sets the VBA project storage used to import VBA source code and forms. More... | |
void | setCurrentSheetIndex (SCTAB nSheet) |
Sets the index of the current Calc sheet, if filter currently processes a sheet. More... | |
void | finalizeWorkbookImport () |
Final conversion after importing the workbook. More... | |
void | useInternalChartDataTable (bool bInternal) |
ScDocument & | getScDocument () |
const ScDocument & | getScDocument () const |
ScDocumentImport & | getDocImport () |
const ScDocumentImport & | getDocImport () const |
ScEditEngineDefaulter & | getEditEngine () const |
const css::uno::Reference< css::sheet::XSpreadsheetDocument > & | getDocument () const |
Returns a reference to the source/target spreadsheet document model. More... | |
css::uno::Reference< css::sheet::XSpreadsheet > | getSheetFromDoc (sal_Int32 nSheet) const |
Returns a reference to the specified spreadsheet in the document model. More... | |
css::uno::Reference< css::sheet::XSpreadsheet > | getSheetFromDoc (const OUString &rSheet) const |
Returns a reference to the specified spreadsheet in the document model. More... | |
css::uno::Reference< css::table::XCellRange > | getCellRangeFromDoc (const ScRange &rRange) const |
Returns the XCellRange interface for the passed cell range address. More... | |
css::uno::Reference< css::container::XNameContainer > | getCellStyleFamily () const |
Returns the cell styles container from the Calc document. More... | |
css::uno::Reference< css::style::XStyle > | getStyleObject (const OUString &rStyleName, bool bPageStyle) const |
Returns the specified cell or page style from the Calc document. More... | |
RangeDataRet | createNamedRangeObject (OUString &orName, sal_Int32 nIndex, sal_Int32 nNameFlags, bool bHidden) const |
Creates and returns a defined name on-the-fly in the Calc document. More... | |
RangeDataRet | createLocalNamedRangeObject (OUString &orName, sal_Int32 nIndex, sal_Int32 nNameFlags, sal_Int32 nTab, bool bHidden) const |
Creates and returns a defined name on-the-fly in the sheet. More... | |
css::uno::Reference< css::sheet::XDatabaseRange > | createDatabaseRangeObject (OUString &orName, const ScRange &rRangeAddr) const |
Creates and returns a database range on-the-fly in the Calc document. More... | |
css::uno::Reference< css::sheet::XDatabaseRange > | createUnnamedDatabaseRangeObject (const ScRange &rRangeAddr) const |
Creates and returns an unnamed database range on-the-fly in the Calc document. More... | |
ScDBData * | findDatabaseRangeByIndex (sal_uInt16 nIndex) const |
Finds the (already existing) database range of the given formula token index. More... | |
css::uno::Reference< css::style::XStyle > | createStyleObject (OUString &orStyleName, bool bPageStyle) const |
Creates and returns a com.sun.star.style.Style object for cells or pages. More... | |
FormulaBuffer & | getFormulaBuffer () const |
WorkbookSettings & | getWorkbookSettings () const |
Returns the global workbook settings object. More... | |
ViewSettings & | getViewSettings () const |
Returns the workbook and sheet view settings object. More... | |
WorksheetBuffer & | getWorksheets () const |
Returns the worksheet buffer containing sheet names and properties. More... | |
ThemeBuffer & | getTheme () const |
Returns the office theme object read from the theme substorage. More... | |
StylesBuffer & | getStyles () const |
Returns all cell formatting objects read from the styles substream. More... | |
SharedStringsBuffer & | getSharedStrings () const |
Returns the shared strings read from the shared strings substream. More... | |
ExternalLinkBuffer & | getExternalLinks () const |
Returns the external links read from the external links substream. More... | |
DefinedNamesBuffer & | getDefinedNames () const |
Returns the defined names read from the workbook globals. More... | |
TableBuffer & | getTables () const |
Returns the tables collection (equivalent to Calc's database ranges). More... | |
ScenarioBuffer & | getScenarios () const |
Returns the scenarios collection. More... | |
ConnectionsBuffer & | getConnections () const |
Returns the collection of external data connections. More... | |
PivotCacheBuffer & | getPivotCaches () const |
Returns the collection of pivot caches. More... | |
PivotTableBuffer & | getPivotTables () const |
Returns the collection of pivot tables. More... | |
FormulaParser & | getFormulaParser () const |
Returns a shared import formula parser (import filter only!). More... | |
FormulaParser * | createFormulaParser () const |
Returns an unshared import formula parser (import filter only!). More... | |
UnitConverter & | getUnitConverter () const |
Returns the measurement unit converter. More... | |
AddressConverter & | getAddressConverter () const |
Returns the converter for string to cell address/range conversion. More... | |
oox::drawingml::chart::ChartConverter * | getChartConverter () const |
Returns the chart object converter. More... | |
PageSettingsConverter & | getPageSettingsConverter () const |
Returns the page and print settings converter. More... | |
::oox::core::XmlFilterBase & | getOoxFilter () const |
Returns the base OOXML/BIFF12 filter object. More... | |
bool | importOoxFragment (const rtl::Reference< oox::core::FragmentHandler > &rxHandler) |
Imports a fragment using the passed fragment handler, which contains the full path to the fragment stream. More... | |
bool | importOoxFragment (const rtl::Reference< oox::core::FragmentHandler > &rxHandler, oox::core::FastParser &rParser) |
rtl_TextEncoding | getTextEncoding () const |
Returns the text encoding used to import/export byte strings. More... | |
Private Member Functions | |
void | setExternalTargetUrl (const OUString &rTargetUrl, const OUString &rTargetType) |
void | setDdeOleTargetUrl (const OUString &rClassName, const OUString &rTargetUrl, ExternalLinkType eLinkType) |
void | parseExternalReference (const ::oox::core::Relations &rRelations, const OUString &rRelId) |
void | insertExternalSheet (const OUString &rSheetName) |
Creates an external document link and the sheet cache for the passed sheet name. More... | |
ExternalNameRef | createExternalName () |
Private Attributes | |
ExternalLinkType | meLinkType |
FunctionLibraryType | meFuncLibType |
Type of this link object. More... | |
OUString | maRelId |
Type of the function library, if link type is ExternalLinkType::Library. More... | |
OUString | maClassName |
Relation identifier for the external link fragment. More... | |
OUString | maTargetUrl |
DDE service, OLE class name. More... | |
css::uno::Reference< css::sheet::XExternalDocLink > | mxDocLink |
Target link, DDE topic, OLE target. More... | |
std::vector< sal_Int32 > | maSheetCaches |
Interface for an external document. More... | |
RefVector< ExternalName > | maExtNames |
External sheet cache indexes. More... | |
Additional Inherited Members | |
Public Types inherited from oox::xls::WorkbookHelper | |
typedef std::pair< ScRangeData *, bool > | RangeDataRet |
Static Public Member Functions inherited from oox::xls::WorkbookHelper | |
static WorkbookGlobalsRef | constructGlobals (ExcelFilter &rFilter) |
Definition at line 190 of file externallinkbuffer.hxx.
|
explicit |
Definition at line 283 of file externallinkbuffer.cxx.
References Unknown.
|
private |
Definition at line 563 of file externallinkbuffer.cxx.
References maExtNames.
Referenced by importDdeItem(), importDefinedName(), importExternalName(), and importOleItem().
|
inline |
Returns the class name of this external link.
Definition at line 236 of file externallinkbuffer.hxx.
References maClassName.
Referenced by oox::xls::ExternalName::getDdeLinkData().
sal_Int32 oox::xls::ExternalLink::getDocumentLinkIndex | ( | ) | const |
Returns the token index of the external document.
Definition at line 445 of file externallinkbuffer.cxx.
References oox::xls::External, meLinkType, and mxDocLink.
Referenced by getSheetRange().
FunctionLibraryType oox::xls::ExternalLink::getFuncLibraryType | ( | ) | const |
Returns the type of the external library if this is a library link.
Definition at line 440 of file externallinkbuffer.cxx.
References oox::xls::FUNCLIB_UNKNOWN, oox::xls::Library, meFuncLibType, and meLinkType.
Referenced by oox::xls::FormulaParserImpl::pushExternalNameOperand(), and oox::xls::FormulaParserImpl::resolveBadFuncName().
ExternalLinkInfo oox::xls::ExternalLink::getLinkInfo | ( | ) | const |
Returns the link info needed by the XML formula parser.
Definition at line 402 of file externallinkbuffer.cxx.
References aItemInfos, comphelper::containerToSequence(), oox::xls::DDE, oox::xls::External, oox::xls::Library, maClassName, maExtNames, maTargetUrl, meLinkType, oox::xls::Same, and oox::xls::Self.
|
inline |
Returns the type of this external link.
Definition at line 231 of file externallinkbuffer.hxx.
References meLinkType.
Referenced by oox::xls::ExternalName::getDdeItemInfo(), oox::xls::ExternalName::getDdeLinkData(), oox::xls::ExternalName::importExternalNameFlags(), oox::xls::FormulaParser::importMacroName(), oox::xls::ExternalLinkFragment::onCreateContext(), oox::xls::ExternalLinkFragment::onCreateRecordContext(), oox::xls::FormulaParserImpl::pushExternalNameOperand(), oox::xls::FormulaParserImpl::resolveBadFuncName(), oox::xls::FormulaParserImpl::resolveOleTarget(), and oox::xls::ExternalName::setResultSize().
ExternalNameRef oox::xls::ExternalLink::getNameByIndex | ( | sal_Int32 | nIndex | ) | const |
Returns the external name with the passed zero-based index.
Definition at line 498 of file externallinkbuffer.cxx.
References maExtNames, and nIndex.
|
inline |
Returns the relation identifier for the external link fragment.
Definition at line 234 of file externallinkbuffer.hxx.
References maRelId.
Referenced by oox::xls::WorkbookFragment::importExternalLinkFragment().
Reference< XExternalSheetCache > oox::xls::ExternalLink::getSheetCache | ( | sal_Int32 | nTabId | ) | const |
Returns the sheet cache of the external sheet with the passed index.
Definition at line 457 of file externallinkbuffer.cxx.
References Exception, getSheetCacheIndex(), and mxDocLink.
Referenced by oox::xls::ExternalLinkFragment::createSheetDataContext().
sal_Int32 oox::xls::ExternalLink::getSheetCacheIndex | ( | sal_Int32 | nTabId | ) | const |
Returns the external sheet cache index or for the passed sheet.
Definition at line 451 of file externallinkbuffer.cxx.
References oox::xls::External, oox::ContainerHelper::getVectorElement(), maSheetCaches, and meLinkType.
Referenced by getSheetCache(), and getSheetRange().
void oox::xls::ExternalLink::getSheetRange | ( | LinkSheetRange & | orSheetRange, |
sal_Int32 | nTabId1, | ||
sal_Int32 | nTabId2 | ||
) | const |
Returns the internal sheet range or range of external sheet caches for the passed sheet range (BIFF only).
Definition at line 472 of file externallinkbuffer.cxx.
References oox::xls::External, getDocumentLinkIndex(), getSheetCacheIndex(), meLinkType, oox::xls::Same, oox::xls::Self, oox::xls::LinkSheetRange::setDeleted(), oox::xls::LinkSheetRange::setExternalRange(), oox::xls::LinkSheetRange::setRange(), and oox::xls::LinkSheetRange::setSameSheet().
|
inline |
Returns the target URL of this external link.
Definition at line 238 of file externallinkbuffer.hxx.
References maTargetUrl.
Referenced by oox::xls::ExternalName::getDdeLinkData(), oox::xls::ExternalName::importDefinedName(), and oox::xls::FormulaParserImpl::resolveOleTarget().
ExternalNameRef oox::xls::ExternalLink::importDdeItem | ( | const AttributeList & | rAttribs | ) |
Imports the ddeItem element describing an item of a DDE link.
Definition at line 317 of file externallinkbuffer.cxx.
References createExternalName().
Referenced by oox::xls::ExternalLinkFragment::onCreateContext().
void oox::xls::ExternalLink::importDdeLink | ( | const AttributeList & | rAttribs | ) |
Imports the ddeLink element describing a DDE link.
Definition at line 310 of file externallinkbuffer.cxx.
References oox::xls::DDE, oox::AttributeList::getXString(), and setDdeOleTargetUrl().
Referenced by oox::xls::ExternalLinkFragment::onCreateContext().
void oox::xls::ExternalLink::importDefinedName | ( | const AttributeList & | rAttribs | ) |
Imports the definedName element describing an external name.
Definition at line 305 of file externallinkbuffer.cxx.
References createExternalName().
Referenced by oox::xls::ExternalLinkFragment::onCreateContext().
void oox::xls::ExternalLink::importExternalAddin | ( | SequenceInputStream & | rStrm | ) |
Imports the EXTERNALADDIN record from the passed stream.
Definition at line 353 of file externallinkbuffer.cxx.
References meLinkType, and oox::xls::Unknown.
void oox::xls::ExternalLink::importExternalBook | ( | const ::oox::core::Relations & | rRelations, |
const AttributeList & | rAttribs | ||
) |
Imports the externalBook element describing an externally linked document.
Referenced by oox::xls::ExternalLinkFragment::onCreateContext(), and oox::xls::ExternalLinkFragment::onCreateRecordContext().
void oox::xls::ExternalLink::importExternalBook | ( | const ::oox::core::Relations & | rRelations, |
SequenceInputStream & | rStrm | ||
) |
Imports the EXTERNALBOOK record describing an externally linked document, DDE link, or OLE link.
ExternalNameRef oox::xls::ExternalLink::importExternalName | ( | SequenceInputStream & | rStrm | ) |
Imports the EXTERNALNAME record describing an external name.
Definition at line 395 of file externallinkbuffer.cxx.
References createExternalName(), and rStrm.
Referenced by oox::xls::ExternalLinkFragment::onCreateRecordContext().
void oox::xls::ExternalLink::importExternalRef | ( | SequenceInputStream & | rStrm | ) |
Imports the EXTERNALREF record from the passed stream.
Definition at line 338 of file externallinkbuffer.cxx.
void oox::xls::ExternalLink::importExternalReference | ( | const AttributeList & | rAttribs | ) |
Imports the externalReference element containing the relation identifier.
Definition at line 290 of file externallinkbuffer.cxx.
References oox::AttributeList::getString(), and maRelId.
void oox::xls::ExternalLink::importExternalSame | ( | SequenceInputStream & | rStrm | ) |
Imports the EXTERNALSAME record from the passed stream.
Definition at line 348 of file externallinkbuffer.cxx.
References meLinkType, and oox::xls::Same.
void oox::xls::ExternalLink::importExternalSelf | ( | SequenceInputStream & | rStrm | ) |
Imports the EXTERNALSELF record from the passed stream.
Definition at line 343 of file externallinkbuffer.cxx.
References meLinkType, and oox::xls::Self.
void oox::xls::ExternalLink::importExtSheetNames | ( | SequenceInputStream & | rStrm | ) |
Imports the EXTSHEETNAMES record containing the sheet names in an externally linked document.
Definition at line 384 of file externallinkbuffer.cxx.
References oox::xls::External, insertExternalSheet(), oox::xls::Library, meLinkType, nCount, oox::xls::BiffHelper::readString(), rStrm, and SAL_WARN_IF.
Referenced by oox::xls::ExternalLinkFragment::onCreateRecordContext().
ExternalNameRef oox::xls::ExternalLink::importOleItem | ( | const AttributeList & | rAttribs | ) |
Imports the oleItem element describing an object of an OLE link.
Definition at line 331 of file externallinkbuffer.cxx.
References createExternalName().
Referenced by oox::xls::ExternalLinkFragment::onCreateContext().
void oox::xls::ExternalLink::importOleLink | ( | const ::oox::core::Relations & | rRelations, |
const AttributeList & | rAttribs | ||
) |
Imports the oleLink element describing an OLE link.
Definition at line 324 of file externallinkbuffer.cxx.
References oox::AttributeList::getString(), oox::AttributeList::getXString(), oox::xls::OLE, and setDdeOleTargetUrl().
Referenced by oox::xls::ExternalLinkFragment::onCreateContext().
void oox::xls::ExternalLink::importSheetName | ( | const AttributeList & | rAttribs | ) |
Imports the sheetName element containing the sheet name in an externally linked document.
Definition at line 300 of file externallinkbuffer.cxx.
References oox::AttributeList::getXString(), and insertExternalSheet().
Referenced by oox::xls::ExternalLinkFragment::onCreateContext().
|
private |
Creates an external document link and the sheet cache for the passed sheet name.
Definition at line 552 of file externallinkbuffer.cxx.
References maSheetCaches, and mxDocLink.
Referenced by importExtSheetNames(), and importSheetName().
|
private |
Definition at line 546 of file externallinkbuffer.cxx.
References Relation, and setExternalTargetUrl().
|
private |
Definition at line 538 of file externallinkbuffer.cxx.
References maClassName, maTargetUrl, meLinkType, and oox::xls::Unknown.
Referenced by importDdeLink(), and importOleLink().
|
private |
Definition at line 505 of file externallinkbuffer.cxx.
References CREATE_MSOFFICE_RELATION_TYPE, CREATE_OFFICEDOC_RELATION_TYPE, CREATE_OFFICEDOC_RELATION_TYPE_STRICT, Exception, oox::xls::External, oox::core::FilterBase::getAbsoluteUrl(), oox::PropertySet::getAnyProperty(), oox::xls::WorkbookHelper::getBaseFilter(), oox::xls::WorkbookHelper::getDocument(), oox::xls::FunctionProvider::getFuncLibTypeFromLibraryName(), oox::xls::Library, maTargetUrl, meFuncLibType, meLinkType, mxDocLink, oox::xls::PathMissing, SAL_WARN_IF, and oox::xls::Unknown.
Referenced by parseExternalReference().
|
inline |
Sets the link type to 'self reference'.
Definition at line 228 of file externallinkbuffer.hxx.
References meLinkType, and oox::xls::Self.
|
private |
Relation identifier for the external link fragment.
Definition at line 273 of file externallinkbuffer.hxx.
Referenced by getClassName(), getLinkInfo(), and setDdeOleTargetUrl().
|
private |
External sheet cache indexes.
Definition at line 278 of file externallinkbuffer.hxx.
Referenced by createExternalName(), getLinkInfo(), and getNameByIndex().
|
private |
Type of the function library, if link type is ExternalLinkType::Library.
Definition at line 272 of file externallinkbuffer.hxx.
Referenced by getRelId(), importExternalRef(), and importExternalReference().
|
private |
Interface for an external document.
Definition at line 277 of file externallinkbuffer.hxx.
Referenced by getSheetCacheIndex(), and insertExternalSheet().
|
private |
DDE service, OLE class name.
Definition at line 274 of file externallinkbuffer.hxx.
Referenced by getLinkInfo(), getTargetUrl(), setDdeOleTargetUrl(), and setExternalTargetUrl().
|
private |
Type of this link object.
Definition at line 271 of file externallinkbuffer.hxx.
Referenced by getFuncLibraryType(), and setExternalTargetUrl().
|
private |
Definition at line 270 of file externallinkbuffer.hxx.
Referenced by getDocumentLinkIndex(), getFuncLibraryType(), getLinkInfo(), getLinkType(), getSheetCacheIndex(), getSheetRange(), importExternalAddin(), importExternalSame(), importExternalSelf(), importExtSheetNames(), setDdeOleTargetUrl(), setExternalTargetUrl(), and setSelfLinkType().
|
private |
Target link, DDE topic, OLE target.
Definition at line 276 of file externallinkbuffer.hxx.
Referenced by getDocumentLinkIndex(), getSheetCache(), insertExternalSheet(), and setExternalTargetUrl().