|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.globalmentor.beans.BoundPropertyObject
com.guiseframework.event.GuiseBoundPropertyObject
com.guiseframework.model.ui.AbstractPresentationModel
com.guiseframework.component.AbstractComponent
com.guiseframework.component.AbstractCompositeComponent
com.guiseframework.component.AbstractMultipleCompositeComponent
com.guiseframework.component.AbstractArrayCompositeComponent
com.guiseframework.component.AbstractEnumCompositeComponent<AbstractFrame.FrameComponent>
com.guiseframework.component.AbstractFrame
com.guiseframework.component.AbstractDialogFrame<V>
V - The value to be communicated.public abstract class AbstractDialogFrame<V>
Abstract implementation of a frame meant for communication of a value.
A dialog frame by default is modal and movable but not resizable.
The component valid status is updated before a change in the ValueModel.VALUE_PROPERTY or the ValueModel.VALIDATOR_PROPERTY is fired.
This implementation binds the action AbstractFrame.getCloseActionPrototype() to the command ProcessCommand.CONTINUE.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class com.guiseframework.component.AbstractFrame |
|---|
AbstractFrame.DefaultPrototypeProvider, AbstractFrame.FrameComponent |
| Nested classes/interfaces inherited from class com.guiseframework.component.AbstractComponent |
|---|
AbstractComponent.AbstractFlyoverFrameStrategy<S extends Component>, AbstractComponent.AbstractFlyoverStrategy<S extends Component>, AbstractComponent.DefaultFlyoverStrategy<S extends Component> |
| Nested classes/interfaces inherited from interface com.guiseframework.component.Frame |
|---|
Frame.Mode, Frame.State |
| Nested classes/interfaces inherited from interface com.guiseframework.component.Control |
|---|
Control.Status |
| Field Summary |
|---|
| Fields inherited from class com.globalmentor.beans.BoundPropertyObject |
|---|
NO_PROPERTY_CHANGE_LISTENERS, NO_VETOABLE_CHANGE_LISTENERS |
| Fields inherited from interface com.guiseframework.component.Frame |
|---|
CLOSE_ACTION_CONTROL_PROPERTY, MENU_PROPERTY, MODAL_PROPERTY, MOVABLE_PROPERTY, OPEN_EFFECT_PROPERTY, RELATED_COMPONENT_PROPERTY, RESIZABLE_PROPERTY, STATE_PROPERTY, TITLE_BACKGROUND_COLOR_PROPERTY, TITLE_VISIBLE_PROPERTY, TOOLBAR_PROPERTY |
| Fields inherited from interface com.guiseframework.component.ContentComponent |
|---|
CONTENT_PROPERTY |
| Fields inherited from interface com.guiseframework.component.ModalComponent |
|---|
MODE_PROPERTY |
| Fields inherited from interface com.guiseframework.component.InputFocusGroupComponent |
|---|
INPUT_FOCUS_STRATEGY_PROPERTY, INPUT_FOCUSED_COMPONENT_PROPERTY |
| Fields inherited from interface com.guiseframework.component.ValueControl |
|---|
CONVERTER_PROPERTY |
| Fields inherited from interface com.guiseframework.component.Control |
|---|
STATUS_PROPERTY |
| Fields inherited from interface com.guiseframework.model.Enableable |
|---|
ENABLED_PROPERTY |
| Fields inherited from interface com.guiseframework.model.ValueModel |
|---|
VALIDATOR_PROPERTY, VALUE_PROPERTY |
| Constructor Summary | |
|---|---|
AbstractDialogFrame(ValueModel<V> valueModel,
Component component)
Value model, and component constructor. |
|
| Method Summary | ||
|---|---|---|
void |
clearValue()
Clears the value by setting the value to null, which may be invalid according to any installed validators. |
|
protected Control.Status |
determineStatus()
Checks the user input status of the control. |
|
protected boolean |
determineValid()
Checks the state of the component for validity. |
|
protected
|
firePropertyChange(java.lang.String propertyName,
VV oldValue,
VV newValue)
Reports that a bound property has changed. |
|
V |
getDefaultValue()
|
|
Control.Status |
getStatus()
|
|
Validator<V> |
getValidator()
|
|
V |
getValue()
|
|
java.lang.Class<V> |
getValueClass()
|
|
protected ValueModel<V> |
getValueModel()
|
|
boolean |
isEnabled()
|
|
boolean |
isValidValue()
Determines whether the value of this model is valid. |
|
void |
reset()
Resets the control to its default value. |
|
void |
resetValue()
Resets the value to a default value, which may be invalid according to any installed validators. |
|
void |
setEnabled(boolean newEnabled)
Sets whether the control is enabled and and can receive user input. |
|
void |
setNotification(Notification newNotification)
Sets the component notification. |
|
protected void |
setStatus(Control.Status newStatus)
Sets the status of the current user input. |
|
void |
setValidator(Validator<V> newValidator)
Sets the validator. |
|
void |
setValue(V newValue)
Sets the input value. |
|
protected void |
updateStatus()
Rechecks user input status of this component, and updates the status. |
|
protected void |
updateValid()
Rechecks user input validity of this component and all child components, and updates the valid state. |
|
boolean |
validate()
Validates the user input of this component and all child components. |
|
void |
validateValue()
Validates the value of this model, throwing an exception if the model is not valid. |
|
| Methods inherited from class com.guiseframework.component.AbstractEnumCompositeComponent |
|---|
getComponent, setComponent |
| Methods inherited from class com.guiseframework.component.AbstractArrayCompositeComponent |
|---|
getChildComponents, getChildList, getComponent, hasChildComponents, setComponent |
| Methods inherited from class com.guiseframework.component.AbstractMultipleCompositeComponent |
|---|
addComponent, removeComponent |
| Methods inherited from class com.guiseframework.event.GuiseBoundPropertyObject |
|---|
getSession |
| Methods inherited from class com.globalmentor.beans.BoundPropertyObject |
|---|
addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, addVetoableChangeListener, createPostponedPropertyChangeEvent, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, getForwardPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, getPropertyChangeSupport, getRepeatPropertyChangeListener, getRepeatVetoableChangeListener, getVetoableChangeListeners, getVetoableChangeListeners, getVetoableChangeSupport, hasPropertyChangeListeners, hasVetoableChangeListeners, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, removeVetoableChangeListener |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface com.guiseframework.component.Frame |
|---|
canClose, close, getCloseActionControl, getCloseActionPrototype, getMenu, getOpenEffect, getRelatedComponent, getState, getTitleBackgroundColor, getToolbar, isModal, isMovable, isResizable, isTitleVisible, open, open, open, setCloseActionControl, setMenu, setModal, setMovable, setOpenEffect, setRelatedComponent, setResizable, setTitleBackgroundColor, setTitleVisible, setToolbar |
| Methods inherited from interface com.guiseframework.component.ContentComponent |
|---|
getContent, setContent |
| Methods inherited from interface com.guiseframework.component.CompositeComponent |
|---|
addCompositeComponentListener, getChildComponents, hasChildComponents, removeCompositeComponentListener |
| Methods inherited from interface com.guiseframework.component.ModalComponent |
|---|
getMode, setMode |
| Methods inherited from interface com.guiseframework.component.InputFocusGroupComponent |
|---|
getInputFocusedComponent, getInputFocusStrategy, setInputFocusedComponent, setInputFocusStrategy |
| Constructor Detail |
|---|
public AbstractDialogFrame(ValueModel<V> valueModel,
Component component)
valueModel - The frame value model.component - The single child component, or null if this frame should have no child component.
java.lang.NullPointerException - if the given value model is null.| Method Detail |
|---|
protected ValueModel<V> getValueModel()
public boolean isEnabled()
isEnabled in interface Enableablepublic void setEnabled(boolean newEnabled)
Boolean.
setEnabled in interface EnableablenewEnabled - true if the control should indicate and accept user input.Enableable.ENABLED_PROPERTYpublic Control.Status getStatus()
getStatus in interface Controlnull if there is no status to report.protected void setStatus(Control.Status newStatus)
newStatus - The new status of the current user input, or null if there is no status to report.Control.STATUS_PROPERTYprotected void updateStatus()
setStatus(Control.Status)protected Control.Status determineStatus()
Notification.Severity#WARNING, the status is determined to be Status#WARNING.
If the component has a notification of Notification.Severity#ERROR, the status is determined to be Status#ERROR.
Otherwise, this version returns null.
protected void updateValid()
updateValid in class AbstractComponentAbstractComponent.setValid(boolean),
updateStatus()public void setNotification(Notification newNotification)
setNotification in interface ComponentsetNotification in class AbstractComponentnewNotification - The notification for the component, or null if no notification is associated with this component.Component.NOTIFICATION_PROPERTYpublic void reset()
reset in interface ControlsetNotification(Notification),
resetValue()
protected <VV> void firePropertyChange(java.lang.String propertyName,
VV oldValue,
VV newValue)
firePropertyChange in class com.globalmentor.beans.BoundPropertyObjectpropertyName - The name of the property being changed.oldValue - The old property value.newValue - The new property value.BoundPropertyObject.firePropertyChange(PropertyChangeEvent),
BoundPropertyObject.hasPropertyChangeListeners(String),
GenericPropertyChangeEvent,
GenericPropertyChangeListenerprotected boolean determineValid()
determineValid in class AbstractCompositeComponenttrue if the component and all children passes all validity tests, else false.public boolean validate()
validate in interface Componentvalidate in class AbstractFrameAbstractComponent.isValid() as a convenience.public V getDefaultValue()
getDefaultValue in interface ValueModel<V>public V getValue()
getValue in interface ValuedComponent<V>getValue in interface Valued<V>getValue in interface ValueModel<V>null if there is no input value.
public void setValue(V newValue)
throws java.beans.PropertyVetoException
equals() method.
If a validator is installed, the value will first be validated before the current value is changed.
Validation always occurs if a validator is installed, even if the value is not changing.
If the value change is vetoed by the installed validator, the validation exception will be accessible via Throwable.getCause().
setValue in interface ValuedComponent<V>setValue in interface Valued<V>setValue in interface ValueModel<V>newValue - The input value of the model.
java.beans.PropertyVetoException - if the provided value is not valid or the change has otherwise been vetoed.getValidator(),
ValueModel.VALUE_PROPERTYpublic void clearValue()
null, which may be invalid according to any installed validators.
No validation occurs.
clearValue in interface ValueModel<V>ValueModel.VALUE_PROPERTYpublic void resetValue()
resetValue in interface ValueModel<V>ValueModel.VALUE_PROPERTYpublic Validator<V> getValidator()
getValidator in interface ValueModel<V>null if no validator is installed.public void setValidator(Validator<V> newValidator)
setValidator in interface ValueModel<V>newValidator - The validator for this model, or null if no validator should be used.ValueModel.VALIDATOR_PROPERTYpublic boolean isValidValue()
isValidValue in interface ValueModel<V>
public void validateValue()
throws ValidationException
validateValue in interface ValueModel<V>ValidationException - if the value of this model is not valid.public java.lang.Class<V> getValueClass()
getValueClass in interface ValuedComponent<V>getValueClass in interface ValueModel<V>
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||