Class Tree<T>

java.lang.Object
fr.formiko.usuel.structures.Tree<T>
All Implemented Interfaces:
Serializable, Iterable<T>
Direct Known Subclasses:
ImageTree

public class Tree<T> extends Object implements Serializable, Iterable<T>
Custom Tree class using Generics.
Author:
Hydrolien
See Also:
Serialized Form
  • Field Details

  • Constructor Details

    • Tree

      public Tree()
      Main constructor.
  • Method Details

    • getRoot

      public TreeNode<T> getRoot()
    • toString

      public String toString()
      Compact toString function.
      Overrides:
      toString in class Object
    • copyStructure

      public Tree<T> copyStructure()
      Copy the structure of a given Tree. content of node will not be copy.
    • iterator

      public Iterator<T> iterator()
      return the coresponding Iterator
      Specified by:
      iterator in interface Iterable<T>