Package uk.ac.starlink.connect

## Interface Branch

All Superinterfaces:
  `Node`

All Known Implementing Classes:
  `FileBranch`

    public interface Branch
    extends Node

Represents a directory-like node in a (possibly remote) filesystem. A branch may contain child items.

Since:
  18 Feb 2005
Author:
  Mark Taylor (Starlink)

### Method Summary

All Methods Instance Methods Abstract Methods
`Node` `createNode​(java.lang.String name)` Attempts to construct a new node in the context of this one.
`Node[]` `getChildren()` Returns the array of child nodes belonging to this branch.

### Methods inherited from interface uk.ac.starlink.connect.Node

`getName, getParent`

### Method Detail

#### getChildren

    Node[] getChildren()

Returns the array of child nodes belonging to this branch. All the returned values represent file objects which actuallly exist in the filesystem.

Returns:
  child nodes of this one

#### createNode

    Node createNode​(java.lang.String name)

Attempts to construct a new node in the context of this one. The new item may represent a new or an existing node in the filesystem. This call should not in itself perform any write operations on the filesystem (such as creating a node which doesn't currently exist), though a subsequent `Leaf.getOutputStream()` call may do so.

The returned node will typically be a child of this branch, but need not be, for instance if `name` is interpreted as an absolute path.

If the named node cannot be created, `null` may be returned.

Parameters:
  `name` - name of a node in the context of this branch
Returns:
  node representing the location of an existing or new node