本文整理汇总了Java中net.sf.jasperreports.charts.JRMultiAxisPlot类的典型用法代码示例。如果您正苦于以下问题:Java JRMultiAxisPlot类的具体用法?Java JRMultiAxisPlot怎么用?Java JRMultiAxisPlot使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
JRMultiAxisPlot类属于net.sf.jasperreports.charts包,在下文中一共展示了JRMultiAxisPlot类的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: JRBaseMultiAxisPlot
import net.sf.jasperreports.charts.JRMultiAxisPlot; //导入依赖的package包/类
/**
* Creates a copy of an existing multiple axis chart plot and registers
* any expression contained in the plot with the specified factory. Since
* the plot contains multiple other charts nested inside of it all of the
* expressions used by those charts is also registered with the factory.
*
* @param multiAxisPlot the plot to copy
* @param factory the factory to register expressions with
*/
public JRBaseMultiAxisPlot(JRMultiAxisPlot multiAxisPlot, JRBaseObjectFactory factory)
{
super(multiAxisPlot, factory);
List<JRChartAxis> origAxes = multiAxisPlot.getAxes();
axes.clear();
if (origAxes != null)
{
Iterator<JRChartAxis> iter = origAxes.iterator();
while (iter.hasNext())
{
JRChartAxis axis = iter.next();
axes.add(factory.getChartAxis(axis));
}
}
}
示例2: getMultiAxisPlot
import net.sf.jasperreports.charts.JRMultiAxisPlot; //导入依赖的package包/类
/**
*
*/
public JRMultiAxisPlot getMultiAxisPlot(JRMultiAxisPlot multiAxisPlot)
{
JRBaseMultiAxisPlot baseMultiAxisPlot = null;
if (multiAxisPlot != null)
{
baseMultiAxisPlot = (JRBaseMultiAxisPlot)get(multiAxisPlot);
if (baseMultiAxisPlot == null)
{
baseMultiAxisPlot = new JRBaseMultiAxisPlot(multiAxisPlot, this);
}
}
return baseMultiAxisPlot;
}
示例3: writeMultiAxisChart
import net.sf.jasperreports.charts.JRMultiAxisPlot; //导入依赖的package包/类
/**
* Writes the definition of a multiple axis chart to the output stream.
*
* @param chart the multiple axis chart to write
*/
public void writeMultiAxisChart( JRChart chart, String chartName)
{
if(chart != null)
{
write( "JRDesignChart " + chartName + " = new JRDesignChart(jasperDesign, JRChart.CHART_TYPE_MULTI_AXIS);\n");
writeChart( chart, chartName);
JRMultiAxisPlot plot = (JRMultiAxisPlot) chart.getPlot();
String plotName = chartName + "MultiAxisPlot";
write( "JRDesignMultiAxisPlot " + plotName + " = (JRDesignMultiAxisPlot)" + chartName + ".getPlot();\n");
write( plotName + ".setChart(" + chartName + ");\n");//FIXMECHART why is this needed since we get the plot from chart?
writePlot( chart.getPlot(), plotName);
List<JRChartAxis> axes = plot.getAxes();
if (axes != null && axes.size() > 0)
{
for (int i = 0; i < axes.size(); i++)
{
JRChartAxis chartAxis = axes.get(i);
writeChartAxis( chartAxis, plotName, plotName + "Axis" + i, chartName);
}
}
flush();
}
}
示例4: getMultiAxisPlot
import net.sf.jasperreports.charts.JRMultiAxisPlot; //导入依赖的package包/类
/**
*
*/
public JRMultiAxisPlot getMultiAxisPlot(JRMultiAxisPlot multiAxisPlot)
{
JRFillMultiAxisPlot fillMultiAxisPlot = null;
if (multiAxisPlot != null)
{
fillMultiAxisPlot = (JRFillMultiAxisPlot)get(multiAxisPlot);
if (fillMultiAxisPlot == null)
{
fillMultiAxisPlot = new JRFillMultiAxisPlot(multiAxisPlot, this);
}
}
return fillMultiAxisPlot;
}
示例5: JRFillMultiAxisPlot
import net.sf.jasperreports.charts.JRMultiAxisPlot; //导入依赖的package包/类
public JRFillMultiAxisPlot(JRMultiAxisPlot multiAxisPlot, JRFillObjectFactory factory)
{
super(multiAxisPlot, factory);
List<JRChartAxis> parentAxes = multiAxisPlot.getAxes();
this.axes = new ArrayList<JRChartAxis>(parentAxes.size());
Iterator<JRChartAxis> iter = parentAxes.iterator();
while (iter.hasNext())
{
JRChartAxis axis = iter.next();
this.axes.add(factory.getChartAxis(axis));
}
}
示例6: writeMultiAxisChart
import net.sf.jasperreports.charts.JRMultiAxisPlot; //导入依赖的package包/类
/**
* Writes the definition of a multiple axis chart to the output stream.
*
* @param chart the multiple axis chart to write
*/
public void writeMultiAxisChart(JRChart chart) throws IOException
{
writer.startElement(JRXmlConstants.ELEMENT_multiAxisChart, getNamespace());
writeChart(chart);
// write plot
JRMultiAxisPlot plot = (JRMultiAxisPlot) chart.getPlot();
writer.startElement(JRXmlConstants.ELEMENT_multiAxisPlot);
writePlot(chart.getPlot());
List<JRChartAxis> axes = plot.getAxes();
if (axes != null)
{
Iterator<JRChartAxis> iter = axes.iterator();
while (iter.hasNext())
{
JRChartAxis chartAxis = iter.next();
writeChartAxis(chartAxis);
}
}
writer.closeElement();
writer.closeElement();
}
示例7: getChartPlot
import net.sf.jasperreports.charts.JRMultiAxisPlot; //导入依赖的package包/类
public static MChartPlot getChartPlot(JRChartPlot plot) {
if (plot instanceof JRAreaPlot)
return new MAreaPlot((JRAreaPlot) plot);
if (plot instanceof JRBar3DPlot)
return new MBar3DPlot((JRBar3DPlot) plot);
if (plot instanceof JRBarPlot)
return new MBarPlot((JRBarPlot) plot);
if (plot instanceof JRBubblePlot)
return new MBubblePlot((JRBubblePlot) plot);
if (plot instanceof JRCandlestickPlot)
return new MCandlestickPlot((JRCandlestickPlot) plot);
if (plot instanceof JRHighLowPlot)
return new MHighLowPlot((JRHighLowPlot) plot);
if (plot instanceof JRLinePlot)
return new MLinePlot((JRLinePlot) plot);
if (plot instanceof JRMeterPlot)
return new MMeterPlot((JRMeterPlot) plot);
if (plot instanceof JRMultiAxisPlot)
return new MMultiAxisPlot((JRMultiAxisPlot) plot);
if (plot instanceof JRPie3DPlot)
return new MPie3DPlot((JRPie3DPlot) plot);
if (plot instanceof JRPiePlot)
return new MPiePlot((JRPiePlot) plot);
if (plot instanceof JRScatterPlot)
return new MScatterPlot((JRScatterPlot) plot);
if (plot instanceof JRThermometerPlot)
return new MThermometerPlot((JRThermometerPlot) plot);
if (plot instanceof JRTimeSeriesPlot)
return new MTimeSeriesPlot((JRTimeSeriesPlot) plot);
return new MChartPlot(plot);
}
示例8: getChildren4Element
import net.sf.jasperreports.charts.JRMultiAxisPlot; //导入依赖的package包/类
public List<?> getChildren4Element(Object jrObject) {
List<Object> ch = new ArrayList<Object>();
if (jrObject instanceof JRDesignCategoryDataset)
ch.addAll(((JRDesignCategoryDataset) jrObject).getSeriesList());
else if (jrObject instanceof JRDesignGanttDataset)
ch.addAll(((JRDesignGanttDataset) jrObject).getSeriesList());
else if (jrObject instanceof JRDesignPieDataset)
ch.addAll(((JRDesignPieDataset) jrObject).getSeriesList());
else if (jrObject instanceof JRDesignTimePeriodDataset)
ch.addAll(((JRDesignTimePeriodDataset) jrObject).getSeriesList());
else if (jrObject instanceof JRDesignTimeSeriesDataset)
ch.addAll(((JRDesignTimeSeriesDataset) jrObject).getSeriesList());
else if (jrObject instanceof JRDesignXyDataset)
ch.addAll(((JRDesignXyDataset) jrObject).getSeriesList());
else if (jrObject instanceof JRDesignXyzDataset)
ch.addAll(((JRDesignXyzDataset) jrObject).getSeriesList());
else if (jrObject instanceof JRDesignChartAxis)
ch.add(((JRDesignChartAxis) jrObject).getChart().getDataset());
if (jrObject instanceof JRChart) {
ch.add(((JRChart) jrObject).getDataset());
}
if (jrObject instanceof JRChart && ((JRChart) jrObject).getPlot() instanceof JRMultiAxisPlot) {
JRMultiAxisPlot slc = (JRMultiAxisPlot) ((JRChart) jrObject).getPlot();
if (slc.getAxes() != null)
ch.addAll(slc.getAxes());
}
return ch;
}
示例9: MMultiAxisPlot
import net.sf.jasperreports.charts.JRMultiAxisPlot; //导入依赖的package包/类
public MMultiAxisPlot(JRMultiAxisPlot value) {
super(value);
}