LibreOffice: ValidatableControlModel Service Reference

LibreOffice LibreOffice 7.6 SDK API Reference

Loading...
Searching...
No Matches
Included Services | Exported Interfaces | List of all members
ValidatableControlModel Service Reference

specifies the model of a form control which supports live validation of its input. More...

`import <ValidatableControlModel.idl;`

Inheritance diagram for ValidatableControlModel:

## Included Services
service | com::sun::star::form::FormControlModel
| specifies the basic functionality for a form control model
Included Services inherited from FormControlModel
service | com::sun::star::awt::UnoControlModel
service | com::sun::star::form::FormComponent
Included Services inherited from UnoControlModel
service | com::sun::star::awt::UnoControlDialogElement
| This service is present when the control model is embedded in an UnoControlDialogModel.

## Exported Interfaces
interface | XValidatableFormComponent
| enables support for validating the value of the control model
interface | XValidityConstraintListener
| enables support for validators with dynamic validity constraints.
Exported Interfaces inherited from FormControlModel
interface | com::sun::star::beans::XFastPropertySet
| This optional interface gives an efficient access to all properties at once or an ability to set more than one property at once.
interface | com::sun::star::beans::XPropertyState
| This optional interface gives access to the state of the properties, e.g.
Exported Interfaces inherited from UnoControlModel
interface | com::sun::star::awt::XControlModel
interface | com::sun::star::lang::XComponent
interface | com::sun::star::beans::XPropertySet
interface | com::sun::star::beans::XMultiPropertySet
interface | com::sun::star::io::XPersistObject
interface | com::sun::star::util::XCloneable
Exported Interfaces inherited from FormComponent
interface | com::sun::star::form::XFormComponent
| identifies the component as a candidate for being part of a form.
interface | com::sun::star::lang::XComponent
| allows life-time control of form components.
interface | com::sun::star::container::XNamed
| Each FormComponent must supply a name for identification.
interface | com::sun::star::beans::XPropertySet
| gives access to the properties.
interface | com::sun::star::io::XPersistObject
| Each FormComponent must be able to be stored into and read from a stream.
interface | com::sun::star::beans::XPropertyBag
| allows to associate arbitrary properties with the form component
Exported Interfaces inherited from XPropertyBag
interface | com::sun::star::beans::XPropertySet
interface | com::sun::star::beans::XPropertyContainer
interface | com::sun::star::beans::XPropertyAccess

