libs/core/src/lib/model/internal/options.ts
Properties |
|
constructor(internalId: string, color: string, timestamp: number)
|
Public timestamp |
Type : number
|
Optional autoRangeSelection |
Type : boolean
|
Default value : false
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:42
|
auto zoom when range selection |
Public barPeriod |
Type : string
|
Default value : 'PT1H'
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:73
|
period of the bars defined as moment.duration by a string See also: https://momentjs.com/docs/#/durations/ default is 'PT1H' which means one hour duration |
Public barStartOf |
Type : string
|
Default value : 'hour'
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:65
|
the start of, where to start with the bar chart See also: https://momentjs.com/docs/#/manipulating/start-of/ default is 'hour' |
Public color |
Type : string
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:22
|
color of the dataset |
Public Optional generalize |
Type : boolean
|
Default value : false
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:47
|
marker to request dataset data generalized |
Public internalId |
Type : string
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:11
|
internal dataset id |
Public lineDashArray |
Type : number | number[]
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:84
|
dasharray to structure the line or bar chart border See also here: https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/stroke-dasharray |
Public lineWidth |
Type : number
|
Default value : 1
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:78
|
width of graphline |
Public pointBorderColor |
Type : string
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:89
|
color of the point border |
Public pointBorderWidth |
Type : number
|
Default value : 0
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:94
|
width of the point border |
Public pointRadius |
Type : number
|
Default value : 0
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:58
|
radius of graphpoint default is 0 |
Public Optional separateYAxis |
Type : boolean
|
Default value : false
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:32
|
separate y axis of datasets with same unit |
Public showReferenceValues |
Type : ReferenceValueOption[]
|
Default value : []
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:52
|
list of visible reference values |
Public type |
Type : "line" | "bar"
|
Default value : 'line'
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:17
|
type to display the data default is 'line' |
Public visible |
Type : boolean
|
Default value : true
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:27
|
show or hide in the graph |
Public Optional yAxisRange |
Type : MinMaxRange
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:99
|
min and max range of y axis |
Public Optional zeroBasedYAxis |
Type : boolean
|
Default value : false
|
Inherited from
DatasetOptions
|
Defined in
DatasetOptions:37
|
align graph that zero y axis is visible |
export class DatasetOptions {
/**
* internal dataset id
*/
public internalId: string;
/**
* type to display the data
* default is 'line'
*/
public type: 'line' | 'bar' = 'line';
/**
* color of the dataset
*/
public color: string;
/**
* show or hide in the graph
*/
public visible: boolean = true;
/**
* separate y axis of datasets with same unit
*/
public separateYAxis?: boolean = false;
/**
* align graph that zero y axis is visible
*/
public zeroBasedYAxis?: boolean = false;
/**
* auto zoom when range selection
*/
autoRangeSelection?: boolean = false;
/**
* marker to request dataset data generalized
*/
public generalize?: boolean = false;
/**
* list of visible reference values
*/
public showReferenceValues: ReferenceValueOption[] = [];
/**
* radius of graphpoint
* default is 0
*/
public pointRadius: number = 0;
/**
* the start of, where to start with the bar chart
* See also: https://momentjs.com/docs/#/manipulating/start-of/
* default is 'hour'
*/
public barStartOf: string = 'hour';
/**
* period of the bars
* defined as moment.duration by a string
* See also: https://momentjs.com/docs/#/durations/
* default is 'PT1H' which means one hour duration
*/
public barPeriod: string = 'PT1H';
/**
* width of graphline
*/
public lineWidth: number = 1;
/**
* dasharray to structure the line or bar chart border
* See also here: https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/stroke-dasharray
*/
public lineDashArray: number | number[];
/**
* color of the point border
*/
public pointBorderColor: string;
/**
* width of the point border
*/
public pointBorderWidth: number = 0;
/**
* min and max range of y axis
*/
public yAxisRange?: MinMaxRange;
constructor(
internalId: string,
color: string
) {
this.internalId = internalId;
this.color = color;
}
}
export interface ReferenceValueOption {
id: string;
color: string;
}
/**
* numbered range with a min and a max value
*
* @export
*/
export interface MinMaxRange {
min: number;
max: number;
}
export class TimedDatasetOptions extends DatasetOptions {
public timestamp: number;
constructor(
internalId: string,
color: string,
timestamp: number
) {
super(internalId, color);
this.timestamp = timestamp;
}
}