org.openide.loaders
Class DataFolder.Index
java.lang.Object
|
+--org.openide.nodes.Index.Support
|
+--org.openide.loaders.DataFolder.Index
- All Implemented Interfaces:
- Index, Node.Cookie
- Enclosing class:
- DataFolder
- public static class DataFolder.Index
- extends Index.Support
Support for index cookie for folder nodes.
Method Summary |
Node[] |
getNodes()
Get the nodes; should be overridden if needed. |
int |
getNodesCount()
Get the node count. |
int |
indexOf(Node node)
Get the index of a node. |
void |
reorder()
Reorder the nodes with dialog; should be overridden if needed. |
void |
reorder(int[] perm)
Reorder by permutation. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DataFolder.Index
public DataFolder.Index(DataFolder df)
- Deprecated. Please explicitly specify a node to be safe.
- Create an index cookie associated with a data folder.
- Parameters:
df
- the data folder
DataFolder.Index
public DataFolder.Index(DataFolder df,
Node node)
- Create an index cookie associated with a data folder.
- Parameters:
df
- the data foldernode
- node to be associated with. subnodes of this node will be returned, etc.
indexOf
public int indexOf(Node node)
- Description copied from class:
Index.Support
- Get the index of a node. Simply scans through the array returned by
Index.Support.getNodes()
.
- Overrides:
indexOf
in class Index.Support
- Following copied from class:
org.openide.nodes.Index.Support
- Parameters:
node
- the node- Returns:
- the index, or
-1
if the node was not found
getNodesCount
public int getNodesCount()
- Description copied from class:
Index.Support
- Get the node count. Subclasses must provide this.
- Overrides:
getNodesCount
in class Index.Support
- Following copied from class:
org.openide.nodes.Index.Support
- Returns:
- the count
getNodes
public Node[] getNodes()
- Description copied from class:
Index.Support
- Get the nodes; should be overridden if needed.
- Overrides:
getNodes
in class Index.Support
- Following copied from class:
org.openide.nodes.Index.Support
- Returns:
- the nodes
reorder
public void reorder(int[] perm)
- Description copied from class:
Index.Support
- Reorder by permutation. Subclasses must provide this.
- Overrides:
reorder
in class Index.Support
- Following copied from class:
org.openide.nodes.Index.Support
- Parameters:
perm
- the permutation
reorder
public void reorder()
- Description copied from class:
Index.Support
- Reorder the nodes with dialog; should be overridden if needed.
- Overrides:
reorder
in class Index.Support
Built on December 12 2001. | Portions Copyright 1997-2001 Sun Microsystems, Inc. All rights reserved.