function handleEvent(eventData, eventTypeName) {
  const j = JSON.parse(eventData);
  if (DEBUG_REALTIME) {
    console.log({ // eslint-disable-line no-console
      handleEventTimestamp: new Date(),
      eventData: j,
    });
  }

  eventsQueue.enqueueEvent(eventTypeName, j[eventTypeName]);
  if (_realtimeEventThrottleMilliseconds === ZERO) {
    eventsQueue.createAndDispatchLensEvent(eventsQueue.queue, LENS_DIV);
    eventsQueue.queue.length = ZERO;
  }

  if (eventTypeName === eventsQueue.eventType.INTRNL_SMPL_ADD) {
    const sample = j[eventTypeName];
    updateTimeoutValues(sample.aspect.timeout);
  } else if (eventTypeName === eventsQueue.eventType.INTRNL_SMPL_UPD) {
    const newSample = j[eventTypeName].new;
    updateTimeoutValues(newSample.aspect.timeout);
  } else if (eventTypeName === eventsQueue.eventType.INTRNL_SMPL_DEL) {
    const sample = j[eventTypeName];
    updateDeletedTimeoutValues(sample.aspect.timeout);
  } else if (eventTypeName === eventsQueue.eventType.INTRNL_SMPL_NC) {
    const sample = j[eventTypeName];
    updateTimeoutValues(sample.aspect.timeout);
  }
} // handleEvent
/**
 * Handle event data, push the event data to the event queue.
 *
 * @param  {String} eventData - Data recieved with event
 * @param  {String} eventTypeName - Event type
 */
Handle event data, push the event data to the event queue.
@param  {String} eventData - Data recieved with event
@param  {String} eventTypeName - Event type
Handle event data push the event data to the event queue . @param { String } eventData - Data recieved with event @param { String } eventTypeName - Event type
function handleEvent(eventData, eventTypeName) {
  const j = JSON.parse(eventData);
  if (DEBUG_REALTIME) {
    console.log({ 
      handleEventTimestamp: new Date(),
      eventData: j,
    });
  }
  eventsQueue.enqueueEvent(eventTypeName, j[eventTypeName]);
  if (_realtimeEventThrottleMilliseconds === ZERO) {
    eventsQueue.createAndDispatchLensEvent(eventsQueue.queue, LENS_DIV);
    eventsQueue.queue.length = ZERO;
  }
  if (eventTypeName === eventsQueue.eventType.INTRNL_SMPL_ADD) {
    const sample = j[eventTypeName];
    updateTimeoutValues(sample.aspect.timeout);
  } else if (eventTypeName === eventsQueue.eventType.INTRNL_SMPL_UPD) {
    const newSample = j[eventTypeName].new;
    updateTimeoutValues(newSample.aspect.timeout);
  } else if (eventTypeName === eventsQueue.eventType.INTRNL_SMPL_DEL) {
    const sample = j[eventTypeName];
    updateDeletedTimeoutValues(sample.aspect.timeout);
  } else if (eventTypeName === eventsQueue.eventType.INTRNL_SMPL_NC) {
    const sample = j[eventTypeName];
    updateTimeoutValues(sample.aspect.timeout);
  }
} 
function handleEvent ( eventData , eventTypeName ) { const j = JSON . parse ( eventData ) ; if ( DEBUG_REALTIME ) { console . log ( { handleEventTimestamp : new Date ( ) , eventData : j , } ) ; } eventsQueue . enqueueEvent ( eventTypeName , j [ eventTypeName ] ) ; if ( _realtimeEventThrottleMilliseconds === ZERO ) { eventsQueue . createAndDispatchLensEvent ( eventsQueue . queue , LENS_DIV ) ; eventsQueue . queue . length = ZERO ; } if ( eventTypeName === eventsQueue . eventType . INTRNL_SMPL_ADD ) { const sample = j [ eventTypeName ] ; updateTimeoutValues ( sample . aspect . timeout ) ; } else if ( eventTypeName === eventsQueue . eventType . INTRNL_SMPL_UPD ) { const newSample = j [ eventTypeName ] . new ; updateTimeoutValues ( newSample . aspect . timeout ) ; } else if ( eventTypeName === eventsQueue . eventType . INTRNL_SMPL_DEL ) { const sample = j [ eventTypeName ] ; updateDeletedTimeoutValues ( sample . aspect . timeout ) ; } else if ( eventTypeName === eventsQueue . eventType . INTRNL_SMPL_NC ) { const sample = j [ eventTypeName ] ; updateTimeoutValues ( sample . aspect . timeout ) ; } }
Handle event data, push the event data to the event queue.
Handle event data push the event data to the event queue .
// eslint-disable-line no-console // handleEvent