com.guiseframework.component
Class BooleanValueControlSelectControl<V>

java.lang.Object
  extended by com.globalmentor.beans.BoundPropertyObject
      extended by com.guiseframework.event.GuiseBoundPropertyObject
          extended by com.guiseframework.model.ui.AbstractPresentationModel
              extended by com.guiseframework.component.AbstractComponent
                  extended by com.guiseframework.component.AbstractCompositeComponent
                      extended by com.guiseframework.component.AbstractMultipleCompositeComponent
                          extended by com.guiseframework.component.AbstractCompositeStateComponent<T,S>
                              extended by com.guiseframework.component.AbstractCompositeStateControl<V,AbstractListSelectControl.ValueComponentState>
                                  extended by com.guiseframework.component.AbstractListSelectControl<V>
                                      extended by com.guiseframework.component.BooleanValueControlSelectControl<V>
Type Parameters:
V - The type of values to select.
All Implemented Interfaces:
com.globalmentor.beans.PropertyBindable, com.globalmentor.beans.PropertyConstrainable, Component, CompositeComponent, Control, InputFocusableComponent, LayoutComponent, ListSelectControl<V>, SelectControl<V>, ValueControl<V>, ValuedComponent<V>, ListListenable<V>, Displayable, Enableable, InfoModel, LabelModel, ListSelectModel<V>, Model, SelectModel<V>, PresentationModel, Valued<V>, ValueModel<V>, DepictedObject, java.lang.Iterable<V>, java.util.Collection<V>, java.util.List<V>

public class BooleanValueControlSelectControl<V>
extends AbstractListSelectControl<V>
implements LayoutComponent, ListSelectControl<V>

A list select control that uses child components to show the list items. Only ValueControls of type Boolean will be recognized as able to receive user input to select items in the list. Only a Layout that supports default constraints can be used.

Author:
Garret Wilson

Nested Class Summary
 
Nested classes/interfaces inherited from class com.guiseframework.component.AbstractListSelectControl
AbstractListSelectControl.ConverterInfoModelValueRepresentationStrategy<VV>, AbstractListSelectControl.DefaultValueRepresentationStrategy<VV>, AbstractListSelectControl.ValueComponentState
 
Nested classes/interfaces inherited from class com.guiseframework.component.AbstractCompositeStateComponent
AbstractCompositeStateComponent.ComponentState
 
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.ListSelectControl
ListSelectControl.ValueRepresentationStrategy<VV>
 
Nested classes/interfaces inherited from interface com.guiseframework.component.Control
Control.Status
 
Nested classes/interfaces inherited from interface com.guiseframework.component.Component
Component.FlyoverStrategy<S extends Component>
 
Field Summary
protected  com.globalmentor.beans.GenericPropertyChangeListener<java.lang.Boolean> componentValueChangeListener
          The listener that detects changes to a child component's Boolean value and updates the control's selected values accordingly.
protected  java.util.concurrent.atomic.AtomicBoolean synchronizingValuesFlag
          The atomic flag that allows us to know whether we're synchronizing values, either from the list to the child controls or vice versa.
 
Fields inherited from class com.globalmentor.beans.BoundPropertyObject
NO_PROPERTY_CHANGE_LISTENERS, NO_VETOABLE_CHANGE_LISTENERS
 
Fields inherited from interface com.guiseframework.component.LayoutComponent
LAYOUT_PROPERTY, LAYOUT_THEME_APPLIED_PROPERTY
 
Fields inherited from interface com.guiseframework.component.SelectControl
VALUE_REPRESENTATION_STRATEGY_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.component.Component
BOOKMARK_ENABLED_PROPERTY, CONSTRAINTS_PROPERTY, DRAG_ENABLED_PROPERTY, DROP_ENABLED_PROPERTY, FLYOVER_ENABLED_PROPERTY, FLYOVER_STRATEGY_PROPERTY, INPUT_STRATEGY_PROPERTY, NAME_PROPERTY, NOTIFICATION_PROPERTY, ORIENTATION_PROPERTY, THEME_APPLIED_PROPERTY, VALID_PROPERTY
 
Fields inherited from interface com.guiseframework.model.ui.PresentationModel
BACKGROUND_COLOR_PROPERTY, BORDER_LINE_FAR_COLOR_PROPERTY, BORDER_LINE_FAR_EXTENT_PROPERTY, BORDER_LINE_FAR_STYLE_PROPERTY, BORDER_LINE_NEAR_COLOR_PROPERTY, BORDER_LINE_NEAR_EXTENT_PROPERTY, BORDER_LINE_NEAR_STYLE_PROPERTY, BORDER_PAGE_FAR_COLOR_PROPERTY, BORDER_PAGE_FAR_EXTENT_PROPERTY, BORDER_PAGE_FAR_STYLE_PROPERTY, BORDER_PAGE_NEAR_COLOR_PROPERTY, BORDER_PAGE_NEAR_EXTENT_PROPERTY, BORDER_PAGE_NEAR_STYLE_PROPERTY, CORNER_LINE_FAR_PAGE_FAR_ARC_SIZE_PROPERTY, CORNER_LINE_FAR_PAGE_NEAR_ARC_SIZE_PROPERTY, CORNER_LINE_NEAR_PAGE_FAR_ARC_SIZE_PROPERTY, CORNER_LINE_NEAR_PAGE_NEAR_ARC_SIZE_PROPERTY, CURSOR_PROPERTY, FONT_FAMILIES_PROPERTY, FONT_SIZE_PROPERTY, FONT_STYLE_PROPERTY, FONT_WEIGHT_BOLD, FONT_WEIGHT_NORMAL, FONT_WEIGHT_PROPERTY, LABEL_FONT_FAMILIES_PROPERTY, LABEL_FONT_SIZE_PROPERTY, LABEL_FONT_STYLE_PROPERTY, LABEL_FONT_WEIGHT_PROPERTY, LABEL_TEXT_COLOR_PROPERTY, LINE_EXTENT_PROPERTY, MARGIN_LINE_FAR_EXTENT_PROPERTY, MARGIN_LINE_NEAR_EXTENT_PROPERTY, MARGIN_PAGE_FAR_EXTENT_PROPERTY, MARGIN_PAGE_NEAR_EXTENT_PROPERTY, OPACITY_PROPERTY, PADDING_LINE_FAR_EXTENT_PROPERTY, PADDING_LINE_NEAR_EXTENT_PROPERTY, PADDING_PAGE_FAR_EXTENT_PROPERTY, PADDING_PAGE_NEAR_EXTENT_PROPERTY, PAGE_EXTENT_PROPERTY, ROUNDED_CORNER_ARC_SIZE, STYLE_ID_PROPERTY, TEXT_COLOR_PROPERTY, TOOLTIP_ENABLED_PROPERTY, VISIBLE_PROPERTY
 
Fields inherited from interface com.guiseframework.model.Displayable
DISPLAYED_PROPERTY
 
Fields inherited from interface com.guiseframework.model.InfoModel
DESCRIPTION_CONTENT_TYPE_PROPERTY, DESCRIPTION_PROPERTY, INFO_CONTENT_TYPE_PROPERTY, INFO_PROPERTY
 
Fields inherited from interface com.guiseframework.model.LabelModel
GLYPH_URI_PROPERTY, LABEL_CONTENT_TYPE_PROPERTY, LABEL_PROPERTY
 
Fields inherited from interface com.guiseframework.model.Model
PLAIN_TEXT_CONTENT_TYPE, XHTML_CONTENT_TYPE, XHTML_FRAGMENT_CONTENT_TYPE
 
Fields inherited from interface com.guiseframework.model.Enableable
ENABLED_PROPERTY
 
Fields inherited from interface com.guiseframework.model.ValueModel
VALIDATOR_PROPERTY, VALUE_PROPERTY
 
Constructor Summary
BooleanValueControlSelectControl(java.lang.Class<V> valueClass)
          Value class constructor with a default data model to represent a given type with multiple selection and a FlowLayout with Flow.PAGE flow.
BooleanValueControlSelectControl(java.lang.Class<V> valueClass, Layout<?> layout)
          Value class and layout constructor with a default data model to represent a given type with multiple selection.
BooleanValueControlSelectControl(java.lang.Class<V> valueClass, Layout<?> layout, ListSelectControl.ValueRepresentationStrategy<V> valueRepresentationStrategy)
          Value class, layout, and value representation strategy constructor with a default data model to represent a given type with multiple selection.
BooleanValueControlSelectControl(java.lang.Class<V> valueClass, ListSelectControl.ValueRepresentationStrategy<V> valueRepresentationStrategy)
          Value class and value representation strategy constructor with a default data model to represent a given type with multiple selection and a FlowLayout with Flow.PAGE flow.
BooleanValueControlSelectControl(java.lang.Class<V> valueClass, ListSelectionPolicy<V> selectionStrategy)
          Value class and selection strategy constructor with a default data model to represent a given type and a FlowLayout with Flow.PAGE flow.
