arlas-web-contributors > "contributors/HistogramContributor" > HistogramContributor

Class: HistogramContributor

Hierarchy

Contributor

↳ HistogramContributor

DetailedHistogramContributor

Index

Constructors

Properties

Methods


Constructors

constructor

new HistogramContributor(identifier: string, collaborativeSearcheService: CollaborativesearchService, configService: ConfigService, collection: string, isOneDimension?: boolean, additionalCollections?: Array<object>): HistogramContributor

Overrides Contributor.__constructor

Defined in contributors/HistogramContributor.ts:117

Parameters:

Name Type Description
identifier string Identifier of contributor.
collaborativeSearcheService CollaborativesearchService Instance of CollaborativesearchService from Arlas-web-core.
configService ConfigService Instance of ConfigService from Arlas-web-core.
collection string
Optional isOneDimension boolean
Optional additionalCollections Array<object>

Returns: HistogramContributor


Properties

<Optional> additionalCollections

● additionalCollections: Array<object>

Defined in contributors/HistogramContributor.ts:130


<Protected> aggregations

● aggregations: Array<Aggregation> = this.getConfigValue('aggregationmodels')

Defined in contributors/HistogramContributor.ts:85


<Protected> cacheDuration

● cacheDuration: number

Inherited from Contributor.cacheDuration

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:17


chartData

● chartData: Array<object> = new Array<{ key: number, value: number, chartId?: string }>()

Defined in contributors/HistogramContributor.ts:48


chartDataEvent

● chartDataEvent: Subject<object[]> = new Subject()

Defined in contributors/HistogramContributor.ts:51


collaborativeSearcheService

● collaborativeSearcheService: CollaborativesearchService

Inherited from Contributor.collaborativeSearcheService

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:9


collection

● collection: string

Inherited from Contributor.collection

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:14


collections

● collections: CollectionAggField[]

Inherited from Contributor.collections

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:15


configService

● configService: ConfigService

Inherited from Contributor.configService

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:8


endCollaborationEvent

● endCollaborationEvent: Subject<unknown>

Inherited from Contributor.endCollaborationEvent

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:16


<Protected> endValue

● endValue: string

Defined in contributors/HistogramContributor.ts:105


<Protected> field

● field: string = (!!this.aggregations) ? (this.aggregations[this.aggregations.length - 1].field) : (undefined)

Defined in contributors/HistogramContributor.ts:97


identifier

● identifier: string

Inherited from Contributor.identifier

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:7


intervalListSelection

● intervalListSelection: SelectedOutputValues[] = []

Defined in contributors/HistogramContributor.ts:61


intervalSelection

● intervalSelection: SelectedOutputValues

Defined in contributors/HistogramContributor.ts:56


isDataUpdating

● isDataUpdating: boolean

Inherited from Contributor.isDataUpdating

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:13


<Protected>``<Optional> isOneDimension

● isOneDimension: boolean

Defined in contributors/HistogramContributor.ts:129


<Protected> json_path

● json_path: string = this.getConfigValue('jsonpath') !== undefined ? this.getConfigValue('jsonpath') : '$.count'

Defined in contributors/HistogramContributor.ts:89


<Protected> maxValue

● maxValue: number = 0

Defined in contributors/HistogramContributor.ts:109


<Protected> nbBuckets

● nbBuckets: number = this.getConfigValue('numberOfBuckets')

Defined in contributors/HistogramContributor.ts:93


range

● range: number

Defined in contributors/HistogramContributor.ts:81


<Protected> startValue

● startValue: string

Defined in contributors/HistogramContributor.ts:101


timeLabel

● timeLabel: any

Defined in contributors/HistogramContributor.ts:113


timeShortcuts

● timeShortcuts: Array<StringifiedTimeShortcut>

Defined in contributors/HistogramContributor.ts:66


timeShortcutsLabels

● timeShortcutsLabels: Array<string> = this.getConfigValue('timeShortcuts')

Defined in contributors/HistogramContributor.ts:71


updateData

● updateData: boolean

Inherited from Contributor.updateData

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:46


useUtc

● useUtc: any = this.getConfigValue('useUtc') !== undefined ? this.getConfigValue('useUtc') : true

Defined in contributors/HistogramContributor.ts:117


yearShortcutsLabels

● yearShortcutsLabels: Array<string> = this.getConfigValue('yearShortcuts')

Defined in contributors/HistogramContributor.ts:76


Methods

computeData

computeData(aggResponses: AggregationResponse[]): Array<object>

Overrides Contributor.computeData

Defined in contributors/HistogramContributor.ts:271

Parameters:

Name Type
aggResponses AggregationResponse[]

Returns: Array<object>


fetchData

fetchData(collaborationEvent?: CollaborationEvent): Observable<AggregationResponse[]>

Overrides Contributor.fetchData

Defined in contributors/HistogramContributor.ts:262

Parameters:

Name Type
Optional collaborationEvent CollaborationEvent

Returns: Observable<AggregationResponse[]>


<Protected> fetchDataGivenFilter

fetchDataGivenFilter(identifier: string, additionalFilters?: Map<string, Filter>): Observable<AggregationResponse[]>

Defined in contributors/HistogramContributor.ts:316

Parameters:

Name Type
identifier string
Optional additionalFilters Map<string, Filter>

Returns: Observable<AggregationResponse[]>


getAggregations

getAggregations(): Aggregation[]

Defined in contributors/HistogramContributor.ts:175

Returns: Aggregation[]


getConfigValue

getConfigValue(key: string): any

Inherited from Contributor.getConfigValue

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:31

Parameters:

Name Type Description
key string a `key` defined in configuration.

Returns: any value of the key in configuration.


getField

getField(): string

Defined in contributors/HistogramContributor.ts:163

Returns: string


getFilterDisplayName

getFilterDisplayName(): string

Overrides Contributor.getFilterDisplayName

Defined in contributors/HistogramContributor.ts:212

Returns: string Pretty name of contribution based on startValue/endValue properties


getJsonPath

getJsonPath(): string

Defined in contributors/HistogramContributor.ts:171

Returns: string


getName

getName(): string

Inherited from Contributor.getName

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:35

Returns: string name of contributor set in configuration.


getNbBuckets

getNbBuckets(): number

Defined in contributors/HistogramContributor.ts:155

Returns: number


getPackageName

getPackageName(): string

Overrides Contributor.getPackageName

Defined in contributors/HistogramContributor.ts:228

Returns: string Package name for the configuration service.


getShortcutLabel

getShortcutLabel(intervalSelection: SelectedOutputValues, startValue: string, endValue: string): string

Defined in contributors/HistogramContributor.ts:243

Parameters:

Name Type
intervalSelection SelectedOutputValues
startValue string
endValue string

Returns: string


<Protected> resolveHistogramAgg

resolveHistogramAgg(identifier: string, aggregations: Array<Aggregation>, collaborations: Map<string, Collaboration>, additionalFilter: Filter, ac: CollectionAggField): Observable<AggregationResponse>

Defined in contributors/HistogramContributor.ts:361

Parameters:

Name Type
identifier string
aggregations Array<Aggregation>
collaborations Map<string, Collaboration>
additionalFilter Filter
ac CollectionAggField

Returns: Observable<AggregationResponse>


setAggregations

setAggregations(aggregations: Array<Aggregation>): void

Defined in contributors/HistogramContributor.ts:201

Parameters:

Name Type
aggregations Array<Aggregation>

Returns: void


setData

setData(data: Array<object>): Array<object>

Overrides Contributor.setData

Defined in contributors/HistogramContributor.ts:288

Parameters:

Name Type
data Array<object>

Returns: Array<object>


setField

setField(field: any): void

Defined in contributors/HistogramContributor.ts:167

Parameters:

Name Type
field any

Returns: void


setName

setName(name: string): void

Inherited from Contributor.setName

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:39

Parameters:

Name Type
name string

Returns: void set the name of the contributor


setNbBuckets

setNbBuckets(nbBuckets: number): void

Defined in contributors/HistogramContributor.ts:159

Parameters:

Name Type
nbBuckets number

Returns: void


setSelection

setSelection(data: Array<object>, collaboration: Collaboration): any

Overrides Contributor.setSelection

Defined in contributors/HistogramContributor.ts:306

Parameters:

Name Type
data Array<object>
collaboration Collaboration

Returns: any


updateFromCollaboration

updateFromCollaboration(collaborationEvent: CollaborationEvent): void

Inherited from Contributor.updateFromCollaboration

Defined in /docs/node_modules/arlas-web-core/models/contributor.d.ts:55

Parameters:

Name Type
collaborationEvent CollaborationEvent

Returns: void


valueChanged

valueChanged(values: SelectedOutputValues[]): void

Defined in contributors/HistogramContributor.ts:235

Parameters:

Name Type
values SelectedOutputValues[]

Returns: void


<Static> getJsonSchema

getJsonSchema(): Object

Defined in contributors/HistogramContributor.ts:205

Returns: Object