public abstract class AbstractShapeBuilder
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
AbstractShapeBuilder.Shrinkage |
Modifier and Type | Field and Description |
---|---|
protected long[] |
coords |
protected int |
pointCount |
Constructor and Description |
---|
AbstractShapeBuilder()
Creates a new instance of AbstractShapeBuilder
|
AbstractShapeBuilder(boolean rotateNodes) |
Modifier and Type | Method and Description |
---|---|
protected abstract void |
addBox(Layer layer)
Subclasses of AbstractShapeBuilder redefine this method to register transformed box.
|
protected abstract void |
addPoly(int numPoints,
Poly.Type style,
Layer layer,
EGraphics graphicsOverride,
PrimitivePort pp)
Subclasses of AbstractShapeBuilder redefine this method to register transformed Poly.
|
void |
addTextPoly(int numPoints,
Poly.Type style,
Layer layer,
PrimitivePort pp,
java.lang.String message,
TextDescriptor descriptor)
Subclasses of AbstractShapeBuilder redefine this method to register transformed text Poly.
|
void |
genShapeOfArc(ImmutableArcInst a) |
void |
genShapeOfNode(ImmutableNodeInst n,
PrimitiveNode np,
Technology.NodeLayer[] primLayers,
EGraphics graphicsOverride)
Returns the polygons that describe node "n", given a set of
NodeLayer objects to use.
|
void |
genShapeOfPort(ImmutableNodeInst n,
PrimitiveNode pn,
PrimitivePort pp)
Puts into shape builder s the polygons that describes port "pp" of node "n".
|
void |
genShapeOfPort(ImmutableNodeInst n,
PrimitivePort pp) |
void |
genShapeOfPort(ImmutableNodeInst n,
PrimitivePort pp,
java.awt.geom.Point2D selectPt) |
CellBackup |
getCellBackup() |
java.util.List<ImmutableArcInst> |
getConnections(java.util.BitSet headEnds,
ImmutableNodeInst n) |
java.util.List<ImmutableArcInst> |
getConnections(java.util.BitSet headEnds,
ImmutableNodeInst n,
PortProtoId portId) |
ImmutableElectricObject |
getCurObj() |
java.util.Iterator<ImmutableExport> |
getExportsOnNode(ImmutableNodeInst originalNode) |
AbstractShapeBuilder.Shrinkage |
getShrinkage() |
TechPool |
getTechPool() |
boolean |
hasExportsOnNode(ImmutableNodeInst n) |
boolean |
isElectrical() |
boolean |
isReasonable() |
boolean |
isWiped(ImmutableNodeInst n) |
boolean |
isWipePins() |
void |
makeGridPoly(ImmutableArcInst a,
long gridWidth,
Poly.Type style,
Layer layer,
EGraphics graphicsOverride)
Method to fill in an AbstractShapeBuilder a polygon that describes this ImmutableArcInst in grid units.
|
boolean |
pinUseCount(ImmutableNodeInst n) |
void |
pushOutlineSegment(EPoint[] outline,
int offset,
int count,
boolean removeCoincidentPoints,
boolean removeSameStartEnd) |
void |
pushPoint(double fixpX,
double fixpY)
Technologies use this method to push a point into the point buffer
|
void |
pushPoint(EPoint p)
Technologies use this method to push a point into the point buffer
|
void |
pushPoint(EPoint p,
double fixpX,
double fixpY)
Technologies use this method to push a point into the point buffer
|
void |
pushPoint(EPoint p,
long fixpX,
long fixpY)
Technologies use this method to push a point into the point buffer
|
void |
pushPoint(long fixpX,
long fixpY) |
void |
pushPoly(Poly.Type style,
Layer layer,
EGraphics graphicsOverride,
PrimitivePort pp)
Technologies use this method to emit a Poly from points in the points buffer.
|
void |
pushTextPoly(Poly.Type style,
Layer layer,
PrimitivePort pp,
java.lang.String message,
TextDescriptor descriptor)
Technologies use this method to emit a text Poly from points in the points buffer.
|
void |
setCurNode(ImmutableNodeInst n) |
void |
setup(Cell cell) |
void |
setup(CellBackup cellBackup,
Orientation orient,
boolean electrical,
boolean wipePins,
boolean reasonable,
Layer.Function.Set onlyTheseLayers) |
void |
setup(CellTree cellTree,
Orientation orient,
boolean electrical,
boolean wipePins,
boolean reasonable,
Layer.Function.Set onlyTheseLayers) |
void |
setup(TechPool techPool) |
boolean |
skipLayer(Layer layer) |
public AbstractShapeBuilder()
public AbstractShapeBuilder(boolean rotateNodes)
public void setup(TechPool techPool)
public void setup(Cell cell)
public void setup(CellTree cellTree, Orientation orient, boolean electrical, boolean wipePins, boolean reasonable, Layer.Function.Set onlyTheseLayers)
public void setup(CellBackup cellBackup, Orientation orient, boolean electrical, boolean wipePins, boolean reasonable, Layer.Function.Set onlyTheseLayers)
public boolean isWipePins()
public boolean isElectrical()
public boolean isReasonable()
public boolean skipLayer(Layer layer)
public CellBackup getCellBackup()
public boolean pinUseCount(ImmutableNodeInst n)
public boolean hasExportsOnNode(ImmutableNodeInst n)
public java.util.Iterator<ImmutableExport> getExportsOnNode(ImmutableNodeInst originalNode)
public java.util.List<ImmutableArcInst> getConnections(java.util.BitSet headEnds, ImmutableNodeInst n)
public java.util.List<ImmutableArcInst> getConnections(java.util.BitSet headEnds, ImmutableNodeInst n, PortProtoId portId)
public boolean isWiped(ImmutableNodeInst n)
public AbstractShapeBuilder.Shrinkage getShrinkage()
public TechPool getTechPool()
public void genShapeOfArc(ImmutableArcInst a)
public void setCurNode(ImmutableNodeInst n)
public ImmutableElectricObject getCurObj()
public void genShapeOfNode(ImmutableNodeInst n, PrimitiveNode np, Technology.NodeLayer[] primLayers, EGraphics graphicsOverride)
n
- the ImmutableNodeInst that is being described.np
- PrimitiveNode prototype of give ImmutableNodeInst in TechPool of MemoizationprimLayers
- an array of NodeLayer objects to convert to Poly objects.graphicsOverride
- the graphics override to use for all generated polygons (if not null).
The prototype of this NodeInst must be a PrimitiveNode and not a Cell.public void pushOutlineSegment(EPoint[] outline, int offset, int count, boolean removeCoincidentPoints, boolean removeSameStartEnd)
public void genShapeOfPort(ImmutableNodeInst n, PrimitivePort pp)
public void genShapeOfPort(ImmutableNodeInst n, PrimitivePort pp, java.awt.geom.Point2D selectPt)
public void genShapeOfPort(ImmutableNodeInst n, PrimitiveNode pn, PrimitivePort pp)
n
- the ImmutableNodeInst that is being described.pn
- prototype of the ImmutableNodeInst in this Technologypp
- PrimitivePortpublic void makeGridPoly(ImmutableArcInst a, long gridWidth, Poly.Type style, Layer layer, EGraphics graphicsOverride)
a
- the arc information.gridWidth
- the gridWidth of the Poly.style
- the style of the Poly.layer
- layer of the PolygraphicsOverride
- graphics override of the Polypublic void pushPoint(EPoint p, long fixpX, long fixpY)
p
- Electric pointfixpX
- x-displacement in fixed-point unitsfixpY
- y-displacement in fixed-point unitspublic void pushPoint(EPoint p, double fixpX, double fixpY)
p
- Electric pointfixpX
- x-displacement in fixed-point unitsfixpY
- y-displacement in fixed-point unitspublic void pushPoint(double fixpX, double fixpY)
fixpX
- x-displacement in grid unitsfixpY
- y-displacement in grid unitspublic void pushPoint(EPoint p)
p
- Electric pointpublic void pushPoint(long fixpX, long fixpY)
public void pushPoly(Poly.Type style, Layer layer, EGraphics graphicsOverride, PrimitivePort pp)
style
- style of Polylayer
- layer of PolygraphicsOverride
- optional graphics overridepp
- port connected to this Polypublic void pushTextPoly(Poly.Type style, Layer layer, PrimitivePort pp, java.lang.String message, TextDescriptor descriptor)
style
- style of Polylayer
- layer of Polypp
- port connected to this Polymessage
- text messagedescriptor
- text descriptorpublic void addTextPoly(int numPoints, Poly.Type style, Layer layer, PrimitivePort pp, java.lang.String message, TextDescriptor descriptor)
numPoints
- number of pointsstyle
- style of Polylayer
- layer of Polypp
- port connected to this Polymessage
- text messagedescriptor
- text descriptorprotected abstract void addPoly(int numPoints, Poly.Type style, Layer layer, EGraphics graphicsOverride, PrimitivePort pp)
numPoints
- number of pointsstyle
- style of Polylayer
- layer of PolygraphicsOverride
- optional graphics overridepp
- port connected to this Polyprotected abstract void addBox(Layer layer)
layer
- layer of the box