|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent javax.swing.JTree com.alee.laf.tree.WebTree<E> com.alee.extended.tree.WebAsyncTree<E>
E
- tree nodes typepublic class WebAsyncTree<E extends AsyncUniqueNode>
This class provides a custom tree with asynchronous childs loading. All you need is to provide a custom AsyncTreeDataProvider for the new WebAsyncTree instance.
WebTree
,
AsyncTreeModel
,
AsyncTreeDataProvider
,
AsyncTreeListener
,
WebAsyncTreeCellRenderer
,
Serialized FormNested Class Summary |
---|
Nested classes/interfaces inherited from class javax.swing.JTree |
---|
javax.swing.JTree.AccessibleJTree, javax.swing.JTree.DropLocation, javax.swing.JTree.DynamicUtilTreeNode, javax.swing.JTree.EmptySelectionModel, javax.swing.JTree.TreeModelHandler, javax.swing.JTree.TreeSelectionRedirector |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
javax.swing.JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
java.awt.Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
Field Summary | |
---|---|
protected boolean |
asyncLoading
Whether to load childs asynchronously or not. |
protected java.util.List<AsyncTreeListener> |
asyncTreeListeners
Asynchronous tree listeners. |
protected CellEditorAdapter |
cellEditorAdapter
Special cell editor listener. |
protected java.util.Comparator<E> |
comparator
Tree nodes comparator. |
protected Filter<E> |
filter
Tree nodes filter. |
protected java.lang.Object |
listenersLock
Asynchronous tree listeners lock object. |
protected static java.lang.Object |
lock
General lock. |
protected java.lang.Object |
syncLoadingLock
Sync loading methods and option lock. |
Fields inherited from class com.alee.laf.tree.WebTree |
---|
cellEditorListeners, CONTIGUOUS_TREE_SELECTION, DISCONTIGUOUS_TREE_SELECTION, scrollToSelectionListener, SINGLE_TREE_SELECTION |
Fields inherited from class javax.swing.JTree |
---|
ANCHOR_SELECTION_PATH_PROPERTY, CELL_EDITOR_PROPERTY, CELL_RENDERER_PROPERTY, cellEditor, cellRenderer, editable, EDITABLE_PROPERTY, EXPANDS_SELECTED_PATHS_PROPERTY, INVOKES_STOP_CELL_EDITING_PROPERTY, invokesStopCellEditing, LARGE_MODEL_PROPERTY, largeModel, LEAD_SELECTION_PATH_PROPERTY, ROOT_VISIBLE_PROPERTY, rootVisible, ROW_HEIGHT_PROPERTY, rowHeight, SCROLLS_ON_EXPAND_PROPERTY, scrollsOnExpand, SELECTION_MODEL_PROPERTY, selectionModel, selectionRedirector, SHOWS_ROOT_HANDLES_PROPERTY, showsRootHandles, TOGGLE_CLICK_COUNT_PROPERTY, toggleClickCount, TREE_MODEL_PROPERTY, treeModel, treeModelListener, VISIBLE_ROW_COUNT_PROPERTY, visibleRowCount |
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
WebAsyncTree()
Constructs sample asynchronous tree. |
|
WebAsyncTree(AsyncTreeDataProvider dataProvider)
Costructs asynchronous tree using data from the custom data provider. |
|
WebAsyncTree(AsyncTreeModel newModel)
Costructs asynchronous tree using the specified tree model. |
Method Summary | |
---|---|
void |
addAsyncTreeListener(AsyncTreeListener listener)
Adds new asynchronous tree listener. |
void |
addChildNode(E parent,
E child)
Adds child node for the specified node. |
void |
addChildNodes(E parent,
java.util.List<E> children)
Adds child nodes for the specified node. |
boolean |
areChildsLoaded(E parent)
Returns whether childs for the specified node are already loaded or not. |
void |
childsLoadCompleted(E parent,
java.util.List<E> childs)
Invoked when childs load operation finishes. |
void |
childsLoadFailed(E parent,
java.lang.Throwable cause)
Invoked when childs load operation fails. |
void |
childsLoadStarted(E parent)
Invoked when childs load operation starts. |
void |
clearComparator()
Removes any applied tree nodes comparator. |
void |
clearFilter()
Removes any applied tree nodes filter. |
void |
expandAll()
Expands all visible tree rows in a single call. |
void |
expandNode(java.lang.String nodeId)
Expands node with the specified ID. |
void |
expandPath(java.util.List<java.lang.String> pathNodeIds)
Expands path using the specified node path IDs. |
void |
expandPath(java.util.List<java.lang.String> pathNodeIds,
AsyncPathExpansionListener listener)
Expands path using the specified node path IDs. |
void |
expandPath(java.util.List<java.lang.String> pathNodeIds,
boolean expandLastNode)
Expands path using the specified node path IDs. |
void |
expandPath(java.util.List<java.lang.String> pathNodeIds,
boolean expandLastNode,
AsyncPathExpansionListener listener)
Expands path using the specified node path IDs. |
void |
expandPath(java.util.List<java.lang.String> pathNodeIds,
boolean expandLastNode,
boolean selectLastNode)
Expands path using the specified node path IDs. |
void |
expandPath(java.util.List<java.lang.String> pathNodeIds,
boolean expandLastNode,
boolean selectLastNode,
AsyncPathExpansionListener listener)
Expands path using the specified node path IDs. |
protected void |
expandPathEndImpl(E lastFoundNode,
boolean expandLastNode,
boolean selectLastNode)
Finishes async tree path expansion. |
protected void |
expandPathImpl(E currentNode,
java.util.List<java.lang.String> leftToExpand,
boolean expandLastNode,
boolean selectLastNode,
AsyncPathExpansionListener listener)
Performs a single path node expansion. |
E |
findNode(java.lang.String nodeId)
Looks for the node with the specified ID in the tree model and returns it or null if it was not found. |
protected void |
fireChildsLoadCompleted(E parent,
java.util.List<E> childs)
Fires childs load complete event. |
protected void |
fireChildsLoadFailed(E parent,
java.lang.Throwable cause)
Fires childs load complete event. |
protected void |
fireChildsLoadStarted(E parent)
Fires childs load start event. |
AsyncTreeModel<E> |
getAsyncModel()
Returns asynchronous tree model. |
java.util.List<AsyncTreeListener> |
getAsyncTreeListeners()
Returns all available asynchronous tree listeners list. |
java.util.Comparator<E> |
getComparator()
Returns tree nodes comparator. |
AsyncTreeDataProvider<E> |
getDataProvider()
Returns asynchronous tree data provider. |
Filter<E> |
getFilter()
Returns tree nodes filter. |
void |
insertChildNodes(E[] children,
E parent,
int index)
Inserts an array of child nodes into parent node. |
void |
insertChildNodes(java.util.List<E> children,
E parent,
int index)
Inserts a list of child nodes into parent node. |
boolean |
isAsyncLoading()
Returns whether childs are loaded asynchronously or not. |
boolean |
isAsyncModel()
Returns whether asynchronous tree model is installed or not. |
protected void |
performFullAsyncPathExpand(javax.swing.tree.TreePath path)
Expands path asynchronously. |
protected void |
performFullPathExpand(javax.swing.tree.TreePath path)
Expands path right away (if node childs were loaded atleast once before or not) or asynchronously. |
protected void |
performFullSyncPathExpand(javax.swing.tree.TreePath path)
Expands path right away. |
protected void |
performReload(E node,
javax.swing.tree.TreePath path,
boolean select)
Performs the actual reload call. |
E |
reloadNode(E node)
Reloads specified node childs. |
E |
reloadNode(E node,
boolean select)
Reloads specified node childs and selects it if requested. |
E |
reloadNode(java.lang.String nodeId)
Reloads node with the specified ID. |
E |
reloadNodeSync(E node)
Reloads specified node childs. |
E |
reloadNodeSync(E node,
boolean select)
Reloads specified node childs and selects it if requested. |
E |
reloadNodeSync(java.lang.String nodeId)
Reloads node with the specified ID. |
E |
reloadNodeUnderPoint(int x,
int y)
Reloads node under the specified point. |
E |
reloadNodeUnderPoint(java.awt.Point point)
Reloads node under the specified point. |
E |
reloadPath(javax.swing.tree.TreePath path)
Reloads node childs at the specified path. |
E |
reloadPath(javax.swing.tree.TreePath path,
boolean select)
Reloads node childs at the specified path and selects it if needed. |
E |
reloadPathSync(javax.swing.tree.TreePath path)
Reloads node childs at the specified path. |
E |
reloadPathSync(javax.swing.tree.TreePath path,
boolean select)
Reloads node childs at the specified path and selects it if needed. |
E |
reloadRootNode()
Reloads root node childs. |
void |
reloadSelectedNodes()
Reloads selected node childs. |
void |
reloadSelectedNodesSync()
Reloads selected node childs. |
void |
removeAsyncTreeListener(AsyncTreeListener listener)
Removes asynchronous tree listener. |
boolean |
removeNode(E node)
Removes node from tree structure. |
boolean |
removeNode(java.lang.String nodeId)
Removes node with the specified ID from tree structure. |
void |
removeNodes(E[] nodes)
Removes nodes from tree structure. |
void |
removeNodes(java.util.List<E> nodes)
Removes nodes from tree structure. |
void |
setAsyncLoading(boolean asyncLoading)
Sets whether to load childs asynchronously or not. |
void |
setCellEditor(javax.swing.tree.TreeCellEditor cellEditor)
Sets the cell editor for this tree. |
void |
setChildNodes(E parent,
java.util.List<E> children)
Sets child nodes for the specified node. |
void |
setComparator(java.util.Comparator<E> comparator)
Sets tree nodes comparator. |
void |
setDataProvider(AsyncTreeDataProvider dataProvider)
Changes data provider for this asynchronous tree. |
void |
setFilter(Filter<E> filter)
Sets tree nodes filter. |
void |
setMaximumThreadsAmount(int amount)
Sets maximum threads amount for this asynchronous tree. |
void |
setModel(javax.swing.tree.TreeModel newModel)
Sets the TreeModel that will provide the data. |
void |
updateNode(E node)
Forces tree node to be updated. |
void |
updateNode(java.lang.String nodeId)
Forces tree node with the specified ID to be updated. |
void |
updateNodeStructure(E node)
Forces tree node structure with the specified ID to be updated. |
void |
updateNodeStructure(java.lang.String nodeId)
Forces tree node structure with the specified ID to be updated. |
void |
updateSortingAndFiltering()
Updates nodes sorting and filtering for all loaded nodes. |
void |
updateSortingAndFiltering(E node)
Updates sorting and filtering for the specified node childs. |
Methods inherited from class javax.swing.JTree |
---|
addSelectionInterval, addSelectionPath, addSelectionPaths, addSelectionRow, addSelectionRows, addTreeExpansionListener, addTreeSelectionListener, addTreeWillExpandListener, cancelEditing, clearSelection, clearToggledPaths, collapsePath, collapseRow, convertValueToText, createTreeModelListener, expandPath, expandRow, fireTreeCollapsed, fireTreeExpanded, fireTreeWillCollapse, fireTreeWillExpand, fireValueChanged, getAccessibleContext, getAnchorSelectionPath, getCellEditor, getCellRenderer, getClosestPathForLocation, getClosestRowForLocation, getDescendantToggledPaths, getDragEnabled, getDropLocation, getDropMode, getEditingPath, getExpandedDescendants, getExpandsSelectedPaths, getInvokesStopCellEditing, getLastSelectedPathComponent, getLeadSelectionPath, getLeadSelectionRow, getMaxSelectionRow, getMinSelectionRow, getModel, getNextMatch, getPathBetweenRows, getPathBounds, getPathForLocation, getPathForRow, getPreferredScrollableViewportSize, getRowBounds, getRowCount, getRowForLocation, getRowForPath, getRowHeight, getScrollableBlockIncrement, getScrollableTracksViewportHeight, getScrollableTracksViewportWidth, getScrollableUnitIncrement, getScrollsOnExpand, getSelectionCount, getSelectionModel, getSelectionPath, getSelectionPaths, getSelectionRows, getShowsRootHandles, getToggleClickCount, getToolTipText, getTreeExpansionListeners, getTreeSelectionListeners, getTreeWillExpandListeners, getUI, getUIClassID, getVisibleRowCount, hasBeenExpanded, isCollapsed, isCollapsed, isEditable, isEditing, isExpanded, isExpanded, isFixedRowHeight, isLargeModel, isPathEditable, isPathSelected, isRootVisible, isRowSelected, isSelectionEmpty, isVisible, makeVisible, paramString, removeDescendantSelectedPaths, removeDescendantToggledPaths, removeSelectionInterval, removeSelectionPath, removeSelectionPaths, removeSelectionRow, removeSelectionRows, removeTreeExpansionListener, removeTreeSelectionListener, removeTreeWillExpandListener, scrollPathToVisible, scrollRowToVisible, setAnchorSelectionPath, setCellRenderer, setDragEnabled, setDropMode, setEditable, setExpandedState, setExpandsSelectedPaths, setInvokesStopCellEditing, setLargeModel, setLeadSelectionPath, setRootVisible, setRowHeight, setScrollsOnExpand, setSelectionInterval, setSelectionModel, setSelectionPath, setSelectionPaths, setSelectionRow, setSelectionRows, setShowsRootHandles, setToggleClickCount, setUI, setVisibleRowCount, startEditingAtPath, stopEditing, treeDidChange |
Methods inherited from class javax.swing.JComponent |
---|
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update |
Methods inherited from class java.awt.Container |
---|
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree |
Methods inherited from class java.awt.Component |
---|
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected static final java.lang.Object lock
protected final java.lang.Object listenersLock
protected java.util.List<AsyncTreeListener> asyncTreeListeners
protected final java.lang.Object syncLoadingLock
protected boolean asyncLoading
protected java.util.Comparator<E extends AsyncUniqueNode> comparator
protected Filter<E extends AsyncUniqueNode> filter
protected CellEditorAdapter cellEditorAdapter
Constructor Detail |
---|
public WebAsyncTree()
public WebAsyncTree(AsyncTreeDataProvider dataProvider)
dataProvider
- custom data providerpublic WebAsyncTree(AsyncTreeModel newModel)
newModel
- custom tree modelMethod Detail |
---|
public boolean isAsyncLoading()
public void setAsyncLoading(boolean asyncLoading)
asyncLoading
- whether to load childs asynchronously or notpublic AsyncTreeDataProvider<E> getDataProvider()
public void setDataProvider(AsyncTreeDataProvider dataProvider)
dataProvider
- new data providerpublic java.util.Comparator<E> getComparator()
public void setComparator(java.util.Comparator<E> comparator)
comparator
- tree nodes comparatorpublic void clearComparator()
public Filter<E> getFilter()
public void setFilter(Filter<E> filter)
filter
- tree nodes filterpublic void clearFilter()
public void updateSortingAndFiltering()
public void updateSortingAndFiltering(E node)
public void setModel(javax.swing.tree.TreeModel newModel)
setModel
in class javax.swing.JTree
newModel
- the TreeModel that is to provide the datapublic void setCellEditor(javax.swing.tree.TreeCellEditor cellEditor)
setCellEditor
in class WebTree<E extends AsyncUniqueNode>
cellEditor
- cell editorpublic AsyncTreeModel<E> getAsyncModel()
public boolean isAsyncModel()
public void setMaximumThreadsAmount(int amount)
amount
- new maximum threads amountpublic void setChildNodes(E parent, java.util.List<E> children)
parent
- node to processchildren
- new node childrenpublic void addChildNode(E parent, E child)
parent
- node to processchild
- new node childpublic void addChildNodes(E parent, java.util.List<E> children)
parent
- node to processchildren
- new node childrenpublic void insertChildNodes(java.util.List<E> children, E parent, int index)
children
- list of new child nodesparent
- parent nodeindex
- insert indexpublic void insertChildNodes(E[] children, E parent, int index)
children
- array of new child nodesparent
- parent nodeindex
- insert indexpublic boolean removeNode(java.lang.String nodeId)
nodeId
- ID of the node to remove
public boolean removeNode(E node)
node
- node to remove
public void removeNodes(java.util.List<E> nodes)
nodes
- list of nodes to removepublic void removeNodes(E[] nodes)
nodes
- array of nodes to removepublic boolean areChildsLoaded(E parent)
parent
- node to process
public E findNode(java.lang.String nodeId)
nodeId
- node ID
public void updateNode(java.lang.String nodeId)
nodeId
- ID of the tree node to be updatedpublic void updateNode(E node)
node
- tree node to be updatedpublic void updateNodeStructure(java.lang.String nodeId)
nodeId
- ID of the tree node to be updatedpublic void updateNodeStructure(E node)
node
- tree node to be updatedpublic void reloadSelectedNodesSync()
public void reloadSelectedNodes()
public E reloadNodeUnderPoint(java.awt.Point point)
point
- point to look for node
public E reloadNodeUnderPoint(int x, int y)
x
- point X coordinatey
- point Y coordinate
public E reloadNodeSync(java.lang.String nodeId)
nodeId
- ID of the node to reload
public E reloadNodeSync(E node)
node
- node to reload
public E reloadNodeSync(E node, boolean select)
node
- node to reloadselect
- whether select the node or not
public E reloadRootNode()
public E reloadNode(java.lang.String nodeId)
nodeId
- ID of the node to reload
public E reloadNode(E node)
node
- node to reload
public E reloadNode(E node, boolean select)
node
- node to reloadselect
- whether select the node or not
public E reloadPathSync(javax.swing.tree.TreePath path)
path
- path of the node to reload
public E reloadPathSync(javax.swing.tree.TreePath path, boolean select)
path
- path of the node to reloadselect
- whether select the node or not
public E reloadPath(javax.swing.tree.TreePath path)
path
- path of the node to reload
public E reloadPath(javax.swing.tree.TreePath path, boolean select)
path
- path of the node to reloadselect
- whether select the node or not
protected void performReload(E node, javax.swing.tree.TreePath path, boolean select)
node
- node to reloadpath
- path to nodeselect
- whether select the node or notpublic java.util.List<AsyncTreeListener> getAsyncTreeListeners()
public void addAsyncTreeListener(AsyncTreeListener listener)
listener
- asynchronous tree listener to addpublic void removeAsyncTreeListener(AsyncTreeListener listener)
listener
- asynchronous tree listener to removepublic void childsLoadStarted(E parent)
childsLoadStarted
in interface AsyncTreeModelListener<E extends AsyncUniqueNode>
parent
- node which childs are being loadedprotected void fireChildsLoadStarted(E parent)
parent
- node which childs are being loadedpublic void childsLoadCompleted(E parent, java.util.List<E> childs)
childsLoadCompleted
in interface AsyncTreeModelListener<E extends AsyncUniqueNode>
parent
- node which childs were loadedchilds
- loaded child nodesprotected void fireChildsLoadCompleted(E parent, java.util.List<E> childs)
parent
- node which childs were loadedchilds
- loaded child nodespublic void childsLoadFailed(E parent, java.lang.Throwable cause)
childsLoadFailed
in interface AsyncTreeModelListener<E extends AsyncUniqueNode>
parent
- node which childs were loadedcause
- childs load failure causeprotected void fireChildsLoadFailed(E parent, java.lang.Throwable cause)
parent
- node which childs were loadedcause
- childs load failure causepublic void expandNode(java.lang.String nodeId)
nodeId
- ID of the node to expandpublic void expandPath(java.util.List<java.lang.String> pathNodeIds)
pathNodeIds
- node path IDspublic void expandPath(java.util.List<java.lang.String> pathNodeIds, AsyncPathExpansionListener listener)
pathNodeIds
- node path IDslistener
- async path expansion listenerpublic void expandPath(java.util.List<java.lang.String> pathNodeIds, boolean expandLastNode)
pathNodeIds
- node path IDsexpandLastNode
- whether should expand last found path node or notpublic void expandPath(java.util.List<java.lang.String> pathNodeIds, boolean expandLastNode, AsyncPathExpansionListener listener)
pathNodeIds
- node path IDsexpandLastNode
- whether should expand last found path node or notlistener
- async path expansion listenerpublic void expandPath(java.util.List<java.lang.String> pathNodeIds, boolean expandLastNode, boolean selectLastNode)
pathNodeIds
- node path IDsexpandLastNode
- whether should expand last found path node or notselectLastNode
- whether should select last found path node or notpublic void expandPath(java.util.List<java.lang.String> pathNodeIds, boolean expandLastNode, boolean selectLastNode, AsyncPathExpansionListener listener)
pathNodeIds
- node path IDsexpandLastNode
- whether should expand last found path node or notselectLastNode
- whether should select last found path node or notlistener
- async path expansion listenerprotected void expandPathImpl(E currentNode, java.util.List<java.lang.String> leftToExpand, boolean expandLastNode, boolean selectLastNode, AsyncPathExpansionListener listener)
currentNode
- last reached nodeleftToExpand
- node path IDs left for expansionexpandLastNode
- whether should expand last found path node or notselectLastNode
- whether should select last found path node or notlistener
- async path expansion listenerprotected void expandPathEndImpl(E lastFoundNode, boolean expandLastNode, boolean selectLastNode)
lastFoundNode
- last found path nodeexpandLastNode
- whether should expand last found path node or notselectLastNode
- whether should select last found path node or notpublic final void expandAll()
expandAll
in class WebTree<E extends AsyncUniqueNode>
protected void performFullPathExpand(javax.swing.tree.TreePath path)
path
- path to expandprotected void performFullSyncPathExpand(javax.swing.tree.TreePath path)
path
- path to expandprotected void performFullAsyncPathExpand(javax.swing.tree.TreePath path)
path
- path to expand
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |