Contentserv PHP API

CSMonitorChart
in package

Implementation of a special chart type for the monitoring reports

Tags
since

CS15

Table of Contents

addData()  : mixed
Add a dataset to chart
getHtml()  : string
Get the chart HTML string
getSampleData()  : array<string|int, mixed>
create a sample data value range
makeHtml()  : string
Get the chart HTML view
prepareChart()  : mixed
Prepare the chart values
setColorCritical()  : mixed
Set graph color critical level
setColorNormal()  : mixed
Set the graph color
setColorWarning()  : mixed
Set graph color warning level
setCriticalValue()  : mixed
Set the chart critical level
setData()  : mixed
Set the chart data
setEndTime()  : mixed
Set the chart end time value
setMaxValue()  : mixed
Set the chart max value
setMinValue()  : mixed
Set the chart min value
setStartTime()  : mixed
Set the chart start time value
setSubTitle()  : mixed
Set the chart subtitle
setTitle()  : mixed
Set the chart title
setValueUnit()  : mixed
Set the chart value unit
setWarningValue()  : mixed
Set the chart warning level

Methods

addData()

Add a dataset to chart

public addData(int $time, float $value, string $onclick, int $state) : mixed
Parameters
$time : int
$value : float
$onclick : string
$state : int
Tags
Return values
mixed

getHtml()

Get the chart HTML string

public getHtml() : string
Tags
Return values
string

getSampleData()

create a sample data value range

public getSampleData(int $count, float $minValue, float $maxValue, int $startTime, int $endTime) : array<string|int, mixed>
Parameters
$count : int
$minValue : float
$maxValue : float
$startTime : int
$endTime : int
Tags
Return values
array<string|int, mixed>

makeHtml()

Get the chart HTML view

public makeHtml() : string
Tags
Return values
string

prepareChart()

Prepare the chart values

public prepareChart() : mixed
Tags
Return values
mixed

setColorCritical()

Set graph color critical level

public setColorCritical(string $color) : mixed
Parameters
$color : string
Tags
Return values
mixed

setColorNormal()

Set the graph color

public setColorNormal(string $color) : mixed
Parameters
$color : string
Tags
Return values
mixed

setColorWarning()

Set graph color warning level

public setColorWarning(string $color) : mixed
Parameters
$color : string
Tags
Return values
mixed

setCriticalValue()

Set the chart critical level

public setCriticalValue(float $criticalValue) : mixed
Parameters
$criticalValue : float
Tags
Return values
mixed

setData()

Set the chart data

public setData(array<string|int, mixed> $data) : mixed
Parameters
$data : array<string|int, mixed>
Tags
Return values
mixed

setEndTime()

Set the chart end time value

public setEndTime(int $endTime) : mixed
Parameters
$endTime : int
Tags
Return values
mixed

setMaxValue()

Set the chart max value

public setMaxValue(float $maxValue) : mixed
Parameters
$maxValue : float
Tags
Return values
mixed

setMinValue()

Set the chart min value

public setMinValue(float $minValue) : mixed
Parameters
$minValue : float
Tags
Return values
mixed

setStartTime()

Set the chart start time value

public setStartTime(int $startTime) : mixed
Parameters
$startTime : int
Tags
Return values
mixed

setSubTitle()

Set the chart subtitle

public setSubTitle(string $subTitle) : mixed
Parameters
$subTitle : string
Tags
Return values
mixed

setTitle()

Set the chart title

public setTitle(string $title) : mixed
Parameters
$title : string
Tags
Return values
mixed

setValueUnit()

Set the chart value unit

public setValueUnit(string $unit) : mixed
Parameters
$unit : string
Tags
Return values
mixed

setWarningValue()

Set the chart warning level

public setWarningValue(float $warningValue) : mixed
Parameters
$warningValue : float
Tags
Return values
mixed

        

Search results