LibreOffice Module extensions (master) 1
|
the base class for property handlers More...
#include <propertyhandler.hxx>
Protected Member Functions | |
PropertyHandler (const css::uno::Reference< css::uno::XComponentContext > &_rxContext) | |
virtual | ~PropertyHandler () override |
virtual void SAL_CALL | inspect (const css::uno::Reference< css::uno::XInterface > &_rxIntrospectee) override |
virtual css::uno::Sequence< css::beans::Property > SAL_CALL | getSupportedProperties () override |
virtual css::uno::Sequence< OUString > SAL_CALL | getSupersededProperties () override |
virtual css::uno::Sequence< OUString > SAL_CALL | getActuatingProperties () override |
virtual css::uno::Any SAL_CALL | convertToPropertyValue (const OUString &_rPropertyName, const css::uno::Any &_rControlValue) override |
virtual css::uno::Any SAL_CALL | convertToControlValue (const OUString &_rPropertyName, const css::uno::Any &_rPropertyValue, const css::uno::Type &_rControlValueType) override |
virtual css::beans::PropertyState SAL_CALL | getPropertyState (const OUString &_rPropertyName) override |
virtual css::inspection::LineDescriptor SAL_CALL | describePropertyLine (const OUString &_rPropertyName, const css::uno::Reference< css::inspection::XPropertyControlFactory > &_rxControlFactory) override |
virtual sal_Bool SAL_CALL | isComposable (const OUString &_rPropertyName) override |
virtual css::inspection::InteractiveSelectionResult SAL_CALL | onInteractivePropertySelection (const OUString &_rPropertyName, sal_Bool _bPrimary, css::uno::Any &_rData, const css::uno::Reference< css::inspection::XObjectInspectorUI > &_rxInspectorUI) override |
virtual void SAL_CALL | actuatingPropertyChanged (const OUString &_rActuatingPropertyName, const css::uno::Any &_rNewValue, const css::uno::Any &_rOldValue, const css::uno::Reference< css::inspection::XObjectInspectorUI > &_rxInspectorUI, sal_Bool _bFirstTimeInit) override |
virtual void SAL_CALL | addPropertyChangeListener (const css::uno::Reference< css::beans::XPropertyChangeListener > &_rxListener) override |
virtual void SAL_CALL | removePropertyChangeListener (const css::uno::Reference< css::beans::XPropertyChangeListener > &_rxListener) override |
virtual sal_Bool SAL_CALL | suspend (sal_Bool _bSuspend) override |
virtual void SAL_CALL | disposing () override |
virtual css::uno::Sequence< css::beans::Property > | doDescribeSupportedProperties () const =0 |
virtual void | onNewComponent () |
called when XPropertyHandler::inspect has been called, and we thus have a new component to inspect More... | |
void | firePropertyChange (const OUString &_rPropName, PropertyId _nPropId, const css::uno::Any &_rOldValue, const css::uno::Any &_rNewValue) |
fires the change in a property value to our listener (if any) More... | |
weld::Window * | impl_getDefaultDialogFrame_nothrow () const |
retrieves a window which can be used as parent for dialogs More... | |
PropertyId | impl_getPropertyId_throwUnknownProperty (const OUString &_rPropertyName) const |
retrieves the property id for a given property name More... | |
PropertyId | impl_getPropertyId_throwRuntime (const OUString &_rPropertyName) const |
retrieves the property id for a given property name More... | |
PropertyId | impl_getPropertyId_nothrow (const OUString &_rPropertyName) const |
retrieves the property id for a given property name More... | |
void | addStringPropertyDescription (std::vector< css::beans::Property > &_rProperties, const OUString &_rPropertyName) const |
adds a description for the given string property to the given property vector Most probably to be called from within getSupportedProperties More... | |
void | addInt32PropertyDescription (std::vector< css::beans::Property > &_rProperties, const OUString &_rPropertyName, sal_Int16 _nAttribs=0) const |
adds a description for the given int32 property to the given property vector More... | |
void | addInt16PropertyDescription (std::vector< css::beans::Property > &_rProperties, const OUString &_rPropertyName, sal_Int16 _nAttribs=0) const |
adds a description for the given int16 property to the given property vector More... | |
void | addDoublePropertyDescription (std::vector< css::beans::Property > &_rProperties, const OUString &_rPropertyName, sal_Int16 _nAttribs) const |
adds a description for the given double property to the given property vector More... | |
void | addDatePropertyDescription (std::vector< css::beans::Property > &_rProperties, const OUString &_rPropertyName, sal_Int16 _nAttribs) const |
adds a description for the given date property to the given property vector More... | |
void | addTimePropertyDescription (std::vector< css::beans::Property > &_rProperties, const OUString &_rPropertyName, sal_Int16 _nAttribs) const |
adds a description for the given time property to the given property vector More... | |
void | addDateTimePropertyDescription (std::vector< css::beans::Property > &_rProperties, const OUString &_rPropertyName, sal_Int16 _nAttribs) const |
adds a description for the given DateTime property to the given property vector More... | |
void | implAddPropertyDescription (std::vector< css::beans::Property > &_rProperties, const OUString &_rPropertyName, const css::uno::Type &_rType, sal_Int16 _nAttribs=0) const |
adds a Property, given by name only, to a given vector of Properties More... | |
const css::beans::Property * | impl_getPropertyFromId_nothrow (PropertyId _nPropId) const |
retrieves a property given by handle More... | |
const css::beans::Property & | impl_getPropertyFromId_throw (PropertyId _nPropId) const |
retrieves a property given by handle More... | |
bool | impl_isSupportedProperty_nothrow (PropertyId _nPropId) const |
determines whether a given property id is part of our supported properties More... | |
const css::beans::Property & | impl_getPropertyFromName_throw (const OUString &_rPropertyName) const |
retrieves a property given by name More... | |
OUString | impl_getPropertyNameFromId_nothrow (PropertyId _nPropId) const |
get the name of a property given by handle More... | |
css::uno::Reference< css::frame::XModel > | impl_getContextDocument_nothrow () const |
returns the value of the ContextDocument property in the ComponentContext which was used to create this handler. More... | |
void | impl_setContextDocumentModified_nothrow () const |
marks the context document as modified More... | |
bool | impl_componentHasProperty_throw (const OUString &_rPropName) const |
determines whether our component has a given property More... | |
sal_Int16 | impl_getDocumentMeasurementUnit_throw () const |
determines the default measure unit for the document in which our component lives More... | |
Protected Attributes | |
css::uno::Reference< css::uno::XComponentContext > | m_xContext |
the context in which the instance was created More... | |
css::uno::Reference< css::beans::XPropertySet > | m_xComponent |
the component we're inspecting More... | |
css::uno::Reference< css::beans::XPropertySetInfo > | m_xComponentPropertyInfo |
info about our component's properties More... | |
css::uno::Reference< css::script::XTypeConverter > | m_xTypeConverter |
type converter, needed on various occasions More... | |
std::unique_ptr< OPropertyInfoService > | m_pInfoService |
access to property meta data More... | |
Protected Attributes inherited from cppu::BaseMutex | |
mutable::osl::Mutex | m_aMutex |
Private Member Functions | |
PropertyHandler (const PropertyHandler &)=delete | |
PropertyHandler & | operator= (const PropertyHandler &)=delete |
Private Attributes | |
StlSyntaxSequence< css::beans::Property > | m_aSupportedProperties |
cache for getSupportedProperties More... | |
bool | m_bSupportedPropertiesAreKnown |
PropertyChangeListeners | m_aPropertyListeners |
the property listener which has been registered More... | |
the base class for property handlers
Definition at line 68 of file propertyhandler.hxx.
|
explicitprotected |
|
overrideprotectedvirtual |
Definition at line 66 of file propertyhandler.cxx.
|
privatedelete |
|
overrideprotectedvirtual |
Reimplemented in pcr::ButtonNavigationHandler, pcr::CellBindingPropertyHandler, pcr::FormComponentPropertyHandler, pcr::EditPropertyHandler, pcr::EFormsPropertyHandler, pcr::SubmissionPropertyHandler, and pcr::XSDValidationPropertyHandler.
Definition at line 221 of file propertyhandler.cxx.
|
inlineprotected |
adds a description for the given date property to the given property vector
Definition at line 320 of file propertyhandler.hxx.
References implAddPropertyDescription().
Referenced by pcr::XSDValidationPropertyHandler::doDescribeSupportedProperties().
|
inlineprotected |
adds a description for the given DateTime property to the given property vector
Definition at line 330 of file propertyhandler.hxx.
References implAddPropertyDescription().
Referenced by pcr::XSDValidationPropertyHandler::doDescribeSupportedProperties().
|
inlineprotected |
adds a description for the given double property to the given property vector
Definition at line 315 of file propertyhandler.hxx.
References implAddPropertyDescription().
Referenced by pcr::XSDValidationPropertyHandler::doDescribeSupportedProperties().
|
inlineprotected |
adds a description for the given int16 property to the given property vector
Definition at line 310 of file propertyhandler.hxx.
References implAddPropertyDescription().
Referenced by pcr::XSDValidationPropertyHandler::doDescribeSupportedProperties().
|
inlineprotected |
adds a description for the given int32 property to the given property vector
Definition at line 305 of file propertyhandler.hxx.
References implAddPropertyDescription().
Referenced by pcr::EditPropertyHandler::doDescribeSupportedProperties(), and pcr::XSDValidationPropertyHandler::doDescribeSupportedProperties().
|
overrideprotectedvirtual |
Reimplemented in pcr::EFormsPropertyHandler, pcr::FormComponentPropertyHandler, and pcr::XSDValidationPropertyHandler.
Definition at line 226 of file propertyhandler.cxx.
References m_aMutex.
Referenced by pcr::EFormsPropertyHandler::addPropertyChangeListener(), and pcr::XSDValidationPropertyHandler::addPropertyChangeListener().
|
inlineprotected |
adds a description for the given string property to the given property vector Most probably to be called from within getSupportedProperties
Definition at line 300 of file propertyhandler.hxx.
References implAddPropertyDescription().
Referenced by pcr::ButtonNavigationHandler::doDescribeSupportedProperties(), pcr::EFormsPropertyHandler::doDescribeSupportedProperties(), and pcr::XSDValidationPropertyHandler::doDescribeSupportedProperties().
|
inlineprotected |
adds a description for the given time property to the given property vector
Definition at line 325 of file propertyhandler.hxx.
References implAddPropertyDescription().
Referenced by pcr::XSDValidationPropertyHandler::doDescribeSupportedProperties().
|
overrideprotectedvirtual |
Reimplemented in pcr::CellBindingPropertyHandler, pcr::EFormsPropertyHandler, pcr::FormComponentPropertyHandler, and pcr::SubmissionPropertyHandler.
Definition at line 155 of file propertyhandler.cxx.
References Any, DBG_ASSERT, m_aMutex, m_xContext, and PROP_FLAG_ENUM.
Referenced by pcr::EFormsPropertyHandler::convertToControlValue().
|
overrideprotectedvirtual |
Reimplemented in pcr::CellBindingPropertyHandler, pcr::EFormsPropertyHandler, pcr::FormComponentPropertyHandler, and pcr::SubmissionPropertyHandler.
Definition at line 129 of file propertyhandler.cxx.
References Any, m_aMutex, m_xContext, PROP_FLAG_ENUM, and Property.
Referenced by pcr::EFormsPropertyHandler::convertToPropertyValue().
|
overrideprotectedvirtual |
Reimplemented in pcr::ButtonNavigationHandler, pcr::EFormsPropertyHandler, pcr::FormComponentPropertyHandler, pcr::SubmissionPropertyHandler, and pcr::XSDValidationPropertyHandler.
Definition at line 179 of file propertyhandler.cxx.
References m_aMutex, PROP_FLAG_DATA_PROPERTY, PROP_FLAG_ENUM, and Property.
Referenced by pcr::ButtonNavigationHandler::describePropertyLine().
|
overrideprotectedvirtual |
Reimplemented in pcr::FormComponentPropertyHandler.
Definition at line 247 of file propertyhandler.cxx.
|
protectedpure virtual |
|
protected |
fires the change in a property value to our listener (if any)
Definition at line 255 of file propertyhandler.cxx.
References aEvent.
Referenced by pcr::SubmissionPropertyHandler::_propertyChanged(), pcr::CellBindingPropertyHandler::setPropertyValue(), and pcr::EFormsPropertyHandler::setPropertyValue().
|
overrideprotectedvirtual |
Reimplemented in pcr::ButtonNavigationHandler, pcr::CellBindingPropertyHandler, pcr::EditPropertyHandler, pcr::EFormsPropertyHandler, pcr::FormComponentPropertyHandler, pcr::SubmissionPropertyHandler, and pcr::XSDValidationPropertyHandler.
Definition at line 124 of file propertyhandler.cxx.
|
overrideprotectedvirtual |
Reimplemented in pcr::ButtonNavigationHandler, and pcr::FormComponentPropertyHandler.
Definition at line 174 of file propertyhandler.cxx.
|
overrideprotectedvirtual |
Reimplemented in pcr::EditPropertyHandler, pcr::EFormsPropertyHandler, pcr::FormComponentPropertyHandler, pcr::SubmissionPropertyHandler, and pcr::XSDValidationPropertyHandler.
Definition at line 119 of file propertyhandler.cxx.
|
overrideprotectedvirtual |
Definition at line 108 of file propertyhandler.cxx.
References m_aMutex.
|
protected |
determines whether our component has a given property
Definition at line 341 of file propertyhandler.cxx.
Referenced by pcr::CellBindingPropertyHandler::actuatingPropertyChanged().
|
inlineprotected |
returns the value of the ContextDocument property in the ComponentContext which was used to create this handler.
Definition at line 275 of file propertyhandler.hxx.
References m_xContext.
Referenced by pcr::FormComponentPropertyHandler::impl_getDocumentURL_nothrow(), pcr::CellBindingPropertyHandler::onNewComponent(), pcr::EFormsPropertyHandler::onNewComponent(), pcr::SubmissionPropertyHandler::onNewComponent(), and pcr::XSDValidationPropertyHandler::onNewComponent().
|
protected |
retrieves a window which can be used as parent for dialogs
Definition at line 308 of file propertyhandler.cxx.
References m_xContext.
|
protected |
determines the default measure unit for the document in which our component lives
Definition at line 346 of file propertyhandler.cxx.
References utl::OConfigurationTreeRoot::CM_READONLY, VCLUnoHelper::ConvertToMeasurementUnit(), utl::OConfigurationTreeRoot::createWithComponentContext(), SvtSysLocale::GetLocaleData(), LocaleDataWrapper::getMeasurementSystemEnum(), utl::OConfigurationNode::getNodeValue(), m_xContext, SERVICE_DRAWING_DOCUMENT, SERVICE_PRESENTATION_DOCUMENT, SERVICE_SPREADSHEET_DOCUMENT, SERVICE_TEXT_DOCUMENT, and SERVICE_WEB_DOCUMENT.
|
protected |
retrieves a property given by handle
Definition at line 266 of file propertyhandler.cxx.
References Property.
Referenced by impl_getPropertyNameFromId_nothrow(), and impl_isSupportedProperty_nothrow().
|
protected |
retrieves a property given by handle
UnknownPropertyException | if the handler does not support a property with the given handle |
@seealso doDescribeSupportedProperties
Definition at line 277 of file propertyhandler.cxx.
References Property.
|
protected |
retrieves a property given by name
UnknownPropertyException | if the handler does not support a property with the given name |
@seealso doDescribeSupportedProperties
Definition at line 286 of file propertyhandler.cxx.
References pcr::StlSyntaxSequence< ELEMENT >::end(), and Property.
|
protected |
retrieves the property id for a given property name
Definition at line 329 of file propertyhandler.cxx.
|
protected |
retrieves the property id for a given property name
css::uno::RuntimeException | if the property name is not known to our ->m_pInfoService |
Definition at line 321 of file propertyhandler.cxx.
Referenced by pcr::ButtonNavigationHandler::actuatingPropertyChanged(), pcr::CellBindingPropertyHandler::actuatingPropertyChanged(), pcr::EditPropertyHandler::actuatingPropertyChanged(), pcr::EFormsPropertyHandler::actuatingPropertyChanged(), pcr::SubmissionPropertyHandler::actuatingPropertyChanged(), and pcr::XSDValidationPropertyHandler::actuatingPropertyChanged().
|
protected |
retrieves the property id for a given property name
css::beans::UnknownPropertyException | if the property name is not known to our ->m_pInfoService |
Definition at line 313 of file propertyhandler.cxx.
Referenced by pcr::ButtonNavigationHandler::describePropertyLine(), pcr::EFormsPropertyHandler::describePropertyLine(), pcr::SubmissionPropertyHandler::describePropertyLine(), pcr::XSDValidationPropertyHandler::describePropertyLine(), pcr::ButtonNavigationHandler::getPropertyState(), pcr::ButtonNavigationHandler::getPropertyValue(), pcr::CellBindingPropertyHandler::getPropertyValue(), pcr::EditPropertyHandler::getPropertyValue(), pcr::EFormsPropertyHandler::getPropertyValue(), pcr::SubmissionPropertyHandler::getPropertyValue(), pcr::XSDValidationPropertyHandler::getPropertyValue(), pcr::ButtonNavigationHandler::onInteractivePropertySelection(), pcr::EFormsPropertyHandler::onInteractivePropertySelection(), pcr::XSDValidationPropertyHandler::onInteractivePropertySelection(), pcr::ButtonNavigationHandler::setPropertyValue(), pcr::CellBindingPropertyHandler::setPropertyValue(), pcr::EditPropertyHandler::setPropertyValue(), pcr::EFormsPropertyHandler::setPropertyValue(), pcr::SubmissionPropertyHandler::setPropertyValue(), and pcr::XSDValidationPropertyHandler::setPropertyValue().
|
inlineprotected |
get the name of a property given by handle
Definition at line 335 of file propertyhandler.hxx.
References impl_getPropertyFromId_nothrow().
Referenced by pcr::FormComponentPropertyHandler::impl_doDesignSQLCommand_nothrow().
|
inlineprotected |
determines whether a given property id is part of our supported properties
Definition at line 251 of file propertyhandler.hxx.
References impl_getPropertyFromId_nothrow().
Referenced by pcr::CellBindingPropertyHandler::actuatingPropertyChanged(), pcr::EditPropertyHandler::actuatingPropertyChanged(), and pcr::CellBindingPropertyHandler::impl_updateDependentProperty_nothrow().
|
protected |
marks the context document as modified
Definition at line 334 of file propertyhandler.cxx.
Referenced by pcr::CellBindingPropertyHandler::setPropertyValue(), pcr::EFormsPropertyHandler::setPropertyValue(), pcr::SubmissionPropertyHandler::setPropertyValue(), and pcr::XSDValidationPropertyHandler::setPropertyValue().
|
protected |
adds a Property, given by name only, to a given vector of Properties
Definition at line 298 of file propertyhandler.cxx.
References Property.
Referenced by addDatePropertyDescription(), addDateTimePropertyDescription(), addDoublePropertyDescription(), addInt16PropertyDescription(), addInt32PropertyDescription(), addStringPropertyDescription(), addTimePropertyDescription(), pcr::ButtonNavigationHandler::doDescribeSupportedProperties(), pcr::EFormsPropertyHandler::doDescribeSupportedProperties(), and pcr::SubmissionPropertyHandler::doDescribeSupportedProperties().
|
overrideprotectedvirtual |
Reimplemented in pcr::ButtonNavigationHandler.
Definition at line 70 of file propertyhandler.cxx.
References comphelper::OInterfaceIteratorHelper3< class ListenerT >::hasMoreElements(), m_aMutex, comphelper::OInterfaceIteratorHelper3< class ListenerT >::next(), and removeListener().
Referenced by pcr::ButtonNavigationHandler::inspect().
|
overrideprotectedvirtual |
Definition at line 209 of file propertyhandler.cxx.
References m_aMutex.
|
overrideprotectedvirtual |
Reimplemented in pcr::ButtonNavigationHandler, pcr::EFormsPropertyHandler, pcr::FormComponentPropertyHandler, and pcr::XSDValidationPropertyHandler.
Definition at line 215 of file propertyhandler.cxx.
Referenced by pcr::ButtonNavigationHandler::onInteractivePropertySelection().
|
protectedvirtual |
called when XPropertyHandler::inspect has been called, and we thus have a new component to inspect
Reimplemented in pcr::CellBindingPropertyHandler, pcr::EFormsPropertyHandler, pcr::FormComponentPropertyHandler, pcr::SubmissionPropertyHandler, and pcr::XSDValidationPropertyHandler.
Definition at line 97 of file propertyhandler.cxx.
Referenced by pcr::CellBindingPropertyHandler::onNewComponent(), pcr::EFormsPropertyHandler::onNewComponent(), pcr::SubmissionPropertyHandler::onNewComponent(), and pcr::XSDValidationPropertyHandler::onNewComponent().
|
privatedelete |
|
overrideprotectedvirtual |
Reimplemented in pcr::EFormsPropertyHandler, pcr::FormComponentPropertyHandler, and pcr::XSDValidationPropertyHandler.
Definition at line 234 of file propertyhandler.cxx.
References m_aMutex.
Referenced by pcr::EFormsPropertyHandler::removePropertyChangeListener(), and pcr::XSDValidationPropertyHandler::removePropertyChangeListener().
Reimplemented in pcr::FormComponentPropertyHandler.
Definition at line 240 of file propertyhandler.cxx.
|
private |
the property listener which has been registered
Definition at line 79 of file propertyhandler.hxx.
|
mutableprivate |
cache for getSupportedProperties
Definition at line 74 of file propertyhandler.hxx.
|
mutableprivate |
Definition at line 75 of file propertyhandler.hxx.
|
protected |
access to property meta data
Definition at line 91 of file propertyhandler.hxx.
Referenced by pcr::CellBindingPropertyHandler::convertToControlValue(), pcr::EFormsPropertyHandler::convertToControlValue(), pcr::SubmissionPropertyHandler::convertToControlValue(), pcr::CellBindingPropertyHandler::convertToPropertyValue(), pcr::EFormsPropertyHandler::convertToPropertyValue(), pcr::SubmissionPropertyHandler::convertToPropertyValue(), pcr::EFormsPropertyHandler::describePropertyLine(), pcr::SubmissionPropertyHandler::describePropertyLine(), and pcr::XSDValidationPropertyHandler::describePropertyLine().
|
protected |
the component we're inspecting
Definition at line 85 of file propertyhandler.hxx.
Referenced by pcr::ButtonNavigationHandler::actuatingPropertyChanged(), pcr::ButtonNavigationHandler::doDescribeSupportedProperties(), pcr::ButtonNavigationHandler::getPropertyState(), pcr::ButtonNavigationHandler::getPropertyValue(), pcr::EditPropertyHandler::getPropertyValue(), pcr::SubmissionPropertyHandler::getPropertyValue(), pcr::FormComponentPropertyHandler::impl_doDesignSQLCommand_nothrow(), pcr::EditPropertyHandler::implHaveBothScrollBarProperties(), pcr::EditPropertyHandler::implHaveTextTypeProperty(), pcr::CellBindingPropertyHandler::onNewComponent(), pcr::EFormsPropertyHandler::onNewComponent(), pcr::SubmissionPropertyHandler::onNewComponent(), pcr::XSDValidationPropertyHandler::onNewComponent(), pcr::ButtonNavigationHandler::setPropertyValue(), pcr::EditPropertyHandler::setPropertyValue(), and pcr::SubmissionPropertyHandler::setPropertyValue().
|
protected |
info about our component's properties
Definition at line 87 of file propertyhandler.hxx.
|
protected |
the context in which the instance was created
Definition at line 83 of file propertyhandler.hxx.
Referenced by pcr::ButtonNavigationHandler::ButtonNavigationHandler(), pcr::FormComponentPropertyHandler::impl_doDesignSQLCommand_nothrow(), impl_getContextDocument_nothrow(), and pcr::EFormsPropertyHandler::onInteractivePropertySelection().
|
protected |
type converter, needed on various occasions
Definition at line 89 of file propertyhandler.hxx.