LibreOffice Module sw (master) 1
Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | List of all members
SwXMLImport Class Reference

#include <xmlimp.hxx>

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

Public Member Functions

 SwXMLImport (const css::uno::Reference< css::uno::XComponentContext > &rContext, OUString const &implementationName, SvXMLImportFlags nImportFlags)
 
virtual ~SwXMLImport () noexcept override
 
virtual void SAL_CALL startDocument () override
 
virtual void SAL_CALL endDocument () override
 
virtual void SAL_CALL initialize (const css::uno::Sequence< css::uno::Any > &aArguments) override
 
void InsertStyles (bool bAuto)
 
void FinishStyles ()
 
SvXMLImportContextCreateMetaContext (const sal_Int32 nElement)
 
SvXMLImportContextCreateScriptContext ()
 
SvXMLImportContextCreateStylesContext (bool bAuto)
 
SvXMLImportContextCreateMasterStylesContext ()
 
SvXMLImportContextCreateFontDeclsContext ()
 
SvXMLImportContextCreateBodyContentContext ()
 
SfxStyleFamily GetStyleFamilyMask () const
 
bool IsInsertMode () const
 
bool IsStylesOnlyMode () const
 
bool IsBlockMode () const
 
const SvXMLImportItemMapperGetTableItemMapper () const
 
SvXMLImportItemMapperGetTableItemMapper ()
 
SvXMLImportContextCreateTableItemImportContext (sal_Int32 nElement, const css::uno::Reference< css::xml::sax::XFastAttributeList > &xAttrList, XmlStyleFamily nSubFamily, SfxItemSet &rItemSet)
 
bool FindAutomaticStyle (XmlStyleFamily nFamily, const OUString &rName, const SfxItemSet **ppItemSet) const
 
void MergeListsAtDocumentInsertPosition (SwDoc *pDoc)
 
virtual void SetStatistics (const css::uno::Sequence< css::beans::NamedValue > &i_rStats) override
 
virtual void SetViewSettings (const css::uno::Sequence< css::beans::PropertyValue > &aViewProps) override
 
virtual void SetConfigurationSettings (const css::uno::Sequence< css::beans::PropertyValue > &aConfigProps) override
 
virtual void SetDocumentSpecificSettings (const OUString &_rSettingsGroupName, const css::uno::Sequence< css::beans::PropertyValue > &_rSettings) override
 
virtual void initXForms () override
 
css::uno::Reference< css::document::XDocumentProperties > GetDocumentProperties () const
 
virtual void NotifyContainsEmbeddedFont () override
 
const SwDocgetDoc () const
 
SwDocgetDoc ()
 
const OUString & GetDefTableName ()
 
std::map< OUString, sal_uInt32 > & GetTableNameMap ()
 

Protected Member Functions

virtual SvXMLImportContextCreateFastContext (sal_Int32 nElement, const ::css::uno::Reference< ::css::xml::sax::XFastAttributeList > &xAttrList) override
 
virtual XMLTextImportHelperCreateTextImport () override
 
virtual XMLShapeImportHelperCreateShapeImport () override
 

Private Member Functions

void InitItemImport ()
 
void FinitItemImport ()
 
void UpdateTextCollConditions (SwDoc *pDoc)
 
void setTextInsertMode (const css::uno::Reference< css::text::XTextRange > &rInsertPos)
 
void setStyleInsertMode (SfxStyleFamily nFamilies, bool bOverwrite)
 

Private Attributes

std::optional< SwNodeIndexm_oSttNdIdx
 
std::unique_ptr< SvXMLUnitConverterm_pTwipUnitConv
 
std::unique_ptr< SvXMLImportItemMapperm_pTableItemMapper
 
rtl::Reference< SvXMLGraphicHelperm_xGraphicStorageHandler
 
rtl::Reference< SvXMLEmbeddedObjectHelperm_xEmbeddedResolver
 
SvXMLItemMapEntriesRef m_xTableItemMap
 
SvXMLItemMapEntriesRef m_xTableColItemMap
 
