org.jfree.layouting.renderer.model
Class RenderNode
public abstract
class
RenderNode
extends Object
implements Cloneable
A node of the rendering model. The renderer model keeps track of the
rendering state - what has already been rendered, what is pending, etc.
Things that have been rendered completely get removed from the model.
The default model makes some assumptions about the node processing:
- Once placed somewhere, nodes will never move anywhere else
- Once size computation is complete, nodes will not be modified
anymore.
Finished nodes can be removed as soon as they have been physically rendered.
In case a node cannot be rendered right now (think of tables, which need all
cells before a row or in some cases even the columns can be computed), a cell
receives the 'pending' flag. If a cell is added to a parent which is pending,
the cell is pending as well. The pending state must be resolved by the
outer-most element. An element cannot be finished or removed unless it
resolved the pending state.
Author: Thomas Morgner
public static final int HORIZONTAL_AXIS
public static final int VERTICAL_AXIS
public RenderNode()
public Object clone()
Clones this node. Be aware that cloning can get you into deep trouble, as
the relations this node has may no longer be valid.
Returns:
Derive creates a disconnected node that shares all the properties of the
original node. The derived node will no longer have any parent, silbling,
child or any other relationships with other nodes.
Returns:
public void freeze()
public long getChangeTracker()
public final long getDimension(int axis)
public long getEffectiveMarginBottom()
public long getEffectiveMarginTop()
public long getHeight()
public Object getInstanceId()
public int getMajorAxis()
public long getMaximumBoxWidth()
public long getMinimumChunkWidth()
public int getMinorAxis()
public String getNamespace()
Returns the baseline info for the given node. This can be null, if the node
does not have any baseline info at all. If the element has more than one
set of baselines, the baseline of the first element is returned.
Returns:
public final long getPosition(int axis)
public long getStickyMarker()
public String getTagName()
public long getWidth()
public long getX()
public long getY()
Derives an hibernation copy. The resulting object should get stripped of
all unnecessary caching information and all objects, which will be
regenerated when the layouting restarts. Size does matter here.
Returns:
public boolean isDirectionLTR()
public boolean isDirty()
public boolean isDiscardable()
public boolean isEmpty()
public boolean isFrozen()
public boolean isHibernated()
public boolean isIcmMetricsFinished()
public boolean isIgnorableForRendering()
If that method returns true, the element will not be used for rendering.
For the purpose of computing sizes or performing the layouting (in the
validate() step), this element will treated as if it is not there.
If the element reports itself as non-empty, however, it will affect the
margin computation.
Returns:
public boolean isOpen()
public final void setDimension(int axis, long value)
public void setDirty(boolean dirty)
public void setHeight(long height)
protected void setHibernated(boolean hibernated)
public void setIcmMetricsFinished(boolean icmMetricsFinished)
protected void setMajorAxis(int majorAxis)
public void setMaximumBoxWidth(long maximumBoxWidth)
public void setMinimumChunkWidth(long minimumChunkWidth)
protected void setMinorAxis(int minorAxis)
public final void setPosition(int axis, long value)
public void setStickyMarker(long stickyMarker)
public void setWidth(long width)
public void setX(long x)
public void setY(long y)
public void updateChangeTracker()