public class FileTreeNode extends Object implements TreeNode, Comparable<FileTreeNode>
Modifier and Type | Class and Description |
---|---|
static class |
FileTreeNode.RootNode |
Modifier and Type | Field and Description |
---|---|
protected AtomicReference<List<FileTreeNode>> |
children |
protected FileNode |
fileNode |
protected FileTreeModel |
model |
protected FileTreeNode |
parent |
protected AtomicInteger |
taskCount |
protected WatchKey |
watchKey |
Constructor and Description |
---|
FileTreeNode(FileTreeNode parent,
FileNode fileNode,
FileTreeModel model) |
Modifier and Type | Method and Description |
---|---|
Enumeration<? extends TreeNode> |
children() |
int |
compareTo(FileTreeNode o) |
protected <T> void |
doInBackground(Consumer<Consumer<T>> task,
Consumer<List<T>> processor) |
protected <T> void |
doInBackground(Consumer<Consumer<T>> task,
Consumer<List<T>> processor,
Runnable doneTask) |
boolean |
equals(Object o) |
boolean |
getAllowsChildren() |
TreeNode |
getChildAt(int childIndex) |
int |
getChildCount() |
FileNode |
getFile() |
int |
getIndex(TreeNode node) |
TreeNode |
getParent() |
int |
hashCode() |
boolean |
isBusy() |
boolean |
isLeaf() |
boolean |
isNodeChild(TreeNode aNode) |
void |
reload() |
protected void |
reload(int depth) |
protected FileTreeNode |
toNode(FileNode fileNode) |
String |
toString() |
protected void |
traverseChildren(Consumer<Stream<FileNode>> consumer) |
protected final FileTreeNode parent
protected final FileTreeModel model
protected final FileNode fileNode
protected AtomicInteger taskCount
protected AtomicReference<List<FileTreeNode>> children
protected WatchKey watchKey
public FileTreeNode(FileTreeNode parent, FileNode fileNode, FileTreeModel model)
public FileNode getFile()
public void reload()
protected void reload(int depth)
protected FileTreeNode toNode(FileNode fileNode)
protected <T> void doInBackground(Consumer<Consumer<T>> task, Consumer<List<T>> processor)
protected <T> void doInBackground(Consumer<Consumer<T>> task, Consumer<List<T>> processor, Runnable doneTask)
public TreeNode getChildAt(int childIndex)
getChildAt
in interface TreeNode
public int getChildCount()
getChildCount
in interface TreeNode
public boolean getAllowsChildren()
getAllowsChildren
in interface TreeNode
public Enumeration<? extends TreeNode> children()
public boolean isNodeChild(TreeNode aNode)
public int compareTo(FileTreeNode o)
compareTo
in interface Comparable<FileTreeNode>
public boolean isBusy()