SvXMLItemMapEntriesRef m_xTableRowItemMap
 
SvXMLItemMapEntriesRef m_xTableCellItemMap
 
css::uno::Reference< css::container::XNameContainer > m_xLateInitSettings
 
SfxStyleFamily m_nStyleFamilyMask
 
bool m_bLoadDoc: 1
 
bool m_bInsert: 1
 
bool m_bBlock: 1
 
bool m_bOrganizerMode: 1
 
bool m_bInititedXForms: 1
 
SwDocm_pDoc
 
OUString m_sDefTableName
 
std::map< OUString, sal_uInt32 > m_aTableNameMap
 

Detailed Description

Definition at line 57 of file xmlimp.hxx.

Constructor & Destructor Documentation

◆ SwXMLImport()

SwXMLImport::SwXMLImport ( const css::uno::Reference< css::uno::XComponentContext > &  rContext,
OUString const &  implementationName,
SvXMLImportFlags  nImportFlags 
)

Definition at line 322 of file xmlimp.cxx.

References All, implementationName, and InitItemImport().

◆ ~SwXMLImport()

SwXMLImport::~SwXMLImport ( )
overridevirtualnoexcept

Definition at line 338 of file xmlimp.cxx.

References cleanup(), FinitItemImport(), and SAL_WARN.

Member Function Documentation

◆ CreateBodyContentContext()

SvXMLImportContext * SwXMLImport::CreateBodyContentContext ( )

Definition at line 67 of file xmltext.cxx.

References IsStylesOnlyMode().

◆ CreateFastContext()

SvXMLImportContext * SwXMLImport::CreateFastContext ( sal_Int32  nElement,
const ::css::uno::Reference< ::css::xml::sax::XFastAttributeList > &  xAttrList 
)
overrideprotectedvirtual

◆ CreateFontDeclsContext()

SvXMLImportContext * SwXMLImport::CreateFontDeclsContext ( )

Definition at line 1138 of file xmlimp.cxx.

◆ CreateMasterStylesContext()

SvXMLImportContext * SwXMLImport::CreateMasterStylesContext ( )

Definition at line 985 of file xmlfmt.cxx.

◆ CreateMetaContext()

SvXMLImportContext * SwXMLImport::CreateMetaContext ( const sal_Int32  nElement)

Definition at line 53 of file xmlmeta.cxx.

References GetDocumentProperties().

Referenced by CreateFastContext().

◆ CreateScriptContext()

SvXMLImportContext * SwXMLImport::CreateScriptContext ( )

Definition at line 25 of file xmlscript.cxx.

References IsInsertMode(), and IsStylesOnlyMode().

◆ CreateShapeImport()

XMLShapeImportHelper * SwXMLImport::CreateShapeImport ( )
overrideprotectedvirtual

Definition at line 1133 of file xmlimp.cxx.

◆ CreateStylesContext()

SvXMLImportContext * SwXMLImport::CreateStylesContext ( bool  bAuto)

Definition at line 973 of file xmlfmt.cxx.

◆ CreateTableItemImportContext()

SvXMLImportContext * SwXMLImport::CreateTableItemImportContext ( sal_Int32  nElement,
const css::uno::Reference< css::xml::sax::XFastAttributeList > &  xAttrList,
XmlStyleFamily  nSubFamily,
SfxItemSet rItemSet 
)

◆ CreateTextImport()

XMLTextImportHelper * SwXMLImport::CreateTextImport ( )
overrideprotectedvirtual

Definition at line 1125 of file xmlimp.cxx.

References IsBlockMode(), IsInsertMode(), IsStylesOnlyMode(), and m_bOrganizerMode.

◆ endDocument()

void SwXMLImport::endDocument ( )
overridevirtual

Definition at line 613 of file xmlimp.cxx.

