Class TreeView

java.lang.Object
io.bdeploy.bhive.objects.view.ElementView
io.bdeploy.bhive.objects.view.TreeView
All Implemented Interfaces:
Comparable<ElementView>
Direct Known Subclasses:
ManifestRefView

public class TreeView extends ElementView
A recursive view of a Tree's metadata, usually a Manifest's root Tree.

The referenced recursive elements hold relevant information of Tree entries (blobs, trees, and as Manifest references). It does, however, not hold any expensive-to-calculate information (file sizes, attributes, etc.).

  • Constructor Details

  • Method Details

    • addChild

      public void addChild(ElementView snapshot)
      Parameters:
      snapshot - the snapshot to add to the tree.
    • getChildren

      public Map<String,ElementView> getChildren()
      Returns:
      all children of this TreeView.
    • visit

      public void visit(TreeVisitor scanner)
      Visit all children of this tree recursively until the scanner opts out.
      Parameters:
      scanner - the scanner to call for each element.
    • visitDfs

      public void visitDfs(TreeVisitor scanner)
      Visit all children of this tree recursively in a DFS manner.
      Parameters:
      scanner - the scanner to call for each element.