當前位置: 首頁>>代碼示例>>Java>>正文


Java JRCategorySeries類代碼示例

本文整理匯總了Java中net.sf.jasperreports.charts.JRCategorySeries的典型用法代碼示例。如果您正苦於以下問題:Java JRCategorySeries類的具體用法?Java JRCategorySeries怎麽用?Java JRCategorySeries使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


JRCategorySeries類屬於net.sf.jasperreports.charts包,在下文中一共展示了JRCategorySeries類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: JRBaseCategoryDataset

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
/**
 *
 */
public JRBaseCategoryDataset(JRCategoryDataset dataset, JRBaseObjectFactory factory)
{
	super(dataset, factory);

	/*   */
	JRCategorySeries[] srcCategorySeries = dataset.getSeries();
	if (srcCategorySeries != null && srcCategorySeries.length > 0)
	{
		categorySeries = new JRCategorySeries[srcCategorySeries.length];
		for(int i = 0; i < categorySeries.length; i++)
		{
			categorySeries[i] = factory.getCategorySeries(srcCategorySeries[i]);
		}
	}

}
 
開發者ID:TIBCOSoftware,項目名稱:jasperreports,代碼行數:20,代碼來源:JRBaseCategoryDataset.java

示例2: removeCategorySeries

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
/**
 *
 */
public JRCategorySeries removeCategorySeries(JRCategorySeries categorySeries)
{
	if (categorySeries != null)
	{
		int idx = categorySeriesList.indexOf(categorySeries);
		if (idx >= 0)
		{
			categorySeriesList.remove(idx);
			getEventSupport().fireCollectionElementRemovedEvent(PROPERTY_CATEGORY_SERIES, 
					categorySeries, idx);
		}
	}
	
	return categorySeries;
}
 
開發者ID:TIBCOSoftware,項目名稱:jasperreports,代碼行數:19,代碼來源:JRDesignCategoryDataset.java

示例3: JRFillCategoryDataset

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
/**
 *
 */
public JRFillCategoryDataset(
	JRCategoryDataset categoryDataset, 
	JRFillObjectFactory factory
	)
{
	super(categoryDataset, factory);

	/*   */
	JRCategorySeries[] srcCategorySeries = categoryDataset.getSeries();
	if (srcCategorySeries != null && srcCategorySeries.length > 0)
	{
		categorySeries = new JRFillCategorySeries[srcCategorySeries.length];
		for(int i = 0; i < categorySeries.length; i++)
		{
			categorySeries[i] = (JRFillCategorySeries)factory.getCategorySeries(srcCategorySeries[i]);
		}
	}
}
 
開發者ID:TIBCOSoftware,項目名稱:jasperreports,代碼行數:22,代碼來源:JRFillCategoryDataset.java

示例4: getCategorySeries

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
@Override
public JRCategorySeries getCategorySeries(JRCategorySeries categorySeries)
{
	JRBaseCategorySeries baseCategorySeries = null;

	if (categorySeries != null)
	{
		baseCategorySeries = (JRBaseCategorySeries)get(categorySeries);
		if (baseCategorySeries == null)
		{
			baseCategorySeries = new JRBaseCategorySeries(categorySeries, this);
		}
	}

	return baseCategorySeries;
}
 
開發者ID:TIBCOSoftware,項目名稱:jasperreports,代碼行數:17,代碼來源:JRBaseObjectFactory.java

示例5: writeCategoryDataSet

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
/**
 *
 */
private void writeCategoryDataSet(JRCategoryDataset dataset) throws IOException
{
	writer.startElement(JRXmlConstants.ELEMENT_categoryDataset);

	writeElementDataset(dataset);

	/*   */
	JRCategorySeries[] categorySeries = dataset.getSeries();
	if (categorySeries != null && categorySeries.length > 0)
	{
		for(int i = 0; i < categorySeries.length; i++)
		{
			writeCategorySeries(categorySeries[i]);
		}
	}

	writer.closeElement();
}
 
開發者ID:TIBCOSoftware,項目名稱:jasperreports,代碼行數:22,代碼來源:JRXmlWriter.java

示例6: writeCategoryDataSet

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
/**
 *
 */
private void writeCategoryDataSet( JRCategoryDataset dataset, String parentName, String datasetNameSuffix)
{
	if(dataset != null)
	{
		String datasetName = parentName + datasetNameSuffix;
		write( "JRDesignCategoryDataset " + datasetName + " = new JRDesignCategoryDataset("+ parentName + ".getDataset());\n");

		writeElementDataset( dataset, datasetName);

		JRCategorySeries[] categorySeries = dataset.getSeries();
		if (categorySeries != null && categorySeries.length > 0)
		{
			for(int i = 0; i < categorySeries.length; i++)
			{
				writeCategorySeries( categorySeries[i], datasetName, i);
			}
		}

		write( parentName + ".setDataset(" + datasetName + ");\n");
		flush();
	}
}
 