References SwPosition::Adjust(), applyXFormsSettings(), SwPosition::Assign(), SwContentNode::CanJoinNext(), SwContentNode::CanJoinPrev(), SwTextNode::ChgFormatColl(), SwTextNode::CopyCollFormat(), Count, SwNodes::Delete(), SwPaM::DeleteMark(), SwNode::EndOfSectionIndex(), Exception, fnMoveBackward, SwTextNode::FormatToTextAttr(), SwPaM::GetBound(), SwPosition::GetContentIndex(), SwPaM::GetDoc(), getDoc(), IDocumentDrawModelAccess::GetDrawModel(), SwDoc::getIDocumentDrawModelAccess(), SwNodeIndex::GetIndex(), SwPaM::GetMark(), SwContentNode::GetNoCondAttr(), SwNodeIndex::GetNode(), SwPosition::GetNode(), SwPosition::GetNodeIndex(), SwDoc::GetNodes(), SwPaM::GetPoint(), SwPaM::GetPointContentNode(), SwTextNode::GetText(), SwTextNode::GetTextColl(), SwNode::GetTextNode(), GetXMLToken(), SwPaM::HasMark(), i, SwNode::IsContentNode(), SwNode::IsEndNode(), SwDoc::IsInReading(), IsInsertMode(), SwDoc::IsInXMLImport(), SwDoc::IsOLEPrtNotifyPending(), SwNode::IsSectionNode(), IsStylesOnlyMode(), SwNode::IsTextNode(), SwTextNode::JoinNext(), SwTextNode::JoinPrev(), m_bInititedXForms, m_oSttNdIdx, m_xEmbeddedResolver, m_xGraphicStorageHandler, m_xLateInitSettings, MergeListsAtDocumentInsertPosition(), SwPaM::Move(), SwDoc::PrtOLENotify(), RES_CHRATR_BEGIN(), RES_CHRATR_END(), RES_PARATR_LIST_ID(), SwTextNode::ResetAttr(), SwPosition::SetContent(), SwDoc::SetInReading(), SwDoc::SetInXMLImport(), SdrModel::setLock(), SwPaM::SetMark(), SwNode::StartOfSectionIndex(), SwNode::StartOfSectionNode(), UpdateTextCollConditions(), and XML_XFORM_MODEL_SETTINGS.

◆ FindAutomaticStyle()

bool SwXMLImport::FindAutomaticStyle ( XmlStyleFamily  nFamily,
const OUString &  rName,
const SfxItemSet **  ppItemSet 
) const

Definition at line 1043 of file xmlfmt.cxx.

Referenced by SwXMLTableContext::MakeTable().

◆ FinishStyles()

void SwXMLImport::FinishStyles ( )

Definition at line 1002 of file xmlfmt.cxx.

References IsInsertMode().

◆ FinitItemImport()

void SwXMLImport::FinitItemImport ( )
private

Definition at line 239 of file xmlitemi.cxx.

References m_pTableItemMapper, and m_pTwipUnitConv.

Referenced by ~SwXMLImport().

◆ GetDefTableName()

const OUString & SwXMLImport::GetDefTableName ( )
inline

Definition at line 171 of file xmlimp.hxx.

References m_sDefTableName.

◆ getDoc() [1/2]

SwDoc * SwXMLImport::getDoc ( )

Definition at line 1670 of file xmlimp.cxx.

References SwXText::GetDoc(), and m_pDoc.

◆ getDoc() [2/2]

const SwDoc * SwXMLImport::getDoc ( ) const

◆ GetDocumentProperties()

uno::Reference< document::XDocumentProperties > SwXMLImport::GetDocumentProperties ( ) const

Definition at line 41 of file xmlmeta.cxx.

References IsBlockMode(), IsInsertMode(), IsStylesOnlyMode(), and m_bOrganizerMode.

Referenced by CreateFastContext(), and CreateMetaContext().

◆ GetStyleFamilyMask()

SfxStyleFamily SwXMLImport::GetStyleFamilyMask ( ) const
inline

Definition at line 136 of file xmlimp.hxx.

References m_nStyleFamilyMask.

◆ GetTableItemMapper() [1/2]

SvXMLImportItemMapper & SwXMLImport::GetTableItemMapper ( )
inline