## Additional Inherited Members
Public Member Functions inherited from XInterface
any | queryInterface ([in] type aType)
| queries for a new interface to an existing UNO object.
void | acquire ()
| increases the reference counter by one.
void | release ()
| decreases the reference counter by one.
Public Member Functions inherited from XComponent
void | dispose ()
| The owner of an object calls this method to explicitly free all resources kept by this object and thus break cyclic references.
void | addEventListener ([in] XEventListener xListener)
| adds an event listener to the object.
void | removeEventListener ([in] XEventListener aListener)
| removes an event listener from the listener list.
Public Member Functions inherited from XPropertySet
com::sun::star::beans::XPropertySetInfo | getPropertySetInfo ()
void | setPropertyValue ([in] string aPropertyName, [in] any aValue) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::beans::PropertyVetoException, com::sun::star::lang::IllegalArgumentException, com::sun::star::lang::WrappedTargetException )
| sets the value of the property with the specified name.
any | getPropertyValue ([in] string PropertyName) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::lang::WrappedTargetException )
void | addPropertyChangeListener ([in] string aPropertyName, [in] com::sun::star::beans::XPropertyChangeListener xListener) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::lang::WrappedTargetException )
| adds an XPropertyChangeListener to the specified property.
void | removePropertyChangeListener ([in] string aPropertyName, [in] com::sun::star::beans::XPropertyChangeListener aListener) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::lang::WrappedTargetException )
| removes an XPropertyChangeListener from the listener list.
void | addVetoableChangeListener ([in] string PropertyName, [in] com::sun::star::beans::XVetoableChangeListener aListener) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::lang::WrappedTargetException )
| adds an XVetoableChangeListener to the specified property with the name PropertyName.
void | removeVetoableChangeListener ([in] string PropertyName, [in] com::sun::star::beans::XVetoableChangeListener aListener) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::lang::WrappedTargetException )
| removes an XVetoableChangeListener from the listener list.
Public Member Functions inherited from XMultiPropertySet
com::sun::star::beans::XPropertySetInfo | getPropertySetInfo ()
void | setPropertyValues ([in] sequence< string > aPropertyNames, [in] sequence< any > aValues) raises ( com::sun::star::beans::PropertyVetoException, com::sun::star::lang::IllegalArgumentException, com::sun::star::lang::WrappedTargetException )
| sets the values to the properties with the specified names.
sequence< any > | getPropertyValues ([in] sequence< string > aPropertyNames)
void | addPropertiesChangeListener ([in] sequence< string > aPropertyNames, [in] com::sun::star::beans::XPropertiesChangeListener xListener)
| adds an XPropertiesChangeListener to the specified property with the specified names.
void | removePropertiesChangeListener ([in] com::sun::star::beans::XPropertiesChangeListener xListener)
| removes an XPropertiesChangeListener from the listener list.
void | firePropertiesChangeEvent ([in] sequence< string > aPropertyNames, [in] com::sun::star::beans::XPropertiesChangeListener xListener)
| fires a sequence of PropertyChangeEvents to the specified listener.
Public Member Functions inherited from XPersistObject
string | getServiceName ()
| gives the service name of the object
void | write ([in] com::sun::star::io::XObjectOutputStream OutStream) raises ( com::sun::star::io::IOException )
| writes all the persistent data of the object to the stream.
void | read ([in] com::sun::star::io::XObjectInputStream InStream) raises ( com::sun::star::io::IOException )
| reads all the persistent data of the object from the stream.
Public Member Functions inherited from XCloneable
com::sun::star::util::XCloneable | createClone ()
| creates a copy of the object.
Public Member Functions inherited from XChild
com::sun::star::uno::XInterface | getParent ()
| grants access to the object containing this content.
void | setParent ([in] com::sun::star::uno::XInterface Parent) raises ( com::sun::star::lang::NoSupportException )
| sets the parent to this object.
Public Member Functions inherited from XNamed
string | getName ()
void | setName ([in] string aName)
| sets the programmatic name of the object.
Public Member Functions inherited from XValidatableFormComponent
boolean | isValid ()
| determines whether the current value of the component passed the validity test at the validator.
any | getCurrentValue ()
| retrieves the current value of the component.
void | addFormComponentValidityListener ([in] XFormComponentValidityListener Listener) raises ( com::sun::star::lang::NullPointerException )
| registers the given listener.
void | removeFormComponentValidityListener ([in] XFormComponentValidityListener Listener) raises ( com::sun::star::lang::NullPointerException )
| registers the given listener.
Public Member Functions inherited from XValidatable
void | setValidator ([in] XValidator Validator) raises ( com::sun::star::util::VetoException )
| sets an external instance which is able to validate the component
XValidator | getValidator ()
| retrieves the external instance which is currently used to validate the component
Public Member Functions inherited from XValidityConstraintListener
void | validityConstraintChanged ([in] com::sun::star::lang::EventObject Source)
| called when the validity constraint represented by an XValidator, at which the listener is registered, changed.
Public Member Functions inherited from XEventListener
void | disposing ([in] com::sun::star::lang::EventObject Source)
| gets called when the broadcaster is about to be disposed.
Public Attributes inherited from FormControlModel
short | ClassId
| specifies the ID for classification of the component.
short | TabIndex
| determines the relative taborder of the control associated with the model.
string | Tag
| used for additional information.
Public Attributes inherited from UnoControlModel
string | DefaultControl
| specifies the service name of the default control for this model.
Public Attributes inherited from FormComponent
string | Name
| the name of the component.
Protected Member Functions inherited from XInterface
any | queryInterface ([in] type aType)
| queries for a new interface to an existing UNO object.
void | acquire ()
| increases the reference counter by one.
void | release ()
| decreases the reference counter by one.
Protected Member Functions inherited from XComponent
void | dispose ()
| The owner of an object calls this method to explicitly free all resources kept by this object and thus break cyclic references.
void | addEventListener ([in] XEventListener xListener)
| adds an event listener to the object.
void | removeEventListener ([in] XEventListener aListener)
| removes an event listener from the listener list.
Protected Member Functions inherited from XPropertySet
com::sun::star::beans::XPropertySetInfo | getPropertySetInfo ()
void | setPropertyValue ([in] string aPropertyName, [in] any aValue) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::beans::PropertyVetoException, com::sun::star::lang::IllegalArgumentException, com::sun::star::lang::WrappedTargetException )
| sets the value of the property with the specified name.
any | getPropertyValue ([in] string PropertyName) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::lang::WrappedTargetException )
void | addPropertyChangeListener ([in] string aPropertyName, [in] com::sun::star::beans::XPropertyChangeListener xListener) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::lang::WrappedTargetException )
| adds an XPropertyChangeListener to the specified property.
void | removePropertyChangeListener ([in] string aPropertyName, [in] com::sun::star::beans::XPropertyChangeListener aListener) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::lang::WrappedTargetException )
| removes an XPropertyChangeListener from the listener list.
void | addVetoableChangeListener ([in] string PropertyName, [in] com::sun::star::beans::XVetoableChangeListener aListener) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::lang::WrappedTargetException )
| adds an XVetoableChangeListener to the specified property with the name PropertyName.
void | removeVetoableChangeListener ([in] string PropertyName, [in] com::sun::star::beans::XVetoableChangeListener aListener) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::lang::WrappedTargetException )
| removes an XVetoableChangeListener from the listener list.
Protected Member Functions inherited from XMultiPropertySet
com::sun::star::beans::XPropertySetInfo | getPropertySetInfo ()
void | setPropertyValues ([in] sequence< string > aPropertyNames, [in] sequence< any > aValues) raises ( com::sun::star::beans::PropertyVetoException, com::sun::star::lang::IllegalArgumentException, com::sun::star::lang::WrappedTargetException )
| sets the values to the properties with the specified names.
sequence< any > | getPropertyValues ([in] sequence< string > aPropertyNames)
void | addPropertiesChangeListener ([in] sequence< string > aPropertyNames, [in] com::sun::star::beans::XPropertiesChangeListener xListener)
| adds an XPropertiesChangeListener to the specified property with the specified names.
void | removePropertiesChangeListener ([in] com::sun::star::beans::XPropertiesChangeListener xListener)
| removes an XPropertiesChangeListener from the listener list.
void | firePropertiesChangeEvent ([in] sequence< string > aPropertyNames, [in] com::sun::star::beans::XPropertiesChangeListener xListener)
| fires a sequence of PropertyChangeEvents to the specified listener.
Protected Member Functions inherited from XPersistObject
string | getServiceName ()
| gives the service name of the object
void | write ([in] com::sun::star::io::XObjectOutputStream OutStream) raises ( com::sun::star::io::IOException )
| writes all the persistent data of the object to the stream.
void | read ([in] com::sun::star::io::XObjectInputStream InStream) raises ( com::sun::star::io::IOException )
| reads all the persistent data of the object from the stream.
Protected Member Functions inherited from XCloneable
com::sun::star::util::XCloneable | createClone ()
| creates a copy of the object.
Protected Member Functions inherited from XPropertyContainer
void | addProperty ([in] string Name, [in] short Attributes, [in] any DefaultValue) raises ( com::sun::star::beans::PropertyExistException, com::sun::star::beans::IllegalTypeException, com::sun::star::lang::IllegalArgumentException )
| adds a property to the object.
void | removeProperty ([in] string Name) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::beans::NotRemoveableException )
| removes a property from the object.
Protected Member Functions inherited from XPropertyAccess
sequence< com::sun::star::beans::PropertyValue > | getPropertyValues ()
void | setPropertyValues ([in] sequence< com::sun::star::beans::PropertyValue > aProps) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::beans::PropertyVetoException, com::sun::star::lang::IllegalArgumentException, com::sun::star::lang::WrappedTargetException )
| sets the values of given properties.
Protected Member Functions inherited from XFastPropertySet
void | setFastPropertyValue ([in] long nHandle, [in] any aValue) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::beans::PropertyVetoException, com::sun::star::lang::IllegalArgumentException, com::sun::star::lang::WrappedTargetException )
| sets the value to the property with the specified name.
any | getFastPropertyValue ([in] long nHandle) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::lang::WrappedTargetException )
Protected Member Functions inherited from XPropertyState
com::sun::star::beans::PropertyState | getPropertyState ([in] string PropertyName) raises ( com::sun::star::beans::UnknownPropertyException )
sequence< com::sun::star::beans::PropertyState > | getPropertyStates ([in] sequence< string > aPropertyName) raises ( com::sun::star::beans::UnknownPropertyException )
void | setPropertyToDefault ([in] string PropertyName) raises ( com::sun::star::beans::UnknownPropertyException )
| Sets the property to default value.
any | getPropertyDefault ([in] string aPropertyName) raises ( com::sun::star::beans::UnknownPropertyException, com::sun::star::lang::WrappedTargetException )
Protected Attributes inherited from UnoControlDialogElement
long | Height
| specifies the height of the control.
string | Name
| specifies the name of the control.
string | PositionX
| specifies the horizontal position of the control.
string | PositionY
| specifies the vertical position of the control.
long | Step
| specifies the step of the control.
short | TabIndex
| specifies the tabindex of the control.
string | Tag
| specifies the tag of the control.
long | Width
| specifies the width of the control.

