BiChartSeries

This describes a series of values that is used with the graph control. Each series has a unique id and every value of the series belongs to a certain category.

This class extends BiObject and therefore all methods and fields available for BiObject are also available for BiChartSeries .

Constructor

new BiChartSeries ( oGraph,sId [ ,sTitle [ ,oValues ] ] )

Parameters

Name Type Optional Default Descripton
oGraph BiGraph The graph that the series belongs to
sId String The id of the series
sTitle String checked The title of the series
oValues Number[] checked [] The values in the series given in the same order as the categories

Properties

Name Type get set Descripton
absSum Number checked The sum of the absolute values in the series
id String checked The id of the series
index Number checked The index of the series
maximumValue Number checked The maximum of the values in the series
minimumValue Number checked The maximum of the values in the series
sum Number checked The sum of the values in the series
title String checked checked The title of the series
values Number[] checked checked The values in the series. This is the same order as the order of the categories. If a value for a certain category is missing the value for that is null in the array.

Methods

Name Description
getValueByCategory Returns the value for the given category
getValueByCategoryId Returns the value for the given category id
getValueByIndex Returns the value for the given index
setValueByCategory Sets the value for the given category
setValueByCategoryId Sets the value for the given category id
setValueByIndex Sets the value for the given index
toXmlElement Serializes the series to an XML element (sub tree)

Events

None.

Static Methods

Name Description
fromXmlElement Creates a new series object from an XML element

Static Fields

None.

Remarks

Changing the series does not update the chart. The graph components needs to be updated manually.

Method Details

getValueByCategory

Returns the value for the given category

Syntax

object.getValueByCategory
 (
 oCategory
 )
 

Parameters

Name Type Optional Default Descripton
oCategory BiChartCategory The category to get the value for

Return Type

Number

getValueByCategoryId

Returns the value for the given category id

Syntax

object.getValueByCategoryId
 (
 sCatId
 )
 

Parameters

Name Type Optional Default Descripton
sCatId String The category id to get the value for

Return Type

Number

getValueByIndex

Returns the value for the given index

Syntax

object.getValueByIndex
 (
 i
 )
 

Parameters

Name Type Optional Default Descripton
i Number The index to get the value for

Return Type

Number

setValueByCategory

Sets the value for the given category

Syntax

object.setValueByCategory
 (
 oCategory,nValue
 )
 

Parameters

Name Type Optional Default Descripton
oCategory BiChartCategory The category to set the value for
nValue Number The value to set

Return Type

void

setValueByCategoryId

Sets the value for the given category id

Syntax

object.setValueByCategoryId
 (
 sCatId,nValue
 )
 

Parameters

Name Type Optional Default Descripton
sCatId String The category id to set the value for
nValue Number The value to set

Return Type

void

setValueByIndex

Sets the value for the given index

Syntax

object.setValueByIndex
 (
 i,nValue
 )
 

Parameters

Name Type Optional Default Descripton
i Number The category id to set the value for
nValue Number The value to set

Return Type

void

toXmlElement

Serializes the series to an XML element (sub tree)

Syntax

object.toXmlElement
 (
 oDoc
 )
 

Parameters

Name Type Optional Default Descripton
oDoc BiXmlDocument The XML document to create the element in

Return Type

XmlElement

Static Method Details

fromXmlElement

Creates a new series object from an XML element

Syntax

BiChartSeries
 .
 fromXmlElement
 (
 oGraph,oNode
 )
 

Parameters

Name Type Optional Default Descripton
oGraph BiGraph The graph that the series belongs to
oNode XmlElement The element describing the series

Return Type

BiChartSeries