import { BucketId } from '@/services/data/tuples/bucket-types' ; import { Enum , EnumId } from '@/services/data/tuples/enum-types' ; import { Indicator , IndicatorId } from '@/services/data/tuples/indicator-types' ; import { Inspection , InspectionId } from '@/services/data/tuples/inspection-types' ; import { QueryBucket , QueryByBucketMethod } from '@/services/data/tuples/query-bucket-types' ; import { EnumForIndicator , QueryIndicator , TopicForIndicator } from '@/services/data/tuples/query-indicator-types' ; import { QueryInspection } from '@/services/data/tuples/query-inspection-types' ; import { RowOfAny } from '@/services/data/types' ; import { Columns } from './types' ; export interface IndicatorForInspection { indicator : Indicator ; topic : TopicForIndicator ; enums : Array < EnumForIndicator > ; } export interface AskBucketsParams { valueBucketIds : Array < BucketId > ; measureMethods : Array < QueryByBucketMethod > ; } export enum InspectionEventTypes { ASK_INSPECTIONS = 'ask-inspections' , ASK_INSPECTION = 'ask-inspection' , ASK_INDICATORS = 'ask-indicators' , ASK_INDICATOR = 'ask-indicator' , ASK_BUCKETS = 'ask-buckets' , ASK_ENUM = 'ask-enum' , INSPECTION_PICKED = 'inspection-picked' , INDICATOR_PICKED = 'indicator-picked' , AGGREGATE_ARITHMETIC_CHANGED = 'aggregate_arithmetic_changed' , BUCKET_ON_CHANGED = 'bucket-on-changed' , TIME_RANGE_ON_CHANGED = 'time-range-on-changed' , TIME_RANGE_VALUES_CHANGED = 'time-range-values-changed' , TIME_MEASURE_CHANGED = 'time-measure-changed' , REFRESH_DATA = 'refresh-data' , DATA_LOADED = 'data-loaded' , DISPLAY_DATA_READY = 'display-data-ready' , SAVE_INSPECTION = 'save-inspection' , INSPECTION_SAVED = 'inspection-saved' , CLEAR_INSPECTION = 'clear-inspection' , INSPECTION_CLEARED = 'inspection-cleared' , SET_DATA_GRID_VISIBILITY = 'set-data-grid-visibility' , SET_CHARTS_VISIBILITY = 'set-charts-visibility' } export interface InspectionEventBus { fire ( type , onData ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspectionId , onData ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , onData ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , indicatorId , onData ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , params , onData ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , enumId , onData ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection , indicator ? ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , indicator ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection , data ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection , data , buckets , columns ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection , onSaved ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection , visible ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; fire ( type , inspection , visible ) : this ; on ( type , listener ) : this ; off ( type , listener ) : this ; }