|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectat.spardat.xma.mdl.UIDelegateClient
at.spardat.xma.mdl.table.TableUIDelegateClient
This class manages the UI related aspects of a TableWMClient widget model
| Nested Class Summary | |
class |
TableUIDelegateClient.RowComparator
To compare two entries of the sortPermutation instance variable |
| Constructor Summary | |
TableUIDelegateClient(TableWMClient wModel)
Constructor |
|
| Method Summary | |
void |
attachUI(java.lang.Object control,
java.lang.Object label)
Requirements on the attached SWT table are: The number of visible columns in the model must match the number of columns of the SWT table. |
void |
detachUI()
Detaches the UI-control. |
java.lang.Object |
getUIControl()
This method returns the attached UI-control. |
java.lang.Object |
getUILabel()
Returns the label that has been provided via attachUI. |
WModel |
getWModel()
Returns the WidgetModel this UIDelegateClient is attached to. |
void |
handleModelChangeEvent(ModelChangeEvent event)
The widget model has been changed. |
void |
handleUIEvent(java.lang.Object event,
int type)
The attached Table must delegate its SelectionEvent to this method in order to keep track of the selection state of the table. |
boolean |
isEditable()
Returns true if this model's widget may be modified by the end-user. |
boolean |
isEnabled()
Returns true, if this model's widget is enabled. |
boolean |
isUIAttached()
Yields true, if this UIDelegateClient is attached, i.e., has a Control of the UI-library associated. |
void |
setEditable(boolean what)
Sets the editable-state of this models's widget. |
void |
setEnabled(boolean what)
Sets the enabled-state of this model's widget. |
void |
setErrorColor(boolean inError)
Not implemented - does nothing |
protected void |
sortNatural()
Resets the order to the natural order of the rows. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public TableUIDelegateClient(TableWMClient wModel)
wModel - the widget model this UI delegate belongs to| Method Detail |
public void handleUIEvent(java.lang.Object event,
int type)
handleUIEvent in class UIDelegateClientevent - the Event-object from a particular UI libraray, e.g., SWT.type - TODOUIDelegateClient.handleUIEvent(java.lang.Object, int)public void handleModelChangeEvent(ModelChangeEvent event)
UIDelegateClient
handleModelChangeEvent in class UIDelegateClientUIDelegateClient.handleModelChangeEvent(at.spardat.xma.mdl.ModelChangeEvent)public WModel getWModel()
UIDelegateClient
getWModel in class UIDelegateClientUIDelegateClient.getWModel()public boolean isUIAttached()
UIDelegateClient
isUIAttached in class UIDelegateClientUIDelegateClient.isUIAttached()
public void attachUI(java.lang.Object control,
java.lang.Object label)
throws AttachmentExceptionClient
attachUI in class UIDelegateClientcontrol - an object of the UI class library. For example, in the
case of SWT it is a SWT Widget like a Text, Label or Check Box.label - a widget of the UI class library which is the label for control.
With SWT, typically it the control is a Text field, the
label is a Label widget which usually is the widget
holding the describing text in front of the Text field. The label
is used in error messages. It may be null.
AttachmentExceptionClient - if the control cannot be attached.UIDelegateClient.attachUI(java.lang.Object, java.lang.Object)public java.lang.Object getUIControl()
UIDelegateClient
getUIControl in class UIDelegateClientUIDelegateClient.getUIControl()public java.lang.Object getUILabel()
UIDelegateClient
getUILabel in class UIDelegateClientUIDelegateClient.getUILabel()public void detachUI()
UIDelegateClient
detachUI in class UIDelegateClientUIDelegateClient.detachUI()protected void sortNatural()
public boolean isEnabled()
UIDelegateClient
isEnabled in class UIDelegateClientUIDelegateClient.isEnabled()public void setEnabled(boolean what)
UIDelegateClient
setEnabled in class UIDelegateClientwhat - the state to set.UIDelegateClient.setEnabled(boolean)public boolean isEditable()
UIDelegateClient
isEditable in class UIDelegateClientUIDelegateClient.isEditable()public void setEditable(boolean what)
UIDelegateClientUsually, this method is called on all widget-models of a page to set the whole page to a read-only mode.
If this method is not called, the default is true.
setEditable in class UIDelegateClientwhat - true if the model's widget should be editable, false otherwise.UIDelegateClient.setEditable(boolean)public void setErrorColor(boolean inError)
setErrorColor in class UIDelegateClient
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||