org.netbeans.spi.project.ui.support
Interface NodeFactory
public interface NodeFactory
Factory interface for distributed creation of project node's children. Implementation
instances are assumed to be registered in layers at a location specific for the particular
project type. Project types wanting to make use of NodeFactory can use the
NodeFactorySupport.createCompositeChildren(org.netbeans.api.project.Project, java.lang.String)
method to create the Project nodes's children.
public class FooBarLogicalViewProvider implements LogicalViewProvider {
public Node createLogicalView() {
return new FooBarRootNode(NodeFactorySupport.createCompositeChildren(myProject, "Projects/org-foo-bar-project/Nodes"));
}
}
- Since:
- org.netbeans.modules.projectuiapi/1 1.18
createNodes
NodeList<?> createNodes(Project p)
- Create a list of children nodes for the given project. If the list is to be static,
use the
NodeFactorySupport.fixedNodeList(org.openide.nodes.Node...)
- Returns:
- never return null, if the project is not relevant to the NodeFactory,
use
NodeFactorySupport.fixedNodeList(org.openide.nodes.Node...)
empty value.