LibreOffice Module xmloff (master) 1
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
SvXMLMetaExport Class Referencefinal

export meta data from an XDocumentProperties instance. More...

#include <xmlmetae.hxx>

Inheritance diagram for SvXMLMetaExport:
[legend]
Collaboration diagram for SvXMLMetaExport:
[legend]

Public Member Functions

 SvXMLMetaExport (SvXMLExport &i_rExport, css::uno::Reference< css::document::XDocumentProperties > i_xDocProps)
 
virtual ~SvXMLMetaExport () override
 
void Export ()
 export via XSAXWriter interface, with fallback to _MExport More...
 
virtual void SAL_CALL startDocument () override
 
virtual void SAL_CALL endDocument () override
 
virtual void SAL_CALL startElement (const OUString &i_rName, const css::uno::Reference< css::xml::sax::XAttributeList > &i_xAttribs) override
 
virtual void SAL_CALL endElement (const OUString &i_rName) override
 
virtual void SAL_CALL characters (const OUString &i_rChars) override
 
virtual void SAL_CALL ignorableWhitespace (const OUString &i_rWhitespaces) override
 
virtual void SAL_CALL processingInstruction (const OUString &i_rTarget, const OUString &i_rData) override
 
virtual void SAL_CALL setDocumentLocator (const css::uno::Reference< css::xml::sax::XLocator > &i_xLocator) override
 

Static Public Member Functions

static OUString GetISODateTimeString (const css::util::DateTime &rDateTime)
 

Private Member Functions

void SimpleStringElement (const OUString &rText, sal_uInt16 nNamespace, enum ::xmloff::token::XMLTokenEnum eElementName)
 
void SimpleDateTimeElement (const css::util::DateTime &rDate, sal_uInt16 nNamespace, enum ::xmloff::token::XMLTokenEnum eElementName)
 
void MExport_ ()
 currently unused; for exporting via the XDocumentProperties interface More...
 

Private Attributes

SvXMLExportmrExport
 
css::uno::Reference< css::document::XDocumentProperties > mxDocProps
 
int m_level
 counts levels of the xml document. necessary for special handling. More...
 
std::vector< css::beans::StringPair > m_preservedNSs
 preserved namespaces. necessary because we do not write the root node. More...
 

Detailed Description

export meta data from an XDocumentProperties instance.

This class will start the export at the office:meta element, not at the root element. This means that when <method>Export</method> is called here, the document root element must already be written, but office:meta must not be written.

Definition at line 49 of file xmlmetae.hxx.

Constructor & Destructor Documentation

◆ SvXMLMetaExport()

SvXMLMetaExport::SvXMLMetaExport ( SvXMLExport i_rExport,
css::uno::Reference< css::document::XDocumentProperties >  i_xDocProps 
)

Definition at line 303 of file xmlmetae.cxx.

References mxDocProps.

◆ ~SvXMLMetaExport()

SvXMLMetaExport::~SvXMLMetaExport ( )
overridevirtual

Definition at line 313 of file xmlmetae.cxx.

Member Function Documentation

◆ characters()

void SAL_CALL SvXMLMetaExport::characters ( const OUString &  i_rChars)
overridevirtual

Definition at line 456 of file xmlmetae.cxx.

References SvXMLExport::Characters(), and mrExport.

◆ endDocument()

void SAL_CALL SvXMLMetaExport::endDocument ( )
overridevirtual

Definition at line 355 of file xmlmetae.cxx.

References m_level.

◆ endElement()

void SAL_CALL SvXMLMetaExport::endElement ( const OUString &  i_rName)
overridevirtual

Definition at line 444 of file xmlmetae.cxx.

References SvXMLExport::EndElement(), m_level, and mrExport.

◆ Export()

void SvXMLMetaExport::Export ( )

◆ GetISODateTimeString()

OUString SvXMLMetaExport::GetISODateTimeString ( const css::util::DateTime &  rDateTime)
static

Definition at line 53 of file xmlmetae.cxx.

References lcl_AddTwoDigits().

Referenced by XMLVersionListExport::exportDoc(), MExport_(), and SimpleDateTimeElement().

◆ ignorableWhitespace()

void SAL_CALL SvXMLMetaExport::ignorableWhitespace ( const OUString &  i_rWhitespaces)
overridevirtual

Definition at line 462 of file xmlmetae.cxx.

References SvXMLExport::IgnorableWhitespace(), and mrExport.

◆ MExport_()

void SvXMLMetaExport::MExport_ ( )
private

currently unused; for exporting via the XDocumentProperties interface

define strings for xlink:show values

Definition at line 96 of file xmlmetae.cxx.