開發者ID:TIBCOSoftware,項目名稱:jasperreports,代碼行數:26,代碼來源:JRApiWriter.java

示例7: writeCategorySeries

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
/**
 *
 */
private void writeCategorySeries( JRCategorySeries categorySeries, String parentName, int index)
{
	if(categorySeries != null)
	{
		String categorySeriesName = parentName + "CategorySeries" + index;

		write( "JRDesignCategorySeries " + categorySeriesName + " = new JRDesignCategorySeries();\n");

		writeExpression( categorySeries.getSeriesExpression(), categorySeriesName, "SeriesExpression");
		writeExpression( categorySeries.getCategoryExpression(), categorySeriesName, "CategoryExpression");
		writeExpression( categorySeries.getValueExpression(), categorySeriesName, "ValueExpression");
		writeExpression( categorySeries.getLabelExpression(), categorySeriesName, "LabelExpression");
		writeHyperlink( categorySeries.getItemHyperlink(), categorySeriesName, "ItemHyperlink");
		write( parentName + ".addCategorySeries(" + categorySeriesName + ");\n");
		flush();
	}
}
 
開發者ID:TIBCOSoftware,項目名稱:jasperreports,代碼行數:21,代碼來源:JRApiWriter.java

示例8: getCategorySeries

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
@Override
public JRCategorySeries getCategorySeries(JRCategorySeries categorySeries)
{
	JRFillCategorySeries fillCategorySeries = null;

	if (categorySeries != null)
	{
		fillCategorySeries = (JRFillCategorySeries)get(categorySeries);
		if (fillCategorySeries == null)
		{
			fillCategorySeries = new JRFillCategorySeries(categorySeries, this);
		}
	}

	return fillCategorySeries;
}
 
開發者ID:TIBCOSoftware,項目名稱:jasperreports,代碼行數:17,代碼來源:JRFillObjectFactory.java

示例9: writeSpiderDataSet

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
private void writeSpiderDataSet(SpiderDataset dataset, JRXmlWriteHelper writer, JRXmlWriter reportWriter, XmlNamespace namespace) throws IOException
{
	writer.startElement(ELEMENT_spiderDataset, namespace);

	reportWriter.writeElementDataset(dataset);

	/*   */
	JRCategorySeries[] categorySeries = dataset.getSeries();
	if (categorySeries != null && categorySeries.length > 0)
	{
		for(int i = 0; i < categorySeries.length; i++)
		{
			writeCategorySeries(categorySeries[i], writer, reportWriter);
		}
	}

	writer.closeElement();
}
 
開發者ID:TIBCOSoftware,項目名稱:jasperreports,代碼行數:19,代碼來源:SpiderChartXmlWriter.java

示例10: collectExpressions

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
public static void collectExpressions(SpiderDataset dataset, JRExpressionCollector collector)
{
	if(dataset != null)
	{
		collector.collect(dataset);

		JRCategorySeries[] categorySeries = dataset.getSeries();
		if (categorySeries != null && categorySeries.length > 0)
		{
			JRExpressionCollector seriesCollector = collector.getCollector(dataset);
			for(int j = 0; j < categorySeries.length; j++)
			{
				seriesCollector.addExpression(categorySeries[j].getSeriesExpression());
				seriesCollector.addExpression(categorySeries[j].getCategoryExpression());
				seriesCollector.addExpression(categorySeries[j].getValueExpression());
				seriesCollector.addExpression(categorySeries[j].getLabelExpression());

				seriesCollector.collectHyperlink(categorySeries[j].getItemHyperlink());
				
			}
		}
	}
}
 
開發者ID:TIBCOSoftware,項目名稱:jasperreports,代碼行數:24,代碼來源:SpiderChartCompiler.java

示例11: FillSpiderDataset

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
/**
 *
 */
public FillSpiderDataset(
	SpiderDataset spiderDataset, 
	JRFillObjectFactory factory
	)
{
	super(spiderDataset, factory);

	/*   */
	JRCategorySeries[] srcCategorySeries = spiderDataset.getSeries();
	if (srcCategorySeries != null && srcCategorySeries.length > 0)
	{
		categorySeries = new JRFillCategorySeries[srcCategorySeries.length];
		for(int i = 0; i < srcCategorySeries.length; i++)
		{
			categorySeries[i] = (JRFillCategorySeries)factory.getCategorySeries(srcCategorySeries[i]);
		}
	}
}
 