BooleanValueControlSelectControl(java.lang.Class<V> valueClass, ListSelectionPolicy<V> selectionStrategy, Layout<?> layout)
          Value class, selection strategy, and layout constructor with a default data model to represent a given type.
BooleanValueControlSelectControl(java.lang.Class<V> valueClass, ListSelectionPolicy<V> selectionStrategy, Layout<?> layout, ListSelectControl.ValueRepresentationStrategy<V> valueRepresentationStrategy)
          Value class, selection strategy, layout, and value representation strategy constructor with a default data model to represent a given type.
BooleanValueControlSelectControl(java.lang.Class<V> valueClass, ListSelectionPolicy<V> selectionStrategy, ListSelectControl.ValueRepresentationStrategy<V> valueRepresentationStrategy)
          Value class, selection strategy, and value representation strategy constructor with a default data model to represent a given type and a FlowLayout with Flow.PAGE flow.
BooleanValueControlSelectControl(ListSelectModel<V> listSelectModel)
          List select model constructor with a FlowLayout with Flow.PAGE flow.
BooleanValueControlSelectControl(ListSelectModel<V> listSelectModel, Layout<?> layout)
          List select model and layout constructor.
BooleanValueControlSelectControl(ListSelectModel<V> listSelectModel, Layout<?> layout, ListSelectControl.ValueRepresentationStrategy<V> valueRepresentationStrategy)
          List select model, layout, and value representation strategy constructor.
BooleanValueControlSelectControl(ListSelectModel<V> listSelectModel, ListSelectControl.ValueRepresentationStrategy<V> valueRepresentationStrategy)
          List select model and value representation strategy constructor with a FlowLayout with Flow.PAGE flow.
 
Method Summary
protected  void addComponent(Component childComponent)
          Adds a component to the layout component with default constraints.
 void applyTheme()
          Applies the theme to this object.
 void applyTheme(Theme theme)
          Applies a theme and its parents to this object.
 java.lang.Iterable<Component> getChildComponents()
          Returns an iterable to child components.
 Layout<? extends Constraints> getLayout()
           
protected  ValuePolicyModelGroup<java.lang.Boolean> getValuePolicyModelGroup()
           
 boolean isLayoutThemeApplied()
           
protected  void removeComponent(Component childComponent)
          Removes a component from the layout component.
 void resetTheme()
          Resets this object's theme.
protected
<T extends Constraints>
void
setLayout(Layout<T> newLayout)
          Sets the layout definition for the component.
 void setLayoutThemeApplied(boolean newLayoutThemeApplied)
          Sets whether a theme has been applied to this component's layout.
protected  void updateChildControlValues()
          Updates the values of child controls based upon the current state of the list selected values.
protected  void updateListSelectedValues()
          Updates the list selected values based upon the current values of the child controls.
 void updateTheme()
          Updates this object's theme.
 
Methods inherited from class com.guiseframework.component.AbstractListSelectControl
add, add, addAll, addAll, addListListener, addListSelectionListener, addSelectedIndexes, clear, clearValue, contains, containsAll, createComponentState, determineValid, fireListModified, firePropertyChange, fireSelectionChanged, get, getComponent, getDefaultValue, getListSelectModel, getSelectedIndex, getSelectedIndexes, getSelectedValue, getSelectedValues, getSelectionPolicy, getValidator, getValue, getValueClass, getValueRepresentationStrategy, indexOf, isEmpty, isIndexDisplayed, isIndexEnabled, isValidValue, isValueDisplayed, isValueEnabled, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeListListener, removeListSelectionListener, removeSelectedIndexes, replace, reset, resetValue, retainAll, set, setIndexDisplayed, setIndexEnabled, setSelectedIndexes, setSelectedValues, setValidator, setValue, setValueDisplayed, setValueEnabled, setValueRepresentationStrategy, size, subList, toArray, toArray, validate, validateValue
 
Methods inherited from class com.guiseframework.component.AbstractCompositeStateControl
determineStatus, getEnableable, getStatus, isEnabled, setEnabled, setNotification, setStatus, updateStatus, updateValid
 
Methods inherited from class com.guiseframework.component.AbstractCompositeStateComponent
clearComponentStates, determineComponentState, getComponentState, getComponentStates, getObject, putComponentState, removeComponentState
 
Methods inherited from class com.guiseframework.component.AbstractMultipleCompositeComponent
hasChildComponents
 
