DepTreeNode implements Cloneable, Serializable { public DepTreeNode(String name, URI uri) { if (name.contains("/")) { throw new IllegalArgumentException(name); } children = null; defineDependencies = null; requireDependencies = null; parent = new WeakReference<DepTreeNode>(null); this.name = name; this.uri = uri; } DepTreeNode(String name, URI uri); String getName(); long lastModified(); long lastModifiedDep(); long lastModifiedDepTree(); DepTreeNode getParent(); DepTreeNode getRoot(); String[] getDefineDepArray(); String[] getRequireDepArray(); String[] getDependentFeatures(); String getParentPath(); String getFullPathName(); void add(DepTreeNode child); void overlay(DepTreeNode node); void addAll(Collection<DepTreeNode> children); DepTreeNode createOrGet(String path, URI uri); DepTreeNode getDescendent(String path); void remove(DepTreeNode child); void removeAll(); Map<String, DepTreeNode> getChildren(); DepTreeNode getChild(String name); void prune(); void setDependencies(String[] defineDependencies, String[] requireDependencies, String[] dependentFeatures, long lastModifiedFile, long lastModifiedDep); @Override String toString(); String toStringTree(); @Override DepTreeNode clone(); IConfig getConfig();  }
@Test public void testDepTreeNode() { DepTreeNode node = new DepTreeNode("foo", null); assertNotNull(node); try { node = new DepTreeNode("foo/bar", null); fail("Exception not thrown"); } catch (IllegalArgumentException e) { } try { node = new DepTreeNode(null, null); fail("Exception not thrown"); } catch (NullPointerException e) { } }