This package contains classes and interfaces for the implementation of form controllers.
Dealing with a form is typically a tedious task. When the GUI is setup, a lot of tasks have to be performed for correctly handling user input: the input fields of the form have to be filled with their initial values, user input has to be validated, fields containing invalid data have to be marked somehow, committing the form is only allowed if all entered data is valid, and so on.
This package defines a form controller base class that addresses these problems. In collaboration with a bunch of helper classes, a form controller is able to manage the whole life cycle of a form:
FormValidationTrigger
determines when a validation has to be performed. This could for instance be any
time the user leaves an input field. Of course, if the user hits the OK button
to close the form, a validation will always be initiated.FieldMarker
is responsible for changing the display properties
of an input field depending on its current validation status. A concrete
implementation could for instance paint the background of input fields containing
invalid data in a different color.
The main FormController
class is the central point for implementing
this functionality. In most cases, it should be possible to use this class out
of the box. Application-specific logic can be injected by specifying configuration
objects when the controller is created. Adaptations to the specific look and
feel of a concrete application can be achieved by providing different
implementations of the helper objects involved.
$Id: package.html 192 2010-08-22 16:15:22Z oheger $