Methods inherited from class com.guiseframework.component.AbstractCompositeComponent
addCompositeComponentListener, childComponentValidPropertyChanged, determineChildrenValid, dispatchInputEvent, dispatchInputEvent, fireChildComponentAdded, fireChildComponentAdded, fireChildComponentRemoved, fireChildComponentRemoved, initializeChildComponent, loadPreferences, removeCompositeComponentListener, savePreferences, uninitializeChildComponent, validateChildren
 
Methods inherited from class com.guiseframework.component.AbstractComponent
addCommandListener, addExportStrategy, addImportStrategy, addKeyListener, addMouseListener, addNotificationListener, addPreferenceProperty, depict, equals, exportTransfer, fireInputEvent, fireNotified, fireNotified, getAncestor, getCommandListeners, getComponentByID, getComponentByName, getComponentOrientation, getConstraints, getDepictID, getDepictor, getDescription, getDescriptionContentType, getDirtyComponents, getDirtyComponents, getEventListenerManager, getFlyoverStrategy, getGlyphURI, getInfo, getInfoContentType, getInfoModel, getInputStrategy, getKeyListeners, getLabel, getLabelContentType, getMouseListeners, getName, getNotification, getNotifications, getNotifications, getOrientation, getParent, getPreferenceProperties, getRootComponent, getTheme, hasAncestor, hasCommandListeners, hashCode, hasKeyListeners, hasMouseListeners, importTransfer, initialize, isDragEnabled, isDropEnabled, isFlyoverEnabled, isPreferenceProperty, isThemeApplied, isValid, notify, processEvent, removeCommandListener, removeExportStrategy, removeImportStrategy, removeKeyListener, removeMouseListener, removeNotificationListener, removePreferenceProperty, setConstraints, setDepicted, setDescription, setDescriptionContentType, setDragEnabled, setDropEnabled, setFlyoverEnabled, setFlyoverStrategy, setGlyphURI, setInfo, setInfoContentType, setInputStrategy, setLabel, setLabelContentType, setName, setOrientation, setParent, setThemeApplied, setValid, toString, update
 
Methods inherited from class com.guiseframework.model.ui.AbstractPresentationModel
BorderLineFarColor, BorderLineFarExtent, BorderLineFarStyle, BorderLineNearColor, BorderLineNearExtent, BorderLineNearStyle, BorderPageFarColor, BorderPageFarExtent, BorderPageFarStyle, BorderPageNearColor, BorderPageNearExtent, BorderPageNearStyle, getBackgroundColor, getBorderColor, getBorderExtent, getBorderStyle, getCornerArcSize, getCornerLineFarPageFarArcSize, getCornerLineFarPageNearArcSize, getCornerLineNearPageFarArcSize, getCornerLineNearPageNearArcSize, getCursor, getExtent, getFontFamilies, getFontSize, getFontStyle, getFontWeight, getLabelFontFamilies, getLabelFontSize, getLabelFontStyle, getLabelFontWeight, getLabelTextColor, getLineExtent, getMarginExtent, getMarginLineFarExtent, getMarginLineNearExtent, getMarginPageFarExtent, getMarginPageNearExtent, getOpacity, getPaddingExtent, getPaddingLineFarExtent, getPaddingLineNearExtent, getPaddingPageFarExtent, getPaddingPageNearExtent, getPageExtent, getStyleID, getTextColor, isDisplayed, isTooltipEnabled, isVisible, setBackgroundColor, setBorderColor, setBorderColor, setBorderExtent, setBorderExtent, setBorderLineFarColor, setBorderLineFarExtent, setBorderLineFarStyle, setBorderLineNearColor, setBorderLineNearExtent, setBorderLineNearStyle, setBorderPageFarColor, setBorderPageFarExtent, setBorderPageFarStyle, setBorderPageNearColor, setBorderPageNearExtent, setBorderPageNearStyle, setBorderStyle, setBorderStyle, setCornerArcSize, setCornerArcSize, setCornerLineFarPageFarArcSize, setCornerLineFarPageNearArcSize, setCornerLineNearPageFarArcSize, setCornerLineNearPageNearArcSize, setCursor, setDisplayed, setExtent, setFontFamilies, setFontSize, setFontStyle, setFontWeight, setLabelFontFamilies, setLabelFontSize, setLabelFontStyle, setLabelFontWeight, setLabelTextColor, setLineExtent, setMarginExtent, setMarginExtent, setMarginLineFarExtent, setMarginLineNearExtent, setMarginPageFarExtent, setMarginPageNearExtent, setOpacity, setPaddingExtent, setPaddingExtent, setPaddingLineFarExtent, setPaddingLineNearExtent, setPaddingPageFarExtent, setPaddingPageNearExtent, setPageExtent, setStyleID, setTextColor, setTooltipEnabled, setVisible
 
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, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.guiseframework.component.CompositeComponent
addCompositeComponentListener, hasChildComponents, removeCompositeComponentListener
 
