@staticmethod
def _insortTimeEvent(tm_event, expiration):
    'Inserts a TimeEvent into the list of time events,\n        sorted by the next expiration of the timer.\n        If the expiration time matches an existing expiration,\n        we add the smallest amount of time to the given expiration\n        to avoid a key collision in the Dict\n        and make the identically-timed events fire in a FIFO fashion.\n        '
    now = Framework._event_loop.time()
    if (expiration < now):
        tm_event.act.postFIFO(tm_event)
    while (expiration in Framework._time_events.keys()):
        (m, e) = math.frexp(expiration)
        expiration = ((m + sys.float_info.epsilon) * (2 ** e))
    Framework._time_events[expiration] = tm_event
    if (len(Framework._time_events) == 1):
        Framework._tm_event_handle = Framework._event_loop.call_at(expiration, Framework.timeEventCallback, tm_event, expiration)
    elif (expiration < min(Framework._time_events.keys())):
        Framework._tm_event_handle.cancel()
        Framework._tm_event_handle = Framework._event_loop.call_at(expiration, Framework.timeEventCallback, tm_event, expiration)
Inserts a TimeEvent into the list of time events,
sorted by the next expiration of the timer.
If the expiration time matches an existing expiration,
we add the smallest amount of time to the given expiration
to avoid a key collision in the Dict
and make the identically-timed events fire in a FIFO fashion.
@staticmethod
def _insortTimeEvent(tm_event, expiration):
    'Inserts a TimeEvent into the list of time events,\n        sorted by the next expiration of the timer.\n        If the expiration time matches an existing expiration,\n        we add the smallest amount of time to the given expiration\n        to avoid a key collision in the Dict\n        and make the identically-timed events fire in a FIFO fashion.\n        '
    now = Framework._event_loop.time()
    if (expiration < now):
        tm_event.act.postFIFO(tm_event)
    while (expiration in Framework._time_events.keys()):
        (m, e) = math.frexp(expiration)
        expiration = ((m + sys.float_info.epsilon) * (2 ** e))
    Framework._time_events[expiration] = tm_event
    if (len(Framework._time_events) == 1):
        Framework._tm_event_handle = Framework._event_loop.call_at(expiration, Framework.timeEventCallback, tm_event, expiration)
    elif (expiration < min(Framework._time_events.keys())):
        Framework._tm_event_handle.cancel()
        Framework._tm_event_handle = Framework._event_loop.call_at(expiration, Framework.timeEventCallback, tm_event, expiration)