|
org.openide.src 1.8.31 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.openide.nodes.Children org.openide.nodes.Children.Array org.openide.nodes.Children.Keys org.openide.src.nodes.SourceChildren
public class SourceChildren
Normal implementation of children for source element nodes.
Ordering and filtering of the children can be customized
using SourceElementFilter
.
FilterCookie
is implemented to provide a means
for user customization of the filter.
The child list listens to changes in the source element, as well as the filter, and automatically updates itself as appropriate.
A child factory can be used to cause the children list to create
non-default
child nodes, if desired, both at the time of the creation
of the children list, and when new children are added.
The children list may be unattached to any source element temporarily, in which case it will have no children (except possibly an error indicator).
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.openide.nodes.Children |
---|
Children.Array, Children.Keys, Children.Map, Children.SortedArray, Children.SortedMap |
Field Summary | |
---|---|
protected SourceElement |
element
The element whose subelements are represented. |
protected ElementNodeFactory |
factory
Factory for obtaining class nodes. |
protected SourceElementFilter |
filter
Filter for elements. |
Fields inherited from class org.openide.nodes.Children.Array |
---|
nodes |
Fields inherited from class org.openide.nodes.Children |
---|
LEAF, MUTEX |
Constructor Summary | |
---|---|
SourceChildren()
Create a children list with the default factory and no attached source element. |
|
SourceChildren(ElementNodeFactory factory)
Create a children list with no attached source element. |
|
SourceChildren(ElementNodeFactory factory,
SourceElement element)
Create a children list. |
|
SourceChildren(SourceElement element)
Create a children list with the default factory. |
Method Summary | |
---|---|
protected void |
addNotify()
|
protected Node[] |
createNodes(Object key)
|
Node |
findChild(String name)
|
SourceElement |
getElement()
Get the currently attached source element. |
Object |
getFilter()
|
Class |
getFilterClass()
|
Node[] |
getNodes(boolean initialize)
If `initialize' is true, invokes the parser and waits for it to finish. |
protected void |
removeNotify()
|
void |
setElement(SourceElement element)
Set a new source element to get information about children from. |
void |
setFilter(Object filter)
|
Methods inherited from class org.openide.nodes.Children.Keys |
---|
add, clone, destroyNodes, refreshKey, remove, setBefore, setKeys, setKeys |
Methods inherited from class org.openide.nodes.Children.Array |
---|
initCollection, refresh |
Methods inherited from class org.openide.nodes.Children |
---|
getNode, getNodes, getNodesCount, isInitialized, nodes |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected SourceElement element
protected SourceElementFilter filter
null
, in which case
modifier filtering is disabled, and ordering may be reset to the default order.
protected ElementNodeFactory factory
Constructor Detail |
---|
public SourceChildren()
public SourceChildren(SourceElement element)
element
- source element to attach to, or null
public SourceChildren(ElementNodeFactory factory)
factory
- a factory for creating childrenpublic SourceChildren(ElementNodeFactory factory, SourceElement element)
factory
- a factory for creating childrenelement
- source element to attach to, or null
Method Detail |
---|
public Class getFilterClass()
getFilterClass
in interface FilterCookie
public Object getFilter()
getFilter
in interface FilterCookie
public void setFilter(Object filter)
setFilter
in interface FilterCookie
protected void addNotify()
protected void removeNotify()
removeNotify
in class Children
protected Node[] createNodes(Object key)
createNodes
in class Children.Keys
public Node[] getNodes(boolean initialize)
public Node findChild(String name)
public SourceElement getElement()
null
if unattachedpublic void setElement(SourceElement element)
element
- the new element, or null
to detach
|
org.openide.src 1.8.31 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |