LibreOffice Module sd (master) 1
Public Types | Public Member Functions | Private Attributes | List of all members
sd::framework::GenericConfigurationChangeRequest Class Referencefinal

This implementation of the XConfigurationChangeRequest interface represents a single explicit request for a configuration change. More...

#include <GenericConfigurationChangeRequest.hxx>

Inheritance diagram for sd::framework::GenericConfigurationChangeRequest:
[legend]
Collaboration diagram for sd::framework::GenericConfigurationChangeRequest:
[legend]

Public Types

enum  Mode {
  Activation ,
  Deactivation
}
 This enum specified whether the activation or deactivation of a resource is requested. More...
 

Public Member Functions

 GenericConfigurationChangeRequest (const css::uno::Reference< css::drawing::framework::XResourceId > &rxResourceId, const Mode eMode)
 Create a new object that represents the request for activation or deactivation of the specified resource. More...
 
virtual ~GenericConfigurationChangeRequest () noexcept override
 
virtual void SAL_CALL execute (const css::uno::Reference< css::drawing::framework::XConfiguration > &rxConfiguration) override
 The requested configuration change is executed on the given configuration. More...
 
virtual OUString SAL_CALL getName () override
 Return a human readable string representation. More...
 
virtual void SAL_CALL setName (const OUString &rName) override
 This call is ignored because the XNamed interface is (mis)used to give access to a human readable name for debugging purposes. More...
 
- Public Member Functions inherited from comphelper::WeakComponentImplHelper< typename... Ifc >
virtual void SAL_CALL acquire () noexcept override
 
virtual void SAL_CALL release () noexcept override
 
virtual void SAL_CALL dispose () noexcept final override
 
virtual void SAL_CALL addEventListener (css::uno::Reference< css::lang::XEventListener > const &rxListener) final override
 
virtual void SAL_CALL removeEventListener (css::uno::Reference< css::lang::XEventListener > const &rxListener) final override
 
virtual css::uno::Any SAL_CALL queryInterface (css::uno::Type const &rType) override
 
virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes () override
 
virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId () override
 
- Public Member Functions inherited from comphelper::WeakComponentImplHelperBase
virtual ~WeakComponentImplHelperBase () override
 
virtual void SAL_CALL dispose () override
 
virtual void SAL_CALL addEventListener (css::uno::Reference< css::lang::XEventListener > const &rxListener) override
 
virtual void SAL_CALL removeEventListener (css::uno::Reference< css::lang::XEventListener > const &rxListener) override
 
virtual css::uno::Any SAL_CALL queryInterface (css::uno::Type const &rType) override
 
virtual void disposing (std::unique_lock< std::mutex > &)
 
- Public Member Functions inherited from comphelper::UnoImplBase
virtual ~UnoImplBase ()
 

Private Attributes

const css::uno::Reference< css::drawing::framework::XResourceId > mxResourceId
 
const Mode meMode
 

Additional Inherited Members

- Protected Member Functions inherited from comphelper::WeakComponentImplHelperBase
void throwIfDisposed (std::unique_lock< std::mutex > &)
 
- Protected Attributes inherited from comphelper::WeakComponentImplHelperBase
comphelper::OInterfaceContainerHelper4< css::lang::XEventListener > maEventListeners
 
- Protected Attributes inherited from comphelper::UnoImplBase
std::mutex m_aMutex
 
bool m_bDisposed
 

Detailed Description

This implementation of the XConfigurationChangeRequest interface represents a single explicit request for a configuration change.

On its execution it may result in other, implicit, configuration changes. For example this is the case when the deactivation of a unique resource is requested: the resources linked to it have to be deactivated as well.

Definition at line 42 of file GenericConfigurationChangeRequest.hxx.

Member Enumeration Documentation

◆ Mode

This enum specified whether the activation or deactivation of a resource is requested.

Enumerator
Activation 
Deactivation 

Definition at line 49 of file GenericConfigurationChangeRequest.hxx.

Constructor & Destructor Documentation

◆ GenericConfigurationChangeRequest()

sd::framework::GenericConfigurationChangeRequest::GenericConfigurationChangeRequest ( const css::uno::Reference< css::drawing::framework::XResourceId > &  rxResourceId,
const Mode  eMode 
)

Create a new object that represents the request for activation or deactivation of the specified resource.

Parameters
rxsResourceIdId of the resource that is to be activated or deactivated.
eModeThe mode specifies whether to activate or to deactivate the resource.
Exceptions
css::css::lang::IllegalArgumentException

Definition at line 34 of file GenericConfigurationChangeRequest.cxx.

References eMode, and meMode.

◆ ~GenericConfigurationChangeRequest()

sd::framework::GenericConfigurationChangeRequest::~GenericConfigurationChangeRequest ( )
overridevirtualnoexcept

Definition at line 44 of file GenericConfigurationChangeRequest.cxx.

Member Function Documentation

◆ execute()

void SAL_CALL sd::framework::GenericConfigurationChangeRequest::execute ( const css::uno::Reference< css::drawing::framework::XConfiguration > &  rxConfiguration)
overridevirtual

The requested configuration change is executed on the given configuration.

Additionally to the explicitly requested change other changes have to be made as well. See class description for an example.

Parameters
rxConfigurationThe configuration to which the requested change is made.

Definition at line 48 of file GenericConfigurationChangeRequest.cxx.

References Activation, Deactivation, meMode, and mxResourceId.

◆ getName()

OUString SAL_CALL sd::framework::GenericConfigurationChangeRequest::getName ( )
overridevirtual

Return a human readable string representation.

This is used for debugging purposes.

Definition at line 66 of file GenericConfigurationChangeRequest.cxx.

References Activation, meMode, mxResourceId, sd::framework::FrameworkHelper::ResourceIdToString(), and u.

◆ setName()

void SAL_CALL sd::framework::GenericConfigurationChangeRequest::setName ( const OUString &  rName)
overridevirtual

This call is ignored because the XNamed interface is (mis)used to give access to a human readable name for debugging purposes.

Definition at line 74 of file GenericConfigurationChangeRequest.cxx.

Member Data Documentation

◆ meMode

const Mode sd::framework::GenericConfigurationChangeRequest::meMode
private

Definition at line 93 of file GenericConfigurationChangeRequest.hxx.

Referenced by execute(), and getName().

◆ mxResourceId

const css::uno::Reference<css::drawing::framework::XResourceId> sd::framework::GenericConfigurationChangeRequest::mxResourceId
private

Definition at line 92 of file GenericConfigurationChangeRequest.hxx.

Referenced by execute(), and getName().


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