PHP Класс FlotChart

Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$chart_id
$legend_id

Защищенные свойства (Protected)

Свойство Тип Описание
$has_data
$options
$point_labels
$series
$x_max
$x_min
$yaxis_map

Открытые методы

Метод Описание
addPoint ( string $series_name, float $x, float $y, string $label = null ) : FlotChart Add a point to the specified data series (creating it if it doesn't exist).
configureChart ( array $config ) : FlotChart Apply configuration to the chart as a whole.
configureSeries ( string $series_name, array $config ) : FlotChart Configure a data series, creating it if it doesn't exist.
configureXAxis ( array $config = [] ) : FlotChart Configure the X axis.
configureYAxis ( string $axis_name, array $config = [] ) : FlotChart Add and/or configure a Y axis.
getXMax ( ) : float Get the highest X value added to the graph so far (or null if none).
getXMin ( ) : float | null Get the lowest X value added to the graph so far (or null if none).
hasData ( ) : boolean Whether there are any points in the graph yet.
run ( ) Render the chart.

Защищенные методы

Метод Описание
initSeries ( $series_name )

Описание методов

addPoint() публичный Метод

Add a point to the specified data series (creating it if it doesn't exist).
public addPoint ( string $series_name, float $x, float $y, string $label = null ) : FlotChart
$series_name string
$x float
$y float
$label string
Результат FlotChart

configureChart() публичный Метод

Apply configuration to the chart as a whole.
public configureChart ( array $config ) : FlotChart
$config array
Результат FlotChart

configureSeries() публичный Метод

Configure a data series, creating it if it doesn't exist.
public configureSeries ( string $series_name, array $config ) : FlotChart
$series_name string
$config array
Результат FlotChart

configureXAxis() публичный Метод

Configure the X axis.
public configureXAxis ( array $config = [] ) : FlotChart
$config array
Результат FlotChart

configureYAxis() публичный Метод

Add and/or configure a Y axis.
public configureYAxis ( string $axis_name, array $config = [] ) : FlotChart
$axis_name string
$config array
Результат FlotChart

getXMax() публичный Метод

Get the highest X value added to the graph so far (or null if none).
public getXMax ( ) : float
Результат float

getXMin() публичный Метод

Get the lowest X value added to the graph so far (or null if none).
public getXMin ( ) : float | null
Результат float | null

hasData() публичный Метод

Whether there are any points in the graph yet.
public hasData ( ) : boolean
Результат boolean

initSeries() защищенный Метод

protected initSeries ( $series_name )

run() публичный Метод

Render the chart.
public run ( )

Описание свойств

$chart_id публичное свойство

public $chart_id

$has_data защищенное свойство

protected $has_data

$legend_id публичное свойство

public $legend_id

$options защищенное свойство

protected $options

$point_labels защищенное свойство

protected $point_labels

$series защищенное свойство

protected $series

$x_max защищенное свойство

protected $x_max

$x_min защищенное свойство

protected $x_min

$yaxis_map защищенное свойство

protected $yaxis_map