hibergui.assoc
Class AssociationEdit<T,C>
java.lang.Object
hibergui.Component<T>
hibergui.Edit<C>
hibergui.assoc.AssociationEdit<T,C>
- Type Parameters:
T - Association "To".C - Collection or map type. (T, Set or List.)
- Direct Known Subclasses:
- M2MEdit, M2OEdit, O2MEdit
public abstract class AssociationEdit<T,C>
- extends Edit<C>
- Author:
- espakm
|
Constructor Summary |
AssociationEdit(Form<?> form,
org.eclipse.swt.widgets.Composite cptParent,
int style,
java.lang.String prop,
java.lang.String name)
|
| Methods inherited from class hibergui.Edit |
addConstraint, addConstraint, addModificationListener, addTraverseListener, fill, fireKeyPressed, fireKeyReleased, fireTraversal, fix, get, getDefault, getName, getPropertyName, hasDefault, isDirty, isEditable, isFixed, isValid, markClean, markDirty, markInvalid, markValid, removeConstraint, removeConstraint, removeModificationListener, removeTraverseListener, resetBackground, set, setDefault, setDefault, setDefault, verify |
| Methods inherited from class hibergui.Component |
addChangeListener, addControlListener, addFocusListener, addKeyListener, createContents, dispose, fireChange, getControl, init, removeChangeListener, removeControlListener, removeFocusListener, removeKeyListener, setLayoutData |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
dlgAssoc
protected FormDialog<T> dlgAssoc
btnAssoc
protected org.eclipse.swt.widgets.Button btnAssoc
AssociationEdit
public AssociationEdit(Form<?> form,
org.eclipse.swt.widgets.Composite cptParent,
int style,
java.lang.String prop,
java.lang.String name)
extract
public C extract()
- Description copied from class:
Edit
- Extracts the value from the controls of the edit.
- Specified by:
extract in class Edit<C>
- Returns:
- the extracted value
refresh
public void refresh()
createAssocDialogButton
protected org.eclipse.swt.widgets.Button createAssocDialogButton(org.eclipse.swt.widgets.Composite cptParent)
setSelection
protected abstract void setSelection(T[] value)
createAssocDialog
protected final FormDialog<T> createAssocDialog(org.eclipse.swt.widgets.Shell shell)
- The implementation should look like the following code where the
SomeForm class extends Form.
FormDialog dlg= new FormDialog(cptParent.getShell()) {
protected Form createForm(Composite cptParent) {
SomeForm f = return new SomeForm(cptParent, Form.NONE);
f.setFixedField(get());
return f;
}
};
createForm
protected abstract Form<T> createForm(org.eclipse.swt.widgets.Composite cpt)
clear
public void clear()
- Description copied from class:
Edit
- Clears the controls of the edit.
- Specified by:
clear in class Edit<C>
setBackground
public void setBackground(org.eclipse.swt.graphics.Color clr)
- Specified by:
setBackground in class Edit<C>
setFocus
public boolean setFocus()
- Specified by:
setFocus in class Component<C>
isEnabled
public boolean isEnabled()
- Specified by:
isEnabled in class Edit<C>
setEnabled
public void setEnabled(boolean b)
- Specified by:
setEnabled in class Edit<C>
setEditable
public void setEditable(boolean b)
- Specified by:
setEditable in class Edit<C>