LibreOffice Module sw (master) 1
Classes | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Attributes | List of all members
SwXContentControl Class Referencefinal

UNO API wrapper around an SwContentControl, exposed as the com.sun.star.text.ContentControl service. More...

#include <unocontentcontrol.hxx>

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

Classes

class  Impl
 The inner part SwXContentControl, which is deleted with a locked SolarMutex. More...
 

Public Member Functions

bool SetContentRange (SwTextNode *&rpNode, sal_Int32 &rStart, sal_Int32 &rEnd) const
 Initializes params with position of the attribute content (without CH_TXTATR). More...
 
const css::uno::Reference< css::text::XText > & GetParentText () const
 
OUString SAL_CALL getImplementationName () override
 
sal_Bool SAL_CALL supportsService (const OUString &rServiceName) override
 
css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames () override
 
void SAL_CALL dispose () override
 
void SAL_CALL addEventListener (const css::uno::Reference< css::lang::XEventListener > &xListener) override
 
void SAL_CALL removeEventListener (const css::uno::Reference< css::lang::XEventListener > &xListener) override
 
css::uno::Type SAL_CALL getElementType () override
 
sal_Bool SAL_CALL hasElements () override
 
css::uno::Reference< css::container::XEnumeration > SAL_CALL createEnumeration () override
 
void SAL_CALL attach (const css::uno::Reference< css::text::XTextRange > &xTextRange) override
 
css::uno::Reference< css::text::XTextRange > SAL_CALL getAnchor () override
 
css::uno::Reference< css::text::XText > SAL_CALL getText () override
 
css::uno::Reference< css::text::XTextRange > SAL_CALL getStart () override
 
css::uno::Reference< css::text::XTextRange > SAL_CALL getEnd () override
 
OUString SAL_CALL getString () override
 
void SAL_CALL setString (const OUString &rString) override
 
css::uno::Reference< css::text::XTextCursor > SAL_CALL createTextCursor () override
 
css::uno::Reference< css::text::XTextCursor > SAL_CALL createTextCursorByRange (const css::uno::Reference< css::text::XTextRange > &xTextPosition) override
 
void SAL_CALL insertString (const css::uno::Reference< css::text::XTextRange > &xRange, const OUString &aString, sal_Bool bAbsorb) override
 
void SAL_CALL insertControlCharacter (const css::uno::Reference< css::text::XTextRange > &xRange, sal_Int16 nControlCharacter, sal_Bool bAbsorb) override
 
void SAL_CALL insertTextContent (const css::uno::Reference< css::text::XTextRange > &xRange, const css::uno::Reference< css::text::XTextContent > &xContent, sal_Bool bAbsorb) override
 
void SAL_CALL removeTextContent (const css::uno::Reference< css::text::XTextContent > &xContent) override
 
css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo () override
 
void SAL_CALL setPropertyValue (const OUString &rPropertyName, const css::uno::Any &rValue) override
 
css::uno::Any SAL_CALL getPropertyValue (const OUString &rPropertyName) override
 
void SAL_CALL addPropertyChangeListener (const OUString &rPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener > &xListener) override
 
void SAL_CALL removePropertyChangeListener (const OUString &rPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener > &xListener) override
 
void SAL_CALL addVetoableChangeListener (const OUString &rPropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener > &xListener) override
 
void SAL_CALL removeVetoableChangeListener (const OUString &rPropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener > &xListener) override
 

Static Public Member Functions

static rtl::Reference< SwXContentControlCreateXContentControl (SwContentControl &rContentControl, const css::uno::Reference< css::text::XText > &xParentText=nullptr, std::unique_ptr< const TextRangeList_t > &&pPortions=std::unique_ptr< const TextRangeList_t >())
 
static rtl::Reference< SwXContentControlCreateXContentControl (SwDoc &rDoc)
 

Protected Member Functions

void AttachImpl (const css::uno::Reference< css::text::XTextRange > &xTextRange, sal_uInt16 nWhich)
 
 ~SwXContentControl () override
 
 SwXContentControl (const SwXContentControl &)=delete
 
SwXContentControloperator= (const SwXContentControl &)=delete
 
 SwXContentControl (SwDoc *pDoc, SwContentControl *pContentControl, const css::uno::Reference< css::text::XText > &xParentText, std::unique_ptr< const TextRangeList_t > pPortions)
 
 SwXContentControl (SwDoc *pDoc)
 

Private Attributes

sw::UnoImplPtr< Implm_pImpl
 

Detailed Description

UNO API wrapper around an SwContentControl, exposed as the com.sun.star.text.ContentControl service.

Definition at line 49 of file unocontentcontrol.hxx.

Constructor & Destructor Documentation

