LibreOffice Module svtools (master) 1
|
SvBaseEventDescriptor: Abstract class that implements the basics of an XNameReplace that is delivered by the XEventsSupplier::getEvents() method. More...
#include <unoevent.hxx>
Public Member Functions | |
SvBaseEventDescriptor (const SvEventDescription *pSupportedMacroItems) | |
virtual | ~SvBaseEventDescriptor () override |
virtual void SAL_CALL | replaceByName (const OUString &rName, const css::uno::Any &rElement) override |
calls replaceByName(const sal_uInt16, const SvxMacro&) More... | |
virtual css::uno::Any SAL_CALL | getByName (const OUString &rName) override |
calls getByName(sal_uInt16) More... | |
virtual css::uno::Sequence< OUString > SAL_CALL | getElementNames () override |
virtual sal_Bool SAL_CALL | hasByName (const OUString &rName) override |
virtual css::uno::Type SAL_CALL | getElementType () override |
virtual sal_Bool SAL_CALL | hasElements () override |
virtual OUString SAL_CALL | getImplementationName () override=0 |
must be implemented in subclass More... | |
virtual sal_Bool SAL_CALL | supportsService (const OUString &ServiceName) override |
virtual css::uno::Sequence< OUString > SAL_CALL | getSupportedServiceNames () override |
Protected Member Functions | |
virtual void | replaceByName (const SvMacroItemId nEvent, const SvxMacro &rMacro)=0 |
Must be implemented in subclass. More... | |
virtual void | getByName (SvxMacro &rMacro, const SvMacroItemId nEvent)=0 |
Must be implemented in subclass. More... | |
SvMacroItemId | mapNameToEventID (std::u16string_view rName) const |
convert an API event name to the event ID as used by SvxMacroItem More... | |
SvMacroItemId | getMacroID (std::u16string_view rName) const |
get the event ID for the name; return 0 if not supported More... | |
Protected Attributes | |
const SvEventDescription * | mpSupportedMacroItems |
last element is 0, 0 More... | |
sal_Int16 | mnMacroItems |
SvBaseEventDescriptor: Abstract class that implements the basics of an XNameReplace that is delivered by the XEventsSupplier::getEvents() method.
The functionality this class provides is: 1) Which elements are in the XNameReplace? 2) Mapping from Api names to item IDs. 3) conversion from SvxMacroItem to Any and vice versa.
All details of how to actually get and set SvxMacroItem(s) have to be supplied by the base class.
Definition at line 60 of file unoevent.hxx.
SvBaseEventDescriptor::SvBaseEventDescriptor | ( | const SvEventDescription * | pSupportedMacroItems | ) |
Definition at line 195 of file unoevent.cxx.
References SvEventDescription::mnEvent, mnMacroItems, and mpSupportedMacroItems.
|
overridevirtual |
Definition at line 205 of file unoevent.cxx.
|
overridevirtual |
calls getByName(sal_uInt16)
API name of event
Reimplemented in SvEventDescriptor, and SvDetachedEventDescriptor.
Definition at line 231 of file unoevent.cxx.
References Any, getByName(), and getMacroID().
Referenced by getByName().
|
protectedpure virtual |
Must be implemented in subclass.
css::container::NoSuchElementException | |
css::lang::WrappedTargetException | |
css::uno::RuntimeException |
Implemented in SvDetachedEventDescriptor, SvEventDescriptor, SvDetachedEventDescriptor, and SvEventDescriptor.
|
overridevirtual |
Definition at line 248 of file unoevent.cxx.
References i, mnMacroItems, and mpSupportedMacroItems.
|
overridevirtual |
Definition at line 268 of file unoevent.cxx.
|
overridepure virtual |
must be implemented in subclass
Implemented in SvDetachedEventDescriptor.
References getSupportedServiceNames(), and supportsService().
|
protected |
get the event ID for the name; return 0 if not supported
Definition at line 303 of file unoevent.cxx.
References mapNameToEventID().
Referenced by getByName(), and hasByName().
|
overridevirtual |
Definition at line 283 of file unoevent.cxx.
References sAPI_ServiceName.
|
overridevirtual |
Definition at line 261 of file unoevent.cxx.
References getMacroID().
|
overridevirtual |
Definition at line 273 of file unoevent.cxx.
References mnMacroItems.
|
protected |
convert an API event name to the event ID as used by SvxMacroItem
Definition at line 288 of file unoevent.cxx.
References o3tl::equalsAscii(), i, SvEventDescription::mnEvent, mnMacroItems, and mpSupportedMacroItems.
Referenced by getMacroID().
|
overridevirtual |
calls replaceByName(const sal_uInt16, const SvxMacro&)
event (PropertyValues)
rElement | API name of event |
Reimplemented in SvEventDescriptor, and SvDetachedEventDescriptor.
|
protectedpure virtual |
Must be implemented in subclass.
css::lang::IllegalArgumentException | |
css::container::NoSuchElementException | |
css::lang::WrappedTargetException | |
css::uno::RuntimeException | event (will be copied) |
rMacro | item ID of event |
Implemented in SvEventDescriptor, SvDetachedEventDescriptor, SvEventDescriptor, and SvDetachedEventDescriptor.
|
overridevirtual |
Definition at line 278 of file unoevent.cxx.
References cppu::supportsService().
|
protected |
Definition at line 69 of file unoevent.hxx.
Referenced by getElementNames(), hasElements(), mapNameToEventID(), SvBaseEventDescriptor(), and SvDetachedEventDescriptor::SvDetachedEventDescriptor().
|
protected |
last element is 0, 0
Definition at line 68 of file unoevent.hxx.
Referenced by SvMacroTableEventDescriptor::copyMacrosIntoTable(), getElementNames(), SvDetachedEventDescriptor::getIndex(), mapNameToEventID(), SvBaseEventDescriptor(), and SvMacroTableEventDescriptor::SvMacroTableEventDescriptor().