Methods inherited from interface com.guiseframework.component.ListSelectControl
getComponent, getValueRepresentationStrategy, setValueRepresentationStrategy
 
Methods inherited from interface com.guiseframework.component.Control
getStatus, reset
 
Methods inherited from interface com.guiseframework.component.Component
addCommandListener, addExportStrategy, addImportStrategy, addKeyListener, addMouseListener, addNotificationListener, addPreferenceProperty, dispatchInputEvent, exportTransfer, fireInputEvent, getAncestor, getComponentOrientation, getConstraints, getDepictor, getFlyoverStrategy, getInputStrategy, getName, getNotification, getOrientation, getParent, getPreferenceProperties, getTheme, hasCommandListeners, hasKeyListeners, hasMouseListeners, importTransfer, initialize, isDragEnabled, isDropEnabled, isFlyoverEnabled, isPreferenceProperty, isThemeApplied, isValid, loadPreferences, notify, removeCommandListener, removeExportStrategy, removeImportStrategy, removeKeyListener, removeMouseListener, removeNotificationListener, removePreferenceProperty, savePreferences, setConstraints, setDragEnabled, setDropEnabled, setFlyoverEnabled, setFlyoverStrategy, setInputStrategy, setName, setNotification, setOrientation, setParent, setThemeApplied, validate
 
Methods inherited from interface com.guiseframework.platform.DepictedObject
depict, getDepictID, getSession, processEvent
 
Methods inherited from interface com.guiseframework.model.ui.PresentationModel
BorderLineFarColor, BorderLineFarExtent, BorderLineFarStyle, BorderLineNearColor, BorderLineNearExtent, BorderLineNearStyle, BorderPageFarColor, BorderPageFarExtent, BorderPageFarStyle, BorderPageNearColor, BorderPageNearExtent, BorderPageNearStyle, getBackgroundColor, getBorderColor, getBorderExtent, getBorderStyle, getCornerArcSize, getCornerLineFarPageFarArcSize, getCornerLineFarPageNearArcSize, getCornerLineNearPageFarArcSize, getCornerLineNearPageNearArcSize, getCursor, getExtent, getFontFamilies, getFontSize, getFontStyle, getFontWeight, getLabelFontFamilies, getLabelFontSize, getLabelFontStyle, getLabelFontWeight, getLabelTextColor, getLineExtent, getMarginExtent, getMarginLineFarExtent, getMarginLineNearExtent, getMarginPageFarExtent, getMarginPageNearExtent, getOpacity, getPaddingExtent, getPaddingLineFarExtent, getPaddingLineNearExtent, getPaddingPageFarExtent, getPaddingPageNearExtent, getPageExtent, getSession, getStyleID, getTextColor, isDisplayed, isTooltipEnabled, isVisible, setBackgroundColor, setBorderColor, setBorderColor, setBorderExtent, setBorderExtent, setBorderLineFarColor, setBorderLineFarExtent, setBorderLineFarStyle, setBorderLineNearColor, setBorderLineNearExtent, setBorderLineNearStyle, setBorderPageFarColor, setBorderPageFarExtent, setBorderPageFarStyle, setBorderPageNearColor, setBorderPageNearExtent, setBorderPageNearStyle, setBorderStyle, setBorderStyle, setCornerArcSize, setCornerArcSize, setCornerLineFarPageFarArcSize, setCornerLineFarPageNearArcSize, setCornerLineNearPageFarArcSize, setCornerLineNearPageNearArcSize, setCursor, setDisplayed, setExtent, setFontFamilies, setFontSize, setFontStyle, setFontWeight, setLabelFontFamilies, setLabelFontSize, setLabelFontStyle, setLabelFontWeight, setLabelTextColor, setLineExtent, setMarginExtent, setMarginExtent, setMarginLineFarExtent, setMarginLineNearExtent, setMarginPageFarExtent, setMarginPageNearExtent, setOpacity, setPaddingExtent, setPaddingExtent, setPaddingLineFarExtent, setPaddingLineNearExtent, setPaddingPageFarExtent, setPaddingPageNearExtent, setPageExtent, setStyleID, setTextColor, setTooltipEnabled, setVisible
 
Methods inherited from interface com.guiseframework.model.InfoModel
getDescription, getDescriptionContentType, getInfo, getInfoContentType, setDescription, setDescriptionContentType, setInfo, setInfoContentType
 