◆ ~SwXContentControl()

SwXContentControl::~SwXContentControl ( )
overrideprotected

Definition at line 257 of file unocontentcontrol.cxx.

◆ SwXContentControl() [1/3]

SwXContentControl::SwXContentControl ( const SwXContentControl )
protecteddelete

Referenced by CreateXContentControl().

◆ SwXContentControl() [2/3]

SwXContentControl::SwXContentControl ( SwDoc pDoc,
SwContentControl pContentControl,
const css::uno::Reference< css::text::XText > &  xParentText,
std::unique_ptr< const TextRangeList_t pPortions 
)
protected

◆ SwXContentControl() [3/3]

SwXContentControl::SwXContentControl ( SwDoc pDoc)
protected

Definition at line 252 of file unocontentcontrol.cxx.

References m_pImpl.

Member Function Documentation

◆ addEventListener()

void SAL_CALL SwXContentControl::addEventListener ( const css::uno::Reference< css::lang::XEventListener > &  xListener)
override

Definition at line 358 of file unocontentcontrol.cxx.

References m_pImpl.

◆ addPropertyChangeListener()

void SAL_CALL SwXContentControl::addPropertyChangeListener ( const OUString &  rPropertyName,
const css::uno::Reference< css::beans::XPropertyChangeListener > &  xListener 
)
override

Definition at line 1316 of file unocontentcontrol.cxx.

References SAL_WARN.

◆ addVetoableChangeListener()

void SAL_CALL SwXContentControl::addVetoableChangeListener ( const OUString &  rPropertyName,
const css::uno::Reference< css::beans::XVetoableChangeListener > &  xListener 
)
override

Definition at line 1330 of file unocontentcontrol.cxx.

References SAL_WARN.

◆ attach()

void SAL_CALL SwXContentControl::attach ( const css::uno::Reference< css::text::XTextRange > &  xTextRange)
override

Definition at line 508 of file unocontentcontrol.cxx.

References AttachImpl(), and RES_TXTATR_CONTENTCONTROL().

◆ AttachImpl()

void SwXContentControl::AttachImpl ( const css::uno::Reference< css::text::XTextRange > &  xTextRange,
sal_uInt16  nWhich 
)
protected

◆ createEnumeration()

uno::Reference< container::XEnumeration > SAL_CALL SwXContentControl::createEnumeration ( )
override

Definition at line 1357 of file unocontentcontrol.cxx.

References GetParentText(), m_pImpl, SAL_WARN, and SetContentRange().

◆ createTextCursor()

uno::Reference< text::XTextCursor > SAL_CALL SwXContentControl::createTextCursor ( )
override

Definition at line 571 of file unocontentcontrol.cxx.

References m_pImpl.

◆ createTextCursorByRange()

uno::Reference< text::XTextCursor > SAL_CALL SwXContentControl::createTextCursorByRange ( const css::uno::Reference< css::text::XTextRange > &  xTextPosition)
override

Definition at line 578 of file unocontentcontrol.cxx.

References m_pImpl.

◆ CreateXContentControl() [1/2]

static rtl::Reference< SwXContentControl > SwXContentControl::CreateXContentControl ( SwContentControl rContentControl,
const css::uno::Reference< css::text::XText > &  xParentText = nullptr,
std::unique_ptr< const TextRangeList_t > &&  pPortions = std::unique_ptr< const TextRangeList_t >() 
)
static

◆ CreateXContentControl() [2/2]

rtl::Reference< SwXContentControl > SwXContentControl::CreateXContentControl ( SwDoc rDoc)
static

Definition at line 259 of file unocontentcontrol.cxx.

References SwXContentControl().

◆ dispose()

void SAL_CALL SwXContentControl::dispose ( void  )
override

◆ getAnchor()

uno::Reference< text::XTextRange > SAL_CALL SwXContentControl::getAnchor ( )
override

◆ getElementType()

uno::Type SAL_CALL SwXContentControl::getElementType ( )
override

Definition at line 1345 of file unocontentcontrol.cxx.

References cppu::UnoType< typename T >::get().

◆ getEnd()

uno::Reference< text::XTextRange > SAL_CALL SwXContentControl::getEnd ( )
override

Definition at line 552 of file unocontentcontrol.cxx.

References m_pImpl.

◆ getImplementationName()

OUString SAL_CALL SwXContentControl::getImplementationName ( )
override

Definition at line 344 of file unocontentcontrol.cxx.

◆ GetParentText()

const uno::Reference< text::XText > & SwXContentControl::GetParentText ( ) const

Definition at line 239 of file unocontentcontrol.cxx.

References m_pImpl.

Referenced by createEnumeration().

◆ getPropertySetInfo()

