private void setParent(DepTreeNode parent) {
		if (this.name.length() == 0) {
			// A child node must have a name.
			throw new IllegalStateException();
		}
		this.parent = new WeakReference<DepTreeNode>(parent);
	}
private void setParent ( DepTreeNode parent ) { if ( this . name . length ( ) == 0 ) { throw new IllegalStateException ( ) ; } this . parent = new WeakReference < DepTreeNode > ( parent ) ; }
Sets the parent reference for this node using a {@link WeakReference}
so as to avoid unwanted circular references which could prevent the
GC from doing its job.

@param parent The reference to the parent node.