|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.swing.tree.DefaultMutableTreeNode
projectviewer.vpt.VPTNode
projectviewer.vpt.VPTDirectory
Models a directory that is part of a project.
Field Summary | |
protected java.io.File |
file
|
Fields inherited from class projectviewer.vpt.VPTNode |
name, treeNoSelectionBackground, treeNoSelectionForeground, treeSelectionBackground, treeSelectionForeground |
Fields inherited from class javax.swing.tree.DefaultMutableTreeNode |
allowsChildren, children, EMPTY_ENUMERATION, parent, userObject |
Constructor Summary | |
VPTDirectory(java.io.File file)
|
|
VPTDirectory(java.lang.String path)
|
Method Summary | |
boolean |
canWrite()
Returns is the underlying file is writable. |
int |
compareToNode(VPTNode node)
Directories have precedende over openable nodes... |
boolean |
delete()
Deletes the file from disk and removes it from the current container. |
java.io.File |
getFile()
Return the file associated with this node. |
javax.swing.Icon |
getIcon(boolean expanded)
Returns the icon to be shown on the tree next to the node name. |
java.lang.String |
getNodePath()
Returns the path to the file represented by this node. |
void |
setFile(java.io.File f)
Sets the file associated with this node. |
java.lang.String |
toString()
Returns a string representation of the current node. |
Methods inherited from class projectviewer.vpt.VPTNode |
canOpen, close, compareName, compareTo, findIndexForChild, findProjectFor, getBackgroundColor, getChildWithName, getClipType, getForegroundColor, getName, isDirectory, isFile, isGroup, isOpened, isProject, isRoot, open, persistChildren, setName, setParent, sortChildren, sortChildren |
Methods inherited from class javax.swing.tree.DefaultMutableTreeNode |
add, breadthFirstEnumeration, children, clone, depthFirstEnumeration, getAllowsChildren, getChildAfter, getChildAt, getChildBefore, getChildCount, getDepth, getFirstChild, getFirstLeaf, getIndex, getLastChild, getLastLeaf, getLeafCount, getLevel, getNextLeaf, getNextNode, getNextSibling, getParent, getPath, getPathToRoot, getPreviousLeaf, getPreviousNode, getPreviousSibling, getRoot, getSharedAncestor, getSiblingCount, getUserObject, getUserObjectPath, insert, isLeaf, isNodeAncestor, isNodeChild, isNodeDescendant, isNodeRelated, isNodeSibling, pathFromAncestorEnumeration, postorderEnumeration, preorderEnumeration, remove, remove, removeAllChildren, removeFromParent, setAllowsChildren, setUserObject |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected java.io.File file
Constructor Detail |
public VPTDirectory(java.lang.String path)
public VPTDirectory(java.io.File file)
Method Detail |
public boolean canWrite()
canWrite
in class VPTNode
public boolean delete()
delete
in class VPTNode
public java.io.File getFile()
public javax.swing.Icon getIcon(boolean expanded)
getIcon
in class VPTNode
expanded
- If the node is currently expanded or not.public java.lang.String toString()
toString
in class VPTNode
public java.lang.String getNodePath()
getNodePath
in class VPTNode
public void setFile(java.io.File f)
public int compareToNode(VPTNode node)
compareToNode
in class VPTNode
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |