|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.rad.genui.UIResource<C>
javax.rad.genui.UIComponent<C>
javax.rad.genui.control.AbstractControllable<ITree>
javax.rad.genui.control.UITree
public class UITree
Platform and technology independent Tree. It is designed for use with AWT, Swing, SWT, JSP, JSF, ... .
Field Summary |
---|
Fields inherited from class javax.rad.genui.UIComponent |
---|
bTranslate, lLastTranslationModified, parent, popupMenu |
Fields inherited from class javax.rad.genui.UIResource |
---|
uiResource |
Fields inherited from interface javax.rad.model.ui.IControllable |
---|
COMMAND_DELETE, COMMAND_DUPLICATE, COMMAND_EDIT, COMMAND_EXPORT, COMMAND_FIRST, COMMAND_INSERT, COMMAND_INSERT_SUB, COMMAND_LAST, COMMAND_NEXT, COMMAND_PREVIOUS, COMMAND_RESTORE, COMMAND_SEARCH |
Constructor Summary | |
---|---|
|
UITree()
Creates a new instance of UITree . |
|
UITree(IDataBook... pDataBooks)
Creates a new instance of UITree . |
protected |
UITree(ITree pTree)
Creates a new instance of UITree with the given
tree. |
Method Summary | |
---|---|
void |
cancelEditing()
Informs the GUI control, that the last edit should be canceled(restored) the correct value is in the DataBook . |
protected java.lang.String |
createComponentName()
Creates a name for this UIComponent . |
IDataBook |
getActiveDataBook()
Gets the active data book. |
ICellFormatter |
getCellFormatter()
Gets the ICellFormatter . |
IDataBook[] |
getDataBooks()
Returns the DataBooks displayed by this control. |
INodeFormatter |
getNodeFormatter()
Gets the node formatter. |
boolean |
isDetectEndNode()
Gets if a node should be detected to be an end node or not. |
boolean |
isEditable()
Gets if editable or not. |
boolean |
isMouseEventOnSelectedCell()
True, if the mouse event occured on current selected cell. |
void |
notifyRepaint()
The control need to check if the part is visible and then repaint the part. |
void |
saveEditing()
Informs the GUI control, that the last edit should be set into the IDataBook or IDataRow . |
void |
setCellFormatter(ICellFormatter pCellFormatter)
Sets the ICellFormatter . |
void |
setCellFormatter(java.lang.Object pCellFormatter,
java.lang.String pMethodName)
Sets the cell formatter. |
void |
setDataBooks(IDataBook... pDataBooks)
Sets the DataBooks displayed by this control. |
void |
setDetectEndNode(boolean pDetectEndNode)
Sets if a node should be detected to be an end node or not. |
void |
setEditable(boolean pEditable)
Sets if editable or not. |
void |
setNodeFormatter(INodeFormatter pNodeFormatter)
Sets the node formatter. |
void |
setNodeFormatter(java.lang.Object pNodeFormatter,
java.lang.String pMethodName)
Sets the node formatter. |
void |
startEditing()
Informs the GUI control, that the editor should be opened. |
void |
updateTranslation()
Notification for updating the translation. |
Methods inherited from class javax.rad.genui.control.AbstractControllable |
---|
addNotify, createCellFormatter, createNodeFormatter, doCommand, doDelete, doDuplicate, doEdit, doExport, doFirst, doInsert, doInsertSub, doLast, doNext, doNotifyController, doPrevious, doRestore, doSearch, getController, isCommandEnabled, isDeleteEnabled, isDuplicateEnabled, isEditEnabled, isExportEnabled, isFirstEnabled, isInsertEnabled, isInsertSubEnabled, isLastEnabled, isNextEnabled, isPreviousEnabled, isRestoreEnabled, isSearchEnabled, removeNotify, setController |
Methods inherited from class javax.rad.genui.UIResource |
---|
eventResourceChanged, eventResourceChanged, fireResourceChanged, getObject, getObjectNames, getUIResource, hasResourceHandler, putObject, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface javax.rad.ui.IResource |
---|
getResource |
Methods inherited from interface javax.rad.model.ui.ITranslatable |
---|
getTranslation, isTranslationEnabled, setTranslation, setTranslationEnabled |
Methods inherited from interface javax.rad.util.ITranslator |
---|
translate |
Constructor Detail |
---|
public UITree()
UITree
.
ITree
protected UITree(ITree pTree)
UITree
with the given
tree.
pTree
- the treeITree
public UITree(IDataBook... pDataBooks)
UITree
.
pDataBooks
- the data books
.setDataBooks(IDataBook...)
Method Detail |
---|
public IDataBook[] getDataBooks()
getDataBooks
in interface ITreeControl
ITreeControl.setDataBooks(javax.rad.model.IDataBook...)
public void setDataBooks(IDataBook... pDataBooks)
setDataBooks
in interface ITreeControl
pDataBooks
- the DataBooksITreeControl.getDataBooks()
public IDataBook getActiveDataBook()
getActiveDataBook
in interface IControllable
getActiveDataBook
in interface ITreeControl
public boolean isDetectEndNode()
isDetectEndNode
in interface ITree
public void setDetectEndNode(boolean pDetectEndNode)
setDetectEndNode
in interface ITree
pDetectEndNode
- true, if end node detection is enabled.public boolean isEditable()
isEditable
in interface ITree
public void setEditable(boolean pEditable)
setEditable
in interface ITree
pEditable
- if editable or not.public void notifyRepaint()
notifyRepaint
in interface IControl
public void startEditing()
startEditing
in interface ITreeControl
public void saveEditing() throws ModelException
IDataBook
or IDataRow
.
saveEditing
in interface IControl
ModelException
- if the value can not be stored.public void cancelEditing()
DataBook
.
cancelEditing
in interface IControl
public ICellFormatter getCellFormatter()
ICellFormatter
.
The ICellFormatter
will be called for every cell and can return a
style for that cell.
getCellFormatter
in interface ICellFormatable
ICellFormatter
.ICellFormatable.setCellFormatter(ICellFormatter)
public void setCellFormatter(ICellFormatter pCellFormatter)
ICellFormatter
.
The ICellFormatter
will be called for every cell and can return a
style for that cell.
setCellFormatter
in interface ICellFormatable
pCellFormatter
- the ICellFormatter
.ICellFormatable.getCellFormatter()
public void setCellFormatter(java.lang.Object pCellFormatter, java.lang.String pMethodName)
pCellFormatter
- the cell formatter.pMethodName
- the method name.public INodeFormatter getNodeFormatter()
getNodeFormatter
in interface ITree
public void setNodeFormatter(INodeFormatter pNodeFormatter)
setNodeFormatter
in interface ITree
pNodeFormatter
- the node formatter.public void setNodeFormatter(java.lang.Object pNodeFormatter, java.lang.String pMethodName)
pNodeFormatter
- the node formatter.pMethodName
- the method name.public boolean isMouseEventOnSelectedCell()
isMouseEventOnSelectedCell
in interface ITree
public void updateTranslation()
UIComponent
will be added to a displayable containment hierarchy,
when its containment hierarchy is made displayable or the translation table will
be changed.
updateTranslation
in class UIComponent<ITree>
UIComponent.setTranslation(TranslationMap)
,
UIComponent.addNotify()
protected java.lang.String createComponentName()
UIComponent
.
The returned name needs to be unique in the current root/workscreen and
is ideally, but not necessarily, prefixed with the UIComponent.sRootName
,
if there is any.
Overriding classes should be aware that this method will be called in
UIComponent.addNotify()
and the returned name will only be assigned to the
UIComponent
if there isn't already a name set. Also
UIComponent.stExistingNames
can be used to find out if a name has already
been assigned, and UIComponent.sRootName
to get the root name.
In rare cases UIComponent.stExistingNames
and/or UIComponent.sRootName
might
be null
when this method is called.
createComponentName
in class UIComponent<ITree>
UIComponent
.UIComponent.getExistingNames()
,
UIComponent.getRootName()
,
UIComponent.incrementNameIfExists(String, Set, boolean)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |