LibreOffice Module xmloff (master) 1
Public Member Functions | Private Types | Private Attributes | List of all members
xmloff::OEventDescriptorMapper Class Reference

helper class wrapping different script event representations More...

#include <eventexport.hxx>

Inheritance diagram for xmloff::OEventDescriptorMapper:
[legend]
Collaboration diagram for xmloff::OEventDescriptorMapper:
[legend]

Public Member Functions

 OEventDescriptorMapper (const css::uno::Sequence< css::script::ScriptEventDescriptor > &_rEvents)
 
virtual void SAL_CALL replaceByName (const OUString &aName, const css::uno::Any &aElement) override
 
virtual css::uno::Any SAL_CALL getByName (const OUString &aName) override
 
virtual css::uno::Sequence< OUString > SAL_CALL getElementNames () override
 
virtual sal_Bool SAL_CALL hasByName (const OUString &aName) override
 
virtual css::uno::Type SAL_CALL getElementType () override
 
virtual sal_Bool SAL_CALL hasElements () override
 

Private Types

typedef std::map< OUString, css::uno::Sequence< css::beans::PropertyValue > > MapString2PropertyValueSequence
 

Private Attributes

MapString2PropertyValueSequence m_aMappedEvents
 

Detailed Description

helper class wrapping different script event representations

In the form layer, the script events are represented by <type scope="com.sun.star.script">ScriptEventDescriptor</type> instances. The office applications, on the other hand, represent their a single script event as sequence of <type scope="com.sun.star.beans">PropertyValue</type>s, where all events of a given object are accessible through a <type scope="com.sun.star.container">XNameReplace</type> interface.

This class maps the first representation of events of a single object to the second one.

This way, we can use the helper classes here in the project.

Definition at line 47 of file eventexport.hxx.

Member Typedef Documentation

◆ MapString2PropertyValueSequence

typedef std::map< OUString, css::uno::Sequence < css::beans::PropertyValue > > xmloff::OEventDescriptorMapper::MapString2PropertyValueSequence
private

Definition at line 49 of file eventexport.hxx.

Constructor & Destructor Documentation

◆ OEventDescriptorMapper()

xmloff::OEventDescriptorMapper::OEventDescriptorMapper ( const css::uno::Sequence< css::script::ScriptEventDescriptor > &  _rEvents)
explicit

Member Function Documentation

◆ getByName()

Any SAL_CALL xmloff::OEventDescriptorMapper::getByName ( const OUString &  aName)
overridevirtual

Definition at line 92 of file eventexport.cxx.

References Any, and m_aMappedEvents.

◆ getElementNames()

Sequence< OUString > SAL_CALL xmloff::OEventDescriptorMapper::getElementNames ( )
overridevirtual

Definition at line 103 of file eventexport.cxx.

References m_aMappedEvents, and comphelper::mapKeysToSequence().

◆ getElementType()

Type SAL_CALL xmloff::OEventDescriptorMapper::getElementType ( )
overridevirtual

Definition at line 114 of file eventexport.cxx.

◆ hasByName()

sal_Bool SAL_CALL xmloff::OEventDescriptorMapper::hasByName ( const OUString &  aName)
overridevirtual

Definition at line 108 of file eventexport.cxx.

References m_aMappedEvents.

◆ hasElements()

sal_Bool SAL_CALL xmloff::OEventDescriptorMapper::hasElements ( )
overridevirtual

Definition at line 119 of file eventexport.cxx.

References m_aMappedEvents.

◆ replaceByName()

void SAL_CALL xmloff::OEventDescriptorMapper::replaceByName ( const OUString &  aName,
const css::uno::Any &  aElement 
)
overridevirtual

Definition at line 86 of file eventexport.cxx.

Member Data Documentation

◆ m_aMappedEvents

MapString2PropertyValueSequence xmloff::OEventDescriptorMapper::m_aMappedEvents
private

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