Methods inherited from interface com.guiseframework.model.LabelModel
getGlyphURI, getLabel, getLabelContentType, setGlyphURI, setLabel, setLabelContentType
 
Methods inherited from interface com.globalmentor.beans.PropertyBindable
addPropertyChangeListener, addPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, hasPropertyChangeListeners, removePropertyChangeListener, removePropertyChangeListener
 
Methods inherited from interface com.globalmentor.beans.PropertyConstrainable
addVetoableChangeListener, addVetoableChangeListener, getVetoableChangeListeners, getVetoableChangeListeners, hasVetoableChangeListeners, removeVetoableChangeListener, removeVetoableChangeListener
 
Methods inherited from interface com.guiseframework.model.Enableable
isEnabled, setEnabled
 
Methods inherited from interface com.guiseframework.component.ValuedComponent
getValue, getValueClass, setValue
 
Methods inherited from interface com.guiseframework.model.ListSelectModel
addListListener, addListSelectionListener, addSelectedIndexes, getSelectedIndex, getSelectedIndexes, getSelectionPolicy, isIndexDisplayed, isIndexEnabled, isValueDisplayed, isValueEnabled, removeListListener, removeListSelectionListener, removeSelectedIndexes, setIndexDisplayed, setIndexEnabled, setSelectedIndexes, setValueDisplayed, setValueEnabled
 
Methods inherited from interface com.guiseframework.model.SelectModel
getSelectedValue, getSelectedValues, replace, setSelectedValues
 
Methods inherited from interface com.guiseframework.model.ValueModel
clearValue, getDefaultValue, getValidator, getValue, getValueClass, isValidValue, resetValue, setValidator, setValue, validateValue
 
Methods inherited from interface java.util.List
add, add, addAll, addAll, clear, contains, containsAll, equals, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, size, subList, toArray, toArray
 

Field Detail

componentValueChangeListener

protected final com.globalmentor.beans.GenericPropertyChangeListener<java.lang.Boolean> componentValueChangeListener
The listener that detects changes to a child component's Boolean value and updates the control's selected values accordingly.


synchronizingValuesFlag

protected final java.util.concurrent.atomic.AtomicBoolean synchronizingValuesFlag
The atomic flag that allows us to know whether we're synchronizing values, either from the list to the child controls or vice versa.

Constructor Detail

BooleanValueControlSelectControl

public BooleanValueControlSelectControl(java.lang.Class<V> valueClass)
Value class constructor with a default data model to represent a given type with multiple selection and a FlowLayout with Flow.PAGE flow.

Parameters:
valueClass - The class indicating the type of value held in the model.
Throws:
java.lang.NullPointerException - if the given value class is null.

BooleanValueControlSelectControl

public BooleanValueControlSelectControl(java.lang.Class<V> valueClass,
                                        ListSelectControl.ValueRepresentationStrategy<V> valueRepresentationStrategy)
Value class and value representation strategy constructor with a default data model to represent a given type with multiple selection and a FlowLayout with Flow.PAGE flow.

Parameters:
valueClass - The class indicating the type of value held in the model.
valueRepresentationStrategy - The strategy to create label models to represent this model's values.
Throws:
java.lang.NullPointerException - if the given value class and/or value representation strategy is null.

BooleanValueControlSelectControl

public BooleanValueControlSelectControl(java.lang.Class<V> valueClass,
                                        ListSelectionPolicy<V> selectionStrategy)
Value class and selection strategy constructor with a default data model to represent a given type and a FlowLayout with Flow.PAGE flow.

Parameters:
valueClass - The class indicating the type of value held in the model.
selectionStrategy - The strategy for selecting values in the model.
Throws:
java.lang.NullPointerException - if the given value class and/or selection strategy is null.

BooleanValueControlSelectControl

public BooleanValueControlSelectControl(java.lang.Class<V> valueClass,
                                        ListSelectionPolicy<V> selectionStrategy,
                                        ListSelectControl.ValueRepresentationStrategy<V> valueRepresentationStrategy)
Value class, selection strategy, and value representation strategy constructor with a default data model to represent a given type and a FlowLayout with Flow.PAGE flow.

Parameters:
valueClass - The class indicating the type of value held in the model.
selectionStrategy - The strategy for selecting values in the model.
valueRepresentationStrategy - The strategy to create label models to represent this model's values.
Throws:
java.lang.NullPointerException - if the given value class, selection strategy, and/or value representation strategy is null.

BooleanValueControlSelectControl

