|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.jasperreports.engine.fill.JRFillElement
public abstract class JRFillElement
| Field Summary | |
|---|---|
protected JRFillBand |
band
|
protected JRFillElementContainer |
conditionalStylesContainer
|
protected byte |
currentEvaluation
|
protected JRStyle |
currentStyle
|
protected JRDefaultStyleProvider |
defaultStyleProvider
|
protected java.util.Map |
delayedEvaluationsMap
|
protected JRPropertiesMap |
dynamicProperties
|
protected JRFillElementGroup |
elementGroup
|
protected JRFillExpressionEvaluator |
expressionEvaluator
|
protected JRBaseFiller |
filler
|
protected JRStyle |
initStyle
|
protected JRPropertiesMap |
mergedProperties
|
protected JROriginProvider |
originProvider
|
protected JRElement |
parent
|
protected JRGroup |
printWhenGroupChanges
|
protected JRPropertiesMap |
staticProperties
|
protected java.util.Map |
templates
|
| Fields inherited from interface net.sf.jasperreports.engine.JRElement |
|---|
MODE_OPAQUE, MODE_TRANSPARENT, POSITION_TYPE_FIX_RELATIVE_TO_BOTTOM, POSITION_TYPE_FIX_RELATIVE_TO_TOP, POSITION_TYPE_FLOAT, STRETCH_TYPE_NO_STRETCH, STRETCH_TYPE_RELATIVE_TO_BAND_HEIGHT, STRETCH_TYPE_RELATIVE_TO_TALLEST_OBJECT |
| Constructor Summary | |
|---|---|
protected |
JRFillElement(JRBaseFiller filler,
JRElement element,
JRFillObjectFactory factory)
private JRElement topElementInGroup; private JRElement bottomElementInGroup; /** |
protected |
JRFillElement(JRFillElement element,
JRFillCloneFactory factory)
|
| Method Summary | |
|---|---|
protected void |
addDependantElement(JRElement element)
|
java.lang.Object |
clone()
|
java.lang.Object |
clone(JRElementGroup parentGroup)
|
protected void |
collectDelayedEvaluations()
|
protected void |
collectDelayedEvaluations(JRExpression expression)
|
protected void |
collectDelayedEvaluations(JRStyle style)
|
protected void |
collectStyleDelayedEvaluations()
|
protected abstract JRTemplateElement |
createElementTemplate()
|
protected void |
delayedEvaluate(JRRecordedValuesPrintElement printElement,
JREvaluationTime evaluationTime,
byte evaluation)
|
protected abstract void |
evaluate(byte evaluation)
|
java.lang.Object |
evaluateExpression(JRExpression expression,
byte evaluation)
Evaluates an expression. |
protected void |
evaluatePrintWhenExpression(byte evaluation)
|
protected void |
evaluateProperties(byte evaluation)
|
protected abstract JRPrintElement |
fill()
|
java.awt.Color |
getBackcolor()
|
protected JRFillBand |
getBand()
|
JRDefaultStyleProvider |
getDefaultStyleProvider()
|
protected java.util.Collection |
getDependantElements()
|
JRElementGroup |
getElementGroup()
Indicates the logical group that the element belongs to. |
protected JROrigin |
getElementOrigin()
|
protected JRTemplateElement |
getElementTemplate()
|
protected JRPropertiesMap |
getEvaluatedProperties()
|
protected EvaluationTimeEnum |
getEvaluationTimeValue()
|
protected JRFillField |
getField(java.lang.String fieldName)
|
java.awt.Color |
getForecolor()
|
protected JRElement[] |
getGroupElements()
|
int |
getHeight()
|
java.lang.String |
getKey()
Returns the string value that uniquely identifies the element. |
byte |
getMode()
Deprecated. Replaced by getModeValue(). |
ModeEnum |
getModeValue()
Returns the element transparency mode. |
java.awt.Color |
getOwnBackcolor()
|
java.awt.Color |
getOwnForecolor()
|
java.lang.Byte |
getOwnMode()
Deprecated. Replaced by getOwnModeValue(). |
ModeEnum |
getOwnModeValue()
|
JRPropertiesHolder |
getParentProperties()
Returns the parent properties holder, whose properties are used as defaults for this object. |
byte |
getPositionType()
Deprecated. Replaced by getPositionTypeValue(). |
PositionTypeEnum |
getPositionTypeValue()
Returns the position type for the element |
JRExpression |
getPrintWhenExpression()
Gets the the expression that is evaluated in order to decide if the element should be displayed. |
JRGroup |
getPrintWhenGroupChanges()
Returns the group for which an element with a printRepeatedValues attribute set to true will be redisplayed even if the value has not changed. |
JRPropertiesMap |
getPropertiesMap()
Returns this object's properties map. |
JRPropertyExpression[] |
getPropertyExpressions()
Returns the list of dynamic/expression-based properties for this report element. |
protected int |
getRelativeY()
|
protected int |
getStretchHeight()
|
byte |
getStretchType()
Deprecated. Replaced by getStretchTypeValue(). |
StretchTypeEnum |
getStretchTypeValue()
Indicates the stretch type for the element |
JRStyle |
getStyle()
Returns this object's style. |
java.lang.String |
getStyleNameReference()
Returns the name of an external style which is to be used by this object. |
protected JRTemplateElement |
getTemplate(JRStyle style)
|
protected JRFillVariable |
getVariable(java.lang.String variableName)
|
int |
getWidth()
|
int |
getX()
Gets the the section relative horizontal offset of the element top left corner. |
int |
getY()
Gets the the section relative vertical offset of the element top left corner. |
boolean |
hasProperties()
Checks whether the object has any properties. |
protected void |
initDelayedEvaluationPrint(JRRecordedValuesPrintElement printElement)
|
protected void |
initDelayedEvaluations()
|
protected boolean |
isAlreadyPrinted()
|
protected boolean |
isAutoEvaluateNow()
|
protected boolean |
isDelayedStyleEvaluation()
|
protected boolean |
isEvaluateAuto()
|
protected boolean |
isEvaluateNow()
|
boolean |
isPrintInFirstWholeBand()
Returns true if an element with a printRepeatedValues attribute set to true will be redisplayed for every new page or column that is not an overflow from a previous page or column. |
boolean |
isPrintRepeatedValues()
Specifies if the element value will be printed for every iteration, even if its value has not changed. |
boolean |
isPrintWhenDetailOverflows()
If this is set to true, the element will be reprinted on the next page if the band does not fit in the current page. |
protected boolean |
isPrintWhenExpressionNull()
|
protected boolean |
isPrintWhenTrue()
|
boolean |
isRemoveLineWhenBlank()
Returns true if the remaining blank space appearing when the value is not printed will be removed. |
protected boolean |
isReprinted()
|
protected boolean |
isToPrint()
|
protected boolean |
isValueRepeating()
Decides whether the value for this element is repeating. |
protected void |
moveDependantElements()
|
protected void |
performDelayedEvaluation(JRPrintElement element,
byte evaluation)
|
protected boolean |
prepare(int availableHeight,
boolean isOverflow)
|
protected void |
registerTemplate(JRStyle style,
JRTemplateElement template)
|
protected void |
reset()
|
protected abstract void |
resolveElement(JRPrintElement element,
byte evaluation)
Resolves an element. |
protected void |
resolveElement(JRPrintElement element,
byte evaluation,
JREvaluationTime evaluationTime)
Resolves an element. |
protected abstract void |
rewind()
|
protected void |
setAlreadyPrinted(boolean isAlreadyPrinted)
|
void |
setBackcolor(java.awt.Color backcolor)
|
protected void |
setBand(JRFillBand band)
|
protected void |
setConditionalStylesContainer(JRFillElementContainer conditionalStylesContainer)
|
protected void |
setCurrentEvaluation(byte evaluation)
|
void |
setForecolor(java.awt.Color forecolor)
|
void |
setHeight(int height)
|
void |
setMode(byte mode)
Deprecated. Replaced by setMode(ModeEnum). |
void |
setMode(java.lang.Byte mode)
Deprecated. Replaced by setMode(ModeEnum). |
void |
setMode(ModeEnum modeValue)
Sets the element transparency mode. |
protected void |
setOriginProvider(JROriginProvider originProvider)
|
void |
setPositionType(byte positionType)
Deprecated. Replaced by setPositionType(PositionTypeEnum). |
void |
setPositionType(PositionTypeEnum positionType)
Sets the position type for the element. |
void |
setPrintInFirstWholeBand(boolean isPrint)
Specifies whether an element with a printRepeatedValues attribute set to true should be redisplayed for every new page or column that is not an overflow from a previous page or column. |
void |
setPrintRepeatedValues(boolean isPrintRepeatedValues)
|
void |
setPrintWhenDetailOverflows(boolean isPrint)
If this is set to true, the element will be reprinted on the next page if the band does not fit in the current page. |
protected void |
setPrintWhenExpressionNull(boolean isPrintWhenExpressionNull)
|
protected void |
setPrintWhenTrue(boolean isPrintWhenTrue)
|
protected void |
setRelativeY(int relativeY)
|
void |
setRemoveLineWhenBlank(boolean isRemoveLine)
Specifies whether the remaining blank space appearing when the value is not printed will be removed. |
protected void |
setReprinted(boolean isReprinted)
|
protected void |
setShrinkable(boolean shrinkable)
Indicates whether an element is shrinkable. |
protected void |
setStretchHeight(int stretchHeight)
|
void |
setStretchType(byte stretchType)
Deprecated. Replaced by setStretchType(StretchTypeEnum). |
void |
setStretchType(StretchTypeEnum stretchType)
Specifies how the engine should treat a missing image. |
void |
setStyle(JRStyle style)
Set the style on the object. |
void |
setStyleNameReference(java.lang.String name)
Set the name of an external style that is to be used by the object. |
protected void |
setToPrint(boolean isToPrint)
|
protected void |
setValueRepeating(boolean isValueRepeating)
Sets the repeating flag for this element. |
void |
setWidth(int width)
|
void |
setX(int x)
Sets the the section relative horizontal offset of the element top left corner. |
void |
setY(int y)
|
protected void |
stretchElement(int bandStretch)
|
protected void |
stretchHeightFinal()
Called when the stretch height of an element is final so that the element can perform any adjustments. |
protected void |
transferProperties(JRPrintElement element)
|
protected void |
transferProperties(JRTemplateElement template)
|
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface net.sf.jasperreports.engine.JRElement |
|---|
collectExpressions |
| Methods inherited from interface net.sf.jasperreports.engine.JRVisitable |
|---|
visit |
| Methods inherited from interface net.sf.jasperreports.engine.fill.JRFillCloneable |
|---|
createClone |
| Field Detail |
|---|
protected JRElement parent
protected java.util.Map templates
protected JRBaseFiller filler
protected JRFillExpressionEvaluator expressionEvaluator
protected JRDefaultStyleProvider defaultStyleProvider
protected JRGroup printWhenGroupChanges
protected JRFillElementGroup elementGroup
protected JRFillBand band
protected JROriginProvider originProvider
protected byte currentEvaluation
protected java.util.Map delayedEvaluationsMap
protected JRFillElementContainer conditionalStylesContainer
protected JRStyle initStyle
protected JRStyle currentStyle
protected JRPropertiesMap staticProperties
protected JRPropertiesMap dynamicProperties
protected JRPropertiesMap mergedProperties
| Constructor Detail |
|---|
protected JRFillElement(JRBaseFiller filler,
JRElement element,
JRFillObjectFactory factory)
protected JRFillElement(JRFillElement element,
JRFillCloneFactory factory)
| Method Detail |
|---|
public JRDefaultStyleProvider getDefaultStyleProvider()
getDefaultStyleProvider in interface JRStyleContainerpublic java.lang.String getKey()
JRElement
getKey in interface JRCommonElementgetKey in interface JRElementpublic byte getPositionType()
getPositionTypeValue().
getPositionType in interface JRElementpublic PositionTypeEnum getPositionTypeValue()
JRElement
getPositionTypeValue in interface JRElementpublic void setPositionType(byte positionType)
setPositionType(PositionTypeEnum).
setPositionType in interface JRElementpublic void setPositionType(PositionTypeEnum positionType)
JRElement
setPositionType in interface JRElementpositionType - the position typepublic byte getStretchType()
getStretchTypeValue().
getStretchType in interface JRElementpublic void setStretchType(byte stretchType)
setStretchType(StretchTypeEnum).
setStretchType in interface JRElementpublic StretchTypeEnum getStretchTypeValue()
JRElement
getStretchTypeValue in interface JRElementStretchTypeEnumpublic void setStretchType(StretchTypeEnum stretchType)
JRElement
setStretchType in interface JRElementstretchType - a value representing one of the stretch type constants in StretchTypeEnumpublic boolean isPrintRepeatedValues()
JRElement
isPrintRepeatedValues in interface JRElementJRElement.isRemoveLineWhenBlank(),
JRElement.isPrintInFirstWholeBand()public void setPrintRepeatedValues(boolean isPrintRepeatedValues)
setPrintRepeatedValues in interface JRElementpublic byte getMode()
getModeValue().
getMode in interface JRCommonElementpublic java.lang.Byte getOwnMode()
getOwnModeValue().
getOwnMode in interface JRCommonElementpublic ModeEnum getModeValue()
JRCommonElement
getModeValue in interface JRCommonElementpublic ModeEnum getOwnModeValue()
getOwnModeValue in interface JRCommonElementpublic void setMode(byte mode)
setMode(ModeEnum).
setMode in interface JRCommonElementpublic void setMode(java.lang.Byte mode)
setMode(ModeEnum).
setMode in interface JRCommonElementpublic void setMode(ModeEnum modeValue)
JRCommonElement
setMode in interface JRCommonElementpublic int getX()
JRElement
getX in interface JRElementpublic void setX(int x)
JRElement
setX in interface JRElementpublic void setY(int y)
public int getY()
JRElement
getY in interface JRElementpublic int getWidth()
getWidth in interface JRCommonElementpublic void setWidth(int width)
setWidth in interface JRElementpublic void setHeight(int height)
public int getHeight()
getHeight in interface JRCommonElementpublic boolean isRemoveLineWhenBlank()
JRElement
isRemoveLineWhenBlank in interface JRElementpublic void setRemoveLineWhenBlank(boolean isRemoveLine)
JRElement
setRemoveLineWhenBlank in interface JRElementpublic boolean isPrintInFirstWholeBand()
JRElement
isPrintInFirstWholeBand in interface JRElementJRElement.isPrintRepeatedValues()public void setPrintInFirstWholeBand(boolean isPrint)
JRElement
setPrintInFirstWholeBand in interface JRElementJRElement.isPrintRepeatedValues()public boolean isPrintWhenDetailOverflows()
JRElement
isPrintWhenDetailOverflows in interface JRElementpublic void setPrintWhenDetailOverflows(boolean isPrint)
JRElement
setPrintWhenDetailOverflows in interface JRElementpublic java.awt.Color getForecolor()
getForecolor in interface JRCommonElementpublic java.awt.Color getOwnForecolor()
getOwnForecolor in interface JRCommonElementpublic void setForecolor(java.awt.Color forecolor)
setForecolor in interface JRCommonElementpublic java.awt.Color getBackcolor()
getBackcolor in interface JRCommonElementpublic java.awt.Color getOwnBackcolor()
getOwnBackcolor in interface JRCommonElementpublic void setBackcolor(java.awt.Color backcolor)
setBackcolor in interface JRCommonElementpublic JRExpression getPrintWhenExpression()
JRElement
getPrintWhenExpression in interface JRElementpublic JRGroup getPrintWhenGroupChanges()
JRElement
getPrintWhenGroupChanges in interface JRElementJRElement.isPrintRepeatedValues()public JRElementGroup getElementGroup()
JRElement
getElementGroup in interface JRElementJRElement.STRETCH_TYPE_RELATIVE_TO_TALLEST_OBJECTprotected boolean isPrintWhenExpressionNull()
protected void setPrintWhenExpressionNull(boolean isPrintWhenExpressionNull)
protected boolean isPrintWhenTrue()
protected void setPrintWhenTrue(boolean isPrintWhenTrue)
protected boolean isToPrint()
protected void setToPrint(boolean isToPrint)
protected boolean isReprinted()
protected void setReprinted(boolean isReprinted)
protected boolean isAlreadyPrinted()
protected void setAlreadyPrinted(boolean isAlreadyPrinted)
protected JRElement[] getGroupElements()
protected java.util.Collection getDependantElements()
protected void addDependantElement(JRElement element)
protected int getRelativeY()
protected void setRelativeY(int relativeY)
protected int getStretchHeight()
protected void setStretchHeight(int stretchHeight)
protected JRFillBand getBand()
protected void setBand(JRFillBand band)
protected void reset()
protected void setCurrentEvaluation(byte evaluation)
protected abstract void evaluate(byte evaluation)
throws JRException
JRException
protected void evaluatePrintWhenExpression(byte evaluation)
throws JRException
JRException
protected abstract void rewind()
throws JRException
JRException
protected abstract JRPrintElement fill()
throws JRException
JRExceptionprotected JRTemplateElement getElementTemplate()
protected abstract JRTemplateElement createElementTemplate()
protected boolean prepare(int availableHeight,
boolean isOverflow)
throws JRException
JRExceptionprotected void stretchElement(int bandStretch)
protected void moveDependantElements()
protected abstract void resolveElement(JRPrintElement element,
byte evaluation)
throws JRException
element - the elementevaluation - the evaluation type
JRException
protected void performDelayedEvaluation(JRPrintElement element,
byte evaluation)
throws JRException
JRException
public final java.lang.Object evaluateExpression(JRExpression expression,
byte evaluation)
throws JRException
expression - the expressionevaluation - the evaluation type
JRExceptionprotected boolean isValueRepeating()
Dynamic elements should call setValueRepeating(boolean) on
evaluate(byte). Static elements don't have to do anything, this method
will return true by default.
setValueRepeating(boolean)protected void setValueRepeating(boolean isValueRepeating)
This method should be called by dynamic elements on evaluate(byte).
isValueRepeating - whether the value of the element is repeatingisValueRepeating()protected JRFillVariable getVariable(java.lang.String variableName)
protected JRFillField getField(java.lang.String fieldName)
protected EvaluationTimeEnum getEvaluationTimeValue()
protected void resolveElement(JRPrintElement element,
byte evaluation,
JREvaluationTime evaluationTime)
throws JRException
element - the elementevaluation - the evaluation typeevaluationTime - the current evaluation time
JRExceptionprotected void initDelayedEvaluations()
protected void collectDelayedEvaluations()
protected void collectStyleDelayedEvaluations()
protected void collectDelayedEvaluations(JRStyle style)
protected void collectDelayedEvaluations(JRExpression expression)
protected void initDelayedEvaluationPrint(JRRecordedValuesPrintElement printElement)
throws JRException
JRException
protected void delayedEvaluate(JRRecordedValuesPrintElement printElement,
JREvaluationTime evaluationTime,
byte evaluation)
throws JRException
JRExceptionprotected void setConditionalStylesContainer(JRFillElementContainer conditionalStylesContainer)
public JRStyle getStyle()
JRStyleContainer
getStyle in interface JRStyleContainerprotected JRTemplateElement getTemplate(JRStyle style)
protected void registerTemplate(JRStyle style,
JRTemplateElement template)
protected final void setShrinkable(boolean shrinkable)
This flag is only effective when isRemoveLineWhenBlank is also set.
shrinkable - whether the element is shrinkableprotected void stretchHeightFinal()
protected boolean isEvaluateNow()
protected boolean isAutoEvaluateNow()
protected boolean isEvaluateAuto()
public java.lang.String getStyleNameReference()
JRStyleContainertemplates and are resolved
at fill time.
This attribute is only effective if no direct style (as returned by getStyle()
is specified for this object.
getStyleNameReference in interface JRStyleContainerpublic void setStyle(JRStyle style)
JRStyleSetter
setStyle in interface JRStyleSetterstyle - the style to be used by the objectpublic void setStyleNameReference(java.lang.String name)
JRStyleSetter
setStyleNameReference in interface JRStyleSettername - the name of an external stylepublic java.lang.Object clone()
clone in interface JRCloneableclone in class java.lang.Objectpublic java.lang.Object clone(JRElementGroup parentGroup)
clone in interface JRChildpublic boolean hasProperties()
JRPropertiesHolder
hasProperties in interface JRPropertiesHolderpublic JRPropertiesMap getPropertiesMap()
JRPropertiesHolder
getPropertiesMap in interface JRPropertiesHolderpublic JRPropertiesHolder getParentProperties()
JRPropertiesHolder
getParentProperties in interface JRPropertiesHoldernull if no parentpublic JRPropertyExpression[] getPropertyExpressions()
JRElement
getPropertyExpressions in interface JRElementprotected void transferProperties(JRTemplateElement template)
protected void transferProperties(JRPrintElement element)
protected JRPropertiesMap getEvaluatedProperties()
protected void evaluateProperties(byte evaluation)
throws JRException
JRExceptionprotected void setOriginProvider(JROriginProvider originProvider)
protected JROrigin getElementOrigin()
protected boolean isDelayedStyleEvaluation()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||