Class ChartComponent
- java.lang.Object
-
- org.pentaho.platform.plugin.action.chartbeans.ChartComponent
-
public class ChartComponent extends Object
Deprecated.please useChartActionThis is a bean that permits easy access to the ChartBeans functionality and was specifically designed to be run from within the Pentaho Platform as an Action Sequence Component.- Author:
- cboyden
-
-
Field Summary
Fields Modifier and Type Field Description protected ExceptionbootExceptionDeprecated.protected intcategoryColumnDeprecated.protected StringcategoryColumnNameDeprecated.protected StringchartEngineDeprecated.protected intchartHeightDeprecated.protected org.pentaho.chart.model.ChartModelchartModelDeprecated.protected StringchartModelJsonDeprecated.protected StringchartModelXmlDeprecated.protected intchartWidthDeprecated.protected StringcontentLinkingTemplateDeprecated.protected booleanconvertNullsToZeroDeprecated.protected static intDEFAULT_CHART_HEIGHTDeprecated.protected static intDEFAULT_CHART_WIDTHDeprecated.protected OutputStreamoutputStreamDeprecated.protected StringoutputTypeDeprecated.protected org.pentaho.commons.connection.IPentahoResultSetresultSetDeprecated.protected NumberscalingFactorDeprecated.protected intseriesColumnDeprecated.protected StringseriesColumnNameDeprecated.protected StringtitleDeprecated.protected intvalueColumnDeprecated.protected StringvalueColumnNameDeprecated.
-
Constructor Summary
Constructors Constructor Description ChartComponent()Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description booleanexecute()Deprecated.Called to process the chart definition and data set to produce a usable chart.StringgetChartEngine()Deprecated.Get the chart engine that the resulting chart was created throughbooleangetConvertNullsToZero()Deprecated.StringgetMimeType()Deprecated.Fetch the desired MimeTypeprotected org.pentaho.chart.plugin.api.IOutput.OutputTypesgetOutputType()Deprecated.Fetch the desired output typeStringgetSwfName()Deprecated.StringgetSwfPath()Deprecated.protected voidloadChartEngine()Deprecated.Sets the chart engine based on the order of precedence: 1) Chart Definition 2) Action Sequence 3) System Setting 4) Hard Codedprotected voidloadChartModel()Deprecated.protected Object[][]processChartData(org.pentaho.commons.connection.IPentahoResultSet resultSet, int valueColumnIndex)Deprecated.Transform the IPentahoResultSet into the data format suitable for chart creation.voidsetCategoryColumn(String categoryCol)Deprecated.Define the column in the data set that contains the Category datavoidsetChartData(org.pentaho.commons.connection.IPentahoResultSet chartDataSet)Deprecated.Define the data set that will populate the chartvoidsetChartEngine(String chartEngine)Deprecated.Set the chart engine to render the chartvoidsetChartHeight(int chartHeight)Deprecated.Set the height of the chart in units specific to the ChartPluginvoidsetChartHeight(String chartHeight)Deprecated.Set the height of the chart in units specific to the ChartPluginvoidsetChartModel(org.pentaho.chart.model.ChartModel chartModel)Deprecated.Set the ChartModelvoidsetChartModelJson(String chartModelJson)Deprecated.Set the JSON representation of the ChartModelvoidsetChartModelXml(String chartModelXml)Deprecated.Set the XML representation of the ChartModelvoidsetChartWidth(int chartWidth)Deprecated.Set the width of the chart in units specific to the ChartPluginvoidsetChartWidth(String chartWidth)Deprecated.Set the width of the chart in units specific to the ChartPluginvoidsetContentLinkingTemplate(String template)Deprecated.voidsetConvertNullsToZero(boolean convert)Deprecated.voidsetOutputStream(OutputStream outStream)Deprecated.Define the OutputStream to which the resulting chart shall be writtenvoidsetOutputType(String outputType)Deprecated.voidsetScalingFactor(Double scalingFactor)Deprecated.voidsetSeriesColumn(String seriesCol)Deprecated.Define the column in the data set that contains the Series/Domain datavoidsetValueColumn(String valueCol)Deprecated.Define the column in the data set that contains the Value/Range databooleanvalidate()Deprecated.Validate the current settings of the ChartComponent.
-
-
-
Field Detail
-
DEFAULT_CHART_WIDTH
protected static final int DEFAULT_CHART_WIDTH
Deprecated.- See Also:
- Constant Field Values
-
DEFAULT_CHART_HEIGHT
protected static final int DEFAULT_CHART_HEIGHT
Deprecated.- See Also:
- Constant Field Values
-
convertNullsToZero
protected boolean convertNullsToZero
Deprecated.
-
seriesColumnName
protected String seriesColumnName
Deprecated.
-
seriesColumn
protected int seriesColumn
Deprecated.
-
categoryColumnName
protected String categoryColumnName
Deprecated.
-
categoryColumn
protected int categoryColumn
Deprecated.
-
valueColumnName
protected String valueColumnName
Deprecated.
-
valueColumn
protected int valueColumn
Deprecated.
-
resultSet
protected org.pentaho.commons.connection.IPentahoResultSet resultSet
Deprecated.
-
chartEngine
protected String chartEngine
Deprecated.
-
bootException
protected Exception bootException
Deprecated.
-
outputType
protected String outputType
Deprecated.
-
chartWidth
protected int chartWidth
Deprecated.
-
chartHeight
protected int chartHeight
Deprecated.
-
scalingFactor
protected Number scalingFactor
Deprecated.
-
outputStream
protected OutputStream outputStream
Deprecated.
-
chartModelJson
protected String chartModelJson
Deprecated.
-
chartModelXml
protected String chartModelXml
Deprecated.
-
chartModel
protected org.pentaho.chart.model.ChartModel chartModel
Deprecated.
-
contentLinkingTemplate
protected String contentLinkingTemplate
Deprecated.
-
title
protected String title
Deprecated.
-
-
Method Detail
-
execute
public boolean execute() throws ChartBootException, org.pentaho.chart.plugin.ChartProcessingException, org.pentaho.reporting.libraries.resourceloader.ResourceException, org.pentaho.chart.InvalidChartDefinition, IOException, org.pentaho.chart.plugin.api.PersistenceExceptionDeprecated.Called to process the chart definition and data set to produce a usable chart.- Returns:
- state of execution. 'true' if execution was successful, otherwise false.
- Throws:
ChartBootExceptionorg.pentaho.chart.plugin.ChartProcessingExceptionorg.pentaho.reporting.libraries.resourceloader.ResourceExceptionorg.pentaho.chart.InvalidChartDefinitionIOExceptionorg.pentaho.chart.plugin.api.PersistenceException
-
processChartData
protected Object[][] processChartData(org.pentaho.commons.connection.IPentahoResultSet resultSet, int valueColumnIndex)
Deprecated.Transform the IPentahoResultSet into the data format suitable for chart creation.- Returns:
- Row / Column data table or null
-
setOutputStream
public void setOutputStream(OutputStream outStream)
Deprecated.Define the OutputStream to which the resulting chart shall be written- Parameters:
outStream- Stream receive the chart
-
setChartData
public void setChartData(org.pentaho.commons.connection.IPentahoResultSet chartDataSet)
Deprecated.Define the data set that will populate the chart- Parameters:
chartDataSet- data set for charting
-
validate
public boolean validate() throws ExceptionDeprecated.Validate the current settings of the ChartComponent. If validate() returns true, then execute may be called. If validate() returns false, a call to execute() is guaranteed to fail.- Returns:
- state of validation
- Throws:
Exception
-
setSeriesColumn
public void setSeriesColumn(String seriesCol)
Deprecated.Define the column in the data set that contains the Series/Domain data- Parameters:
seriesCol- name of column that contains the Series/Domain for the chart
-
setConvertNullsToZero
public void setConvertNullsToZero(boolean convert)
Deprecated.
-
getConvertNullsToZero
public boolean getConvertNullsToZero()
Deprecated.
-
setCategoryColumn
public void setCategoryColumn(String categoryCol)
Deprecated.Define the column in the data set that contains the Category data- Parameters:
seriesCol- name of column that contains the Category for the chart
-
setValueColumn
public void setValueColumn(String valueCol)
Deprecated.Define the column in the data set that contains the Value/Range data- Parameters:
seriesCol- name of column that contains the Value/Range for the chart
-
getOutputType
protected org.pentaho.chart.plugin.api.IOutput.OutputTypes getOutputType()
Deprecated.Fetch the desired output type- Returns:
- output type
-
getMimeType
public String getMimeType()
Deprecated.Fetch the desired MimeType- Returns:
- mime type
-
loadChartEngine
protected void loadChartEngine()
Deprecated.Sets the chart engine based on the order of precedence: 1) Chart Definition 2) Action Sequence 3) System Setting 4) Hard Coded
-
loadChartModel
protected void loadChartModel()
Deprecated.
-
setChartModelJson
public void setChartModelJson(String chartModelJson)
Deprecated.Set the JSON representation of the ChartModel- Parameters:
chartModelJson- JSON serialized representation of the ChartModel
-
setChartModelXml
public void setChartModelXml(String chartModelXml)
Deprecated.Set the XML representation of the ChartModel- Parameters:
chartStyleXml- XML serialized representation of the ChartModel
-
setChartModel
public void setChartModel(org.pentaho.chart.model.ChartModel chartModel)
Deprecated.Set the ChartModel- Parameters:
chartModel- model of the chart to be generated
-
setChartWidth
public void setChartWidth(int chartWidth)
Deprecated.Set the width of the chart in units specific to the ChartPlugin- Parameters:
chartWidth- width of the chart
-
setChartHeight
public void setChartHeight(int chartHeight)
Deprecated.Set the height of the chart in units specific to the ChartPlugin- Parameters:
chartHeight- height of the chart
-
setChartWidth
public void setChartWidth(String chartWidth)
Deprecated.Set the width of the chart in units specific to the ChartPlugin- Parameters:
chartWidth- width of the chart
-
setChartHeight
public void setChartHeight(String chartHeight)
Deprecated.Set the height of the chart in units specific to the ChartPlugin- Parameters:
chartHeight- height of the chart
-
getChartEngine
public String getChartEngine()
Deprecated.Get the chart engine that the resulting chart was created through- Returns:
-
setChartEngine
public void setChartEngine(String chartEngine)
Deprecated.Set the chart engine to render the chart- Parameters:
chartEngine- Value of "JFreeChart" or "OpenFlashChart"
-
setOutputType
public void setOutputType(String outputType)
Deprecated.
-
setScalingFactor
public void setScalingFactor(Double scalingFactor)
Deprecated.
-
getSwfPath
public String getSwfPath()
Deprecated.
-
getSwfName
public String getSwfName()
Deprecated.
-
setContentLinkingTemplate
public void setContentLinkingTemplate(String template)
Deprecated.
-
-