Definition at line 180 of file xmlimp.hxx.

References m_pTableItemMapper.

◆ GetTableItemMapper() [2/2]

const SvXMLImportItemMapper & SwXMLImport::GetTableItemMapper ( ) const
inline

Definition at line 175 of file xmlimp.hxx.

References m_pTableItemMapper.

Referenced by CreateTableItemImportContext().

◆ GetTableNameMap()

std::map< OUString, sal_uInt32 > & SwXMLImport::GetTableNameMap ( )
inline

Definition at line 172 of file xmlimp.hxx.

References m_aTableNameMap.

◆ initialize()

void SwXMLImport::initialize ( const css::uno::Sequence< css::uno::Any > &  aArguments)
overridevirtual

Definition at line 1633 of file xmlimp.cxx.

References aArguments, and m_xLateInitSettings.

◆ InitItemImport()

void SwXMLImport::InitItemImport ( )
private

◆ initXForms()

void SwXMLImport::initXForms ( )
overridevirtual

◆ InsertStyles()

void SwXMLImport::InsertStyles ( bool  bAuto)

Definition at line 994 of file xmlfmt.cxx.

References IsInsertMode().

◆ IsBlockMode()

bool SwXMLImport::IsBlockMode ( ) const
inline

Definition at line 139 of file xmlimp.hxx.

References m_bBlock.

Referenced by CreateTextImport(), GetDocumentProperties(), and SetViewSettings().

◆ IsInsertMode()

bool SwXMLImport::IsInsertMode ( ) const
inline

◆ IsStylesOnlyMode()

bool SwXMLImport::IsStylesOnlyMode ( ) const
inline

◆ MergeListsAtDocumentInsertPosition()

void SwXMLImport::MergeListsAtDocumentInsertPosition ( SwDoc pDoc)

◆ NotifyContainsEmbeddedFont()

void SwXMLImport::NotifyContainsEmbeddedFont ( )
overridevirtual

◆ SetConfigurationSettings()

void SwXMLImport::SetConfigurationSettings ( const css::uno::Sequence< css::beans::PropertyValue > &  aConfigProps)
overridevirtual

◆ SetDocumentSpecificSettings()

void SwXMLImport::SetDocumentSpecificSettings ( const OUString &  _rSettingsGroupName,
const css::uno::Sequence< css::beans::PropertyValue > &  _rSettings 
)
overridevirtual

Definition at line 1604 of file xmlimp.cxx.

References Any, Exception, IsXMLToken(), m_xLateInitSettings, and XML_XFORM_MODEL_SETTINGS.

◆ SetStatistics()

void SwXMLImport::SetStatistics ( const css::uno::Sequence< css::beans::NamedValue > &  i_rStats)
overridevirtual

◆ setStyleInsertMode()

void SwXMLImport::setStyleInsertMode ( SfxStyleFamily  nFamilies,
bool  bOverwrite 
)
private

Definition at line 362 of file xmlimp.cxx.

References m_bInsert, m_bLoadDoc, and m_nStyleFamilyMask.

Referenced by startDocument().

◆ setTextInsertMode()

void SwXMLImport::setTextInsertMode ( const css::uno::Reference< css::text::XTextRange > &  rInsertPos)
private

Definition at line 351 of file xmlimp.cxx.

References m_bInsert.

Referenced by startDocument().

◆ SetViewSettings()

void SwXMLImport::SetViewSettings ( const css::uno::Sequence< css::beans::PropertyValue > &  aViewProps)
overridevirtual

◆ startDocument()

void SwXMLImport::startDocument ( )
overridevirtual

◆ UpdateTextCollConditions()

void SwXMLImport::UpdateTextCollConditions ( SwDoc pDoc)
private

Member Data Documentation

◆ m_aTableNameMap

std::map<OUString, sal_uInt32> SwXMLImport::m_aTableNameMap
private

Definition at line 89 of file xmlimp.hxx.

Referenced by GetTableNameMap().

◆ m_bBlock

bool SwXMLImport::m_bBlock
private

Definition at line 81 of file xmlimp.hxx.