## Detailed Description

specifies the model of a form control which supports live validation of its input.

Validatable control models support setting a validator with dynamic validity constraints, and broadcasting changes in their value as well as the validity of their value.

## Exported Interfaces

## ◆ com::sun::star::form::FormControlModel

service com::sun::star::form::FormControlModel

specifies the basic functionality for a form control model

Via this service, validatable control models inherit the com::sun::star::util::XCloneable interface.
If a validatable control model, at which a validator has been set (via XValidatable::setValidator()), is being cloned, then the validator is also set at the clone. Effectively, this means that both control model instances share the same validator instance.

## Exported Interfaces

## ◆ XValidatableFormComponent

interface XValidatableFormComponent

enables support for validating the value of the control model

Setting and retrieving the current validator of the control model is possible via the XValidatable interface (which XValidatableFormComponent is derived from).

Easy access to the current value of the control, as well as it's validity (relative to the active validator), is provided by the methods XValidatableFormComponent::isValid() and XValidatableFormComponent::getCurrentValue().

Note that the type of the value provided by XValidatableFormComponent::getCurrentValue() is not specified here, but depends on the concrete control type.

## ◆ XValidityConstraintListener

interface XValidityConstraintListener

enables support for validators with dynamic validity constraints.

As soon as a validator is set via XValidatable::setValidator(), the validatable control model registers itself as listener. If the validity constraint of the validator changes, the ValidatableControlModel re-validates its current valid, and broadcasts any resulting changes to all its XFormComponentValidityListener, if necessary.

The documentation for this service was generated from the following file:

- com/sun/star/form/validation/ValidatableControlModel.idl