|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object cdx.scorebot.util.swing.binding.delegate.GenericDelegate<TYPE,TYPE> cdx.scorebot.util.swing.binding.delegate.IntermediateFieldDelegate<TYPE>
public class IntermediateFieldDelegate<TYPE>
A delegate for an intermediate field of type TYPE.
Field Summary | |
---|---|
protected java.util.Vector<BoundComponent> |
components
components whose bindings are contained within the objects contained in this list |
protected int |
primaryComponentIndex
the index of the subcomponent which determines the names of the entries in the list (-1 [default] => number them instead) |
Constructor Summary | |
---|---|
IntermediateFieldDelegate(BoundComponent owner,
IntermediateField compon)
Instantiates an unbound ButtonGroup Delegate |
|
IntermediateFieldDelegate(BoundComponent owner,
IntermediateField compon,
java.lang.Object boundItem,
java.lang.String varName)
Instantiates a bound ButtonGroup Delegate |
|
IntermediateFieldDelegate(BoundComponent owner,
IntermediateField compon,
java.lang.Object boundItem,
java.lang.String getterName,
java.lang.String setterName)
Instantiates a bound ButtonGroup Delegate |
|
IntermediateFieldDelegate(BoundComponent owner,
IntermediateField compon,
java.lang.String varName)
Instantiates an unbound ButtonGroup Delegate |
Method Summary | |
---|---|
void |
addBoundComponent(BoundComponent b)
add bound component to this (b's parent will be set to this) |
protected void |
completeInit()
does nothing |
java.util.Vector<BoundComponent> |
getBoundComponents()
get bound components this contains |
int |
getPrimaryComponent()
gets the index of the component which whose string value is used as the value to represent that collection, or -1 to just number the sets |
protected void |
handleValidationState()
draw the border to reflect the specified validation state |
void |
load()
refreshes subcomponents bindings |
void |
notifyBoundComponentChange(BoundComponent c)
informs its parent |
void |
save()
tells all subcomponents to save their current value |
void |
selectItem(int index)
does nothing |
void |
setPrimaryComponent(int primComponIndex)
sets the index of the component which whose string value is used as the value to represent that collection, or -1 to just number the sets |
java.lang.String |
toString()
|
void |
updateSubcomponentBindings()
update all components within this component |
Methods inherited from class cdx.scorebot.util.swing.binding.delegate.GenericDelegate |
---|
addBindingListener, changeBinding, changeBinding, changeBinding, changeBinding, changeBinding, changeBinding, changeBinding, getBinding, getBoundParent, getFormattedValidationErrorMsg, getMe, getOwner, getValidationErrorMsg, highlightOnError, isContainer, isValidated, notifyListenersOfBindingChanged, notifyListenersOfBindingChanging, notifyListenersOfBindingLoaded, removeBindingListener, setBoundParent, setHighlightOnError, setValidationError, setValidationError, validationError |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface cdx.scorebot.util.swing.binding.delegate.BoundDelegateComponent |
---|
addBindingListener, changeBinding, changeBinding, changeBinding, changeBinding, changeBinding, changeBinding, changeBinding, getBinding, getBoundParent, highlightOnError, isContainer, isValidated, notifyListenersOfBindingChanged, notifyListenersOfBindingChanging, removeBindingListener, setBoundParent, setHighlightOnError |
Field Detail |
---|
protected java.util.Vector<BoundComponent> components
protected int primaryComponentIndex
Constructor Detail |
---|
public IntermediateFieldDelegate(BoundComponent owner, IntermediateField compon)
owner
- the BoundComponent which this belongs tocompon
- the component that this works forpublic IntermediateFieldDelegate(BoundComponent owner, IntermediateField compon, java.lang.String varName)
owner
- the BoundComponent which this belongs tocompon
- the component that this works forvarName
- the name of the variable; assumes the getter and setter name will
be get and set followed by varName with its first letter capitalized
(ex: if varName is "value" then the getter will be getValue).public IntermediateFieldDelegate(BoundComponent owner, IntermediateField compon, java.lang.Object boundItem, java.lang.String varName)
owner
- the BoundComponent which this belongs tocompon
- the component that this works forboundItem
- the object this is bound to (contains the value to be modified as specified by varName)varName
- the name of the variable; assumes the getter and setter name will
be get and set followed by varName with its first letter capitalized
(ex: if varName is "value" then the getter will be getValue).public IntermediateFieldDelegate(BoundComponent owner, IntermediateField compon, java.lang.Object boundItem, java.lang.String getterName, java.lang.String setterName)
owner
- the BoundComponent which this belongs tocompon
- the component that this works forboundItem
- the object this is bound to (contains the value to be modified as specified by the getter and setter name)getterName
- how to get the bound value from the bound objectsetterName
- how to set the bound value from the bound objectMethod Detail |
---|
protected void completeInit()
completeInit
in class GenericDelegate<TYPE,TYPE>
public void load()
load
in interface BoundDelegateComponent
load
in class GenericDelegate<TYPE,TYPE>
public void save()
save
in interface BoundDelegateComponent
save
in class GenericDelegate<TYPE,TYPE>
protected void handleValidationState()
handleValidationState
in class GenericDelegate<TYPE,TYPE>
public final void addBoundComponent(BoundComponent b)
addBoundComponent
in interface BoundDelegateContainer
public final java.util.Vector<BoundComponent> getBoundComponents()
getBoundComponents
in interface BoundDelegateContainer
public final void updateSubcomponentBindings()
updateSubcomponentBindings
in interface BoundDelegateContainer
public void notifyBoundComponentChange(BoundComponent c)
notifyBoundComponentChange
in interface BoundDelegateContainer
public void selectItem(int index)
selectItem
in interface BoundDelegateContainer
public java.lang.String toString()
toString
in class java.lang.Object
public final int getPrimaryComponent()
getPrimaryComponent
in interface BoundDelegateContainer
public final void setPrimaryComponent(int primComponIndex)
setPrimaryComponent
in interface BoundDelegateContainer
primComponIndex
- index of the BoundComponent which is the primary component in the
getBoundComponents() vector.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |