com.sun.electric.tool.extract
Class GeometrySearch

java.lang.Object
  extended by com.sun.electric.database.hierarchy.HierarchyEnumerator.Visitor
      extended by com.sun.electric.tool.extract.GeometrySearch

public class GeometrySearch
extends HierarchyEnumerator.Visitor

User: gg151869


Constructor Summary
GeometrySearch()
           
 
Method Summary
 java.lang.String describeFoundGeometry()
           
 boolean enterCell(HierarchyEnumerator.CellInfo info)
          Enumerator class
 void exitCell(HierarchyEnumerator.CellInfo info)
          The HierarchyEnumerator has finished enumerating the contents of the current Cell instance.
 boolean foundGeometry()
           
 int getCellsProcessed()
           
 VarContext getContext()
           
 Geometric getGeometricFound()
           
 boolean searchGeometries(Cell cell, EPoint point, boolean visibleObjectsOnly)
          Find a Primitive Node or Arc at a point in a cell.
 boolean visitNodeInst(Nodable no, HierarchyEnumerator.CellInfo info)
          The HierarchyEnumerator is visiting Nodable ni.
 
Methods inherited from class com.sun.electric.database.hierarchy.HierarchyEnumerator.Visitor
newCellInfo
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GeometrySearch

public GeometrySearch()
Method Detail

searchGeometries

public boolean searchGeometries(Cell cell,
                                EPoint point,
                                boolean visibleObjectsOnly)
Find a Primitive Node or Arc at a point in a cell. The geometric found may exist down the hierarchy from the given cell. Currently, it stops at the first Geometric it finds.

Parameters:
cell - the cell in which the point resides
point - a point to search under
visibleObjectsOnly - true to consider only Geometries that are visible
Returns:
true if a Geometric was found, false if none was found

foundGeometry

public boolean foundGeometry()

getGeometricFound

public Geometric getGeometricFound()

getContext

public VarContext getContext()

getCellsProcessed

public int getCellsProcessed()

describeFoundGeometry

public java.lang.String describeFoundGeometry()

enterCell

public boolean enterCell(HierarchyEnumerator.CellInfo info)
Enumerator class

Specified by:
enterCell in class HierarchyEnumerator.Visitor
Parameters:
info - information about the Cell instance being enumerated
Returns:
a boolean indicating if the HierarchyEnumerator should enumerate the contents of the current Cell. True means enumerate the current cell

exitCell

public void exitCell(HierarchyEnumerator.CellInfo info)
Description copied from class: HierarchyEnumerator.Visitor
The HierarchyEnumerator has finished enumerating the contents of the current Cell instance. It is about to leave it, never to return. The CellInfo associated with the current Cell instance is about to be abandoned.

Specified by:
exitCell in class HierarchyEnumerator.Visitor
Parameters:
info - information about the Cell instance being enumerated

visitNodeInst

public boolean visitNodeInst(Nodable no,
                             HierarchyEnumerator.CellInfo info)
Description copied from class: HierarchyEnumerator.Visitor
The HierarchyEnumerator is visiting Nodable ni.

Specified by:
visitNodeInst in class HierarchyEnumerator.Visitor
Parameters:
no - the Nodable that HierarchyEnumerator is visiting.
Returns:
a boolean indicating whether or not the HierarchyEnumerator should expand the Cell instantiated by ni. True means expand. If ni instantiates a PrimitiveNode then the return value is ignored by the HierarchyEnumerator.