References SvXMLExport::AddAttribute(), SvXMLExport::Characters(), sax::Converter::convertAny(), sax::Converter::convertDuration(), LanguageTag::getBcp47(), utl::DocInfoHelper::GetGeneratorString(), GetISODateTimeString(), SvXMLExport::GetRelativeReference(), mrExport, mxDocProps, nValue, props, SAL_WARN, SimpleDateTimeElement(), SimpleStringElement(), sType, xmloff::token::XML_ACTUATE, xmloff::token::XML_AUTO_RELOAD, xmloff::token::XML_CELL_COUNT, xmloff::token::XML_CHARACTER_COUNT, xmloff::token::XML_CREATION_DATE, xmloff::token::XML_CREATOR, xmloff::token::XML_DATE, xmloff::token::XML_DELAY, xmloff::token::XML_DESCRIPTION, xmloff::token::XML_DOCUMENT_STATISTIC, xmloff::token::XML_EDITING_CYCLES, xmloff::token::XML_EDITING_DURATION, xmloff::token::XML_GENERATOR, xmloff::token::XML_HREF, xmloff::token::XML_HYPERLINK_BEHAVIOUR, xmloff::token::XML_IMAGE_COUNT, xmloff::token::XML_INITIAL_CREATOR, xmloff::token::XML_KEYWORD, xmloff::token::XML_LANGUAGE, xmloff::token::XML_NAME, XML_NAMESPACE_DC, XML_NAMESPACE_META, XML_NAMESPACE_OFFICE, XML_NAMESPACE_XLINK, xmloff::token::XML_NEW, xmloff::token::XML_OBJECT_COUNT, xmloff::token::XML_ONREQUEST, xmloff::token::XML_PAGE_COUNT, xmloff::token::XML_PARAGRAPH_COUNT, xmloff::token::XML_PRINT_DATE, xmloff::token::XML_PRINTED_BY, xmloff::token::XML_REPLACE, xmloff::token::XML_SHOW, xmloff::token::XML_SIMPLE, xmloff::token::XML_SUBJECT, xmloff::token::XML_TABLE_COUNT, xmloff::token::XML_TARGET_FRAME_NAME, xmloff::token::XML_TEMPLATE, xmloff::token::XML_TITLE, xmloff::token::XML_TYPE, xmloff::token::XML_USER_DEFINED, xmloff::token::XML_VALUE_TYPE, and xmloff::token::XML_WORD_COUNT.

Referenced by Export().

◆ processingInstruction()

void SAL_CALL SvXMLMetaExport::processingInstruction ( const OUString &  i_rTarget,
const OUString &  i_rData 
)
overridevirtual

Definition at line 468 of file xmlmetae.cxx.

◆ setDocumentLocator()

void SAL_CALL SvXMLMetaExport::setDocumentLocator ( const css::uno::Reference< css::xml::sax::XLocator > &  i_xLocator)
overridevirtual

Definition at line 475 of file xmlmetae.cxx.

◆ SimpleDateTimeElement()

void SvXMLMetaExport::SimpleDateTimeElement ( const css::util::DateTime &  rDate,
sal_uInt16  nNamespace,
enum ::xmloff::token::XMLTokenEnum  eElementName 
)
private

Definition at line 83 of file xmlmetae.cxx.

References SvXMLExport::Characters(), GetISODateTimeString(), mrExport, and nNamespace.

Referenced by MExport_().

◆ SimpleStringElement()

void SvXMLMetaExport::SimpleStringElement ( const OUString &  rText,
sal_uInt16  nNamespace,
enum ::xmloff::token::XMLTokenEnum  eElementName 
)
private

Definition at line 73 of file xmlmetae.cxx.

References SvXMLExport::Characters(), mrExport, and nNamespace.

Referenced by MExport_().

◆ startDocument()

void SAL_CALL SvXMLMetaExport::startDocument ( )
overridevirtual

Definition at line 348 of file xmlmetae.cxx.

References m_level.

◆ startElement()

void SAL_CALL SvXMLMetaExport::startElement ( const OUString &  i_rName,
const css::uno::Reference< css::xml::sax::XAttributeList > &  i_xAttribs 
)
overridevirtual

Member Data Documentation

◆ m_level

int SvXMLMetaExport::m_level
private

counts levels of the xml document. necessary for special handling.

Definition at line 56 of file xmlmetae.hxx.

Referenced by endDocument(), endElement(), startDocument(), and startElement().

◆ m_preservedNSs

std::vector< css::beans::StringPair > SvXMLMetaExport::m_preservedNSs
private

preserved namespaces. necessary because we do not write the root node.

Definition at line 58 of file xmlmetae.hxx.

Referenced by startElement().

◆ mrExport

SvXMLExport& SvXMLMetaExport::mrExport
private

◆ mxDocProps

css::uno::Reference< css::document::XDocumentProperties> SvXMLMetaExport::mxDocProps
private

Definition at line 54 of file xmlmetae.hxx.

Referenced by Export(), MExport_(), and SvXMLMetaExport().


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