using System;
namespace Netron.Diagramming.Core.Analysis {
///
/// This interface describes the additional members useful if the underlying graph is a tree.
///
public interface ITree : IGraph {
///
/// Gets or sets a value indicating whether this tree is directed.
///
///
/// true if this instance is directed; otherwise, false.
///
new bool IsDirected { get; set; }
///
/// Gets or sets the root of the tree
///
INode Root { get; set; }
///
/// Gets the children of the given node in the tree hierarchy.
///
///
///
CollectionBase Children(INode node);
///
/// Gets the edges connecting the children of the given node.
///
///
///
CollectionBase ChildEdges(INode node);
///
/// Returns the next sibling node of the given node.
///
/// The node.
///
INode NextSibling(INode node);
///
/// Returns the previous sibling node of the given node.
///
/// The node.
///
INode PreviousSibling(INode node);
///
/// Returns the last child of the given node.
///
/// The node.
///
INode LastChild(INode node);
///
/// Returns the first child of the given node.
///
/// The node.
///
INode FirstChild(INode node);
///
/// Returns how many children the given node has.
///
/// The node.
///
int ChildCount(INode node);
///
/// Returns the depth the specified node.
///
/// The node.
///
int Depth(INode node);
///
/// Returns the parent edge of the given node.
///
/// The node.
///
IEdge ParentEdge(INode node);
///
/// Executes a the given on each node, starting from the given node, by means of a traversal
///
/// The action.
/// The start node.
void ForEach(Action action, INode startNode) where T : INode;
}
}