public BooleanValueControlSelectControl(ListSelectModel<V> listSelectModel)
List select model constructor with a FlowLayout with Flow.PAGE flow.

Parameters:
listSelectModel - The component list select model.
Throws:
java.lang.NullPointerException - if the given list select model is null.

BooleanValueControlSelectControl

public BooleanValueControlSelectControl(ListSelectModel<V> listSelectModel,
                                        ListSelectControl.ValueRepresentationStrategy<V> valueRepresentationStrategy)
List select model and value representation strategy constructor with a FlowLayout with Flow.PAGE flow.

Parameters:
listSelectModel - The component list select model.
valueRepresentationStrategy - The strategy to create label models to represent this model's values.
Throws:
java.lang.NullPointerException - if the given list select model and/or value representation strategy is null.

BooleanValueControlSelectControl

public BooleanValueControlSelectControl(java.lang.Class<V> valueClass,
                                        Layout<?> layout)
Value class and layout constructor with a default data model to represent a given type with multiple selection.

Parameters:
valueClass - The class indicating the type of value held in the model.
layout - The layout definition for the component.
Throws:
java.lang.NullPointerException - if the given value class and/or layout is null.

BooleanValueControlSelectControl

public BooleanValueControlSelectControl(java.lang.Class<V> valueClass,
                                        Layout<?> layout,
                                        ListSelectControl.ValueRepresentationStrategy<V> valueRepresentationStrategy)
Value class, layout, and value representation strategy constructor with a default data model to represent a given type with multiple selection.

Parameters:
valueClass - The class indicating the type of value held in the model.
valueRepresentationStrategy - The strategy to create label models to represent this model's values.
layout - The layout definition for the component.
Throws:
java.lang.NullPointerException - if the given value class, layout, and/or value representation strategy is null.

BooleanValueControlSelectControl

public BooleanValueControlSelectControl(java.lang.Class<V> valueClass,
                                        ListSelectionPolicy<V> selectionStrategy,
                                        Layout<?> layout)
Value class, selection strategy, and layout constructor with a default data model to represent a given type.

Parameters:
valueClass - The class indicating the type of value held in the model.
selectionStrategy - The strategy for selecting values in the model.
layout - The layout definition for the component.
Throws:
java.lang.NullPointerException - if the given value class, selection strategy, and/or layout is null.

BooleanValueControlSelectControl

public BooleanValueControlSelectControl(java.lang.Class<V> valueClass,
                                        ListSelectionPolicy<V> selectionStrategy,
                                        Layout<?> layout,
                                        ListSelectControl.ValueRepresentationStrategy<V> valueRepresentationStrategy)
Value class, selection strategy, layout, and value representation strategy constructor with a default data model to represent a given type.

Parameters:
valueClass - The class indicating the type of value held in the model.
selectionStrategy - The strategy for selecting values in the model.
layout - The layout definition for the component.
valueRepresentationStrategy - The strategy to create label models to represent this model's values.
Throws:
java.lang.NullPointerException - if the given value class, selection strategy, layout, and/or value representation strategy is null.

BooleanValueControlSelectControl

public BooleanValueControlSelectControl(ListSelectModel<V> listSelectModel,
                                        Layout<?> layout)
List select model and layout constructor.

Parameters:
listSelectModel - The component list select model.
layout - The layout definition for the component.
Throws:
java.lang.NullPointerException - if the given list select model and/or layout is null.

BooleanValueControlSelectControl

public BooleanValueControlSelectControl(ListSelectModel<V> listSelectModel,
                                        Layout<?> layout,
                                        ListSelectControl.ValueRepresentationStrategy<V> valueRepresentationStrategy)
List select model, layout, and value representation strategy constructor.

Parameters:
listSelectModel - The component list select model.
layout - The layout definition for the component.
valueRepresentationStrategy - The strategy to create label models to represent this model's values.
Throws:
java.lang.NullPointerException - if the given list select model, layout, and/or value representation strategy is null.
Method Detail

getLayout

public Layout<? extends Constraints> getLayout()
Specified by:
getLayout in interface LayoutComponent
Returns:
The layout definition for the component.

setLayout

protected <T extends Constraints> void setLayout(Layout<T> newLayout)
Sets the layout definition for the component. This is a bound property. The layout is marked as not yet having a theme applied, as the specific theme rules applied to the layout may depend on the layout's owner.

Parameters:
newLayout - The new layout definition for the container.
Throws:
java.lang.NullPointerException - if the given layout is null.
See Also:
LayoutComponent.LAYOUT_PROPERTY, #setPropertiesInitialized(boolean)

isLayoutThemeApplied

