Class to represent a complete chart.
Source for this file: /Graph/src/interfaces/chart.php
Version: | //autogentag// |
Child Class | Description |
---|---|
ezcGraphRadarChart | Class for radar charts. |
ezcGraphLineChart | Class for line charts. Can make use of an unlimited amount of datasets and will display them as lines by default. |
ezcGraphOdometerChart | Class for odometer charts. Can only use one dataset which will be dispalyed as a odometer chart. |
ezcGraphPieChart | Class for pie charts. Can only use one dataset which will be dispalyed as a pie chart. |
ezcGraphDriver | read/write |
$driver
Output driver used for chart |
ezcGraphPalette | read/write |
$palette
Palette used for colorization of chart |
mixed | read |
$renderedFile
Contains the filename of the rendered file, if rendered. |
ezcGraphRenderer | read/write |
$renderer
Renderer used to render chart |
protected ezcGraphChartDataContainer |
$data
Contains the data of the chart |
protected array(ezcGraphChartElement) |
$elements
= array()
Contains subelelemnts of the chart like legend and axes |
protected ezcGraphChartConfig |
$options
Contains all general chart options |
protected array |
$properties
Array containing chart properties |
protected array |
$renderElement
Contains the status wheather an element should be rendered |
protected void |
addElement(
$name
, $element
)
Add element to chart |
public abstract int |
getDefaultDisplayType(
)
Returns the default display type of the current chart type. |
public mixed |
getRenderedFile(
)
Return filename of rendered file, and false if no file was yet rendered. |
public abstract void |
render(
$width
, $height
, [ $file
= null] )
Renders this chart |
public abstract void |
renderToOutput(
$width
, $height
)
Renders this chart to direct output |
public void |
setFromPalette(
$palette
)
Set colors and border fro this element |
Add element to chart
Add a chart element to the chart and perform the required configuration tasks for the chart element.
Name | Type | Description |
---|---|---|
$name |
string | Element name |
$element |
ezcGraphChartElement | Chart element |
Returns the default display type of the current chart type.
Method | Description |
---|---|
ezcGraphRadarChart::getDefaultDisplayType() |
Returns the default display type of the current chart type. |
ezcGraphLineChart::getDefaultDisplayType() |
Returns the default display type of the current chart type. |
ezcGraphBarChart::getDefaultDisplayType() |
Returns the default display type of the current chart type. |
ezcGraphOdometerChart::getDefaultDisplayType() |
Returns the default display type of the current chart type. |
ezcGraphPieChart::getDefaultDisplayType() |
Returns the default display type of the current chart type. |
Return filename of rendered file, and false if no file was yet rendered.
Renders this chart
Creates basic visual chart elements from the chart to be processed by the renderer.
Name | Type | Description |
---|---|---|
$width |
int | |
$height |
int | |
$file |
string |
Method | Description |
---|---|
ezcGraphRadarChart::render() |
Render the line chart |
ezcGraphLineChart::render() |
Render the line chart |
ezcGraphOdometerChart::render() |
Render the pie chart |
ezcGraphPieChart::render() |
Render the pie chart |
Renders this chart to direct output
Does the same as ezcGraphChart::render(), but renders directly to output and not into a file.
Name | Type | Description |
---|---|---|
$width |
int | |
$height |
int |
Method | Description |
---|---|
ezcGraphRadarChart::renderToOutput() |
Renders this chart to direct output |
ezcGraphLineChart::renderToOutput() |
Renders this chart to direct output |
ezcGraphOdometerChart::renderToOutput() |
Renders this chart to direct output |
ezcGraphPieChart::renderToOutput() |
Renders this chart to direct output |
Set colors and border fro this element
Name | Type | Description |
---|---|---|
$palette |
ezcGraphPalette | Palette |
Method | Description |
---|---|
ezcGraphRadarChart::setFromPalette() |
Set colors and border fro this element |
ezcGraphLineChart::setFromPalette() |
Set colors and border for this element |