uno::Reference< beans::XPropertySetInfo > SAL_CALL SwXContentControl::getPropertySetInfo ( )
override

◆ getPropertyValue()

uno::Any SAL_CALL SwXContentControl::getPropertyValue ( const OUString &  rPropertyName)
override

◆ getStart()

uno::Reference< text::XTextRange > SAL_CALL SwXContentControl::getStart ( )
override

Definition at line 546 of file unocontentcontrol.cxx.

References m_pImpl.

◆ getString()

OUString SAL_CALL SwXContentControl::getString ( )
override

Definition at line 558 of file unocontentcontrol.cxx.

References m_pImpl.

◆ getSupportedServiceNames()

uno::Sequence< OUString > SAL_CALL SwXContentControl::getSupportedServiceNames ( )
override

Definition at line 351 of file unocontentcontrol.cxx.

◆ getText()

uno::Reference< text::XText > SAL_CALL SwXContentControl::getText ( )
override

Definition at line 544 of file unocontentcontrol.cxx.

◆ hasElements()

sal_Bool SAL_CALL SwXContentControl::hasElements ( )
override

Definition at line 1350 of file unocontentcontrol.cxx.

References m_pImpl.

◆ insertControlCharacter()

void SAL_CALL SwXContentControl::insertControlCharacter ( const css::uno::Reference< css::text::XTextRange > &  xRange,
sal_Int16  nControlCharacter,
sal_Bool  bAbsorb 
)
override

Definition at line 591 of file unocontentcontrol.cxx.

References m_pImpl.

◆ insertString()

void SAL_CALL SwXContentControl::insertString ( const css::uno::Reference< css::text::XTextRange > &  xRange,
const OUString &  aString,
sal_Bool  bAbsorb 
)
override

Definition at line 584 of file unocontentcontrol.cxx.

References m_pImpl.

◆ insertTextContent()

void SAL_CALL SwXContentControl::insertTextContent ( const css::uno::Reference< css::text::XTextRange > &  xRange,
const css::uno::Reference< css::text::XTextContent > &  xContent,
sal_Bool  bAbsorb 
)
override

Definition at line 599 of file unocontentcontrol.cxx.

References m_pImpl.

◆ operator=()

SwXContentControl & SwXContentControl::operator= ( const SwXContentControl )
protecteddelete

◆ removeEventListener()

void SAL_CALL SwXContentControl::removeEventListener ( const css::uno::Reference< css::lang::XEventListener > &  xListener)
override

Definition at line 365 of file unocontentcontrol.cxx.

References m_pImpl.

◆ removePropertyChangeListener()

void SAL_CALL SwXContentControl::removePropertyChangeListener ( const OUString &  rPropertyName,
const css::uno::Reference< css::beans::XPropertyChangeListener > &  xListener 
)
override

Definition at line 1323 of file unocontentcontrol.cxx.

References SAL_WARN.

◆ removeTextContent()

void SAL_CALL SwXContentControl::removeTextContent ( const css::uno::Reference< css::text::XTextContent > &  xContent)
override

Definition at line 608 of file unocontentcontrol.cxx.

References m_pImpl.

◆ removeVetoableChangeListener()

void SAL_CALL SwXContentControl::removeVetoableChangeListener ( const OUString &  rPropertyName,
const css::uno::Reference< css::beans::XVetoableChangeListener > &  xListener 
)
override

Definition at line 1337 of file unocontentcontrol.cxx.

References SAL_WARN.

◆ SetContentRange()

bool SwXContentControl::SetContentRange ( SwTextNode *&  rpNode,
sal_Int32 &  rStart,
sal_Int32 &  rEnd 
) const

Initializes params with position of the attribute content (without CH_TXTATR).

Definition at line 320 of file unocontentcontrol.cxx.

References SwTextAttr::End(), SwTextAttr::GetStart(), SwContentControl::GetTextAttr(), SwContentControl::GetTextNode(), and m_pImpl.

Referenced by createEnumeration(), dispose(), and getAnchor().

◆ setPropertyValue()

void SAL_CALL SwXContentControl::setPropertyValue ( const OUString &  rPropertyName,
const css::uno::Any &  rValue 
)
override

◆ setString()

void SAL_CALL SwXContentControl::setString ( const OUString &  rString)
override

Definition at line 564 of file unocontentcontrol.cxx.

References m_pImpl.

◆ supportsService()

sal_Bool SAL_CALL SwXContentControl::supportsService ( const OUString &  rServiceName)
override

Definition at line 346 of file unocontentcontrol.cxx.

References cppu::supportsService().

Member Data Documentation

◆ m_pImpl

sw::UnoImplPtr<Impl> SwXContentControl::m_pImpl
private

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