public boolean isLayoutThemeApplied()
Specified by:
isLayoutThemeApplied in interface LayoutComponent
Returns:
Whether a theme has been applied to this component's layout.

setLayoutThemeApplied

public void setLayoutThemeApplied(boolean newLayoutThemeApplied)
Sets whether a theme has been applied to this component's layout. This is a bound property of type Boolean.

Specified by:
setLayoutThemeApplied in interface LayoutComponent
Parameters:
newLayoutThemeApplied - true if a theme has been applied to this component's layout, else false.
See Also:
LayoutComponent.LAYOUT_THEME_APPLIED_PROPERTY, AbstractComponent.setThemeApplied(boolean)

getChildComponents

public java.lang.Iterable<Component> getChildComponents()
Returns an iterable to child components. This version returns the children in the same order as the list values.

Specified by:
getChildComponents in interface CompositeComponent
Overrides:
getChildComponents in class AbstractMultipleCompositeComponent
Returns:
An iterable to child components.

getValuePolicyModelGroup

protected ValuePolicyModelGroup<java.lang.Boolean> getValuePolicyModelGroup()
Returns:
The value policy model group for boolean value models, or null if there is no value policy model group in use.

addComponent

protected void addComponent(Component childComponent)
Adds a component to the layout component with default constraints.

Overrides:
addComponent in class AbstractMultipleCompositeComponent
Parameters:
childComponent - The component to add.
Throws:
java.lang.IllegalArgumentException - if the component already has a parent or if the component is already a child of this composite component.
java.lang.IllegalStateException - if the installed layout does not support default constraints.

removeComponent

protected void removeComponent(Component childComponent)
Removes a component from the layout component.

Overrides:
removeComponent in class AbstractMultipleCompositeComponent
Parameters:
childComponent - The component to remove.
Throws:
java.lang.IllegalArgumentException - if the component does not recognize this composite component as its parent or the component is not a member of this composite component.

updateListSelectedValues

protected void updateListSelectedValues()
Updates the list selected values based upon the current values of the child controls.


updateChildControlValues

protected void updateChildControlValues()
Updates the values of child controls based upon the current state of the list selected values.


resetTheme

public void resetTheme()
Resets this object's theme. This method sets to false the state of whether a theme has been applied to this object. This method is called for any child components resetting its own theme. No new theme is actually loaded. There is normally no need to override this method or to call this method directly by applications. This version resets the theme of the given layout.

Specified by:
resetTheme in interface Component
Overrides:
resetTheme in class AbstractCompositeComponent
See Also:
AbstractComponent.setThemeApplied(boolean), setLayoutThemeApplied(boolean)

updateTheme

public void updateTheme()
                 throws java.io.IOException
Updates this object's theme. This method checks whether a theme has been applied to this object. If a theme has not been applied to this object this method calls applyTheme(). This method is called for any child components before applying the theme to the component itself, to assure that child theme updates have already occured before theme updates occur for this component. There is normally no need to override this method or to call this method directly by applications. This version checks to see if the theme needs to be applied to the given layout.

Specified by:
updateTheme in interface Component
Overrides:
updateTheme in class AbstractCompositeComponent
Throws:
java.io.IOException - if there was an error loading or applying a theme.
See Also:
AbstractComponent.isThemeApplied(), isLayoutThemeApplied(), applyTheme()

applyTheme

public void applyTheme()
                throws java.io.IOException
Applies the theme to this object. Themes are only applied of the application is themed. This method may be overridden to effectively override theme settings by ensuring the state of important properties after the theme has been set. If the theme is successfully applied, this method updates the theme applied status. This version applies the theme to the current layout and updates the layout theme applied status.

Specified by:
applyTheme in interface Component
Overrides:
applyTheme in class AbstractComponent
Throws:
java.io.IOException - if there was an error loading or applying a theme.
See Also:
GuiseApplication.isThemed(), AbstractComponent.getTheme(), applyTheme(Theme), AbstractComponent.setThemeApplied(boolean), setLayoutThemeApplied(boolean)

applyTheme

public void applyTheme(Theme theme)
Applies a theme and its parents to this object. The theme's rules will be applied to this object and any related objects. Theme application occurs unconditionally, regardless of whether themes have been applied to this component before. There is normally no need to call this method directly by applications. This version applies the theme to the current layout.

Specified by:
applyTheme in interface Component
Overrides:
applyTheme in class AbstractComponent
Parameters:
theme - The theme to apply to the object.


Copyright © 2005-2010 GlobalMentor, Inc. All Rights Reserved.