import { GameEvent } from '../../../../../models/game-event' ; import { RealTimeStatsState } from '../real-time-stats' ; import { EventParser } from './_event-parser' ; export class RTStatsReconnectStartParser implements EventParser { applies ( gameEvent , currentState ) { return gameEvent . type === GameEvent . RECONNECT_START ; } parse ( gameEvent , currentState ) { return currentState . update ( { reconnectOngoing : true , } as RealTimeStatsState ) ; } name ( ) { return 'RTStatsReconnectStartParser' ; } }