開發者ID:TIBCOSoftware,項目名稱:jasperreports,代碼行數:22,代碼來源:FillSpiderDataset.java

示例12: setSeries

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
private void setSeries(int selection) {
	List<JRCategorySeries> seriesList = dataset.getSeriesList();
	if (!seriesList.isEmpty()) {
		String[] srnames = new String[seriesList.size()];
		for (int i = 0; i < seriesList.size(); i++) {
			JRCategorySeries cs = seriesList.get(i);
			JRExpression se = cs.getSeriesExpression();
			srnames[i] = se != null && se.getText() != null ? se.getText()
					: ""; //$NON-NLS-1$
		}
		seriesCombo.setItems(srnames);
		seriesCombo.select(selection);
		hyperlinkBtn.setEnabled(true);
		handleSelectSeries(selection);
	} else {
		seriesCombo.setItems(new String[0]);
		hyperlinkBtn.setEnabled(false);
		hyperlinkBtn.setText(Messages.DSCategory_hyperlinkButtonDisabled);
		handleSelectSeries(-1);
	}
}
 
開發者ID:OpenSoftwareSolutions,項目名稱:PDFReporter-Studio,代碼行數:22,代碼來源:DSCategory.java

示例13: setSeries

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
private void setSeries(int selection) {
	List<JRCategorySeries> seriesList = dataset.getSeriesList();
	if (!seriesList.isEmpty()) {
		String[] srnames = new String[seriesList.size()];
		for (int i = 0; i < seriesList.size(); i++) {
			JRCategorySeries cs = seriesList.get(i);
			JRExpression se = cs.getSeriesExpression();
			srnames[i] = se != null && se.getText() != null ? se.getText()
					: "";
		}
		seriesCombo.setItems(srnames);
		seriesCombo.select(selection);
		hyperlinkBtn.setEnabled(true);
		handleSelectSeries(selection);
	} else {
		seriesCombo.setItems(new String[0]);
		hyperlinkBtn.setEnabled(false);
		hyperlinkBtn.setText(Messages.DSCategory_hyperlinkButtonDisabled);
		handleSelectSeries(-1);
	}
}
 
開發者ID:OpenSoftwareSolutions,項目名稱:PDFReporter-Studio,代碼行數:22,代碼來源:DSSpider.java

示例14: jMenuItemPasteActionPerformed

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
private void jMenuItemPasteActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jMenuItemPasteActionPerformed
        java.util.List series = IReportManager.getInstance().getChartSeriesClipBoard();
        //getChartSeriesClipBoard()
        if (currentSelectedChartComponent == null) return;
        if (series != null && series.size() > 0) {
            for (int i=0; i<series.size(); ++i) {
                if (series.get(i) instanceof JRCategorySeries) {
                    JRDesignCategorySeries cs = (JRDesignCategorySeries)series.get(i);
                    try {
                        cs = cloneChartDatasetItem((JRDesignCategorySeries)cs);
                    } catch (Exception ex) {
                        ex.printStackTrace();
                        continue;
                    }
                    ((StandardSpiderDataset)currentSelectedChartComponent.getDataset()).addCategorySeries(cs);
                    ((javax.swing.DefaultListModel)jList1.getModel()).addElement(cs);
                }
            }
            jList1.updateUI();
        }
}
 
開發者ID:JockiHendry,項目名稱:ireport-fork,代碼行數:22,代碼來源:SpiderChartPanel.java

示例15: JRBaseCategorySeries

import net.sf.jasperreports.charts.JRCategorySeries; //導入依賴的package包/類
/**
 *
 */
public JRBaseCategorySeries(JRCategorySeries categorySeries, JRBaseObjectFactory factory)
{
	factory.put(categorySeries, this);

	seriesExpression = factory.getExpression(categorySeries.getSeriesExpression());
	categoryExpression = factory.getExpression(categorySeries.getCategoryExpression());
	valueExpression = factory.getExpression(categorySeries.getValueExpression());
	labelExpression = factory.getExpression(categorySeries.getLabelExpression());
	itemHyperlink = factory.getHyperlink(categorySeries.getItemHyperlink());
}
 
開發者ID:TIBCOSoftware,項目名稱:jasperreports,代碼行數:14,代碼來源:JRBaseCategorySeries.java


注:本文中的net.sf.jasperreports.charts.JRCategorySeries類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。