Referenced by IsBlockMode(), and startDocument().

◆ m_bInititedXForms

bool SwXMLImport::m_bInititedXForms
private

Definition at line 83 of file xmlimp.hxx.

Referenced by endDocument(), and initXForms().

◆ m_bInsert

bool SwXMLImport::m_bInsert
private

Definition at line 77 of file xmlimp.hxx.

Referenced by IsInsertMode(), setStyleInsertMode(), and setTextInsertMode().

◆ m_bLoadDoc

bool SwXMLImport::m_bLoadDoc
private

Definition at line 76 of file xmlimp.hxx.

Referenced by IsStylesOnlyMode(), and setStyleInsertMode().

◆ m_bOrganizerMode

bool SwXMLImport::m_bOrganizerMode
private

Definition at line 82 of file xmlimp.hxx.

Referenced by CreateTextImport(), GetDocumentProperties(), SetViewSettings(), and startDocument().

◆ m_nStyleFamilyMask

SfxStyleFamily SwXMLImport::m_nStyleFamilyMask
private

Definition at line 75 of file xmlimp.hxx.

Referenced by GetStyleFamilyMask(), and setStyleInsertMode().

◆ m_oSttNdIdx

std::optional<SwNodeIndex> SwXMLImport::m_oSttNdIdx
private

Definition at line 59 of file xmlimp.hxx.

Referenced by endDocument(), MergeListsAtDocumentInsertPosition(), and startDocument().

◆ m_pDoc

SwDoc* SwXMLImport::m_pDoc
private

Definition at line 85 of file xmlimp.hxx.

Referenced by getDoc().

◆ m_pTableItemMapper

std::unique_ptr<SvXMLImportItemMapper> SwXMLImport::m_pTableItemMapper
private

◆ m_pTwipUnitConv

std::unique_ptr<SvXMLUnitConverter> SwXMLImport::m_pTwipUnitConv
private

Definition at line 61 of file xmlimp.hxx.

Referenced by CreateTableItemImportContext(), FinitItemImport(), and InitItemImport().

◆ m_sDefTableName

OUString SwXMLImport::m_sDefTableName
private

Definition at line 88 of file xmlimp.hxx.

Referenced by GetDefTableName().

◆ m_xEmbeddedResolver

rtl::Reference<SvXMLEmbeddedObjectHelper> SwXMLImport::m_xEmbeddedResolver
private

Definition at line 66 of file xmlimp.hxx.

Referenced by endDocument(), and startDocument().

◆ m_xGraphicStorageHandler

rtl::Reference<SvXMLGraphicHelper> SwXMLImport::m_xGraphicStorageHandler
private

Definition at line 64 of file xmlimp.hxx.

Referenced by endDocument(), and startDocument().

◆ m_xLateInitSettings

css::uno::Reference< css::container::XNameContainer > SwXMLImport::m_xLateInitSettings
private

Definition at line 73 of file xmlimp.hxx.

Referenced by endDocument(), initialize(), and SetDocumentSpecificSettings().

◆ m_xTableCellItemMap

SvXMLItemMapEntriesRef SwXMLImport::m_xTableCellItemMap
private

Definition at line 71 of file xmlimp.hxx.

Referenced by CreateTableItemImportContext(), and InitItemImport().

◆ m_xTableColItemMap

SvXMLItemMapEntriesRef SwXMLImport::m_xTableColItemMap
private

Definition at line 69 of file xmlimp.hxx.

Referenced by CreateTableItemImportContext(), and InitItemImport().

◆ m_xTableItemMap

SvXMLItemMapEntriesRef SwXMLImport::m_xTableItemMap
private

Definition at line 68 of file xmlimp.hxx.

Referenced by CreateTableItemImportContext(), and InitItemImport().

◆ m_xTableRowItemMap

SvXMLItemMapEntriesRef SwXMLImport::m_xTableRowItemMap
private

Definition at line 70 of file xmlimp.hxx.

Referenced by CreateTableItemImportContext(), and InitItemImport().


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