Documentation

JpGraphRendererBase
in package
implements IRenderer

AbstractYes

Base class for different Jpgraph implementations as charts renderer.

Table of Contents

Interfaces

IRenderer

Constants

DEFAULT_HEIGHT  = 480.0
DEFAULT_WIDTH  = 640.0

Properties

$chart  : Chart
$colourSet  : mixed
$graph  : mixed
$markSet  : array<string|int, mixed>
$plotColour  : mixed
$plotMark  : mixed

Methods

__construct()  : mixed
Create a new jpgraph.
render()  : bool
Render the chart to given file (or stream).
init()  : void
This method should be overriden in descendants to do real JpGraph library initialization.
formatDataSetLabels()  : mixed
formatPointMarker()  : mixed
getCaption()  : mixed
getDataLabel()  : mixed
getGraphHeight()  : float
getGraphWidth()  : float
percentageAdjustValues()  : mixed
percentageSumCalculation()  : mixed
renderAreaChart()  : void
renderBarChart()  : void
renderBubbleChart()  : void
renderCartesianPlotArea()  : void
renderCombinationChart()  : bool
renderContourChart()  : void
renderLegend()  : void
renderLineChart()  : void
renderPieChart()  : void
renderPiePlotArea()  : void
renderPlotBar()  : void
renderPlotContour()  : void
renderPlotLine()  : void
renderPlotRadar()  : void
renderPlotScatter()  : void
renderPlotStock()  : void
renderRadarChart()  : void
renderRadarPlotArea()  : void
renderScatterChart()  : void
renderStockChart()  : void
renderTitle()  : void

Constants

Properties

$colourSet

private static mixed $colourSet = ['mediumpurple1', 'palegreen3', 'gold1', 'cadetblue1', 'darkmagenta', 'coral', 'dodgerblue3', 'eggplant', 'mediumblue', 'magenta', 'sandybrown', 'cyan', 'firebrick1', 'forestgreen', 'deeppink4', 'darkolivegreen', 'goldenrod2']

Methods

render()

Render the chart to given file (or stream).

public render(string|null $outputDestination) : bool
Parameters
$outputDestination : string|null
Return values
bool

true on success

init()

This method should be overriden in descendants to do real JpGraph library initialization.

protected abstract static init() : void

formatDataSetLabels()

private formatDataSetLabels(int $groupID, array<string|int, mixed> $datasetLabels[, mixed $rotation = '' ]) : mixed
Parameters
$groupID : int
$datasetLabels : array<string|int, mixed>
$rotation : mixed = ''

formatPointMarker()

private formatPointMarker(mixed $seriesPlot, mixed $markerID) : mixed
Parameters
$seriesPlot : mixed
$markerID : mixed

getCaption()

private getCaption(mixed $captionElement) : mixed
Parameters
$captionElement : mixed

getDataLabel()

private getDataLabel(int $groupId, int $index) : mixed
Parameters
$groupId : int
$index : int

percentageAdjustValues()

private percentageAdjustValues(array<string|int, mixed> $dataValues, array<string|int, mixed> $sumValues) : mixed
Parameters
$dataValues : array<string|int, mixed>
$sumValues : array<string|int, mixed>

percentageSumCalculation()

private percentageSumCalculation(int $groupID, mixed $seriesCount) : mixed
Parameters
$groupID : int
$seriesCount : mixed

renderAreaChart()

private renderAreaChart(mixed $groupCount) : void
Parameters
$groupCount : mixed

renderBarChart()

private renderBarChart(mixed $groupCount[, string|null $dimensions = '2d' ]) : void
Parameters
$groupCount : mixed
$dimensions : string|null = '2d'

renderBubbleChart()

private renderBubbleChart(mixed $groupCount) : void
Parameters
$groupCount : mixed

renderCartesianPlotArea()

private renderCartesianPlotArea([string $type = 'textlin' ]) : void
Parameters
$type : string = 'textlin'

renderCombinationChart()

private renderCombinationChart(mixed $groupCount, mixed $outputDestination) : bool
Parameters
$groupCount : mixed
$outputDestination : mixed
Return values
bool

renderContourChart()

private renderContourChart(mixed $groupCount) : void
Parameters
$groupCount : mixed

renderLineChart()

private renderLineChart(mixed $groupCount) : void
Parameters
$groupCount : mixed

renderPieChart()

private renderPieChart(mixed $groupCount[, string|null $dimensions = '2d' ][, bool $doughnut = false ][, bool $multiplePlots = false ]) : void
Parameters
$groupCount : mixed
$dimensions : string|null = '2d'
$doughnut : bool = false
$multiplePlots : bool = false

renderPlotBar()

private renderPlotBar(int $groupID[, string|null $dimensions = '2d' ]) : void
Parameters
$groupID : int
$dimensions : string|null = '2d'

renderPlotContour()

private renderPlotContour(int $groupID) : void
Parameters
$groupID : int

renderPlotLine()

private renderPlotLine(int $groupID[, bool $filled = false ][, bool $combination = false ]) : void
Parameters
$groupID : int
$filled : bool = false
$combination : bool = false

renderPlotRadar()

private renderPlotRadar(int $groupID) : void
Parameters
$groupID : int

renderPlotScatter()

private renderPlotScatter(int $groupID, bool $bubble) : void
Parameters
$groupID : int
$bubble : bool

renderPlotStock()

private renderPlotStock(int $groupID) : void
Parameters
$groupID : int

renderRadarChart()

private renderRadarChart(mixed $groupCount) : void
Parameters
$groupCount : mixed

renderScatterChart()

private renderScatterChart(mixed $groupCount) : void
Parameters
$groupCount : mixed

renderStockChart()

private renderStockChart(mixed $groupCount) : void
Parameters
$groupCount : mixed

        
On this page

Search results