## org.apache.commons.math3.geometry.euclidean.threed
Class OutlineExtractor.BoundaryProjector

    java.lang.Object
      org.apache.commons.math3.geometry.euclidean.threed.OutlineExtractor.BoundaryProjector

All Implemented Interfaces:
  BSPTreeVisitor<Euclidean3D>

Enclosing class:
  OutlineExtractor

    private class OutlineExtractor.BoundaryProjector

extends java.lang.Object
implements BSPTreeVisitor<Euclidean3D>

Visitor projecting the boundary facets on a plane.

Nested Class Summary

Nested classes/interfaces inherited from interface org.apache.commons.math3.geometry.partitioning.BSPTreeVisitor
`BSPTreeVisitor.Order`

Field Summary
`private PolygonsSet` `projected` Projection of the polyhedrons set on the plane.

Constructor Summary
`OutlineExtractor.BoundaryProjector()` Simple constructor.

Method Summary
`private void` `addContribution(SubHyperplane<Euclidean3D> facet, boolean reversed)` Add he contribution of a boundary facet.
`PolygonsSet` `getProjected()` Get the projection of the polyhedrons set on the plane.
`void` `visitInternalNode(BSPTree<Euclidean3D> node)` Visit a BSP tree node node having a non-null sub-hyperplane.
`void` `visitLeafNode(BSPTree<Euclidean3D> node)` Visit a leaf BSP tree node node having a null sub-hyperplane.
`BSPTreeVisitor.Order` `visitOrder(BSPTree<Euclidean3D> node)` Determine the visit order for this node.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### projected

    private PolygonsSet projected

  Projection of the polyhedrons set on the plane.

Constructor Detail

### OutlineExtractor.BoundaryProjector

    public OutlineExtractor.BoundaryProjector()

  Simple constructor.

Method Detail

### visitOrder

    public BSPTreeVisitor.Order visitOrder(BSPTree<Euclidean3D> node)

  Determine the visit order for this node.

  Before attempting to visit an internal node, this method is called to determine the desired ordering of the visit. It is guaranteed that this method will be called before `visitInternalNode` for a given node, it will be called exactly once for each internal node.

  Specified by:
    `visitOrder` in interface `BSPTreeVisitor<Euclidean3D>`
  Parameters:
    `node` - BSP node guaranteed to have a non null cut sub-hyperplane
  Returns:
    desired visit order, must be one of `BSPTreeVisitor.Order.PLUS_MINUS_SUB`, `BSPTreeVisitor.Order.PLUS_SUB_MINUS`, `BSPTreeVisitor.Order.MINUS_PLUS_SUB`, `BSPTreeVisitor.Order.MINUS_SUB_PLUS`, `BSPTreeVisitor.Order.SUB_PLUS_MINUS`, `BSPTreeVisitor.Order.SUB_MINUS_PLUS`

### visitInternalNode

    public void visitInternalNode(BSPTree<Euclidean3D> node)

  Visit a BSP tree node node having a non-null sub-hyperplane.

  It is guaranteed that this method will be called after `visitOrder` has been called for a given node, it wil be called exactly once for each internal node.

  Specified by:
    `visitInternalNode` in interface `BSPTreeVisitor<Euclidean3D>`
  Parameters:
    `node` - BSP node guaranteed to have a non null cut sub-hyperplane
  See Also:
    `BSPTreeVisitor.visitLeafNode(org.apache.commons.math3.geometry.partitioning.BSPTree)`

### visitLeafNode

    public void visitLeafNode(BSPTree<Euclidean3D> node)

  Visit a leaf BSP tree node node having a null sub-hyperplane.

  Specified by:
    `visitLeafNode` in interface `BSPTreeVisitor<Euclidean3D>`
  Parameters:
    `node` - leaf BSP node having a null sub-hyperplane
  See Also:
    `BSPTreeVisitor.visitInternalNode(org.apache.commons.math3.geometry.partitioning.BSPTree)`

### addContribution

    private void addContribution(SubHyperplane<Euclidean3D> facet,
                                 boolean reversed)

  Add he contribution of a boundary facet.

  Parameters:
    `facet` - boundary facet
    `reversed` - if true, the facet has the inside on its plus side

### getProjected

    public PolygonsSet getProjected()

  Get the projection of the polyhedrons set on the plane.

  Returns:
    projection of the polyhedrons set on the plane

Copyright (c) 2003-2013 Apache Software Foundation