|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.pentaho.reporting.engine.classic.core.function.AbstractExpression
org.pentaho.reporting.engine.classic.core.function.AbstractFunction
org.pentaho.reporting.engine.classic.core.function.ItemHideFunction
public class ItemHideFunction
The ItemHideFunction hides equal values in a group. Only the first changed value is printed. This function uses the
property element to define the name of the element in the ItemBand that should be made visible or
invisible by this function. The property field defines the field in the datasource or the expression
which should be used to determine the visibility.
=NOT(ISCHANGED("fieldname")). In addition to the simple case, this function behaves special on
pagebreaks and intermediate group changes.
| Constructor Summary | |
|---|---|
ItemHideFunction()
Constructs an unnamed function. |
|
ItemHideFunction(String name)
Constructs a named function. |
|
| Method Summary | |
|---|---|
String |
getElement()
Returns the name of the element in the item band that should be set visible/invisible. |
String |
getField()
Returns the field used by the function. |
Expression |
getInstance()
Return a completly separated copy of this function. |
Object |
getValue()
Returns the function value, in this case the visibility of the defined element. |
boolean |
isIgnoreGroupBreaks()
Returns whether a group start resets the visiblity of the element. |
boolean |
isIgnorePageBreaks()
Returns whether a page start resets the visiblity of the element. |
void |
itemsAdvanced(ReportEvent event)
Receives notification that a row of data is being processed. |
void |
itemsStarted(ReportEvent event)
Resets the state of the function when a new ItemGroup has started. |
void |
pageFinished(ReportEvent event)
Receives notification that a page is completed. |
void |
pageStarted(ReportEvent event)
Receives notification that a new page is being started. |
void |
reportInitialized(ReportEvent event)
Receives notification that the report has started. |
void |
setElement(String name)
Sets the name of the element in the item band that should be set visible/invisible. |
void |
setField(String field)
Sets the field name for the function. |
void |
setIgnoreGroupBreaks(boolean ignoreGroupBreaks)
Defines whether a group start resets the visiblity of the element. |
void |
setIgnorePageBreaks(boolean ignorePageBreaks)
Returns whether a page start resets the visiblity of the element. |
| Methods inherited from class org.pentaho.reporting.engine.classic.core.function.AbstractFunction |
|---|
groupFinished, groupStarted, itemsFinished, reportDone, reportFinished, reportStarted |
| Methods inherited from class org.pentaho.reporting.engine.classic.core.function.AbstractExpression |
|---|
clone, getDataRow, getDependencyLevel, getName, getReportConfiguration, getResourceBundleFactory, getRuntime, isActive, isDeepTraversing, isPreserve, setActive, setDependencyLevel, setName, setPreserve, setRuntime |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.pentaho.reporting.engine.classic.core.event.ReportListener |
|---|
groupFinished, groupStarted, itemsFinished, reportDone, reportFinished, reportStarted |
| Methods inherited from interface org.pentaho.reporting.engine.classic.core.function.Expression |
|---|
clone, getDataRow, getDependencyLevel, getName, getReportConfiguration, getResourceBundleFactory, getRuntime, isActive, isDeepTraversing, isPreserve, setDependencyLevel, setName, setRuntime |
| Constructor Detail |
|---|
public ItemHideFunction()
Make sure to set the function name before it is used, or function initialisation will fail.
public ItemHideFunction(String name)
The field must be defined before using the function.
name - The function name.| Method Detail |
|---|
public boolean isIgnoreGroupBreaks()
public void setIgnoreGroupBreaks(boolean ignoreGroupBreaks)
ignoreGroupBreaks - false, if group breaks reset the visiblity, true otherwise.public boolean isIgnorePageBreaks()
public void setIgnorePageBreaks(boolean ignorePageBreaks)
ignorePageBreaks - false, if page breaks reset the visiblity, true otherwise.public String getElement()
public void setElement(String name)
name - the element name (must not be null).public String getField()
public void setField(String field)
field - the field name.public void itemsAdvanced(ReportEvent event)
itemsAdvanced in interface ReportListeneritemsAdvanced in class AbstractFunctionevent - Information about the event.public void itemsStarted(ReportEvent event)
itemsStarted in interface ReportListeneritemsStarted in class AbstractFunctionevent - the report event.public Object getValue()
getValue in interface Expressionpublic void pageFinished(ReportEvent event)
pageFinished in interface PageEventListenerevent - The event.public void pageStarted(ReportEvent event)
pageStarted in interface PageEventListenerevent - The event.public Expression getInstance()
getInstance in interface ExpressiongetInstance in class AbstractExpressionpublic void reportInitialized(ReportEvent event)
reportInitialized in interface ReportListenerreportInitialized in class AbstractFunctionevent - the event.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||