first commit
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import net.sf.jasperreports.engine.fill.JRBaseFiller;
|
||||
import net.sf.jasperreports.engine.fill.JRFillChart;
|
||||
import net.sf.jasperreports.engine.fill.JRFillChartDataset;
|
||||
|
||||
public abstract class JRAbstractChartCustomizer implements JRChartCustomizer {
|
||||
private JRBaseFiller filler;
|
||||
|
||||
private JRFillChartDataset chartDataset;
|
||||
|
||||
public void init(JRBaseFiller chartFiller, JRFillChart chart) {
|
||||
this.filler = chartFiller;
|
||||
this.chartDataset = (JRFillChartDataset)chart.getDataset();
|
||||
}
|
||||
|
||||
protected final Object getParameterValue(String parameterName) {
|
||||
return getParameterValue(parameterName, false);
|
||||
}
|
||||
|
||||
protected final Object getParameterValue(String parameterName, boolean fromInputDataset) {
|
||||
return (fromInputDataset ? this.chartDataset.getInputDataset() : this.filler.getMainDataset()).getParameterValue(parameterName);
|
||||
}
|
||||
|
||||
protected final Object getVariableValue(String variableName) {
|
||||
return getVariableValue(variableName, false);
|
||||
}
|
||||
|
||||
protected final Object getVariableValue(String variableName, boolean fromInputDataset) {
|
||||
return (fromInputDataset ? this.chartDataset.getInputDataset() : this.filler.getMainDataset()).getVariableValue(variableName);
|
||||
}
|
||||
|
||||
protected final Object getFieldValue(String fieldName) {
|
||||
return getFieldValue(fieldName, false);
|
||||
}
|
||||
|
||||
protected final Object getFieldValue(String fieldName, boolean fromInputDataset) {
|
||||
return (fromInputDataset ? this.chartDataset.getInputDataset() : this.filler.getMainDataset()).getFieldValue(fieldName);
|
||||
}
|
||||
}
|
@@ -0,0 +1,95 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import net.sf.jasperreports.charts.JRAreaPlot;
|
||||
import net.sf.jasperreports.charts.JRBar3DPlot;
|
||||
import net.sf.jasperreports.charts.JRBarPlot;
|
||||
import net.sf.jasperreports.charts.JRBubblePlot;
|
||||
import net.sf.jasperreports.charts.JRCandlestickPlot;
|
||||
import net.sf.jasperreports.charts.JRCategoryDataset;
|
||||
import net.sf.jasperreports.charts.JRCategorySeries;
|
||||
import net.sf.jasperreports.charts.JRLinePlot;
|
||||
import net.sf.jasperreports.charts.JRPie3DPlot;
|
||||
import net.sf.jasperreports.charts.JRPieDataset;
|
||||
import net.sf.jasperreports.charts.JRPiePlot;
|
||||
import net.sf.jasperreports.charts.JRTimePeriodDataset;
|
||||
import net.sf.jasperreports.charts.JRTimePeriodSeries;
|
||||
import net.sf.jasperreports.charts.JRTimeSeries;
|
||||
import net.sf.jasperreports.charts.JRTimeSeriesDataset;
|
||||
import net.sf.jasperreports.charts.JRXyzDataset;
|
||||
import net.sf.jasperreports.charts.JRXyzSeries;
|
||||
|
||||
public abstract class JRAbstractObjectFactory implements JRVisitor {
|
||||
private Map objectsMap = new HashMap();
|
||||
|
||||
private Object visitResult = null;
|
||||
|
||||
protected Object get(Object object) {
|
||||
return this.objectsMap.get(object);
|
||||
}
|
||||
|
||||
public void put(Object object, Object copy) {
|
||||
this.objectsMap.put(object, copy);
|
||||
}
|
||||
|
||||
public Object getVisitResult(JRVisitable visitable) {
|
||||
if (visitable != null) {
|
||||
visitable.visit(this);
|
||||
return this.visitResult;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
protected void setVisitResult(Object visitResult) {
|
||||
this.visitResult = visitResult;
|
||||
}
|
||||
|
||||
public abstract JRReportFont getReportFont(JRReportFont paramJRReportFont);
|
||||
|
||||
public abstract JRStyle getStyle(JRStyle paramJRStyle);
|
||||
|
||||
public abstract void setStyle(JRStyleSetter paramJRStyleSetter, JRStyleContainer paramJRStyleContainer);
|
||||
|
||||
public abstract JRPieDataset getPieDataset(JRPieDataset paramJRPieDataset);
|
||||
|
||||
public abstract JRPiePlot getPiePlot(JRPiePlot paramJRPiePlot);
|
||||
|
||||
public abstract JRPie3DPlot getPie3DPlot(JRPie3DPlot paramJRPie3DPlot);
|
||||
|
||||
public abstract JRCategoryDataset getCategoryDataset(JRCategoryDataset paramJRCategoryDataset);
|
||||
|
||||
public abstract JRTimeSeriesDataset getTimeSeriesDataset(JRTimeSeriesDataset paramJRTimeSeriesDataset);
|
||||
|
||||
public abstract JRTimePeriodDataset getTimePeriodDataset(JRTimePeriodDataset paramJRTimePeriodDataset);
|
||||
|
||||
public abstract JRTimePeriodSeries getTimePeriodSeries(JRTimePeriodSeries paramJRTimePeriodSeries);
|
||||
|
||||
public abstract JRTimeSeries getTimeSeries(JRTimeSeries paramJRTimeSeries);
|
||||
|
||||
public abstract JRCategorySeries getCategorySeries(JRCategorySeries paramJRCategorySeries);
|
||||
|
||||
public abstract JRXyzDataset getXyzDataset(JRXyzDataset paramJRXyzDataset);
|
||||
|
||||
public abstract JRXyzSeries getXyzSeries(JRXyzSeries paramJRXyzSeries);
|
||||
|
||||
public abstract JRBarPlot getBarPlot(JRBarPlot paramJRBarPlot);
|
||||
|
||||
public abstract JRBar3DPlot getBar3DPlot(JRBar3DPlot paramJRBar3DPlot);
|
||||
|
||||
public abstract JRLinePlot getLinePlot(JRLinePlot paramJRLinePlot);
|
||||
|
||||
public abstract JRAreaPlot getAreaPlot(JRAreaPlot paramJRAreaPlot);
|
||||
|
||||
public abstract JRBubblePlot getBubblePlot(JRBubblePlot paramJRBubblePlot);
|
||||
|
||||
public abstract JRCandlestickPlot getCandlestickPlot(JRCandlestickPlot paramJRCandlestickPlot);
|
||||
|
||||
public abstract JRConditionalStyle getConditionalStyle(JRConditionalStyle paramJRConditionalStyle, JRStyle paramJRStyle);
|
||||
|
||||
public abstract JRExpression getExpression(JRExpression paramJRExpression, boolean paramBoolean);
|
||||
|
||||
public JRExpression getExpression(JRExpression expression) {
|
||||
return getExpression(expression, false);
|
||||
}
|
||||
}
|
15
hrmsEjb/net/sf/jasperreports/engine/JRAbstractRenderer.java
Normal file
15
hrmsEjb/net/sf/jasperreports/engine/JRAbstractRenderer.java
Normal file
@@ -0,0 +1,15 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public abstract class JRAbstractRenderer implements JRRenderable {
|
||||
private static final long serialVersionUID = 10200L;
|
||||
|
||||
private String id = null;
|
||||
|
||||
public JRAbstractRenderer() {
|
||||
this.id = System.currentTimeMillis() + "-" + Math.random();
|
||||
}
|
||||
|
||||
public String getId() {
|
||||
return this.id;
|
||||
}
|
||||
}
|
140
hrmsEjb/net/sf/jasperreports/engine/JRAbstractScriptlet.java
Normal file
140
hrmsEjb/net/sf/jasperreports/engine/JRAbstractScriptlet.java
Normal file
@@ -0,0 +1,140 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.util.Map;
|
||||
import net.sf.jasperreports.engine.fill.JRFillField;
|
||||
import net.sf.jasperreports.engine.fill.JRFillGroup;
|
||||
import net.sf.jasperreports.engine.fill.JRFillParameter;
|
||||
import net.sf.jasperreports.engine.fill.JRFillVariable;
|
||||
|
||||
public abstract class JRAbstractScriptlet {
|
||||
protected Map parametersMap = null;
|
||||
|
||||
protected Map fieldsMap = null;
|
||||
|
||||
protected Map variablesMap = null;
|
||||
|
||||
protected JRFillGroup[] groups = null;
|
||||
|
||||
public void setData(Map parsm, Map fldsm, Map varsm, JRFillGroup[] grps) {
|
||||
this.parametersMap = parsm;
|
||||
this.fieldsMap = fldsm;
|
||||
this.variablesMap = varsm;
|
||||
this.groups = grps;
|
||||
}
|
||||
|
||||
public Object getParameterValue(String parameterName) throws JRScriptletException {
|
||||
JRFillParameter parameter = (JRFillParameter)this.parametersMap.get(parameterName);
|
||||
if (parameter == null)
|
||||
throw new JRScriptletException("Parameter not found : " + parameterName);
|
||||
return parameter.getValue();
|
||||
}
|
||||
|
||||
public Object getFieldValue(String fieldName) throws JRScriptletException {
|
||||
JRFillField field = (JRFillField)this.fieldsMap.get(fieldName);
|
||||
if (field == null)
|
||||
throw new JRScriptletException("Field not found : " + fieldName);
|
||||
return field.getValue();
|
||||
}
|
||||
|
||||
public Object getVariableValue(String variableName) throws JRScriptletException {
|
||||
JRFillVariable variable = (JRFillVariable)this.variablesMap.get(variableName);
|
||||
if (variable == null)
|
||||
throw new JRScriptletException("Variable not found : " + variableName);
|
||||
return variable.getValue();
|
||||
}
|
||||
|
||||
public void setVariableValue(String variableName, Object value) throws JRScriptletException {
|
||||
JRFillVariable variable = (JRFillVariable)this.variablesMap.get(variableName);
|
||||
if (variable == null)
|
||||
throw new JRScriptletException("Variable not found : " + variableName);
|
||||
if (value != null && !variable.getValueClass().isInstance(value))
|
||||
throw new JRScriptletException("Incompatible value assigned to variable " + variableName + ". Expected " + variable.getValueClassName() + ".");
|
||||
variable.setValue(value);
|
||||
}
|
||||
|
||||
public void callBeforeReportInit() throws JRScriptletException {
|
||||
beforeReportInit();
|
||||
beforePageInit();
|
||||
beforeColumnInit();
|
||||
if (this.groups != null && this.groups.length > 0)
|
||||
for (int i = 0; i < this.groups.length; i++)
|
||||
beforeGroupInit(this.groups[i].getName());
|
||||
}
|
||||
|
||||
public void callAfterReportInit() throws JRScriptletException {
|
||||
if (this.groups != null && this.groups.length > 0)
|
||||
for (int i = this.groups.length - 1; i >= 0; i--)
|
||||
afterGroupInit(this.groups[i].getName());
|
||||
afterColumnInit();
|
||||
afterPageInit();
|
||||
afterReportInit();
|
||||
}
|
||||
|
||||
public void callBeforePageInit() throws JRScriptletException {
|
||||
beforePageInit();
|
||||
beforeColumnInit();
|
||||
}
|
||||
|
||||
public void callAfterPageInit() throws JRScriptletException {
|
||||
afterColumnInit();
|
||||
afterPageInit();
|
||||
}
|
||||
|
||||
public void callBeforeColumnInit() throws JRScriptletException {
|
||||
beforeColumnInit();
|
||||
}
|
||||
|
||||
public void callAfterColumnInit() throws JRScriptletException {
|
||||
afterColumnInit();
|
||||
}
|
||||
|
||||
public void callBeforeGroupInit() throws JRScriptletException {
|
||||
if (this.groups != null && this.groups.length > 0) {
|
||||
JRFillGroup group = null;
|
||||
for (int i = 0; i < this.groups.length; i++) {
|
||||
group = this.groups[i];
|
||||
if (group.hasChanged())
|
||||
beforeGroupInit(group.getName());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void callAfterGroupInit() throws JRScriptletException {
|
||||
if (this.groups != null && this.groups.length > 0) {
|
||||
JRFillGroup group = null;
|
||||
for (int i = this.groups.length - 1; i >= 0; i--) {
|
||||
group = this.groups[i];
|
||||
if (group.hasChanged())
|
||||
afterGroupInit(group.getName());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void callBeforeDetailEval() throws JRScriptletException {
|
||||
beforeDetailEval();
|
||||
}
|
||||
|
||||
public void callAfterDetailEval() throws JRScriptletException {
|
||||
afterDetailEval();
|
||||
}
|
||||
|
||||
public abstract void beforeReportInit() throws JRScriptletException;
|
||||
|
||||
public abstract void afterReportInit() throws JRScriptletException;
|
||||
|
||||
public abstract void beforePageInit() throws JRScriptletException;
|
||||
|
||||
public abstract void afterPageInit() throws JRScriptletException;
|
||||
|
||||
public abstract void beforeColumnInit() throws JRScriptletException;
|
||||
|
||||
public abstract void afterColumnInit() throws JRScriptletException;
|
||||
|
||||
public abstract void beforeGroupInit(String paramString) throws JRScriptletException;
|
||||
|
||||
public abstract void afterGroupInit(String paramString) throws JRScriptletException;
|
||||
|
||||
public abstract void beforeDetailEval() throws JRScriptletException;
|
||||
|
||||
public abstract void afterDetailEval() throws JRScriptletException;
|
||||
}
|
35
hrmsEjb/net/sf/jasperreports/engine/JRAlignment.java
Normal file
35
hrmsEjb/net/sf/jasperreports/engine/JRAlignment.java
Normal file
@@ -0,0 +1,35 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRAlignment extends JRStyleContainer {
|
||||
public static final byte HORIZONTAL_ALIGN_LEFT = 1;
|
||||
|
||||
public static final byte HORIZONTAL_ALIGN_CENTER = 2;
|
||||
|
||||
public static final byte HORIZONTAL_ALIGN_RIGHT = 3;
|
||||
|
||||
public static final byte HORIZONTAL_ALIGN_JUSTIFIED = 4;
|
||||
|
||||
public static final byte VERTICAL_ALIGN_TOP = 1;
|
||||
|
||||
public static final byte VERTICAL_ALIGN_MIDDLE = 2;
|
||||
|
||||
public static final byte VERTICAL_ALIGN_BOTTOM = 3;
|
||||
|
||||
public static final byte VERTICAL_ALIGN_JUSTIFIED = 4;
|
||||
|
||||
byte getHorizontalAlignment();
|
||||
|
||||
Byte getOwnHorizontalAlignment();
|
||||
|
||||
void setHorizontalAlignment(byte paramByte);
|
||||
|
||||
void setHorizontalAlignment(Byte paramByte);
|
||||
|
||||
byte getVerticalAlignment();
|
||||
|
||||
Byte getOwnVerticalAlignment();
|
||||
|
||||
void setVerticalAlignment(byte paramByte);
|
||||
|
||||
void setVerticalAlignment(Byte paramByte);
|
||||
}
|
9
hrmsEjb/net/sf/jasperreports/engine/JRAnchor.java
Normal file
9
hrmsEjb/net/sf/jasperreports/engine/JRAnchor.java
Normal file
@@ -0,0 +1,9 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRAnchor {
|
||||
public static final int NO_BOOKMARK = 0;
|
||||
|
||||
JRExpression getAnchorNameExpression();
|
||||
|
||||
int getBookmarkLevel();
|
||||
}
|
11
hrmsEjb/net/sf/jasperreports/engine/JRBand.java
Normal file
11
hrmsEjb/net/sf/jasperreports/engine/JRBand.java
Normal file
@@ -0,0 +1,11 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRBand extends JRElementGroup {
|
||||
int getHeight();
|
||||
|
||||
boolean isSplitAllowed();
|
||||
|
||||
void setSplitAllowed(boolean paramBoolean);
|
||||
|
||||
JRExpression getPrintWhenExpression();
|
||||
}
|
115
hrmsEjb/net/sf/jasperreports/engine/JRBox.java
Normal file
115
hrmsEjb/net/sf/jasperreports/engine/JRBox.java
Normal file
@@ -0,0 +1,115 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.Color;
|
||||
|
||||
public interface JRBox extends JRStyleContainer {
|
||||
byte getBorder();
|
||||
|
||||
Byte getOwnBorder();
|
||||
|
||||
void setBorder(byte paramByte);
|
||||
|
||||
void setBorder(Byte paramByte);
|
||||
|
||||
Color getBorderColor();
|
||||
|
||||
Color getOwnBorderColor();
|
||||
|
||||
void setBorderColor(Color paramColor);
|
||||
|
||||
int getPadding();
|
||||
|
||||
Integer getOwnPadding();
|
||||
|
||||
void setPadding(int paramInt);
|
||||
|
||||
void setPadding(Integer paramInteger);
|
||||
|
||||
byte getTopBorder();
|
||||
|
||||
Byte getOwnTopBorder();
|
||||
|
||||
void setTopBorder(byte paramByte);
|
||||
|
||||
void setTopBorder(Byte paramByte);
|
||||
|
||||
Color getTopBorderColor();
|
||||
|
||||
Color getOwnTopBorderColor();
|
||||
|
||||
void setTopBorderColor(Color paramColor);
|
||||
|
||||
int getTopPadding();
|
||||
|
||||
Integer getOwnTopPadding();
|
||||
|
||||
void setTopPadding(int paramInt);
|
||||
|
||||
void setTopPadding(Integer paramInteger);
|
||||
|
||||
byte getLeftBorder();
|
||||
|
||||
Byte getOwnLeftBorder();
|
||||
|
||||
void setLeftBorder(byte paramByte);
|
||||
|
||||
void setLeftBorder(Byte paramByte);
|
||||
|
||||
Color getLeftBorderColor();
|
||||
|
||||
Color getOwnLeftBorderColor();
|
||||
|
||||
void setLeftBorderColor(Color paramColor);
|
||||
|
||||
int getLeftPadding();
|
||||
|
||||
Integer getOwnLeftPadding();
|
||||
|
||||
void setLeftPadding(int paramInt);
|
||||
|
||||
void setLeftPadding(Integer paramInteger);
|
||||
|
||||
byte getBottomBorder();
|
||||
|
||||
Byte getOwnBottomBorder();
|
||||
|
||||
void setBottomBorder(byte paramByte);
|
||||
|
||||
void setBottomBorder(Byte paramByte);
|
||||
|
||||
Color getBottomBorderColor();
|
||||
|
||||
Color getOwnBottomBorderColor();
|
||||
|
||||
void setBottomBorderColor(Color paramColor);
|
||||
|
||||
int getBottomPadding();
|
||||
|
||||
Integer getOwnBottomPadding();
|
||||
|
||||
void setBottomPadding(int paramInt);
|
||||
|
||||
void setBottomPadding(Integer paramInteger);
|
||||
|
||||
byte getRightBorder();
|
||||
|
||||
Byte getOwnRightBorder();
|
||||
|
||||
void setRightBorder(byte paramByte);
|
||||
|
||||
void setRightBorder(Byte paramByte);
|
||||
|
||||
Color getRightBorderColor();
|
||||
|
||||
Color getOwnRightBorderColor();
|
||||
|
||||
void setRightBorderColor(Color paramColor);
|
||||
|
||||
int getRightPadding();
|
||||
|
||||
Integer getOwnRightPadding();
|
||||
|
||||
void setRightPadding(int paramInt);
|
||||
|
||||
void setRightPadding(Integer paramInteger);
|
||||
}
|
9
hrmsEjb/net/sf/jasperreports/engine/JRBoxContainer.java
Normal file
9
hrmsEjb/net/sf/jasperreports/engine/JRBoxContainer.java
Normal file
@@ -0,0 +1,9 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.Color;
|
||||
|
||||
public interface JRBoxContainer extends JRStyleContainer {
|
||||
Color getDefaultLineColor();
|
||||
|
||||
JRLineBox getLineBox();
|
||||
}
|
11
hrmsEjb/net/sf/jasperreports/engine/JRBreak.java
Normal file
11
hrmsEjb/net/sf/jasperreports/engine/JRBreak.java
Normal file
@@ -0,0 +1,11 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRBreak extends JRElement {
|
||||
public static final byte TYPE_PAGE = 1;
|
||||
|
||||
public static final byte TYPE_COLUMN = 2;
|
||||
|
||||
byte getType();
|
||||
|
||||
void setType(byte paramByte);
|
||||
}
|
133
hrmsEjb/net/sf/jasperreports/engine/JRChart.java
Normal file
133
hrmsEjb/net/sf/jasperreports/engine/JRChart.java
Normal file
@@ -0,0 +1,133 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.Color;
|
||||
|
||||
public interface JRChart extends JRElement, JRAnchor, JRHyperlink, JRBox, JRBoxContainer {
|
||||
public static final String PROPERTY_CHART_RENDER_TYPE = "net.sf.jasperreports.chart.render.type";
|
||||
|
||||
public static final byte EDGE_TOP = 1;
|
||||
|
||||
public static final byte EDGE_BOTTOM = 2;
|
||||
|
||||
public static final byte EDGE_LEFT = 3;
|
||||
|
||||
public static final byte EDGE_RIGHT = 4;
|
||||
|
||||
public static final byte TITLE_POSITION_TOP = 1;
|
||||
|
||||
public static final byte TITLE_POSITION_BOTTOM = 2;
|
||||
|
||||
public static final byte TITLE_POSITION_LEFT = 3;
|
||||
|
||||
public static final byte TITLE_POSITION_RIGHT = 4;
|
||||
|
||||
public static final byte CHART_TYPE_AREA = 1;
|
||||
|
||||
public static final byte CHART_TYPE_BAR3D = 2;
|
||||
|
||||
public static final byte CHART_TYPE_BAR = 3;
|
||||
|
||||
public static final byte CHART_TYPE_BUBBLE = 4;
|
||||
|
||||
public static final byte CHART_TYPE_CANDLESTICK = 5;
|
||||
|
||||
public static final byte CHART_TYPE_HIGHLOW = 6;
|
||||
|
||||
public static final byte CHART_TYPE_LINE = 7;
|
||||
|
||||
public static final byte CHART_TYPE_PIE3D = 8;
|
||||
|
||||
public static final byte CHART_TYPE_PIE = 9;
|
||||
|
||||
public static final byte CHART_TYPE_SCATTER = 10;
|
||||
|
||||
public static final byte CHART_TYPE_STACKEDBAR3D = 11;
|
||||
|
||||
public static final byte CHART_TYPE_STACKEDBAR = 12;
|
||||
|
||||
public static final byte CHART_TYPE_XYAREA = 13;
|
||||
|
||||
public static final byte CHART_TYPE_XYBAR = 14;
|
||||
|
||||
public static final byte CHART_TYPE_XYLINE = 15;
|
||||
|
||||
public static final byte CHART_TYPE_TIMESERIES = 16;
|
||||
|
||||
public static final byte CHART_TYPE_METER = 17;
|
||||
|
||||
public static final byte CHART_TYPE_THERMOMETER = 18;
|
||||
|
||||
public static final byte CHART_TYPE_MULTI_AXIS = 19;
|
||||
|
||||
public static final byte CHART_TYPE_STACKEDAREA = 20;
|
||||
|
||||
public static final String RENDER_TYPE_DRAW = "draw";
|
||||
|
||||
public static final String RENDER_TYPE_IMAGE = "image";
|
||||
|
||||
public static final String RENDER_TYPE_SVG = "svg";
|
||||
|
||||
boolean isShowLegend();
|
||||
|
||||
void setShowLegend(boolean paramBoolean);
|
||||
|
||||
byte getEvaluationTime();
|
||||
|
||||
JRGroup getEvaluationGroup();
|
||||
|
||||
JRBox getBox();
|
||||
|
||||
JRExpression getTitleExpression();
|
||||
|
||||
JRFont getTitleFont();
|
||||
|
||||
byte getTitlePosition();
|
||||
|
||||
void setTitlePosition(byte paramByte);
|
||||
|
||||
Color getTitleColor();
|
||||
|
||||
Color getOwnTitleColor();
|
||||
|
||||
void setTitleColor(Color paramColor);
|
||||
|
||||
JRExpression getSubtitleExpression();
|
||||
|
||||
JRFont getSubtitleFont();
|
||||
|
||||
Color getSubtitleColor();
|
||||
|
||||
Color getOwnSubtitleColor();
|
||||
|
||||
void setSubtitleColor(Color paramColor);
|
||||
|
||||
Color getLegendColor();
|
||||
|
||||
Color getOwnLegendColor();
|
||||
|
||||
void setLegendColor(Color paramColor);
|
||||
|
||||
Color getOwnLegendBackgroundColor();
|
||||
|
||||
Color getLegendBackgroundColor();
|
||||
|
||||
void setLegendBackgroundColor(Color paramColor);
|
||||
|
||||
JRFont getLegendFont();
|
||||
|
||||
byte getLegendPosition();
|
||||
|
||||
void setLegendPosition(byte paramByte);
|
||||
|
||||
JRChartDataset getDataset();
|
||||
|
||||
JRChartPlot getPlot();
|
||||
|
||||
byte getChartType();
|
||||
|
||||
String getCustomizerClass();
|
||||
|
||||
String getRenderType();
|
||||
|
||||
void setRenderType(String paramString);
|
||||
}
|
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import org.jfree.chart.JFreeChart;
|
||||
|
||||
public interface JRChartCustomizer {
|
||||
void customize(JFreeChart paramJFreeChart, JRChart paramJRChart);
|
||||
}
|
25
hrmsEjb/net/sf/jasperreports/engine/JRChartDataset.java
Normal file
25
hrmsEjb/net/sf/jasperreports/engine/JRChartDataset.java
Normal file
@@ -0,0 +1,25 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import net.sf.jasperreports.engine.design.JRVerifier;
|
||||
|
||||
public interface JRChartDataset extends JRElementDataset {
|
||||
public static final byte PIE_DATASET = 1;
|
||||
|
||||
public static final byte CATEGORY_DATASET = 2;
|
||||
|
||||
public static final byte XY_DATASET = 3;
|
||||
|
||||
public static final byte XYZ_DATASET = 4;
|
||||
|
||||
public static final byte TIMEPERIOD_DATASET = 5;
|
||||
|
||||
public static final byte TIMESERIES_DATASET = 6;
|
||||
|
||||
public static final byte HIGHLOW_DATASET = 7;
|
||||
|
||||
public static final byte VALUE_DATASET = 8;
|
||||
|
||||
byte getDatasetType();
|
||||
|
||||
void validate(JRVerifier paramJRVerifier);
|
||||
}
|
50
hrmsEjb/net/sf/jasperreports/engine/JRChartPlot.java
Normal file
50
hrmsEjb/net/sf/jasperreports/engine/JRChartPlot.java
Normal file
@@ -0,0 +1,50 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.Color;
|
||||
import java.util.Collection;
|
||||
import java.util.SortedSet;
|
||||
import org.jfree.chart.plot.PlotOrientation;
|
||||
|
||||
public interface JRChartPlot {
|
||||
JRChart getChart();
|
||||
|
||||
Color getBackcolor();
|
||||
|
||||
Color getOwnBackcolor();
|
||||
|
||||
void setBackcolor(Color paramColor);
|
||||
|
||||
PlotOrientation getOrientation();
|
||||
|
||||
void setOrientation(PlotOrientation paramPlotOrientation);
|
||||
|
||||
float getBackgroundAlpha();
|
||||
|
||||
void setBackgroundAlpha(float paramFloat);
|
||||
|
||||
float getForegroundAlpha();
|
||||
|
||||
void setForegroundAlpha(float paramFloat);
|
||||
|
||||
double getLabelRotation();
|
||||
|
||||
void setLabelRotation(double paramDouble);
|
||||
|
||||
SortedSet getSeriesColors();
|
||||
|
||||
void clearSeriesColors();
|
||||
|
||||
void addSeriesColor(JRSeriesColor paramJRSeriesColor);
|
||||
|
||||
void setSeriesColors(Collection paramCollection);
|
||||
|
||||
void collectExpressions(JRExpressionCollector paramJRExpressionCollector);
|
||||
|
||||
Object clone(JRChart paramJRChart);
|
||||
|
||||
public static interface JRSeriesColor extends JRCloneable {
|
||||
int getSeriesOrder();
|
||||
|
||||
Color getColor();
|
||||
}
|
||||
}
|
5
hrmsEjb/net/sf/jasperreports/engine/JRChild.java
Normal file
5
hrmsEjb/net/sf/jasperreports/engine/JRChild.java
Normal file
@@ -0,0 +1,5 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRChild extends JRVisitable, JRCloneable {
|
||||
Object clone(JRElementGroup paramJRElementGroup);
|
||||
}
|
5
hrmsEjb/net/sf/jasperreports/engine/JRCloneable.java
Normal file
5
hrmsEjb/net/sf/jasperreports/engine/JRCloneable.java
Normal file
@@ -0,0 +1,5 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRCloneable extends Cloneable {
|
||||
Object clone();
|
||||
}
|
19
hrmsEjb/net/sf/jasperreports/engine/JRCommonElement.java
Normal file
19
hrmsEjb/net/sf/jasperreports/engine/JRCommonElement.java
Normal file
@@ -0,0 +1,19 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.Color;
|
||||
|
||||
public interface JRCommonElement extends JRStyleContainer {
|
||||
String getKey();
|
||||
|
||||
byte getMode();
|
||||
|
||||
Byte getOwnMode();
|
||||
|
||||
Color getForecolor();
|
||||
|
||||
Color getOwnForecolor();
|
||||
|
||||
Color getBackcolor();
|
||||
|
||||
Color getOwnBackcolor();
|
||||
}
|
@@ -0,0 +1,9 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRCommonGraphicElement extends JRCommonElement, JRPenContainer {
|
||||
JRPen getLinePen();
|
||||
|
||||
byte getFill();
|
||||
|
||||
Byte getOwnFill();
|
||||
}
|
7
hrmsEjb/net/sf/jasperreports/engine/JRCommonImage.java
Normal file
7
hrmsEjb/net/sf/jasperreports/engine/JRCommonImage.java
Normal file
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRCommonImage extends JRCommonGraphicElement, JRBoxContainer {
|
||||
byte getScaleImage();
|
||||
|
||||
Byte getOwnScaleImage();
|
||||
}
|
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRCommonRectangle extends JRStyleContainer {
|
||||
int getRadius();
|
||||
|
||||
Integer getOwnRadius();
|
||||
}
|
33
hrmsEjb/net/sf/jasperreports/engine/JRCommonText.java
Normal file
33
hrmsEjb/net/sf/jasperreports/engine/JRCommonText.java
Normal file
@@ -0,0 +1,33 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRCommonText extends JRCommonElement, JRBoxContainer {
|
||||
public static final String MARKUP_NONE = "none";
|
||||
|
||||
public static final String MARKUP_STYLED_TEXT = "styled";
|
||||
|
||||
public static final String MARKUP_HTML = "html";
|
||||
|
||||
public static final String MARKUP_RTF = "rtf";
|
||||
|
||||
int getWidth();
|
||||
|
||||
int getHeight();
|
||||
|
||||
byte getRotation();
|
||||
|
||||
Byte getOwnRotation();
|
||||
|
||||
byte getLineSpacing();
|
||||
|
||||
Byte getOwnLineSpacing();
|
||||
|
||||
boolean isStyledText();
|
||||
|
||||
Boolean isOwnStyledText();
|
||||
|
||||
String getMarkup();
|
||||
|
||||
String getOwnMarkup();
|
||||
|
||||
int getFontSize();
|
||||
}
|
@@ -0,0 +1,5 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRConditionalStyle extends JRStyle {
|
||||
JRExpression getConditionExpression();
|
||||
}
|
7
hrmsEjb/net/sf/jasperreports/engine/JRDataSource.java
Normal file
7
hrmsEjb/net/sf/jasperreports/engine/JRDataSource.java
Normal file
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRDataSource {
|
||||
boolean next() throws JRException;
|
||||
|
||||
Object getFieldValue(JRField paramJRField) throws JRException;
|
||||
}
|
37
hrmsEjb/net/sf/jasperreports/engine/JRDataset.java
Normal file
37
hrmsEjb/net/sf/jasperreports/engine/JRDataset.java
Normal file
@@ -0,0 +1,37 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRDataset extends JRPropertiesHolder, JRCloneable {
|
||||
public static final byte WHEN_RESOURCE_MISSING_TYPE_NULL = 1;
|
||||
|
||||
public static final byte WHEN_RESOURCE_MISSING_TYPE_EMPTY = 2;
|
||||
|
||||
public static final byte WHEN_RESOURCE_MISSING_TYPE_KEY = 3;
|
||||
|
||||
public static final byte WHEN_RESOURCE_MISSING_TYPE_ERROR = 4;
|
||||
|
||||
String getName();
|
||||
|
||||
String getScriptletClass();
|
||||
|
||||
JRParameter[] getParameters();
|
||||
|
||||
JRQuery getQuery();
|
||||
|
||||
JRField[] getFields();
|
||||
|
||||
JRSortField[] getSortFields();
|
||||
|
||||
JRVariable[] getVariables();
|
||||
|
||||
JRGroup[] getGroups();
|
||||
|
||||
boolean isMainDataset();
|
||||
|
||||
String getResourceBundle();
|
||||
|
||||
byte getWhenResourceMissingType();
|
||||
|
||||
void setWhenResourceMissingType(byte paramByte);
|
||||
|
||||
JRExpression getFilterExpression();
|
||||
}
|
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRDatasetParameter extends JRCloneable {
|
||||
String getName();
|
||||
|
||||
JRExpression getExpression();
|
||||
}
|
13
hrmsEjb/net/sf/jasperreports/engine/JRDatasetRun.java
Normal file
13
hrmsEjb/net/sf/jasperreports/engine/JRDatasetRun.java
Normal file
@@ -0,0 +1,13 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRDatasetRun extends JRCloneable {
|
||||
String getDatasetName();
|
||||
|
||||
JRExpression getParametersMapExpression();
|
||||
|
||||
JRDatasetParameter[] getParameters();
|
||||
|
||||
JRExpression getConnectionExpression();
|
||||
|
||||
JRExpression getDataSourceExpression();
|
||||
}
|
@@ -0,0 +1,5 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRDefaultFontProvider {
|
||||
JRReportFont getDefaultFont();
|
||||
}
|
23
hrmsEjb/net/sf/jasperreports/engine/JRDefaultScriptlet.java
Normal file
23
hrmsEjb/net/sf/jasperreports/engine/JRDefaultScriptlet.java
Normal file
@@ -0,0 +1,23 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public class JRDefaultScriptlet extends JRAbstractScriptlet {
|
||||
public void beforeReportInit() throws JRScriptletException {}
|
||||
|
||||
public void afterReportInit() throws JRScriptletException {}
|
||||
|
||||
public void beforePageInit() throws JRScriptletException {}
|
||||
|
||||
public void afterPageInit() throws JRScriptletException {}
|
||||
|
||||
public void beforeColumnInit() throws JRScriptletException {}
|
||||
|
||||
public void afterColumnInit() throws JRScriptletException {}
|
||||
|
||||
public void beforeGroupInit(String groupName) throws JRScriptletException {}
|
||||
|
||||
public void afterGroupInit(String groupName) throws JRScriptletException {}
|
||||
|
||||
public void beforeDetailEval() throws JRScriptletException {}
|
||||
|
||||
public void afterDetailEval() throws JRScriptletException {}
|
||||
}
|
@@ -0,0 +1,5 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRDefaultStyleProvider extends JRDefaultFontProvider {
|
||||
JRStyle getDefaultStyle();
|
||||
}
|
77
hrmsEjb/net/sf/jasperreports/engine/JRElement.java
Normal file
77
hrmsEjb/net/sf/jasperreports/engine/JRElement.java
Normal file
@@ -0,0 +1,77 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.Color;
|
||||
|
||||
public interface JRElement extends JRChild, JRCommonElement, JRPropertiesHolder {
|
||||
public static final byte POSITION_TYPE_FLOAT = 1;
|
||||
|
||||
public static final byte POSITION_TYPE_FIX_RELATIVE_TO_TOP = 2;
|
||||
|
||||
public static final byte POSITION_TYPE_FIX_RELATIVE_TO_BOTTOM = 3;
|
||||
|
||||
public static final byte MODE_OPAQUE = 1;
|
||||
|
||||
public static final byte MODE_TRANSPARENT = 2;
|
||||
|
||||
public static final byte STRETCH_TYPE_NO_STRETCH = 0;
|
||||
|
||||
public static final byte STRETCH_TYPE_RELATIVE_TO_TALLEST_OBJECT = 1;
|
||||
|
||||
public static final byte STRETCH_TYPE_RELATIVE_TO_BAND_HEIGHT = 2;
|
||||
|
||||
String getKey();
|
||||
|
||||
byte getPositionType();
|
||||
|
||||
void setPositionType(byte paramByte);
|
||||
|
||||
byte getStretchType();
|
||||
|
||||
void setStretchType(byte paramByte);
|
||||
|
||||
boolean isPrintRepeatedValues();
|
||||
|
||||
void setPrintRepeatedValues(boolean paramBoolean);
|
||||
|
||||
void setMode(byte paramByte);
|
||||
|
||||
void setMode(Byte paramByte);
|
||||
|
||||
int getX();
|
||||
|
||||
void setX(int paramInt);
|
||||
|
||||
int getY();
|
||||
|
||||
int getWidth();
|
||||
|
||||
void setWidth(int paramInt);
|
||||
|
||||
int getHeight();
|
||||
|
||||
boolean isRemoveLineWhenBlank();
|
||||
|
||||
void setRemoveLineWhenBlank(boolean paramBoolean);
|
||||
|
||||
boolean isPrintInFirstWholeBand();
|
||||
|
||||
void setPrintInFirstWholeBand(boolean paramBoolean);
|
||||
|
||||
boolean isPrintWhenDetailOverflows();
|
||||
|
||||
void setPrintWhenDetailOverflows(boolean paramBoolean);
|
||||
|
||||
void setForecolor(Color paramColor);
|
||||
|
||||
void setBackcolor(Color paramColor);
|
||||
|
||||
JRExpression getPrintWhenExpression();
|
||||
|
||||
JRGroup getPrintWhenGroupChanges();
|
||||
|
||||
JRElementGroup getElementGroup();
|
||||
|
||||
void collectExpressions(JRExpressionCollector paramJRExpressionCollector);
|
||||
|
||||
JRPropertyExpression[] getPropertyExpressions();
|
||||
}
|
17
hrmsEjb/net/sf/jasperreports/engine/JRElementDataset.java
Normal file
17
hrmsEjb/net/sf/jasperreports/engine/JRElementDataset.java
Normal file
@@ -0,0 +1,17 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRElementDataset extends JRCloneable {
|
||||
byte getResetType();
|
||||
|
||||
JRGroup getResetGroup();
|
||||
|
||||
byte getIncrementType();
|
||||
|
||||
JRGroup getIncrementGroup();
|
||||
|
||||
void collectExpressions(JRExpressionCollector paramJRExpressionCollector);
|
||||
|
||||
JRDatasetRun getDatasetRun();
|
||||
|
||||
JRExpression getIncrementWhenExpression();
|
||||
}
|
13
hrmsEjb/net/sf/jasperreports/engine/JRElementGroup.java
Normal file
13
hrmsEjb/net/sf/jasperreports/engine/JRElementGroup.java
Normal file
@@ -0,0 +1,13 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface JRElementGroup extends JRChild {
|
||||
List getChildren();
|
||||
|
||||
JRElementGroup getElementGroup();
|
||||
|
||||
JRElement[] getElements();
|
||||
|
||||
JRElement getElementByKey(String paramString);
|
||||
}
|
3
hrmsEjb/net/sf/jasperreports/engine/JREllipse.java
Normal file
3
hrmsEjb/net/sf/jasperreports/engine/JREllipse.java
Normal file
@@ -0,0 +1,3 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JREllipse extends JRGraphicElement {}
|
17
hrmsEjb/net/sf/jasperreports/engine/JRException.java
Normal file
17
hrmsEjb/net/sf/jasperreports/engine/JRException.java
Normal file
@@ -0,0 +1,17 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public class JRException extends Exception {
|
||||
private static final long serialVersionUID = 10200L;
|
||||
|
||||
public JRException(String message) {
|
||||
super(message);
|
||||
}
|
||||
|
||||
public JRException(Throwable t) {
|
||||
super(t);
|
||||
}
|
||||
|
||||
public JRException(String message, Throwable t) {
|
||||
super(message, t);
|
||||
}
|
||||
}
|
35
hrmsEjb/net/sf/jasperreports/engine/JRExpression.java
Normal file
35
hrmsEjb/net/sf/jasperreports/engine/JRExpression.java
Normal file
@@ -0,0 +1,35 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRExpression extends JRCloneable {
|
||||
public static final byte EVALUATION_TIME_NOW = 1;
|
||||
|
||||
public static final byte EVALUATION_TIME_REPORT = 2;
|
||||
|
||||
public static final byte EVALUATION_TIME_PAGE = 3;
|
||||
|
||||
public static final byte EVALUATION_TIME_COLUMN = 4;
|
||||
|
||||
public static final byte EVALUATION_TIME_GROUP = 5;
|
||||
|
||||
public static final byte EVALUATION_TIME_BAND = 6;
|
||||
|
||||
public static final byte EVALUATION_TIME_AUTO = 7;
|
||||
|
||||
public static final byte EVALUATION_OLD = 1;
|
||||
|
||||
public static final byte EVALUATION_ESTIMATED = 2;
|
||||
|
||||
public static final byte EVALUATION_DEFAULT = 3;
|
||||
|
||||
public static final Integer NOT_USED_ID = new Integer(-1);
|
||||
|
||||
Class getValueClass();
|
||||
|
||||
String getValueClassName();
|
||||
|
||||
int getId();
|
||||
|
||||
JRExpressionChunk[] getChunks();
|
||||
|
||||
String getText();
|
||||
}
|
17
hrmsEjb/net/sf/jasperreports/engine/JRExpressionChunk.java
Normal file
17
hrmsEjb/net/sf/jasperreports/engine/JRExpressionChunk.java
Normal file
@@ -0,0 +1,17 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRExpressionChunk extends JRCloneable {
|
||||
public static final byte TYPE_TEXT = 1;
|
||||
|
||||
public static final byte TYPE_PARAMETER = 2;
|
||||
|
||||
public static final byte TYPE_FIELD = 3;
|
||||
|
||||
public static final byte TYPE_VARIABLE = 4;
|
||||
|
||||
public static final byte TYPE_RESOURCE = 5;
|
||||
|
||||
byte getType();
|
||||
|
||||
String getText();
|
||||
}
|
701
hrmsEjb/net/sf/jasperreports/engine/JRExpressionCollector.java
Normal file
701
hrmsEjb/net/sf/jasperreports/engine/JRExpressionCollector.java
Normal file
@@ -0,0 +1,701 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.HashMap;
|
||||
import java.util.HashSet;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
import java.util.TreeMap;
|
||||
import net.sf.jasperreports.charts.JRAreaPlot;
|
||||
import net.sf.jasperreports.charts.JRBar3DPlot;
|
||||
import net.sf.jasperreports.charts.JRBarPlot;
|
||||
import net.sf.jasperreports.charts.JRBubblePlot;
|
||||
import net.sf.jasperreports.charts.JRCandlestickPlot;
|
||||
import net.sf.jasperreports.charts.JRCategoryDataset;
|
||||
import net.sf.jasperreports.charts.JRCategorySeries;
|
||||
import net.sf.jasperreports.charts.JRDataRange;
|
||||
import net.sf.jasperreports.charts.JRHighLowDataset;
|
||||
import net.sf.jasperreports.charts.JRHighLowPlot;
|
||||
import net.sf.jasperreports.charts.JRLinePlot;
|
||||
import net.sf.jasperreports.charts.JRMeterPlot;
|
||||
import net.sf.jasperreports.charts.JRPieDataset;
|
||||
import net.sf.jasperreports.charts.JRScatterPlot;
|
||||
import net.sf.jasperreports.charts.JRThermometerPlot;
|
||||
import net.sf.jasperreports.charts.JRTimePeriodDataset;
|
||||
import net.sf.jasperreports.charts.JRTimePeriodSeries;
|
||||
import net.sf.jasperreports.charts.JRTimeSeries;
|
||||
import net.sf.jasperreports.charts.JRTimeSeriesDataset;
|
||||
import net.sf.jasperreports.charts.JRTimeSeriesPlot;
|
||||
import net.sf.jasperreports.charts.JRValueDataset;
|
||||
import net.sf.jasperreports.charts.JRXyDataset;
|
||||
import net.sf.jasperreports.charts.JRXySeries;
|
||||
import net.sf.jasperreports.charts.JRXyzDataset;
|
||||
import net.sf.jasperreports.charts.JRXyzSeries;
|
||||
import net.sf.jasperreports.charts.util.JRMeterInterval;
|
||||
import net.sf.jasperreports.crosstabs.JRCellContents;
|
||||
import net.sf.jasperreports.crosstabs.JRCrosstab;
|
||||
import net.sf.jasperreports.crosstabs.JRCrosstabBucket;
|
||||
import net.sf.jasperreports.crosstabs.JRCrosstabCell;
|
||||
import net.sf.jasperreports.crosstabs.JRCrosstabColumnGroup;
|
||||
import net.sf.jasperreports.crosstabs.JRCrosstabDataset;
|
||||
import net.sf.jasperreports.crosstabs.JRCrosstabMeasure;
|
||||
import net.sf.jasperreports.crosstabs.JRCrosstabParameter;
|
||||
import net.sf.jasperreports.crosstabs.JRCrosstabRowGroup;
|
||||
import net.sf.jasperreports.crosstabs.design.JRDesignCrosstab;
|
||||
|
||||
public class JRExpressionCollector {
|
||||
private final JRReport report;
|
||||
|
||||
private final JRExpressionCollector parent;
|
||||
|
||||
private Map expressionIds;
|
||||
|
||||
public static JRExpressionCollector collector(JRReport report) {
|
||||
JRExpressionCollector collector = new JRExpressionCollector(null, report);
|
||||
collector.collect();
|
||||
return collector;
|
||||
}
|
||||
|
||||
public static List collectExpressions(JRReport report) {
|
||||
return collector(report).getExpressions();
|
||||
}
|
||||
|
||||
public static JRExpressionCollector collector(JRReport report, JRCrosstab crosstab) {
|
||||
JRExpressionCollector collector = new JRExpressionCollector(null, report);
|
||||
collector.collect(crosstab);
|
||||
return collector;
|
||||
}
|
||||
|
||||
public static List collectExpressions(JRReport report, JRCrosstab crosstab) {
|
||||
return collector(report, crosstab).getExpressions(crosstab);
|
||||
}
|
||||
|
||||
protected static class GeneratedIds {
|
||||
private final TreeMap ids = new TreeMap();
|
||||
|
||||
private int nextId = 0;
|
||||
|
||||
private List expressions;
|
||||
|
||||
public JRExpression put(Integer id, JRExpression expression) {
|
||||
this.expressions = null;
|
||||
return this.ids.put(id, expression);
|
||||
}
|
||||
|
||||
public Integer nextId() {
|
||||
Integer id = new Integer(this.nextId);
|
||||
while (this.ids.containsKey(id))
|
||||
id = new Integer(++this.nextId);
|
||||
return id;
|
||||
}
|
||||
|
||||
public List expressions() {
|
||||
if (this.expressions == null)
|
||||
this.expressions = new ArrayList(this.ids.values());
|
||||
return this.expressions;
|
||||
}
|
||||
|
||||
public JRExpression expression(int id) {
|
||||
return (JRExpression)this.ids.get(new Integer(id));
|
||||
}
|
||||
}
|
||||
|
||||
private GeneratedIds generatedIds = new GeneratedIds();
|
||||
|
||||
private Map crosstabIds = new HashMap();
|
||||
|
||||
private Map datasetCollectors;
|
||||
|
||||
private Map crosstabCollectors;
|
||||
|
||||
private final Set collectedStyles;
|
||||
|
||||
protected JRExpressionCollector(JRExpressionCollector parent, JRReport report) {
|
||||
this.parent = parent;
|
||||
this.report = report;
|
||||
if (parent == null) {
|
||||
this.expressionIds = new HashMap();
|
||||
this.datasetCollectors = new HashMap();
|
||||
this.crosstabCollectors = new HashMap();
|
||||
} else {
|
||||
this.expressionIds = this.parent.expressionIds;
|
||||
}
|
||||
this.collectedStyles = new HashSet();
|
||||
}
|
||||
|
||||
private void addExpression(JRExpression expression) {
|
||||
if (expression != null) {
|
||||
Integer id = getExpressionId(expression);
|
||||
if (id == null) {
|
||||
id = this.generatedIds.nextId();
|
||||
setGeneratedId(expression, id);
|
||||
this.generatedIds.put(id, expression);
|
||||
} else {
|
||||
JRExpression existingExpression = this.generatedIds.put(id, expression);
|
||||
if (existingExpression != null && !existingExpression.equals(expression)) {
|
||||
Integer newId = this.generatedIds.nextId();
|
||||
updateGeneratedId(existingExpression, id, newId);
|
||||
this.generatedIds.put(newId, existingExpression);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void setGeneratedId(JRExpression expression, Integer id) {
|
||||
Object existingId = this.expressionIds.put(expression, id);
|
||||
if (existingId != null && !existingId.equals(id))
|
||||
throw new JRRuntimeException("Expression \"" + expression.getText() + "\" has two generated IDs");
|
||||
}
|
||||
|
||||
private void updateGeneratedId(JRExpression expression, Integer currentId, Integer newId) {
|
||||
Object existingId = this.expressionIds.put(expression, newId);
|
||||
if (existingId == null || !existingId.equals(currentId))
|
||||
throw new JRRuntimeException("Expression \"" + expression.getText() + "\" not found with id " + currentId);
|
||||
}
|
||||
|
||||
private JRExpressionCollector getCollector(JRElementDataset elementDataset) {
|
||||
JRExpressionCollector collector;
|
||||
JRDatasetRun datasetRun = elementDataset.getDatasetRun();
|
||||
if (datasetRun == null) {
|
||||
collector = this;
|
||||
} else {
|
||||
collector = getDatasetCollector(datasetRun.getDatasetName());
|
||||
}
|
||||
return collector;
|
||||
}
|
||||
|
||||
private JRExpressionCollector getDatasetCollector(String datasetName) {
|
||||
JRExpressionCollector collector = (JRExpressionCollector)this.datasetCollectors.get(datasetName);
|
||||
if (collector == null) {
|
||||
collector = new JRExpressionCollector(this, this.report);
|
||||
this.datasetCollectors.put(datasetName, collector);
|
||||
}
|
||||
return collector;
|
||||
}
|
||||
|
||||
public JRExpressionCollector getCollector(JRDataset dataset) {
|
||||
JRExpressionCollector collector;
|
||||
if (dataset.isMainDataset() || this.datasetCollectors == null) {
|
||||
collector = this;
|
||||
} else {
|
||||
collector = getDatasetCollector(dataset.getName());
|
||||
}
|
||||
return collector;
|
||||
}
|
||||
|
||||
public JRExpressionCollector getCollector(JRCrosstab crosstab) {
|
||||
JRExpressionCollector collector = (JRExpressionCollector)this.crosstabCollectors.get(crosstab);
|
||||
if (collector == null) {
|
||||
collector = new JRExpressionCollector(this, this.report);
|
||||
this.crosstabCollectors.put(crosstab, collector);
|
||||
}
|
||||
return collector;
|
||||
}
|
||||
|
||||
public List getExpressions() {
|
||||
return new ArrayList(this.generatedIds.expressions());
|
||||
}
|
||||
|
||||
public List getExpressions(JRDataset dataset) {
|
||||
return getCollector(dataset).getExpressions();
|
||||
}
|
||||
|
||||
public List getExpressions(JRCrosstab crosstab) {
|
||||
return getCollector(crosstab).getExpressions();
|
||||
}
|
||||
|
||||
public Integer getExpressionId(JRExpression expression) {
|
||||
return (Integer)this.expressionIds.get(expression);
|
||||
}
|
||||
|
||||
public JRExpression getExpression(int expressionId) {
|
||||
return this.generatedIds.expression(expressionId);
|
||||
}
|
||||
|
||||
public Integer getCrosstabId(JRCrosstab crosstab) {
|
||||
return (Integer)this.crosstabIds.get(crosstab);
|
||||
}
|
||||
|
||||
public Collection collect() {
|
||||
collectTemplates();
|
||||
collect(this.report.getDefaultStyle());
|
||||
collect(this.report.getMainDataset());
|
||||
JRDataset[] datasets = this.report.getDatasets();
|
||||
if (datasets != null && datasets.length > 0)
|
||||
for (int i = 0; i < datasets.length; i++) {
|
||||
JRExpressionCollector collector = getCollector(datasets[i]);
|
||||
collector.collect(datasets[i]);
|
||||
}
|
||||
collect(this.report.getBackground());
|
||||
collect(this.report.getTitle());
|
||||
collect(this.report.getPageHeader());
|
||||
collect(this.report.getColumnHeader());
|
||||
collect(this.report.getDetail());
|
||||
collect(this.report.getColumnFooter());
|
||||
collect(this.report.getPageFooter());
|
||||
collect(this.report.getLastPageFooter());
|
||||
collect(this.report.getSummary());
|
||||
collect(this.report.getNoData());
|
||||
return getExpressions();
|
||||
}
|
||||
|
||||
protected void collectTemplates() {
|
||||
JRReportTemplate[] templates = this.report.getTemplates();
|
||||
if (templates != null)
|
||||
for (int i = 0; i < templates.length; i++) {
|
||||
JRReportTemplate template = templates[i];
|
||||
collect(template);
|
||||
}
|
||||
}
|
||||
|
||||
protected void collect(JRReportTemplate template) {
|
||||
addExpression(template.getSourceExpression());
|
||||
}
|
||||
|
||||
private void collect(JRStyle style) {
|
||||
if (style != null && this.collectedStyles.add(style)) {
|
||||
JRConditionalStyle[] conditionalStyles = style.getConditionalStyles();
|
||||
if (conditionalStyles != null && conditionalStyles.length > 0)
|
||||
for (int i = 0; i < conditionalStyles.length; i++)
|
||||
addExpression(conditionalStyles[i].getConditionExpression());
|
||||
collect(style.getStyle());
|
||||
}
|
||||
}
|
||||
|
||||
private void collect(JRParameter[] parameters) {
|
||||
if (parameters != null && parameters.length > 0)
|
||||
for (int i = 0; i < parameters.length; i++)
|
||||
addExpression(parameters[i].getDefaultValueExpression());
|
||||
}
|
||||
|
||||
private void collect(JRVariable[] variables) {
|
||||
if (variables != null && variables.length > 0)
|
||||
for (int i = 0; i < variables.length; i++) {
|
||||
JRVariable variable = variables[i];
|
||||
addExpression(variable.getExpression());
|
||||
addExpression(variable.getInitialValueExpression());
|
||||
}
|
||||
}
|
||||
|
||||
private void collect(JRGroup[] groups) {
|
||||
if (groups != null && groups.length > 0)
|
||||
for (int i = 0; i < groups.length; i++) {
|
||||
JRGroup group = groups[i];
|
||||
addExpression(group.getExpression());
|
||||
collect(group.getGroupHeader());
|
||||
collect(group.getGroupFooter());
|
||||
}
|
||||
}
|
||||
|
||||
private void collect(JRBand band) {
|
||||
if (band != null) {
|
||||
addExpression(band.getPrintWhenExpression());
|
||||
JRElement[] elements = band.getElements();
|
||||
if (elements != null && elements.length > 0)
|
||||
for (int i = 0; i < elements.length; i++)
|
||||
elements[i].collectExpressions(this);
|
||||
}
|
||||
}
|
||||
|
||||
private void collectElement(JRElement element) {
|
||||
collect(element.getStyle());
|
||||
addExpression(element.getPrintWhenExpression());
|
||||
collectPropertyExpressions(element.getPropertyExpressions());
|
||||
}
|
||||
|
||||
protected void collectPropertyExpressions(JRPropertyExpression[] propertyExpressions) {
|
||||
if (propertyExpressions != null && propertyExpressions.length > 0)
|
||||
for (int i = 0; i < propertyExpressions.length; i++)
|
||||
collectPropertyExpression(propertyExpressions[i]);
|
||||
}
|
||||
|
||||
protected void collectPropertyExpression(JRPropertyExpression propertyExpression) {
|
||||
addExpression(propertyExpression.getValueExpression());
|
||||
}
|
||||
|
||||
private void collectAnchor(JRAnchor anchor) {
|
||||
addExpression(anchor.getAnchorNameExpression());
|
||||
}
|
||||
|
||||
private void collectHyperlink(JRHyperlink hyperlink) {
|
||||
if (hyperlink != null) {
|
||||
addExpression(hyperlink.getHyperlinkReferenceExpression());
|
||||
addExpression(hyperlink.getHyperlinkAnchorExpression());
|
||||
addExpression(hyperlink.getHyperlinkPageExpression());
|
||||
addExpression(hyperlink.getHyperlinkTooltipExpression());
|
||||
JRHyperlinkParameter[] hyperlinkParameters = hyperlink.getHyperlinkParameters();
|
||||
if (hyperlinkParameters != null)
|
||||
for (int i = 0; i < hyperlinkParameters.length; i++) {
|
||||
JRHyperlinkParameter parameter = hyperlinkParameters[i];
|
||||
collectHyperlinkParameter(parameter);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected void collectHyperlinkParameter(JRHyperlinkParameter parameter) {
|
||||
if (parameter != null)
|
||||
addExpression(parameter.getValueExpression());
|
||||
}
|
||||
|
||||
public void collect(JRBreak breakElement) {
|
||||
collectElement(breakElement);
|
||||
}
|
||||
|
||||
public void collect(JRLine line) {
|
||||
collectElement(line);
|
||||
}
|
||||
|
||||
public void collect(JRRectangle rectangle) {
|
||||
collectElement(rectangle);
|
||||
}
|
||||
|
||||
public void collect(JREllipse ellipse) {
|
||||
collectElement(ellipse);
|
||||
}
|
||||
|
||||
public void collect(JRImage image) {
|
||||
collectElement(image);
|
||||
addExpression(image.getExpression());
|
||||
collectAnchor(image);
|
||||
collectHyperlink(image);
|
||||
}
|
||||
|
||||
public void collect(JRStaticText staticText) {
|
||||
collectElement(staticText);
|
||||
}
|
||||
|
||||
public void collect(JRTextField textField) {
|
||||
collectElement(textField);
|
||||
addExpression(textField.getExpression());
|
||||
collectAnchor(textField);
|
||||
collectHyperlink(textField);
|
||||
}
|
||||
|
||||
public void collect(JRSubreport subreport) {
|
||||
collectElement(subreport);
|
||||
addExpression(subreport.getParametersMapExpression());
|
||||
JRSubreportParameter[] parameters = subreport.getParameters();
|
||||
if (parameters != null && parameters.length > 0)
|
||||
for (int j = 0; j < parameters.length; j++)
|
||||
addExpression(parameters[j].getExpression());
|
||||
addExpression(subreport.getConnectionExpression());
|
||||
addExpression(subreport.getDataSourceExpression());
|
||||
addExpression(subreport.getExpression());
|
||||
}
|
||||
|
||||
public void collect(JRChart chart) {
|
||||
collectElement(chart);
|
||||
collectAnchor(chart);
|
||||
collectHyperlink(chart);
|
||||
addExpression(chart.getTitleExpression());
|
||||
addExpression(chart.getSubtitleExpression());
|
||||
chart.getDataset().collectExpressions(this);
|
||||
chart.getPlot().collectExpressions(this);
|
||||
}
|
||||
|
||||
public void collect(JRPieDataset pieDataset) {
|
||||
collect((JRElementDataset)pieDataset);
|
||||
JRExpressionCollector collector = getCollector((JRElementDataset)pieDataset);
|
||||
collector.addExpression(pieDataset.getKeyExpression());
|
||||
collector.addExpression(pieDataset.getValueExpression());
|
||||
collector.addExpression(pieDataset.getLabelExpression());
|
||||
collector.collectHyperlink(pieDataset.getSectionHyperlink());
|
||||
}
|
||||
|
||||
public void collect(JRCategoryDataset categoryDataset) {
|
||||
collect((JRElementDataset)categoryDataset);
|
||||
JRCategorySeries[] categorySeries = categoryDataset.getSeries();
|
||||
if (categorySeries != null && categorySeries.length > 0) {
|
||||
JRExpressionCollector collector = getCollector((JRElementDataset)categoryDataset);
|
||||
for (int j = 0; j < categorySeries.length; j++)
|
||||
collector.collect(categorySeries[j]);
|
||||
}
|
||||
}
|
||||
|
||||
public void collect(JRXyDataset xyDataset) {
|
||||
collect((JRElementDataset)xyDataset);
|
||||
JRXySeries[] xySeries = xyDataset.getSeries();
|
||||
if (xySeries != null && xySeries.length > 0) {
|
||||
JRExpressionCollector collector = getCollector((JRElementDataset)xyDataset);
|
||||
for (int j = 0; j < xySeries.length; j++)
|
||||
collector.collect(xySeries[j]);
|
||||
}
|
||||
}
|
||||
|
||||
public void collect(JRTimeSeriesDataset timeSeriesDataset) {
|
||||
collect((JRElementDataset)timeSeriesDataset);
|
||||
JRTimeSeries[] timeSeries = timeSeriesDataset.getSeries();
|
||||
if (timeSeries != null && timeSeries.length > 0) {
|
||||
JRExpressionCollector collector = getCollector((JRElementDataset)timeSeriesDataset);
|
||||
for (int i = 0; i < timeSeries.length; i++)
|
||||
collector.collect(timeSeries[i]);
|
||||
}
|
||||
}
|
||||
|
||||
public void collect(JRTimePeriodDataset timePeriodDataset) {
|
||||
collect((JRElementDataset)timePeriodDataset);
|
||||
JRTimePeriodSeries[] timePeriodSeries = timePeriodDataset.getSeries();
|
||||
if (timePeriodSeries != null && timePeriodSeries.length > 0) {
|
||||
JRExpressionCollector collector = getCollector((JRElementDataset)timePeriodDataset);
|
||||
for (int i = 0; i < timePeriodSeries.length; i++)
|
||||
collector.collect(timePeriodSeries[i]);
|
||||
}
|
||||
}
|
||||
|
||||
public void collect(JRValueDataset valueDataset) {
|
||||
collect((JRElementDataset)valueDataset);
|
||||
JRExpressionCollector collector = getCollector((JRElementDataset)valueDataset);
|
||||
collector.addExpression(valueDataset.getValueExpression());
|
||||
}
|
||||
|
||||
private void collect(JRXySeries xySeries) {
|
||||
addExpression(xySeries.getSeriesExpression());
|
||||
addExpression(xySeries.getXValueExpression());
|
||||
addExpression(xySeries.getYValueExpression());
|
||||
addExpression(xySeries.getLabelExpression());
|
||||
collectHyperlink(xySeries.getItemHyperlink());
|
||||
}
|
||||
|
||||
private void collect(JRCategorySeries categorySeries) {
|
||||
addExpression(categorySeries.getSeriesExpression());
|
||||
addExpression(categorySeries.getCategoryExpression());
|
||||
addExpression(categorySeries.getValueExpression());
|
||||
addExpression(categorySeries.getLabelExpression());
|
||||
collectHyperlink(categorySeries.getItemHyperlink());
|
||||
}
|
||||
|
||||
public void collect(JRBarPlot barPlot) {
|
||||
addExpression(barPlot.getCategoryAxisLabelExpression());
|
||||
addExpression(barPlot.getValueAxisLabelExpression());
|
||||
}
|
||||
|
||||
public void collect(JRBar3DPlot barPlot) {
|
||||
addExpression(barPlot.getCategoryAxisLabelExpression());
|
||||
addExpression(barPlot.getValueAxisLabelExpression());
|
||||
}
|
||||
|
||||
public void collect(JRLinePlot linePlot) {
|
||||
addExpression(linePlot.getCategoryAxisLabelExpression());
|
||||
addExpression(linePlot.getValueAxisLabelExpression());
|
||||
}
|
||||
|
||||
public void collect(JRTimeSeriesPlot timeSeriesPlot) {
|
||||
addExpression(timeSeriesPlot.getTimeAxisLabelExpression());
|
||||
addExpression(timeSeriesPlot.getValueAxisLabelExpression());
|
||||
}
|
||||
|
||||
public void collect(JRScatterPlot scatterPlot) {
|
||||
addExpression(scatterPlot.getXAxisLabelExpression());
|
||||
addExpression(scatterPlot.getYAxisLabelExpression());
|
||||
}
|
||||
|
||||
public void collect(JRAreaPlot areaPlot) {
|
||||
addExpression(areaPlot.getCategoryAxisLabelExpression());
|
||||
addExpression(areaPlot.getValueAxisLabelExpression());
|
||||
}
|
||||
|
||||
private void collect(JRTimeSeries timeSeries) {
|
||||
addExpression(timeSeries.getSeriesExpression());
|
||||
addExpression(timeSeries.getTimePeriodExpression());
|
||||
addExpression(timeSeries.getValueExpression());
|
||||
addExpression(timeSeries.getLabelExpression());
|
||||
collectHyperlink(timeSeries.getItemHyperlink());
|
||||
}
|
||||
|
||||
private void collect(JRTimePeriodSeries timePeriodSeries) {
|
||||
addExpression(timePeriodSeries.getSeriesExpression());
|
||||
addExpression(timePeriodSeries.getStartDateExpression());
|
||||
addExpression(timePeriodSeries.getEndDateExpression());
|
||||
addExpression(timePeriodSeries.getValueExpression());
|
||||
addExpression(timePeriodSeries.getLabelExpression());
|
||||
collectHyperlink(timePeriodSeries.getItemHyperlink());
|
||||
}
|
||||
|
||||
public void collect(JRXyzDataset xyzDataset) {
|
||||
collect((JRElementDataset)xyzDataset);
|
||||
JRXyzSeries[] xyzSeries = xyzDataset.getSeries();
|
||||
if (xyzSeries != null && xyzSeries.length > 0) {
|
||||
JRExpressionCollector collector = getCollector((JRElementDataset)xyzDataset);
|
||||
for (int j = 0; j < xyzSeries.length; j++)
|
||||
collector.collect(xyzSeries[j]);
|
||||
}
|
||||
}
|
||||
|
||||
private void collect(JRXyzSeries xyzSeries) {
|
||||
addExpression(xyzSeries.getSeriesExpression());
|
||||
addExpression(xyzSeries.getXValueExpression());
|
||||
addExpression(xyzSeries.getYValueExpression());
|
||||
addExpression(xyzSeries.getZValueExpression());
|
||||
collectHyperlink(xyzSeries.getItemHyperlink());
|
||||
}
|
||||
|
||||
public void collect(JRBubblePlot bubblePlot) {
|
||||
addExpression(bubblePlot.getXAxisLabelExpression());
|
||||
addExpression(bubblePlot.getYAxisLabelExpression());
|
||||
}
|
||||
|
||||
public void collect(JRHighLowPlot highLowPlot) {
|
||||
addExpression(highLowPlot.getTimeAxisLabelExpression());
|
||||
addExpression(highLowPlot.getValueAxisLabelExpression());
|
||||
}
|
||||
|
||||
public void collect(JRDataRange dataRange) {
|
||||
if (dataRange != null) {
|
||||
addExpression(dataRange.getLowExpression());
|
||||
addExpression(dataRange.getHighExpression());
|
||||
}
|
||||
}
|
||||
|
||||
public void collect(JRMeterPlot meterPlot) {
|
||||
List intervals = meterPlot.getIntervals();
|
||||
if (intervals != null) {
|
||||
Iterator iter = intervals.iterator();
|
||||
while (iter.hasNext()) {
|
||||
JRMeterInterval interval = iter.next();
|
||||
collect(interval.getDataRange());
|
||||
}
|
||||
}
|
||||
collect(meterPlot.getDataRange());
|
||||
}
|
||||
|
||||
public void collect(JRThermometerPlot thermometerPlot) {
|
||||
collect(thermometerPlot.getDataRange());
|
||||
collect(thermometerPlot.getLowRange());
|
||||
collect(thermometerPlot.getMediumRange());
|
||||
collect(thermometerPlot.getHighRange());
|
||||
}
|
||||
|
||||
public void collect(JRHighLowDataset highLowDataset) {
|
||||
collect((JRElementDataset)highLowDataset);
|
||||
JRExpressionCollector collector = getCollector((JRElementDataset)highLowDataset);
|
||||
collector.addExpression(highLowDataset.getSeriesExpression());
|
||||
collector.addExpression(highLowDataset.getDateExpression());
|
||||
collector.addExpression(highLowDataset.getHighExpression());
|
||||
collector.addExpression(highLowDataset.getLowExpression());
|
||||
collector.addExpression(highLowDataset.getOpenExpression());
|
||||
collector.addExpression(highLowDataset.getCloseExpression());
|
||||
collector.addExpression(highLowDataset.getVolumeExpression());
|
||||
collector.collectHyperlink(highLowDataset.getItemHyperlink());
|
||||
}
|
||||
|
||||
public void collect(JRCandlestickPlot candlestickPlot) {
|
||||
addExpression(candlestickPlot.getTimeAxisLabelExpression());
|
||||
addExpression(candlestickPlot.getValueAxisLabelExpression());
|
||||
}
|
||||
|
||||
public void collect(JRCrosstab crosstab) {
|
||||
collectElement((JRElement)crosstab);
|
||||
createCrosstabId(crosstab);
|
||||
JRCrosstabDataset dataset = crosstab.getDataset();
|
||||
collect((JRElementDataset)dataset);
|
||||
JRExpressionCollector datasetCollector = getCollector((JRElementDataset)dataset);
|
||||
JRExpressionCollector crosstabCollector = getCollector(crosstab);
|
||||
crosstabCollector.collect(this.report.getDefaultStyle());
|
||||
addExpression(crosstab.getParametersMapExpression());
|
||||
JRCrosstabParameter[] parameters = crosstab.getParameters();
|
||||
if (parameters != null)
|
||||
for (int i = 0; i < parameters.length; i++)
|
||||
addExpression(parameters[i].getExpression());
|
||||
crosstabCollector.collect(crosstab.getHeaderCell());
|
||||
JRCrosstabRowGroup[] rowGroups = crosstab.getRowGroups();
|
||||
if (rowGroups != null)
|
||||
for (int i = 0; i < rowGroups.length; i++) {
|
||||
JRCrosstabRowGroup rowGroup = rowGroups[i];
|
||||
JRCrosstabBucket bucket = rowGroup.getBucket();
|
||||
datasetCollector.addExpression(bucket.getExpression());
|
||||
addExpression(bucket.getComparatorExpression());
|
||||
crosstabCollector.collect(rowGroup.getHeader());
|
||||
crosstabCollector.collect(rowGroup.getTotalHeader());
|
||||
}
|
||||
JRCrosstabColumnGroup[] colGroups = crosstab.getColumnGroups();
|
||||
if (colGroups != null)
|
||||
for (int i = 0; i < colGroups.length; i++) {
|
||||
JRCrosstabColumnGroup columnGroup = colGroups[i];
|
||||
datasetCollector.addExpression(columnGroup.getBucket().getExpression());
|
||||
addExpression(columnGroup.getBucket().getComparatorExpression());
|
||||
crosstabCollector.collect(columnGroup.getHeader());
|
||||
crosstabCollector.collect(columnGroup.getTotalHeader());
|
||||
}
|
||||
JRCrosstabMeasure[] measures = crosstab.getMeasures();
|
||||
if (measures != null)
|
||||
for (int i = 0; i < measures.length; i++)
|
||||
datasetCollector.addExpression(measures[i].getValueExpression());
|
||||
crosstabCollector.collect(crosstab.getWhenNoDataCell());
|
||||
collectCrosstabCells(crosstab, crosstabCollector);
|
||||
}
|
||||
|
||||
private void createCrosstabId(JRCrosstab crosstab) {
|
||||
this.crosstabIds.put(crosstab, new Integer(this.crosstabIds.size()));
|
||||
}
|
||||
|
||||
private void collectCrosstabCells(JRCrosstab crosstab, JRExpressionCollector crosstabCollector) {
|
||||
if (crosstab instanceof JRDesignCrosstab) {
|
||||
List cellsList = ((JRDesignCrosstab)crosstab).getCellsList();
|
||||
if (cellsList != null)
|
||||
for (Iterator iter = cellsList.iterator(); iter.hasNext(); ) {
|
||||
JRCrosstabCell cell = iter.next();
|
||||
crosstabCollector.collect(cell.getContents());
|
||||
}
|
||||
} else {
|
||||
JRCrosstabCell[][] cells = crosstab.getCells();
|
||||
if (cells != null)
|
||||
for (int i = 0; i < cells.length; i++) {
|
||||
for (int j = 0; j < (cells[i]).length; j++) {
|
||||
if (cells[i][j] != null)
|
||||
crosstabCollector.collect(cells[i][j].getContents());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public Collection collect(JRDataset dataset) {
|
||||
JRExpressionCollector collector = getCollector(dataset);
|
||||
collector.collect(dataset.getParameters());
|
||||
collector.collect(dataset.getVariables());
|
||||
collector.collect(dataset.getGroups());
|
||||
collector.addExpression(dataset.getFilterExpression());
|
||||
return getExpressions(dataset);
|
||||
}
|
||||
|
||||
protected void collect(JRElementDataset dataset) {
|
||||
collect(dataset.getDatasetRun());
|
||||
JRExpression incrementWhenExpression = dataset.getIncrementWhenExpression();
|
||||
if (incrementWhenExpression != null) {
|
||||
JRExpressionCollector datasetCollector = getCollector(dataset);
|
||||
datasetCollector.addExpression(incrementWhenExpression);
|
||||
}
|
||||
}
|
||||
|
||||
private void collect(JRDatasetRun datasetRun) {
|
||||
if (datasetRun != null) {
|
||||
addExpression(datasetRun.getParametersMapExpression());
|
||||
addExpression(datasetRun.getConnectionExpression());
|
||||
addExpression(datasetRun.getDataSourceExpression());
|
||||
JRDatasetParameter[] parameters = datasetRun.getParameters();
|
||||
if (parameters != null && parameters.length > 0)
|
||||
for (int i = 0; i < parameters.length; i++)
|
||||
addExpression(parameters[i].getExpression());
|
||||
}
|
||||
}
|
||||
|
||||
protected void collect(JRCellContents cell) {
|
||||
if (cell != null) {
|
||||
collect(cell.getStyle());
|
||||
JRElement[] elements = cell.getElements();
|
||||
if (elements != null && elements.length > 0)
|
||||
for (int i = 0; i < elements.length; i++)
|
||||
elements[i].collectExpressions(this);
|
||||
}
|
||||
}
|
||||
|
||||
public void collect(JRFrame frame) {
|
||||
collectElement(frame);
|
||||
JRElement[] elements = frame.getElements();
|
||||
if (elements != null)
|
||||
for (int i = 0; i < elements.length; i++)
|
||||
elements[i].collectExpressions(this);
|
||||
}
|
||||
}
|
13
hrmsEjb/net/sf/jasperreports/engine/JRField.java
Normal file
13
hrmsEjb/net/sf/jasperreports/engine/JRField.java
Normal file
@@ -0,0 +1,13 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRField extends JRPropertiesHolder, JRCloneable {
|
||||
String getName();
|
||||
|
||||
String getDescription();
|
||||
|
||||
void setDescription(String paramString);
|
||||
|
||||
Class getValueClass();
|
||||
|
||||
String getValueClassName();
|
||||
}
|
91
hrmsEjb/net/sf/jasperreports/engine/JRFont.java
Normal file
91
hrmsEjb/net/sf/jasperreports/engine/JRFont.java
Normal file
@@ -0,0 +1,91 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRFont extends JRStyleContainer {
|
||||
public static final String DEFAULT_FONT_NAME = "net.sf.jasperreports.default.font.name";
|
||||
|
||||
public static final String DEFAULT_FONT_SIZE = "net.sf.jasperreports.default.font.size";
|
||||
|
||||
public static final String DEFAULT_PDF_FONT_NAME = "net.sf.jasperreports.default.pdf.font.name";
|
||||
|
||||
public static final String DEFAULT_PDF_ENCODING = "net.sf.jasperreports.default.pdf.encoding";
|
||||
|
||||
public static final String DEFAULT_PDF_EMBEDDED = "net.sf.jasperreports.default.pdf.embedded";
|
||||
|
||||
JRReportFont getReportFont();
|
||||
|
||||
void setReportFont(JRReportFont paramJRReportFont);
|
||||
|
||||
String getFontName();
|
||||
|
||||
String getOwnFontName();
|
||||
|
||||
void setFontName(String paramString);
|
||||
|
||||
boolean isBold();
|
||||
|
||||
Boolean isOwnBold();
|
||||
|
||||
void setBold(boolean paramBoolean);
|
||||
|
||||
void setBold(Boolean paramBoolean);
|
||||
|
||||
boolean isItalic();
|
||||
|
||||
Boolean isOwnItalic();
|
||||
|
||||
void setItalic(boolean paramBoolean);
|
||||
|
||||
void setItalic(Boolean paramBoolean);
|
||||
|
||||
boolean isUnderline();
|
||||
|
||||
Boolean isOwnUnderline();
|
||||
|
||||
void setUnderline(boolean paramBoolean);
|
||||
|
||||
void setUnderline(Boolean paramBoolean);
|
||||
|
||||
boolean isStrikeThrough();
|
||||
|
||||
Boolean isOwnStrikeThrough();
|
||||
|
||||
void setStrikeThrough(boolean paramBoolean);
|
||||
|
||||
void setStrikeThrough(Boolean paramBoolean);
|
||||
|
||||
int getSize();
|
||||
|
||||
Integer getOwnSize();
|
||||
|
||||
void setSize(int paramInt);
|
||||
|
||||
void setSize(Integer paramInteger);
|
||||
|
||||
int getFontSize();
|
||||
|
||||
Integer getOwnFontSize();
|
||||
|
||||
void setFontSize(int paramInt);
|
||||
|
||||
void setFontSize(Integer paramInteger);
|
||||
|
||||
String getPdfFontName();
|
||||
|
||||
String getOwnPdfFontName();
|
||||
|
||||
void setPdfFontName(String paramString);
|
||||
|
||||
String getPdfEncoding();
|
||||
|
||||
String getOwnPdfEncoding();
|
||||
|
||||
void setPdfEncoding(String paramString);
|
||||
|
||||
boolean isPdfEmbedded();
|
||||
|
||||
Boolean isOwnPdfEmbedded();
|
||||
|
||||
void setPdfEmbedded(boolean paramBoolean);
|
||||
|
||||
void setPdfEmbedded(Boolean paramBoolean);
|
||||
}
|
3
hrmsEjb/net/sf/jasperreports/engine/JRFrame.java
Normal file
3
hrmsEjb/net/sf/jasperreports/engine/JRFrame.java
Normal file
@@ -0,0 +1,3 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRFrame extends JRElement, JRElementGroup, JRBox, JRBoxContainer {}
|
29
hrmsEjb/net/sf/jasperreports/engine/JRGraphicElement.java
Normal file
29
hrmsEjb/net/sf/jasperreports/engine/JRGraphicElement.java
Normal file
@@ -0,0 +1,29 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRGraphicElement extends JRElement, JRCommonGraphicElement {
|
||||
public static final byte PEN_NONE = 0;
|
||||
|
||||
public static final byte PEN_1_POINT = 1;
|
||||
|
||||
public static final byte PEN_2_POINT = 2;
|
||||
|
||||
public static final byte PEN_4_POINT = 3;
|
||||
|
||||
public static final byte PEN_DOTTED = 4;
|
||||
|
||||
public static final byte PEN_THIN = 5;
|
||||
|
||||
public static final byte FILL_SOLID = 1;
|
||||
|
||||
byte getPen();
|
||||
|
||||
Byte getOwnPen();
|
||||
|
||||
void setPen(byte paramByte);
|
||||
|
||||
void setPen(Byte paramByte);
|
||||
|
||||
void setFill(byte paramByte);
|
||||
|
||||
void setFill(Byte paramByte);
|
||||
}
|
33
hrmsEjb/net/sf/jasperreports/engine/JRGroup.java
Normal file
33
hrmsEjb/net/sf/jasperreports/engine/JRGroup.java
Normal file
@@ -0,0 +1,33 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRGroup extends JRCloneable {
|
||||
String getName();
|
||||
|
||||
boolean isStartNewColumn();
|
||||
|
||||
void setStartNewColumn(boolean paramBoolean);
|
||||
|
||||
boolean isStartNewPage();
|
||||
|
||||
void setStartNewPage(boolean paramBoolean);
|
||||
|
||||
boolean isResetPageNumber();
|
||||
|
||||
void setResetPageNumber(boolean paramBoolean);
|
||||
|
||||
boolean isReprintHeaderOnEachPage();
|
||||
|
||||
void setReprintHeaderOnEachPage(boolean paramBoolean);
|
||||
|
||||
int getMinHeightToStartNewPage();
|
||||
|
||||
void setMinHeightToStartNewPage(int paramInt);
|
||||
|
||||
JRExpression getExpression();
|
||||
|
||||
JRBand getGroupHeader();
|
||||
|
||||
JRBand getGroupFooter();
|
||||
|
||||
JRVariable getCountVariable();
|
||||
}
|
43
hrmsEjb/net/sf/jasperreports/engine/JRHyperlink.java
Normal file
43
hrmsEjb/net/sf/jasperreports/engine/JRHyperlink.java
Normal file
@@ -0,0 +1,43 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRHyperlink extends JRCloneable {
|
||||
public static final byte HYPERLINK_TYPE_NONE = 1;
|
||||
|
||||
public static final byte HYPERLINK_TYPE_REFERENCE = 2;
|
||||
|
||||
public static final byte HYPERLINK_TYPE_LOCAL_ANCHOR = 3;
|
||||
|
||||
public static final byte HYPERLINK_TYPE_LOCAL_PAGE = 4;
|
||||
|
||||
public static final byte HYPERLINK_TYPE_REMOTE_ANCHOR = 5;
|
||||
|
||||
public static final byte HYPERLINK_TYPE_REMOTE_PAGE = 6;
|
||||
|
||||
public static final byte HYPERLINK_TYPE_NULL = 0;
|
||||
|
||||
public static final byte HYPERLINK_TYPE_CUSTOM = 7;
|
||||
|
||||
public static final byte HYPERLINK_TARGET_SELF = 1;
|
||||
|
||||
public static final byte HYPERLINK_TARGET_BLANK = 2;
|
||||
|
||||
public static final byte HYPERLINK_TARGET_PARENT = 3;
|
||||
|
||||
public static final byte HYPERLINK_TARGET_TOP = 4;
|
||||
|
||||
byte getHyperlinkType();
|
||||
|
||||
byte getHyperlinkTarget();
|
||||
|
||||
JRExpression getHyperlinkReferenceExpression();
|
||||
|
||||
JRExpression getHyperlinkAnchorExpression();
|
||||
|
||||
JRExpression getHyperlinkPageExpression();
|
||||
|
||||
String getLinkType();
|
||||
|
||||
JRHyperlinkParameter[] getHyperlinkParameters();
|
||||
|
||||
JRExpression getHyperlinkTooltipExpression();
|
||||
}
|
82
hrmsEjb/net/sf/jasperreports/engine/JRHyperlinkHelper.java
Normal file
82
hrmsEjb/net/sf/jasperreports/engine/JRHyperlinkHelper.java
Normal file
@@ -0,0 +1,82 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
public class JRHyperlinkHelper {
|
||||
public static final String HYPERLINK_TYPE_NONE = "None";
|
||||
|
||||
public static final String HYPERLINK_TYPE_REFERENCE = "Reference";
|
||||
|
||||
public static final String HYPERLINK_TYPE_LOCAL_ANCHOR = "LocalAnchor";
|
||||
|
||||
public static final String HYPERLINK_TYPE_LOCAL_PAGE = "LocalPage";
|
||||
|
||||
public static final String HYPERLINK_TYPE_REMOTE_ANCHOR = "RemoteAnchor";
|
||||
|
||||
public static final String HYPERLINK_TYPE_REMOTE_PAGE = "RemotePage";
|
||||
|
||||
private static final Map builtinTypes = createBuiltinTypes();
|
||||
|
||||
private static Map createBuiltinTypes() {
|
||||
Map types = new HashMap();
|
||||
types.put("None", new Byte((byte)1));
|
||||
types.put("Reference", new Byte((byte)2));
|
||||
types.put("LocalAnchor", new Byte((byte)3));
|
||||
types.put("LocalPage", new Byte((byte)4));
|
||||
types.put("RemoteAnchor", new Byte((byte)5));
|
||||
types.put("RemotePage", new Byte((byte)6));
|
||||
return types;
|
||||
}
|
||||
|
||||
public static byte getHyperlinkType(JRHyperlink hyperlink) {
|
||||
return getHyperlinkType(hyperlink.getLinkType());
|
||||
}
|
||||
|
||||
public static byte getHyperlinkType(String linkType) {
|
||||
byte type;
|
||||
if (linkType == null) {
|
||||
type = 1;
|
||||
} else {
|
||||
Byte builtinType = (Byte)builtinTypes.get(linkType);
|
||||
if (builtinType == null) {
|
||||
type = 7;
|
||||
} else {
|
||||
type = builtinType.byteValue();
|
||||
}
|
||||
}
|
||||
return type;
|
||||
}
|
||||
|
||||
public static String getLinkType(byte hyperlinkType) {
|
||||
String type;
|
||||
switch (hyperlinkType) {
|
||||
case 0:
|
||||
case 1:
|
||||
type = null;
|
||||
return type;
|
||||
case 2:
|
||||
type = "Reference";
|
||||
return type;
|
||||
case 3:
|
||||
type = "LocalAnchor";
|
||||
return type;
|
||||
case 4:
|
||||
type = "LocalPage";
|
||||
return type;
|
||||
case 5:
|
||||
type = "RemoteAnchor";
|
||||
return type;
|
||||
case 6:
|
||||
type = "RemotePage";
|
||||
return type;
|
||||
case 7:
|
||||
throw new JRRuntimeException("Custom hyperlink types cannot be specified using the byte constant");
|
||||
}
|
||||
throw new JRRuntimeException("Unknown hyperlink type " + hyperlinkType);
|
||||
}
|
||||
|
||||
public static boolean isEmpty(JRHyperlink hyperlink) {
|
||||
return (hyperlink == null || (hyperlink.getHyperlinkType() == 1 && hyperlink.getHyperlinkTooltipExpression() == null));
|
||||
}
|
||||
}
|
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRHyperlinkParameter extends JRCloneable {
|
||||
String getName();
|
||||
|
||||
JRExpression getValueExpression();
|
||||
}
|
43
hrmsEjb/net/sf/jasperreports/engine/JRImage.java
Normal file
43
hrmsEjb/net/sf/jasperreports/engine/JRImage.java
Normal file
@@ -0,0 +1,43 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRImage extends JRGraphicElement, JRAnchor, JRHyperlink, JRAlignment, JRBox, JRCommonImage {
|
||||
public static final byte SCALE_IMAGE_CLIP = 1;
|
||||
|
||||
public static final byte SCALE_IMAGE_FILL_FRAME = 2;
|
||||
|
||||
public static final byte SCALE_IMAGE_RETAIN_SHAPE = 3;
|
||||
|
||||
public static final byte ON_ERROR_TYPE_ERROR = 1;
|
||||
|
||||
public static final byte ON_ERROR_TYPE_BLANK = 2;
|
||||
|
||||
public static final byte ON_ERROR_TYPE_ICON = 3;
|
||||
|
||||
void setScaleImage(byte paramByte);
|
||||
|
||||
void setScaleImage(Byte paramByte);
|
||||
|
||||
boolean isUsingCache();
|
||||
|
||||
Boolean isOwnUsingCache();
|
||||
|
||||
void setUsingCache(boolean paramBoolean);
|
||||
|
||||
void setUsingCache(Boolean paramBoolean);
|
||||
|
||||
boolean isLazy();
|
||||
|
||||
void setLazy(boolean paramBoolean);
|
||||
|
||||
byte getOnErrorType();
|
||||
|
||||
void setOnErrorType(byte paramByte);
|
||||
|
||||
byte getEvaluationTime();
|
||||
|
||||
JRGroup getEvaluationGroup();
|
||||
|
||||
JRExpression getExpression();
|
||||
|
||||
JRBox getBox();
|
||||
}
|
189
hrmsEjb/net/sf/jasperreports/engine/JRImageRenderer.java
Normal file
189
hrmsEjb/net/sf/jasperreports/engine/JRImageRenderer.java
Normal file
@@ -0,0 +1,189 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.Dimension;
|
||||
import java.awt.Graphics2D;
|
||||
import java.awt.Image;
|
||||
import java.awt.geom.Dimension2D;
|
||||
import java.awt.geom.Rectangle2D;
|
||||
import java.io.File;
|
||||
import java.io.InputStream;
|
||||
import java.lang.ref.SoftReference;
|
||||
import java.net.URL;
|
||||
import java.net.URLStreamHandlerFactory;
|
||||
import net.sf.jasperreports.engine.util.FileResolver;
|
||||
import net.sf.jasperreports.engine.util.JRImageLoader;
|
||||
import net.sf.jasperreports.engine.util.JRLoader;
|
||||
import net.sf.jasperreports.engine.util.JRResourcesUtil;
|
||||
import net.sf.jasperreports.engine.util.JRTypeSniffer;
|
||||
|
||||
public class JRImageRenderer extends JRAbstractRenderer {
|
||||
private static final long serialVersionUID = 10200L;
|
||||
|
||||
private byte[] imageData = null;
|
||||
|
||||
private String imageLocation = null;
|
||||
|
||||
private byte imageType = 0;
|
||||
|
||||
private transient SoftReference awtImageRef = null;
|
||||
|
||||
protected JRImageRenderer(byte[] imageData) {
|
||||
this.imageData = imageData;
|
||||
if (imageData != null)
|
||||
this.imageType = JRTypeSniffer.getImageType(imageData);
|
||||
}
|
||||
|
||||
protected JRImageRenderer(String imageLocation) {
|
||||
this.imageLocation = imageLocation;
|
||||
}
|
||||
|
||||
public static ClassLoader getClassLoader() {
|
||||
return JRResourcesUtil.getThreadClassLoader();
|
||||
}
|
||||
|
||||
public static void setClassLoader(ClassLoader classLoader) {
|
||||
JRResourcesUtil.setThreadClassLoader(classLoader);
|
||||
}
|
||||
|
||||
public static JRImageRenderer getInstance(byte[] imageData) {
|
||||
return new JRImageRenderer(imageData);
|
||||
}
|
||||
|
||||
public static JRRenderable getInstance(String imageLocation) throws JRException {
|
||||
return getInstance(imageLocation, (byte)1, true);
|
||||
}
|
||||
|
||||
public static JRRenderable getInstance(String imageLocation, byte onErrorType) throws JRException {
|
||||
return getInstance(imageLocation, onErrorType, true);
|
||||
}
|
||||
|
||||
public static JRRenderable getInstance(String imageLocation, byte onErrorType, boolean isLazy) throws JRException {
|
||||
return getInstance(imageLocation, onErrorType, isLazy, null, null, null);
|
||||
}
|
||||
|
||||
public static JRRenderable getInstance(String imageLocation, byte onErrorType, boolean isLazy, ClassLoader classLoader, URLStreamHandlerFactory urlHandlerFactory, FileResolver fileResolver) throws JRException {
|
||||
if (imageLocation == null)
|
||||
return null;
|
||||
if (isLazy)
|
||||
return new JRImageRenderer(imageLocation);
|
||||
try {
|
||||
byte[] data = JRLoader.loadBytesFromLocation(imageLocation, classLoader, urlHandlerFactory, fileResolver);
|
||||
return new JRImageRenderer(data);
|
||||
} catch (JRException e) {
|
||||
return getOnErrorRenderer(onErrorType, e);
|
||||
}
|
||||
}
|
||||
|
||||
public static JRRenderable getInstance(Image img, byte onErrorType) throws JRException {
|
||||
return getInstance(img, (byte)2, onErrorType);
|
||||
}
|
||||
|
||||
public static JRRenderable getInstance(Image image, byte imageType, byte onErrorType) throws JRException {
|
||||
try {
|
||||
return new JRImageRenderer(JRImageLoader.loadImageDataFromAWTImage(image, imageType));
|
||||
} catch (JRException e) {
|
||||
return getOnErrorRenderer(onErrorType, e);
|
||||
}
|
||||
}
|
||||
|
||||
public static JRRenderable getInstance(InputStream is, byte onErrorType) throws JRException {
|
||||
try {
|
||||
return new JRImageRenderer(JRLoader.loadBytes(is));
|
||||
} catch (JRException e) {
|
||||
return getOnErrorRenderer(onErrorType, e);
|
||||
}
|
||||
}
|
||||
|
||||
public static JRRenderable getInstance(URL url, byte onErrorType) throws JRException {
|
||||
try {
|
||||
return new JRImageRenderer(JRLoader.loadBytes(url));
|
||||
} catch (JRException e) {
|
||||
return getOnErrorRenderer(onErrorType, e);
|
||||
}
|
||||
}
|
||||
|
||||
public static JRRenderable getInstance(File file, byte onErrorType) throws JRException {
|
||||
try {
|
||||
return new JRImageRenderer(JRLoader.loadBytes(file));
|
||||
} catch (JRException e) {
|
||||
return getOnErrorRenderer(onErrorType, e);
|
||||
}
|
||||
}
|
||||
|
||||
public static JRRenderable getOnErrorRendererForDimension(JRRenderable renderer, byte onErrorType) throws JRException {
|
||||
try {
|
||||
renderer.getDimension();
|
||||
return renderer;
|
||||
} catch (JRException e) {
|
||||
return getOnErrorRenderer(onErrorType, e);
|
||||
}
|
||||
}
|
||||
|
||||
public static JRRenderable getOnErrorRendererForImageData(JRRenderable renderer, byte onErrorType) throws JRException {
|
||||
try {
|
||||
renderer.getImageData();
|
||||
return renderer;
|
||||
} catch (JRException e) {
|
||||
return getOnErrorRenderer(onErrorType, e);
|
||||
}
|
||||
}
|
||||
|
||||
public static JRImageRenderer getOnErrorRendererForImage(JRImageRenderer renderer, byte onErrorType) throws JRException {
|
||||
try {
|
||||
renderer.getImage();
|
||||
return renderer;
|
||||
} catch (JRException e) {
|
||||
return getOnErrorRenderer(onErrorType, e);
|
||||
}
|
||||
}
|
||||
|
||||
private static JRImageRenderer getOnErrorRenderer(byte onErrorType, JRException e) throws JRException {
|
||||
JRImageRenderer renderer = null;
|
||||
switch (onErrorType) {
|
||||
case 3:
|
||||
renderer = new JRImageRenderer("net/sf/jasperreports/engine/images/noimage.GIF");
|
||||
case 2:
|
||||
return renderer;
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
|
||||
public Image getImage() throws JRException {
|
||||
if (this.awtImageRef == null || this.awtImageRef.get() == null) {
|
||||
Image awtImage = JRImageLoader.loadImage(getImageData());
|
||||
this.awtImageRef = new SoftReference(awtImage);
|
||||
}
|
||||
return this.awtImageRef.get();
|
||||
}
|
||||
|
||||
public String getImageLocation() {
|
||||
return this.imageLocation;
|
||||
}
|
||||
|
||||
public byte getType() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public byte getImageType() {
|
||||
return this.imageType;
|
||||
}
|
||||
|
||||
public Dimension2D getDimension() throws JRException {
|
||||
Image img = getImage();
|
||||
return new Dimension(img.getWidth(null), img.getHeight(null));
|
||||
}
|
||||
|
||||
public byte[] getImageData() throws JRException {
|
||||
if (this.imageData == null) {
|
||||
this.imageData = JRLoader.loadBytesFromLocation(this.imageLocation);
|
||||
if (this.imageData != null)
|
||||
this.imageType = JRTypeSniffer.getImageType(this.imageData);
|
||||
}
|
||||
return this.imageData;
|
||||
}
|
||||
|
||||
public void render(Graphics2D grx, Rectangle2D rectanle) throws JRException {
|
||||
Image img = getImage();
|
||||
grx.drawImage(img, (int)rectanle.getX(), (int)rectanle.getY(), (int)rectanle.getWidth(), (int)rectanle.getHeight(), null);
|
||||
}
|
||||
}
|
11
hrmsEjb/net/sf/jasperreports/engine/JRLine.java
Normal file
11
hrmsEjb/net/sf/jasperreports/engine/JRLine.java
Normal file
@@ -0,0 +1,11 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRLine extends JRGraphicElement {
|
||||
public static final byte DIRECTION_TOP_DOWN = 1;
|
||||
|
||||
public static final byte DIRECTION_BOTTOM_UP = 2;
|
||||
|
||||
byte getDirection();
|
||||
|
||||
void setDirection(byte paramByte);
|
||||
}
|
69
hrmsEjb/net/sf/jasperreports/engine/JRLineBox.java
Normal file
69
hrmsEjb/net/sf/jasperreports/engine/JRLineBox.java
Normal file
@@ -0,0 +1,69 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import net.sf.jasperreports.engine.base.JRBoxPen;
|
||||
|
||||
public interface JRLineBox extends JRPenContainer {
|
||||
JRBoxContainer getBoxContainer();
|
||||
|
||||
JRLineBox clone(JRBoxContainer paramJRBoxContainer);
|
||||
|
||||
JRBoxPen getPen();
|
||||
|
||||
void copyPen(JRBoxPen paramJRBoxPen);
|
||||
|
||||
JRBoxPen getTopPen();
|
||||
|
||||
void copyTopPen(JRBoxPen paramJRBoxPen);
|
||||
|
||||
JRBoxPen getLeftPen();
|
||||
|
||||
void copyLeftPen(JRBoxPen paramJRBoxPen);
|
||||
|
||||
JRBoxPen getBottomPen();
|
||||
|
||||
void copyBottomPen(JRBoxPen paramJRBoxPen);
|
||||
|
||||
JRBoxPen getRightPen();
|
||||
|
||||
void copyRightPen(JRBoxPen paramJRBoxPen);
|
||||
|
||||
Integer getPadding();
|
||||
|
||||
Integer getOwnPadding();
|
||||
|
||||
void setPadding(int paramInt);
|
||||
|
||||
void setPadding(Integer paramInteger);
|
||||
|
||||
Integer getTopPadding();
|
||||
|
||||
Integer getOwnTopPadding();
|
||||
|
||||
void setTopPadding(int paramInt);
|
||||
|
||||
void setTopPadding(Integer paramInteger);
|
||||
|
||||
Integer getLeftPadding();
|
||||
|
||||
Integer getOwnLeftPadding();
|
||||
|
||||
void setLeftPadding(int paramInt);
|
||||
|
||||
void setLeftPadding(Integer paramInteger);
|
||||
|
||||
Integer getBottomPadding();
|
||||
|
||||
Integer getOwnBottomPadding();
|
||||
|
||||
void setBottomPadding(int paramInt);
|
||||
|
||||
void setBottomPadding(Integer paramInteger);
|
||||
|
||||
Integer getRightPadding();
|
||||
|
||||
Integer getOwnRightPadding();
|
||||
|
||||
void setRightPadding(int paramInt);
|
||||
|
||||
void setRightPadding(Integer paramInteger);
|
||||
}
|
94
hrmsEjb/net/sf/jasperreports/engine/JROrigin.java
Normal file
94
hrmsEjb/net/sf/jasperreports/engine/JROrigin.java
Normal file
@@ -0,0 +1,94 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class JROrigin implements JRCloneable, Serializable {
|
||||
private static final long serialVersionUID = 10200L;
|
||||
|
||||
public static final byte UNKNOWN = 0;
|
||||
|
||||
public static final byte BACKGROUND = 1;
|
||||
|
||||
public static final byte TITLE = 2;
|
||||
|
||||
public static final byte PAGE_HEADER = 3;
|
||||
|
||||
public static final byte COLUMN_HEADER = 4;
|
||||
|
||||
public static final byte GROUP_HEADER = 5;
|
||||
|
||||
public static final byte DETAIL = 6;
|
||||
|
||||
public static final byte GROUP_FOOTER = 7;
|
||||
|
||||
public static final byte COLUMN_FOOTER = 8;
|
||||
|
||||
public static final byte PAGE_FOOTER = 9;
|
||||
|
||||
public static final byte LAST_PAGE_FOOTER = 10;
|
||||
|
||||
public static final byte SUMMARY = 11;
|
||||
|
||||
public static final byte NO_DATA = 12;
|
||||
|
||||
private byte bandType = 0;
|
||||
|
||||
private String groupName = null;
|
||||
|
||||
private String reportName = null;
|
||||
|
||||
private int hashCode = 0;
|
||||
|
||||
public JROrigin(byte bandType) {
|
||||
this(null, null, bandType);
|
||||
}
|
||||
|
||||
public JROrigin(String reportName, byte bandType) {
|
||||
this(reportName, null, bandType);
|
||||
}
|
||||
|
||||
public JROrigin(String reportName, String groupName, byte bandType) {
|
||||
this.reportName = reportName;
|
||||
this.groupName = groupName;
|
||||
this.bandType = bandType;
|
||||
int hash = 17;
|
||||
hash = 31 * hash + ((reportName == null) ? 0 : reportName.hashCode());
|
||||
hash = 31 * hash + ((groupName == null) ? 0 : groupName.hashCode());
|
||||
hash = 31 * hash + bandType;
|
||||
this.hashCode = hash;
|
||||
}
|
||||
|
||||
public String getReportName() {
|
||||
return this.reportName;
|
||||
}
|
||||
|
||||
public String getGroupName() {
|
||||
return this.groupName;
|
||||
}
|
||||
|
||||
public byte getBandType() {
|
||||
return this.bandType;
|
||||
}
|
||||
|
||||
public boolean equals(Object obj) {
|
||||
if (obj instanceof JROrigin) {
|
||||
JROrigin origin = (JROrigin)obj;
|
||||
String groupName2 = origin.getGroupName();
|
||||
String reportName2 = origin.getReportName();
|
||||
return (origin.getBandType() == this.bandType && ((this.groupName == null && groupName2 == null) || this.groupName.equals(groupName2)) && ((this.reportName == null && reportName2 == null) || this.reportName.equals(reportName2)));
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
public int hashCode() {
|
||||
return this.hashCode;
|
||||
}
|
||||
|
||||
public Object clone() {
|
||||
try {
|
||||
return super.clone();
|
||||
} catch (CloneNotSupportedException e) {
|
||||
throw new JRRuntimeException(e);
|
||||
}
|
||||
}
|
||||
}
|
49
hrmsEjb/net/sf/jasperreports/engine/JRParameter.java
Normal file
49
hrmsEjb/net/sf/jasperreports/engine/JRParameter.java
Normal file
@@ -0,0 +1,49 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRParameter extends JRPropertiesHolder, JRCloneable {
|
||||
public static final String REPORT_PARAMETERS_MAP = "REPORT_PARAMETERS_MAP";
|
||||
|
||||
public static final String REPORT_CONNECTION = "REPORT_CONNECTION";
|
||||
|
||||
public static final String REPORT_MAX_COUNT = "REPORT_MAX_COUNT";
|
||||
|
||||
public static final String REPORT_DATA_SOURCE = "REPORT_DATA_SOURCE";
|
||||
|
||||
public static final String REPORT_SCRIPTLET = "REPORT_SCRIPTLET";
|
||||
|
||||
public static final String REPORT_LOCALE = "REPORT_LOCALE";
|
||||
|
||||
public static final String REPORT_RESOURCE_BUNDLE = "REPORT_RESOURCE_BUNDLE";
|
||||
|
||||
public static final String REPORT_TIME_ZONE = "REPORT_TIME_ZONE";
|
||||
|
||||
public static final String REPORT_VIRTUALIZER = "REPORT_VIRTUALIZER";
|
||||
|
||||
public static final String REPORT_CLASS_LOADER = "REPORT_CLASS_LOADER";
|
||||
|
||||
public static final String REPORT_URL_HANDLER_FACTORY = "REPORT_URL_HANDLER_FACTORY";
|
||||
|
||||
public static final String REPORT_FILE_RESOLVER = "REPORT_FILE_RESOLVER";
|
||||
|
||||
public static final String REPORT_FORMAT_FACTORY = "REPORT_FORMAT_FACTORY";
|
||||
|
||||
public static final String IS_IGNORE_PAGINATION = "IS_IGNORE_PAGINATION";
|
||||
|
||||
public static final String REPORT_TEMPLATES = "REPORT_TEMPLATES";
|
||||
|
||||
String getName();
|
||||
|
||||
String getDescription();
|
||||
|
||||
void setDescription(String paramString);
|
||||
|
||||
Class getValueClass();
|
||||
|
||||
String getValueClassName();
|
||||
|
||||
boolean isSystemDefined();
|
||||
|
||||
boolean isForPrompting();
|
||||
|
||||
JRExpression getDefaultValueExpression();
|
||||
}
|
43
hrmsEjb/net/sf/jasperreports/engine/JRPen.java
Normal file
43
hrmsEjb/net/sf/jasperreports/engine/JRPen.java
Normal file
@@ -0,0 +1,43 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.Color;
|
||||
|
||||
public interface JRPen {
|
||||
public static final byte LINE_STYLE_SOLID = 0;
|
||||
|
||||
public static final byte LINE_STYLE_DASHED = 1;
|
||||
|
||||
public static final byte LINE_STYLE_DOTTED = 2;
|
||||
|
||||
public static final byte LINE_STYLE_DOUBLE = 3;
|
||||
|
||||
public static final Float LINE_WIDTH_0 = new Float(0.0F);
|
||||
|
||||
public static final Float LINE_WIDTH_1 = new Float(1.0F);
|
||||
|
||||
JRStyleContainer getStyleContainer();
|
||||
|
||||
JRPen clone(JRPenContainer paramJRPenContainer);
|
||||
|
||||
Float getLineWidth();
|
||||
|
||||
Float getOwnLineWidth();
|
||||
|
||||
void setLineWidth(float paramFloat);
|
||||
|
||||
void setLineWidth(Float paramFloat);
|
||||
|
||||
Byte getLineStyle();
|
||||
|
||||
Byte getOwnLineStyle();
|
||||
|
||||
void setLineStyle(byte paramByte);
|
||||
|
||||
void setLineStyle(Byte paramByte);
|
||||
|
||||
Color getLineColor();
|
||||
|
||||
Color getOwnLineColor();
|
||||
|
||||
void setLineColor(Color paramColor);
|
||||
}
|
9
hrmsEjb/net/sf/jasperreports/engine/JRPenContainer.java
Normal file
9
hrmsEjb/net/sf/jasperreports/engine/JRPenContainer.java
Normal file
@@ -0,0 +1,9 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.Color;
|
||||
|
||||
public interface JRPenContainer extends JRStyleContainer {
|
||||
Float getDefaultLineWidth();
|
||||
|
||||
Color getDefaultLineColor();
|
||||
}
|
11
hrmsEjb/net/sf/jasperreports/engine/JRPrintAnchor.java
Normal file
11
hrmsEjb/net/sf/jasperreports/engine/JRPrintAnchor.java
Normal file
@@ -0,0 +1,11 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRPrintAnchor {
|
||||
String getAnchorName();
|
||||
|
||||
void setAnchorName(String paramString);
|
||||
|
||||
int getBookmarkLevel();
|
||||
|
||||
void setBookmarkLevel(int paramInt);
|
||||
}
|
38
hrmsEjb/net/sf/jasperreports/engine/JRPrintAnchorIndex.java
Normal file
38
hrmsEjb/net/sf/jasperreports/engine/JRPrintAnchorIndex.java
Normal file
@@ -0,0 +1,38 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public class JRPrintAnchorIndex {
|
||||
private int pageIndex = 0;
|
||||
|
||||
private JRPrintElement element = null;
|
||||
|
||||
private final int offsetX;
|
||||
|
||||
private final int offsetY;
|
||||
|
||||
public JRPrintAnchorIndex(int page, JRPrintElement elem) {
|
||||
this(page, elem, 0, 0);
|
||||
}
|
||||
|
||||
public JRPrintAnchorIndex(int page, JRPrintElement elem, int offsetX, int offsetY) {
|
||||
this.pageIndex = page;
|
||||
this.element = elem;
|
||||
this.offsetX = offsetX;
|
||||
this.offsetY = offsetY;
|
||||
}
|
||||
|
||||
public int getPageIndex() {
|
||||
return this.pageIndex;
|
||||
}
|
||||
|
||||
public JRPrintElement getElement() {
|
||||
return this.element;
|
||||
}
|
||||
|
||||
public int getElementAbsoluteX() {
|
||||
return this.element.getX() + this.offsetX;
|
||||
}
|
||||
|
||||
public int getElementAbsoluteY() {
|
||||
return this.element.getY() + this.offsetY;
|
||||
}
|
||||
}
|
35
hrmsEjb/net/sf/jasperreports/engine/JRPrintElement.java
Normal file
35
hrmsEjb/net/sf/jasperreports/engine/JRPrintElement.java
Normal file
@@ -0,0 +1,35 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.Color;
|
||||
|
||||
public interface JRPrintElement extends JRCommonElement, JRPropertiesHolder {
|
||||
JROrigin getOrigin();
|
||||
|
||||
void setStyle(JRStyle paramJRStyle);
|
||||
|
||||
void setMode(byte paramByte);
|
||||
|
||||
void setMode(Byte paramByte);
|
||||
|
||||
int getX();
|
||||
|
||||
void setX(int paramInt);
|
||||
|
||||
int getY();
|
||||
|
||||
void setY(int paramInt);
|
||||
|
||||
int getWidth();
|
||||
|
||||
void setWidth(int paramInt);
|
||||
|
||||
int getHeight();
|
||||
|
||||
void setHeight(int paramInt);
|
||||
|
||||
void setForecolor(Color paramColor);
|
||||
|
||||
void setBackcolor(Color paramColor);
|
||||
|
||||
String getKey();
|
||||
}
|
@@ -0,0 +1,13 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface JRPrintElementContainer {
|
||||
int getHeight();
|
||||
|
||||
void setHeight(int paramInt);
|
||||
|
||||
List getElements();
|
||||
|
||||
void addElement(JRPrintElement paramJRPrintElement);
|
||||
}
|
3
hrmsEjb/net/sf/jasperreports/engine/JRPrintEllipse.java
Normal file
3
hrmsEjb/net/sf/jasperreports/engine/JRPrintEllipse.java
Normal file
@@ -0,0 +1,3 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRPrintEllipse extends JRPrintGraphicElement {}
|
7
hrmsEjb/net/sf/jasperreports/engine/JRPrintFrame.java
Normal file
7
hrmsEjb/net/sf/jasperreports/engine/JRPrintFrame.java
Normal file
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface JRPrintFrame extends JRPrintElement, JRBox, JRBoxContainer {
|
||||
List getElements();
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRPrintGraphicElement extends JRPrintElement, JRCommonGraphicElement {
|
||||
byte getPen();
|
||||
|
||||
Byte getOwnPen();
|
||||
|
||||
void setPen(byte paramByte);
|
||||
|
||||
void setPen(Byte paramByte);
|
||||
|
||||
void setFill(byte paramByte);
|
||||
|
||||
void setFill(Byte paramByte);
|
||||
}
|
35
hrmsEjb/net/sf/jasperreports/engine/JRPrintHyperlink.java
Normal file
35
hrmsEjb/net/sf/jasperreports/engine/JRPrintHyperlink.java
Normal file
@@ -0,0 +1,35 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRPrintHyperlink {
|
||||
byte getHyperlinkType();
|
||||
|
||||
void setHyperlinkType(byte paramByte);
|
||||
|
||||
byte getHyperlinkTarget();
|
||||
|
||||
void setHyperlinkTarget(byte paramByte);
|
||||
|
||||
String getHyperlinkReference();
|
||||
|
||||
void setHyperlinkReference(String paramString);
|
||||
|
||||
String getHyperlinkAnchor();
|
||||
|
||||
void setHyperlinkAnchor(String paramString);
|
||||
|
||||
Integer getHyperlinkPage();
|
||||
|
||||
void setHyperlinkPage(Integer paramInteger);
|
||||
|
||||
String getLinkType();
|
||||
|
||||
void setLinkType(String paramString);
|
||||
|
||||
JRPrintHyperlinkParameters getHyperlinkParameters();
|
||||
|
||||
void setHyperlinkParameters(JRPrintHyperlinkParameters paramJRPrintHyperlinkParameters);
|
||||
|
||||
String getHyperlinkTooltip();
|
||||
|
||||
void setHyperlinkTooltip(String paramString);
|
||||
}
|
@@ -0,0 +1,47 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class JRPrintHyperlinkParameter implements Serializable {
|
||||
private static final long serialVersionUID = 10200L;
|
||||
|
||||
public static final String DEFAULT_VALUE_CLASS = String.class.getName();
|
||||
|
||||
private String name;
|
||||
|
||||
private String valueClass = DEFAULT_VALUE_CLASS;
|
||||
|
||||
private Object value;
|
||||
|
||||
public JRPrintHyperlinkParameter(String name, String valueClass, Object value) {
|
||||
this.name = name;
|
||||
this.valueClass = valueClass;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
public String getValueClass() {
|
||||
return this.valueClass;
|
||||
}
|
||||
|
||||
public Object getValue() {
|
||||
return this.value;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public void setValueClass(String valueClass) {
|
||||
this.valueClass = valueClass;
|
||||
}
|
||||
|
||||
public void setValue(Object value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
public JRPrintHyperlinkParameter() {}
|
||||
}
|
@@ -0,0 +1,19 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public class JRPrintHyperlinkParameters implements Serializable {
|
||||
private static final long serialVersionUID = 10200L;
|
||||
|
||||
private List parameters = new ArrayList();
|
||||
|
||||
public List getParameters() {
|
||||
return this.parameters;
|
||||
}
|
||||
|
||||
public void addParameter(JRPrintHyperlinkParameter parameter) {
|
||||
this.parameters.add(parameter);
|
||||
}
|
||||
}
|
27
hrmsEjb/net/sf/jasperreports/engine/JRPrintImage.java
Normal file
27
hrmsEjb/net/sf/jasperreports/engine/JRPrintImage.java
Normal file
@@ -0,0 +1,27 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRPrintImage extends JRPrintGraphicElement, JRPrintAnchor, JRPrintHyperlink, JRAlignment, JRBox, JRCommonImage {
|
||||
JRRenderable getRenderer();
|
||||
|
||||
void setRenderer(JRRenderable paramJRRenderable);
|
||||
|
||||
void setScaleImage(byte paramByte);
|
||||
|
||||
void setScaleImage(Byte paramByte);
|
||||
|
||||
boolean isUsingCache();
|
||||
|
||||
void setUsingCache(boolean paramBoolean);
|
||||
|
||||
boolean isLazy();
|
||||
|
||||
void setLazy(boolean paramBoolean);
|
||||
|
||||
byte getOnErrorType();
|
||||
|
||||
void setOnErrorType(byte paramByte);
|
||||
|
||||
JRBox getBox();
|
||||
|
||||
void setBox(JRBox paramJRBox);
|
||||
}
|
7
hrmsEjb/net/sf/jasperreports/engine/JRPrintLine.java
Normal file
7
hrmsEjb/net/sf/jasperreports/engine/JRPrintLine.java
Normal file
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRPrintLine extends JRPrintGraphicElement {
|
||||
byte getDirection();
|
||||
|
||||
void setDirection(byte paramByte);
|
||||
}
|
11
hrmsEjb/net/sf/jasperreports/engine/JRPrintPage.java
Normal file
11
hrmsEjb/net/sf/jasperreports/engine/JRPrintPage.java
Normal file
@@ -0,0 +1,11 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface JRPrintPage {
|
||||
List getElements();
|
||||
|
||||
void setElements(List paramList);
|
||||
|
||||
void addElement(JRPrintElement paramJRPrintElement);
|
||||
}
|
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRPrintRectangle extends JRPrintGraphicElement, JRCommonRectangle {
|
||||
void setRadius(int paramInt);
|
||||
|
||||
void setRadius(Integer paramInteger);
|
||||
}
|
87
hrmsEjb/net/sf/jasperreports/engine/JRPrintText.java
Normal file
87
hrmsEjb/net/sf/jasperreports/engine/JRPrintText.java
Normal file
@@ -0,0 +1,87 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import net.sf.jasperreports.engine.util.JRStyledText;
|
||||
|
||||
public interface JRPrintText extends JRPrintElement, JRAlignment, JRPrintAnchor, JRPrintHyperlink, JRBox, JRFont, JRCommonText {
|
||||
public static final byte RUN_DIRECTION_LTR = 0;
|
||||
|
||||
public static final byte RUN_DIRECTION_RTL = 1;
|
||||
|
||||
String getText();
|
||||
|
||||
void setText(String paramString);
|
||||
|
||||
Integer getTextTruncateIndex();
|
||||
|
||||
void setTextTruncateIndex(Integer paramInteger);
|
||||
|
||||
String getTextTruncateSuffix();
|
||||
|
||||
void setTextTruncateSuffix(String paramString);
|
||||
|
||||
String getFullText();
|
||||
|
||||
String getOriginalText();
|
||||
|
||||
JRStyledText getStyledText(JRStyledTextAttributeSelector paramJRStyledTextAttributeSelector);
|
||||
|
||||
JRStyledText getFullStyledText(JRStyledTextAttributeSelector paramJRStyledTextAttributeSelector);
|
||||
|
||||
float getLineSpacingFactor();
|
||||
|
||||
void setLineSpacingFactor(float paramFloat);
|
||||
|
||||
float getLeadingOffset();
|
||||
|
||||
void setLeadingOffset(float paramFloat);
|
||||
|
||||
byte getTextAlignment();
|
||||
|
||||
void setTextAlignment(byte paramByte);
|
||||
|
||||
Byte getOwnRotation();
|
||||
|
||||
void setRotation(byte paramByte);
|
||||
|
||||
void setRotation(Byte paramByte);
|
||||
|
||||
byte getRunDirection();
|
||||
|
||||
void setRunDirection(byte paramByte);
|
||||
|
||||
float getTextHeight();
|
||||
|
||||
void setTextHeight(float paramFloat);
|
||||
|
||||
Byte getOwnLineSpacing();
|
||||
|
||||
void setLineSpacing(byte paramByte);
|
||||
|
||||
void setLineSpacing(Byte paramByte);
|
||||
|
||||
void setStyledText(boolean paramBoolean);
|
||||
|
||||
void setStyledText(Boolean paramBoolean);
|
||||
|
||||
String getOwnMarkup();
|
||||
|
||||
void setMarkup(String paramString);
|
||||
|
||||
JRBox getBox();
|
||||
|
||||
void setBox(JRBox paramJRBox);
|
||||
|
||||
JRFont getFont();
|
||||
|
||||
void setFont(JRFont paramJRFont);
|
||||
|
||||
String getValueClassName();
|
||||
|
||||
String getPattern();
|
||||
|
||||
String getFormatFactoryClass();
|
||||
|
||||
String getLocaleCode();
|
||||
|
||||
String getTimeZoneId();
|
||||
}
|
@@ -0,0 +1,9 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRPropertiesHolder {
|
||||
boolean hasProperties();
|
||||
|
||||
JRPropertiesMap getPropertiesMap();
|
||||
|
||||
JRPropertiesHolder getParentProperties();
|
||||
}
|
151
hrmsEjb/net/sf/jasperreports/engine/JRPropertiesMap.java
Normal file
151
hrmsEjb/net/sf/jasperreports/engine/JRPropertiesMap.java
Normal file
@@ -0,0 +1,151 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.io.ObjectInputStream;
|
||||
import java.io.Serializable;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.HashMap;
|
||||
import java.util.LinkedHashSet;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
public class JRPropertiesMap implements Serializable, Cloneable {
|
||||
private static final long serialVersionUID = 10200L;
|
||||
|
||||
private Map propertiesMap;
|
||||
|
||||
private List propertiesList;
|
||||
|
||||
private JRPropertiesMap base;
|
||||
|
||||
public JRPropertiesMap() {}
|
||||
|
||||
public JRPropertiesMap(JRPropertiesMap propertiesMap) {
|
||||
this();
|
||||
this.base = propertiesMap.base;
|
||||
String[] propertyNames = propertiesMap.getPropertyNames();
|
||||
if (propertyNames != null && propertyNames.length > 0)
|
||||
for (int i = 0; i < propertyNames.length; i++)
|
||||
setProperty(propertyNames[i], propertiesMap.getProperty(propertyNames[i]));
|
||||
}
|
||||
|
||||
protected synchronized void ensureInit() {
|
||||
if (this.propertiesMap == null)
|
||||
init();
|
||||
}
|
||||
|
||||
private void init() {
|
||||
this.propertiesMap = new HashMap();
|
||||
this.propertiesList = new ArrayList();
|
||||
}
|
||||
|
||||
public String[] getPropertyNames() {
|
||||
String[] names;
|
||||
if (hasOwnProperties()) {
|
||||
if (this.base == null) {
|
||||
names = (String[])this.propertiesList.toArray((Object[])new String[this.propertiesList.size()]);
|
||||
} else {
|
||||
LinkedHashSet namesSet = new LinkedHashSet();
|
||||
collectPropertyNames(namesSet);
|
||||
names = (String[])namesSet.toArray((Object[])new String[namesSet.size()]);
|
||||
}
|
||||
} else if (this.base != null) {
|
||||
names = this.base.getPropertyNames();
|
||||
} else {
|
||||
names = new String[0];
|
||||
}
|
||||
return names;
|
||||
}
|
||||
|
||||
protected void collectPropertyNames(Collection names) {
|
||||
if (this.base != null)
|
||||
this.base.collectPropertyNames(names);
|
||||
if (this.propertiesList != null)
|
||||
names.addAll(this.propertiesList);
|
||||
}
|
||||
|
||||
public String getProperty(String propName) {
|
||||
String val;
|
||||
if (hasOwnProperty(propName)) {
|
||||
val = getOwnProperty(propName);
|
||||
} else if (this.base != null) {
|
||||
val = this.base.getProperty(propName);
|
||||
} else {
|
||||
val = null;
|
||||
}
|
||||
return val;
|
||||
}
|
||||
|
||||
public boolean containsProperty(String propName) {
|
||||
return (hasOwnProperty(propName) || (this.base != null && this.base.containsProperty(propName)));
|
||||
}
|
||||
|
||||
protected boolean hasOwnProperty(String propName) {
|
||||
return (this.propertiesMap != null && this.propertiesMap.containsKey(propName));
|
||||
}
|
||||
|
||||
protected String getOwnProperty(String propName) {
|
||||
return (this.propertiesMap != null) ? (String)this.propertiesMap.get(propName) : null;
|
||||
}
|
||||
|
||||
public void setProperty(String propName, String value) {
|
||||
ensureInit();
|
||||
if (!hasOwnProperty(propName))
|
||||
this.propertiesList.add(propName);
|
||||
this.propertiesMap.put(propName, value);
|
||||
}
|
||||
|
||||
public void removeProperty(String propName) {
|
||||
if (hasOwnProperty(propName)) {
|
||||
this.propertiesList.remove(propName);
|
||||
this.propertiesMap.remove(propName);
|
||||
}
|
||||
}
|
||||
|
||||
public JRPropertiesMap cloneProperties() {
|
||||
return new JRPropertiesMap(this);
|
||||
}
|
||||
|
||||
public Object clone() {
|
||||
return cloneProperties();
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return (this.propertiesMap == null) ? "" : this.propertiesMap.toString();
|
||||
}
|
||||
|
||||
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException {
|
||||
in.defaultReadObject();
|
||||
if (this.propertiesList == null && this.propertiesMap != null) {
|
||||
this.propertiesList = new ArrayList(this.propertiesMap.keySet());
|
||||
this.propertiesMap = new HashMap(this.propertiesMap);
|
||||
}
|
||||
}
|
||||
|
||||
public boolean hasProperties() {
|
||||
return (hasOwnProperties() || (this.base != null && this.base.hasProperties()));
|
||||
}
|
||||
|
||||
public boolean hasOwnProperties() {
|
||||
return (this.propertiesList != null && !this.propertiesList.isEmpty());
|
||||
}
|
||||
|
||||
public static JRPropertiesMap getPropertiesClone(JRPropertiesHolder propertiesHolder) {
|
||||
JRPropertiesMap clone;
|
||||
if (propertiesHolder.hasProperties()) {
|
||||
clone = propertiesHolder.getPropertiesMap().cloneProperties();
|
||||
} else {
|
||||
clone = null;
|
||||
}
|
||||
return clone;
|
||||
}
|
||||
|
||||
public JRPropertiesMap getBaseProperties() {
|
||||
return this.base;
|
||||
}
|
||||
|
||||
public void setBaseProperties(JRPropertiesMap base) {
|
||||
this.base = base;
|
||||
}
|
||||
}
|
@@ -0,0 +1,9 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRPropertyExpression {
|
||||
String getName();
|
||||
|
||||
void setName(String paramString);
|
||||
|
||||
JRExpression getValueExpression();
|
||||
}
|
9
hrmsEjb/net/sf/jasperreports/engine/JRQuery.java
Normal file
9
hrmsEjb/net/sf/jasperreports/engine/JRQuery.java
Normal file
@@ -0,0 +1,9 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRQuery extends JRCloneable {
|
||||
JRQueryChunk[] getChunks();
|
||||
|
||||
String getText();
|
||||
|
||||
String getLanguage();
|
||||
}
|
19
hrmsEjb/net/sf/jasperreports/engine/JRQueryChunk.java
Normal file
19
hrmsEjb/net/sf/jasperreports/engine/JRQueryChunk.java
Normal file
@@ -0,0 +1,19 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRQueryChunk extends JRCloneable {
|
||||
public static final String PROPERTY_CHUNK_TOKEN_SEPARATOR = "net.sf.jasperreports.query.chunk.token.separators";
|
||||
|
||||
public static final byte TYPE_TEXT = 1;
|
||||
|
||||
public static final byte TYPE_PARAMETER = 2;
|
||||
|
||||
public static final byte TYPE_PARAMETER_CLAUSE = 3;
|
||||
|
||||
public static final byte TYPE_CLAUSE_TOKENS = 4;
|
||||
|
||||
byte getType();
|
||||
|
||||
String getText();
|
||||
|
||||
String[] getTokens();
|
||||
}
|
7
hrmsEjb/net/sf/jasperreports/engine/JRRectangle.java
Normal file
7
hrmsEjb/net/sf/jasperreports/engine/JRRectangle.java
Normal file
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRRectangle extends JRGraphicElement, JRCommonRectangle {
|
||||
void setRadius(int paramInt);
|
||||
|
||||
void setRadius(Integer paramInteger);
|
||||
}
|
42
hrmsEjb/net/sf/jasperreports/engine/JRRenderable.java
Normal file
42
hrmsEjb/net/sf/jasperreports/engine/JRRenderable.java
Normal file
@@ -0,0 +1,42 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.Graphics2D;
|
||||
import java.awt.geom.Dimension2D;
|
||||
import java.awt.geom.Rectangle2D;
|
||||
import java.io.Serializable;
|
||||
|
||||
public interface JRRenderable extends Serializable {
|
||||
public static final byte TYPE_IMAGE = 0;
|
||||
|
||||
public static final byte TYPE_SVG = 1;
|
||||
|
||||
public static final byte IMAGE_TYPE_UNKNOWN = 0;
|
||||
|
||||
public static final byte IMAGE_TYPE_GIF = 1;
|
||||
|
||||
public static final byte IMAGE_TYPE_JPEG = 2;
|
||||
|
||||
public static final byte IMAGE_TYPE_PNG = 3;
|
||||
|
||||
public static final byte IMAGE_TYPE_TIFF = 4;
|
||||
|
||||
public static final String MIME_TYPE_GIF = "image/gif";
|
||||
|
||||
public static final String MIME_TYPE_JPEG = "image/jpeg";
|
||||
|
||||
public static final String MIME_TYPE_PNG = "image/png";
|
||||
|
||||
public static final String MIME_TYPE_TIFF = "image/tiff";
|
||||
|
||||
String getId();
|
||||
|
||||
byte getType();
|
||||
|
||||
byte getImageType();
|
||||
|
||||
Dimension2D getDimension() throws JRException;
|
||||
|
||||
byte[] getImageData() throws JRException;
|
||||
|
||||
void render(Graphics2D paramGraphics2D, Rectangle2D paramRectangle2D) throws JRException;
|
||||
}
|
131
hrmsEjb/net/sf/jasperreports/engine/JRReport.java
Normal file
131
hrmsEjb/net/sf/jasperreports/engine/JRReport.java
Normal file
@@ -0,0 +1,131 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRReport extends JRDefaultFontProvider, JRDefaultStyleProvider, JRPropertiesHolder {
|
||||
public static final String LANGUAGE_JAVA = "java";
|
||||
|
||||
public static final String LANGUAGE_GROOVY = "groovy";
|
||||
|
||||
public static final byte PRINT_ORDER_VERTICAL = 1;
|
||||
|
||||
public static final byte PRINT_ORDER_HORIZONTAL = 2;
|
||||
|
||||
public static final byte ORIENTATION_PORTRAIT = 1;
|
||||
|
||||
public static final byte ORIENTATION_LANDSCAPE = 2;
|
||||
|
||||
public static final byte WHEN_NO_DATA_TYPE_NO_PAGES = 1;
|
||||
|
||||
public static final byte WHEN_NO_DATA_TYPE_BLANK_PAGE = 2;
|
||||
|
||||
public static final byte WHEN_NO_DATA_TYPE_ALL_SECTIONS_NO_DETAIL = 3;
|
||||
|
||||
public static final byte WHEN_NO_DATA_TYPE_NO_DATA_SECTION = 4;
|
||||
|
||||
public static final byte WHEN_RESOURCE_MISSING_TYPE_NULL = 1;
|
||||
|
||||
public static final byte WHEN_RESOURCE_MISSING_TYPE_EMPTY = 2;
|
||||
|
||||
public static final byte WHEN_RESOURCE_MISSING_TYPE_KEY = 3;
|
||||
|
||||
public static final byte WHEN_RESOURCE_MISSING_TYPE_ERROR = 4;
|
||||
|
||||
String getName();
|
||||
|
||||
String getLanguage();
|
||||
|
||||
int getColumnCount();
|
||||
|
||||
byte getPrintOrder();
|
||||
|
||||
int getPageWidth();
|
||||
|
||||
int getPageHeight();
|
||||
|
||||
byte getOrientation();
|
||||
|
||||
byte getWhenNoDataType();
|
||||
|
||||
void setWhenNoDataType(byte paramByte);
|
||||
|
||||
int getColumnWidth();
|
||||
|
||||
int getColumnSpacing();
|
||||
|
||||
int getLeftMargin();
|
||||
|
||||
int getRightMargin();
|
||||
|
||||
int getTopMargin();
|
||||
|
||||
int getBottomMargin();
|
||||
|
||||
boolean isTitleNewPage();
|
||||
|
||||
boolean isSummaryNewPage();
|
||||
|
||||
boolean isFloatColumnFooter();
|
||||
|
||||
String getScriptletClass();
|
||||
|
||||
String getFormatFactoryClass();
|
||||
|
||||
String getResourceBundle();
|
||||
|
||||
String[] getPropertyNames();
|
||||
|
||||
String getProperty(String paramString);
|
||||
|
||||
void setProperty(String paramString1, String paramString2);
|
||||
|
||||
void removeProperty(String paramString);
|
||||
|
||||
String[] getImports();
|
||||
|
||||
JRReportFont[] getFonts();
|
||||
|
||||
JRStyle[] getStyles();
|
||||
|
||||
JRParameter[] getParameters();
|
||||
|
||||
JRQuery getQuery();
|
||||
|
||||
JRField[] getFields();
|
||||
|
||||
JRSortField[] getSortFields();
|
||||
|
||||
JRVariable[] getVariables();
|
||||
|
||||
JRGroup[] getGroups();
|
||||
|
||||
JRBand getBackground();
|
||||
|
||||
JRBand getTitle();
|
||||
|
||||
JRBand getPageHeader();
|
||||
|
||||
JRBand getColumnHeader();
|
||||
|
||||
JRBand getDetail();
|
||||
|
||||
JRBand getColumnFooter();
|
||||
|
||||
JRBand getPageFooter();
|
||||
|
||||
JRBand getLastPageFooter();
|
||||
|
||||
JRBand getSummary();
|
||||
|
||||
JRBand getNoData();
|
||||
|
||||
byte getWhenResourceMissingType();
|
||||
|
||||
void setWhenResourceMissingType(byte paramByte);
|
||||
|
||||
JRDataset getMainDataset();
|
||||
|
||||
JRDataset[] getDatasets();
|
||||
|
||||
boolean isIgnorePagination();
|
||||
|
||||
JRReportTemplate[] getTemplates();
|
||||
}
|
7
hrmsEjb/net/sf/jasperreports/engine/JRReportFont.java
Normal file
7
hrmsEjb/net/sf/jasperreports/engine/JRReportFont.java
Normal file
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRReportFont extends JRFont {
|
||||
String getName();
|
||||
|
||||
boolean isDefault();
|
||||
}
|
@@ -0,0 +1,5 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRReportTemplate {
|
||||
JRExpression getSourceExpression();
|
||||
}
|
@@ -0,0 +1,5 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRRewindableDataSource extends JRDataSource {
|
||||
void moveFirst() throws JRException;
|
||||
}
|
17
hrmsEjb/net/sf/jasperreports/engine/JRRuntimeException.java
Normal file
17
hrmsEjb/net/sf/jasperreports/engine/JRRuntimeException.java
Normal file
@@ -0,0 +1,17 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public class JRRuntimeException extends RuntimeException {
|
||||
private static final long serialVersionUID = 10200L;
|
||||
|
||||
public JRRuntimeException(String message) {
|
||||
super(message);
|
||||
}
|
||||
|
||||
public JRRuntimeException(Throwable t) {
|
||||
super(t);
|
||||
}
|
||||
|
||||
public JRRuntimeException(String message, Throwable t) {
|
||||
super(message, t);
|
||||
}
|
||||
}
|
@@ -0,0 +1,17 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public class JRScriptletException extends JRException {
|
||||
private static final long serialVersionUID = 10200L;
|
||||
|
||||
public JRScriptletException(String message) {
|
||||
super(message);
|
||||
}
|
||||
|
||||
public JRScriptletException(Exception e) {
|
||||
super(e);
|
||||
}
|
||||
|
||||
public JRScriptletException(String message, Exception e) {
|
||||
super(message, e);
|
||||
}
|
||||
}
|
11
hrmsEjb/net/sf/jasperreports/engine/JRSortField.java
Normal file
11
hrmsEjb/net/sf/jasperreports/engine/JRSortField.java
Normal file
@@ -0,0 +1,11 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRSortField extends JRCloneable {
|
||||
public static final byte SORT_ORDER_ASCENDING = 0;
|
||||
|
||||
public static final byte SORT_ORDER_DESCENDING = 1;
|
||||
|
||||
String getName();
|
||||
|
||||
byte getOrder();
|
||||
}
|
7
hrmsEjb/net/sf/jasperreports/engine/JRStaticText.java
Normal file
7
hrmsEjb/net/sf/jasperreports/engine/JRStaticText.java
Normal file
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRStaticText extends JRTextElement {
|
||||
String getText();
|
||||
|
||||
void setText(String paramString);
|
||||
}
|
303
hrmsEjb/net/sf/jasperreports/engine/JRStyle.java
Normal file
303
hrmsEjb/net/sf/jasperreports/engine/JRStyle.java
Normal file
@@ -0,0 +1,303 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.Color;
|
||||
|
||||
public interface JRStyle extends JRStyleContainer, JRBoxContainer, JRPenContainer {
|
||||
String getName();
|
||||
|
||||
boolean isDefault();
|
||||
|
||||
Byte getMode();
|
||||
|
||||
Byte getOwnMode();
|
||||
|
||||
Color getForecolor();
|
||||
|
||||
Color getOwnForecolor();
|
||||
|
||||
Color getBackcolor();
|
||||
|
||||
Color getOwnBackcolor();
|
||||
|
||||
JRPen getLinePen();
|
||||
|
||||
Byte getPen();
|
||||
|
||||
Byte getOwnPen();
|
||||
|
||||
Byte getFill();
|
||||
|
||||
Byte getOwnFill();
|
||||
|
||||
Integer getRadius();
|
||||
|
||||
Integer getOwnRadius();
|
||||
|
||||
Byte getScaleImage();
|
||||
|
||||
Byte getOwnScaleImage();
|
||||
|
||||
Byte getHorizontalAlignment();
|
||||
|
||||
Byte getOwnHorizontalAlignment();
|
||||
|
||||
Byte getVerticalAlignment();
|
||||
|
||||
Byte getOwnVerticalAlignment();
|
||||
|
||||
JRLineBox getLineBox();
|
||||
|
||||
Byte getBorder();
|
||||
|
||||
Byte getOwnBorder();
|
||||
|
||||
Color getBorderColor();
|
||||
|
||||
Color getOwnBorderColor();
|
||||
|
||||
Integer getPadding();
|
||||
|
||||
Integer getOwnPadding();
|
||||
|
||||
Byte getTopBorder();
|
||||
|
||||
Byte getOwnTopBorder();
|
||||
|
||||
Color getTopBorderColor();
|
||||
|
||||
Color getOwnTopBorderColor();
|
||||
|
||||
Integer getTopPadding();
|
||||
|
||||
Integer getOwnTopPadding();
|
||||
|
||||
Byte getLeftBorder();
|
||||
|
||||
Byte getOwnLeftBorder();
|
||||
|
||||
Color getLeftBorderColor();
|
||||
|
||||
Color getOwnLeftBorderColor();
|
||||
|
||||
Integer getLeftPadding();
|
||||
|
||||
Integer getOwnLeftPadding();
|
||||
|
||||
Byte getBottomBorder();
|
||||
|
||||
Byte getOwnBottomBorder();
|
||||
|
||||
Color getBottomBorderColor();
|
||||
|
||||
Color getOwnBottomBorderColor();
|
||||
|
||||
Integer getBottomPadding();
|
||||
|
||||
Integer getOwnBottomPadding();
|
||||
|
||||
Byte getRightBorder();
|
||||
|
||||
Byte getOwnRightBorder();
|
||||
|
||||
Color getRightBorderColor();
|
||||
|
||||
Color getOwnRightBorderColor();
|
||||
|
||||
Integer getRightPadding();
|
||||
|
||||
Integer getOwnRightPadding();
|
||||
|
||||
Byte getRotation();
|
||||
|
||||
Byte getOwnRotation();
|
||||
|
||||
Byte getLineSpacing();
|
||||
|
||||
Byte getOwnLineSpacing();
|
||||
|
||||
Boolean isStyledText();
|
||||
|
||||
Boolean isOwnStyledText();
|
||||
|
||||
String getMarkup();
|
||||
|
||||
String getOwnMarkup();
|
||||
|
||||
String getFontName();
|
||||
|
||||
String getOwnFontName();
|
||||
|
||||
Boolean isBold();
|
||||
|
||||
Boolean isOwnBold();
|
||||
|
||||
Boolean isItalic();
|
||||
|
||||
Boolean isOwnItalic();
|
||||
|
||||
Boolean isUnderline();
|
||||
|
||||
Boolean isOwnUnderline();
|
||||
|
||||
Boolean isStrikeThrough();
|
||||
|
||||
Boolean isOwnStrikeThrough();
|
||||
|
||||
Integer getFontSize();
|
||||
|
||||
Integer getOwnFontSize();
|
||||
|
||||
String getPdfFontName();
|
||||
|
||||
String getOwnPdfFontName();
|
||||
|
||||
String getPdfEncoding();
|
||||
|
||||
String getOwnPdfEncoding();
|
||||
|
||||
Boolean isPdfEmbedded();
|
||||
|
||||
Boolean isOwnPdfEmbedded();
|
||||
|
||||
String getPattern();
|
||||
|
||||
String getOwnPattern();
|
||||
|
||||
Boolean isBlankWhenNull();
|
||||
|
||||
Boolean isOwnBlankWhenNull();
|
||||
|
||||
void setForecolor(Color paramColor);
|
||||
|
||||
void setBackcolor(Color paramColor);
|
||||
|
||||
void setMode(byte paramByte);
|
||||
|
||||
void setMode(Byte paramByte);
|
||||
|
||||
void setPen(byte paramByte);
|
||||
|
||||
void setPen(Byte paramByte);
|
||||
|
||||
void setFill(byte paramByte);
|
||||
|
||||
void setFill(Byte paramByte);
|
||||
|
||||
void setRadius(int paramInt);
|
||||
|
||||
void setRadius(Integer paramInteger);
|
||||
|
||||
void setScaleImage(byte paramByte);
|
||||
|
||||
void setScaleImage(Byte paramByte);
|
||||
|
||||
void setHorizontalAlignment(byte paramByte);
|
||||
|
||||
void setHorizontalAlignment(Byte paramByte);
|
||||
|
||||
void setVerticalAlignment(byte paramByte);
|
||||
|
||||
void setVerticalAlignment(Byte paramByte);
|
||||
|
||||
void setBorder(byte paramByte);
|
||||
|
||||
void setBorder(Byte paramByte);
|
||||
|
||||
void setBorderColor(Color paramColor);
|
||||
|
||||
void setPadding(int paramInt);
|
||||
|
||||
void setPadding(Integer paramInteger);
|
||||
|
||||
void setTopBorder(byte paramByte);
|
||||
|
||||
void setTopBorder(Byte paramByte);
|
||||
|
||||
void setTopBorderColor(Color paramColor);
|
||||
|
||||
void setTopPadding(int paramInt);
|
||||
|
||||
void setTopPadding(Integer paramInteger);
|
||||
|
||||
void setLeftBorder(byte paramByte);
|
||||
|
||||
void setLeftBorder(Byte paramByte);
|
||||
|
||||
void setLeftBorderColor(Color paramColor);
|
||||
|
||||
void setLeftPadding(int paramInt);
|
||||
|
||||
void setLeftPadding(Integer paramInteger);
|
||||
|
||||
void setBottomBorder(byte paramByte);
|
||||
|
||||
void setBottomBorder(Byte paramByte);
|
||||
|
||||
void setBottomBorderColor(Color paramColor);
|
||||
|
||||
void setBottomPadding(int paramInt);
|
||||
|
||||
void setBottomPadding(Integer paramInteger);
|
||||
|
||||
void setRightBorder(byte paramByte);
|
||||
|
||||
void setRightBorder(Byte paramByte);
|
||||
|
||||
void setRightBorderColor(Color paramColor);
|
||||
|
||||
void setRightPadding(int paramInt);
|
||||
|
||||
void setRightPadding(Integer paramInteger);
|
||||
|
||||
void setRotation(byte paramByte);
|
||||
|
||||
void setRotation(Byte paramByte);
|
||||
|
||||
void setFontName(String paramString);
|
||||
|
||||
void setBold(boolean paramBoolean);
|
||||
|
||||
void setBold(Boolean paramBoolean);
|
||||
|
||||
void setItalic(boolean paramBoolean);
|
||||
|
||||
void setItalic(Boolean paramBoolean);
|
||||
|
||||
void setPdfEmbedded(boolean paramBoolean);
|
||||
|
||||
void setPdfEmbedded(Boolean paramBoolean);
|
||||
|
||||
void setStrikeThrough(boolean paramBoolean);
|
||||
|
||||
void setStrikeThrough(Boolean paramBoolean);
|
||||
|
||||
void setStyledText(boolean paramBoolean);
|
||||
|
||||
void setStyledText(Boolean paramBoolean);
|
||||
|
||||
void setMarkup(String paramString);
|
||||
|
||||
void setUnderline(boolean paramBoolean);
|
||||
|
||||
void setUnderline(Boolean paramBoolean);
|
||||
|
||||
void setLineSpacing(byte paramByte);
|
||||
|
||||
void setLineSpacing(Byte paramByte);
|
||||
|
||||
void setPattern(String paramString);
|
||||
|
||||
void setBlankWhenNull(boolean paramBoolean);
|
||||
|
||||
void setBlankWhenNull(Boolean paramBoolean);
|
||||
|
||||
void setPdfEncoding(String paramString);
|
||||
|
||||
void setPdfFontName(String paramString);
|
||||
|
||||
void setFontSize(int paramInt);
|
||||
|
||||
void setFontSize(Integer paramInteger);
|
||||
|
||||
JRConditionalStyle[] getConditionalStyles();
|
||||
}
|
@@ -0,0 +1,9 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRStyleContainer {
|
||||
JRDefaultStyleProvider getDefaultStyleProvider();
|
||||
|
||||
JRStyle getStyle();
|
||||
|
||||
String getStyleNameReference();
|
||||
}
|
7
hrmsEjb/net/sf/jasperreports/engine/JRStyleSetter.java
Normal file
7
hrmsEjb/net/sf/jasperreports/engine/JRStyleSetter.java
Normal file
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRStyleSetter {
|
||||
void setStyle(JRStyle paramJRStyle);
|
||||
|
||||
void setStyleNameReference(String paramString);
|
||||
}
|
@@ -0,0 +1,36 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import java.awt.font.TextAttribute;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import net.sf.jasperreports.engine.util.JRFontUtil;
|
||||
|
||||
public interface JRStyledTextAttributeSelector {
|
||||
public static final JRStyledTextAttributeSelector ALL = new JRStyledTextAttributeSelector() {
|
||||
public Map getStyledTextAttributes(JRPrintText printText) {
|
||||
Map attributes = new HashMap();
|
||||
attributes.putAll(JRFontUtil.setAttributes(attributes, printText));
|
||||
attributes.put(TextAttribute.FOREGROUND, printText.getForecolor());
|
||||
if (printText.getMode() == 1)
|
||||
attributes.put(TextAttribute.BACKGROUND, printText.getBackcolor());
|
||||
return attributes;
|
||||
}
|
||||
};
|
||||
|
||||
public static final JRStyledTextAttributeSelector NO_BACKCOLOR = new JRStyledTextAttributeSelector() {
|
||||
public Map getStyledTextAttributes(JRPrintText printText) {
|
||||
Map attributes = new HashMap();
|
||||
attributes.putAll(JRFontUtil.setAttributes(attributes, printText));
|
||||
attributes.put(TextAttribute.FOREGROUND, printText.getForecolor());
|
||||
return attributes;
|
||||
}
|
||||
};
|
||||
|
||||
public static final JRStyledTextAttributeSelector NONE = new JRStyledTextAttributeSelector() {
|
||||
public Map getStyledTextAttributes(JRPrintText printText) {
|
||||
return null;
|
||||
}
|
||||
};
|
||||
|
||||
Map getStyledTextAttributes(JRPrintText paramJRPrintText);
|
||||
}
|
23
hrmsEjb/net/sf/jasperreports/engine/JRSubreport.java
Normal file
23
hrmsEjb/net/sf/jasperreports/engine/JRSubreport.java
Normal file
@@ -0,0 +1,23 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRSubreport extends JRElement {
|
||||
boolean isUsingCache();
|
||||
|
||||
void setUsingCache(boolean paramBoolean);
|
||||
|
||||
JRExpression getParametersMapExpression();
|
||||
|
||||
JRSubreportParameter[] getParameters();
|
||||
|
||||
JRExpression getConnectionExpression();
|
||||
|
||||
JRExpression getDataSourceExpression();
|
||||
|
||||
JRExpression getExpression();
|
||||
|
||||
JRSubreportReturnValue[] getReturnValues();
|
||||
|
||||
Boolean isOwnUsingCache();
|
||||
|
||||
void setUsingCache(Boolean paramBoolean);
|
||||
}
|
@@ -0,0 +1,3 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRSubreportParameter extends JRDatasetParameter {}
|
@@ -0,0 +1,11 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRSubreportReturnValue extends JRCloneable {
|
||||
String getSubreportVariable();
|
||||
|
||||
String getToVariable();
|
||||
|
||||
byte getCalculation();
|
||||
|
||||
String getIncrementerFactoryClassName();
|
||||
}
|
7
hrmsEjb/net/sf/jasperreports/engine/JRTemplate.java
Normal file
7
hrmsEjb/net/sf/jasperreports/engine/JRTemplate.java
Normal file
@@ -0,0 +1,7 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRTemplate extends JRDefaultStyleProvider {
|
||||
JRTemplateReference[] getIncludedTemplates();
|
||||
|
||||
JRStyle[] getStyles();
|
||||
}
|
19
hrmsEjb/net/sf/jasperreports/engine/JRTemplateReference.java
Normal file
19
hrmsEjb/net/sf/jasperreports/engine/JRTemplateReference.java
Normal file
@@ -0,0 +1,19 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public class JRTemplateReference {
|
||||
private String location;
|
||||
|
||||
public JRTemplateReference() {}
|
||||
|
||||
public JRTemplateReference(String location) {
|
||||
this.location = location;
|
||||
}
|
||||
|
||||
public String getLocation() {
|
||||
return this.location;
|
||||
}
|
||||
|
||||
public void setLocation(String location) {
|
||||
this.location = location;
|
||||
}
|
||||
}
|
51
hrmsEjb/net/sf/jasperreports/engine/JRTextElement.java
Normal file
51
hrmsEjb/net/sf/jasperreports/engine/JRTextElement.java
Normal file
@@ -0,0 +1,51 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRTextElement extends JRElement, JRAlignment, JRBox, JRFont, JRCommonText {
|
||||
public static final String PROPERTY_PRINT_KEEP_FULL_TEXT = "net.sf.jasperreports.print.keep.full.text";
|
||||
|
||||
public static final String PROPERTY_TRUNCATE_AT_CHAR = "net.sf.jasperreports.text.truncate.at.char";
|
||||
|
||||
public static final String PROPERTY_TRUNCATE_SUFFIX = "net.sf.jasperreports.text.truncate.suffix";
|
||||
|
||||
public static final byte TEXT_ALIGN_LEFT = 1;
|
||||
|
||||
public static final byte TEXT_ALIGN_CENTER = 2;
|
||||
|
||||
public static final byte TEXT_ALIGN_RIGHT = 3;
|
||||
|
||||
public static final byte TEXT_ALIGN_JUSTIFIED = 4;
|
||||
|
||||
public static final byte ROTATION_NONE = 0;
|
||||
|
||||
public static final byte ROTATION_LEFT = 1;
|
||||
|
||||
public static final byte ROTATION_RIGHT = 2;
|
||||
|
||||
public static final byte ROTATION_UPSIDE_DOWN = 3;
|
||||
|
||||
public static final byte LINE_SPACING_SINGLE = 0;
|
||||
|
||||
public static final byte LINE_SPACING_1_1_2 = 1;
|
||||
|
||||
public static final byte LINE_SPACING_DOUBLE = 2;
|
||||
|
||||
byte getTextAlignment();
|
||||
|
||||
void setTextAlignment(byte paramByte);
|
||||
|
||||
void setRotation(byte paramByte);
|
||||
|
||||
void setRotation(Byte paramByte);
|
||||
|
||||
void setLineSpacing(byte paramByte);
|
||||
|
||||
void setLineSpacing(Byte paramByte);
|
||||
|
||||
void setStyledText(boolean paramBoolean);
|
||||
|
||||
void setStyledText(Boolean paramBoolean);
|
||||
|
||||
JRBox getBox();
|
||||
|
||||
JRFont getFont();
|
||||
}
|
41
hrmsEjb/net/sf/jasperreports/engine/JRTextField.java
Normal file
41
hrmsEjb/net/sf/jasperreports/engine/JRTextField.java
Normal file
@@ -0,0 +1,41 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRTextField extends JRTextElement, JRAnchor, JRHyperlink {
|
||||
public static final String STANDARD_DATE_FORMAT_DEFAULT = "default";
|
||||
|
||||
public static final String STANDARD_DATE_FORMAT_SHORT = "short";
|
||||
|
||||
public static final String STANDARD_DATE_FORMAT_MEDIUM = "medium";
|
||||
|
||||
public static final String STANDARD_DATE_FORMAT_LONG = "long";
|
||||
|
||||
public static final String STANDARD_DATE_FORMAT_FULL = "full";
|
||||
|
||||
public static final String STANDARD_DATE_FORMAT_HIDE = "hide";
|
||||
|
||||
public static final String STANDARD_DATE_FORMAT_SEPARATOR = ",";
|
||||
|
||||
boolean isStretchWithOverflow();
|
||||
|
||||
void setStretchWithOverflow(boolean paramBoolean);
|
||||
|
||||
byte getEvaluationTime();
|
||||
|
||||
String getPattern();
|
||||
|
||||
String getOwnPattern();
|
||||
|
||||
void setPattern(String paramString);
|
||||
|
||||
boolean isBlankWhenNull();
|
||||
|
||||
Boolean isOwnBlankWhenNull();
|
||||
|
||||
void setBlankWhenNull(boolean paramBoolean);
|
||||
|
||||
void setBlankWhenNull(Boolean paramBoolean);
|
||||
|
||||
JRGroup getEvaluationGroup();
|
||||
|
||||
JRExpression getExpression();
|
||||
}
|
@@ -0,0 +1,5 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRValueParameter extends JRParameter {
|
||||
Object getValue();
|
||||
}
|
71
hrmsEjb/net/sf/jasperreports/engine/JRVariable.java
Normal file
71
hrmsEjb/net/sf/jasperreports/engine/JRVariable.java
Normal file
@@ -0,0 +1,71 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRVariable extends JRCloneable {
|
||||
public static final String REPORT_COUNT = "REPORT_COUNT";
|
||||
|
||||
public static final String PAGE_COUNT = "PAGE_COUNT";
|
||||
|
||||
public static final String COLUMN_COUNT = "COLUMN_COUNT";
|
||||
|
||||
public static final String PAGE_NUMBER = "PAGE_NUMBER";
|
||||
|
||||
public static final String COLUMN_NUMBER = "COLUMN_NUMBER";
|
||||
|
||||
public static final byte RESET_TYPE_REPORT = 1;
|
||||
|
||||
public static final byte RESET_TYPE_PAGE = 2;
|
||||
|
||||
public static final byte RESET_TYPE_COLUMN = 3;
|
||||
|
||||
public static final byte RESET_TYPE_GROUP = 4;
|
||||
|
||||
public static final byte RESET_TYPE_NONE = 5;
|
||||
|
||||
public static final byte CALCULATION_NOTHING = 0;
|
||||
|
||||
public static final byte CALCULATION_COUNT = 1;
|
||||
|
||||
public static final byte CALCULATION_SUM = 2;
|
||||
|
||||
public static final byte CALCULATION_AVERAGE = 3;
|
||||
|
||||
public static final byte CALCULATION_LOWEST = 4;
|
||||
|
||||
public static final byte CALCULATION_HIGHEST = 5;
|
||||
|
||||
public static final byte CALCULATION_STANDARD_DEVIATION = 6;
|
||||
|
||||
public static final byte CALCULATION_VARIANCE = 7;
|
||||
|
||||
public static final byte CALCULATION_SYSTEM = 8;
|
||||
|
||||
public static final byte CALCULATION_FIRST = 9;
|
||||
|
||||
public static final byte CALCULATION_DISTINCT_COUNT = 10;
|
||||
|
||||
String getName();
|
||||
|
||||
Class getValueClass();
|
||||
|
||||
String getValueClassName();
|
||||
|
||||
Class getIncrementerFactoryClass();
|
||||
|
||||
String getIncrementerFactoryClassName();
|
||||
|
||||
byte getResetType();
|
||||
|
||||
byte getIncrementType();
|
||||
|
||||
byte getCalculation();
|
||||
|
||||
boolean isSystemDefined();
|
||||
|
||||
JRExpression getExpression();
|
||||
|
||||
JRExpression getInitialValueExpression();
|
||||
|
||||
JRGroup getResetGroup();
|
||||
|
||||
JRGroup getIncrementGroup();
|
||||
}
|
25
hrmsEjb/net/sf/jasperreports/engine/JRVirtualizable.java
Normal file
25
hrmsEjb/net/sf/jasperreports/engine/JRVirtualizable.java
Normal file
@@ -0,0 +1,25 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
import net.sf.jasperreports.engine.fill.JRVirtualizationContext;
|
||||
|
||||
public interface JRVirtualizable {
|
||||
String getUID();
|
||||
|
||||
void setVirtualData(Object paramObject);
|
||||
|
||||
Object getVirtualData();
|
||||
|
||||
void removeVirtualData();
|
||||
|
||||
void setIdentityData(Object paramObject);
|
||||
|
||||
Object getIdentityData();
|
||||
|
||||
void beforeExternalization();
|
||||
|
||||
void afterExternalization();
|
||||
|
||||
void afterInternalization();
|
||||
|
||||
JRVirtualizationContext getContext();
|
||||
}
|
@@ -0,0 +1,17 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public class JRVirtualizationHelper {
|
||||
private static final ThreadLocal threadVirtualizer = new ThreadLocal();
|
||||
|
||||
public static void setThreadVirtualizer(JRVirtualizer virtualizer) {
|
||||
threadVirtualizer.set(virtualizer);
|
||||
}
|
||||
|
||||
public static void clearThreadVirtualizer() {
|
||||
threadVirtualizer.set(null);
|
||||
}
|
||||
|
||||
public static JRVirtualizer getThreadVirtualizer() {
|
||||
return threadVirtualizer.get();
|
||||
}
|
||||
}
|
17
hrmsEjb/net/sf/jasperreports/engine/JRVirtualizer.java
Normal file
17
hrmsEjb/net/sf/jasperreports/engine/JRVirtualizer.java
Normal file
@@ -0,0 +1,17 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRVirtualizer {
|
||||
void registerObject(JRVirtualizable paramJRVirtualizable);
|
||||
|
||||
void deregisterObject(JRVirtualizable paramJRVirtualizable);
|
||||
|
||||
void touch(JRVirtualizable paramJRVirtualizable);
|
||||
|
||||
void requestData(JRVirtualizable paramJRVirtualizable);
|
||||
|
||||
void clearData(JRVirtualizable paramJRVirtualizable);
|
||||
|
||||
void virtualizeData(JRVirtualizable paramJRVirtualizable);
|
||||
|
||||
void cleanup();
|
||||
}
|
5
hrmsEjb/net/sf/jasperreports/engine/JRVisitable.java
Normal file
5
hrmsEjb/net/sf/jasperreports/engine/JRVisitable.java
Normal file
@@ -0,0 +1,5 @@
|
||||
package net.sf.jasperreports.engine;
|
||||
|
||||
public interface JRVisitable {
|
||||
void visit(JRVisitor paramJRVisitor);
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user