Interface IEventQueue<TEvent, TPoint, TPointDelta>
Represents a generic event queue.
public interface IEventQueue<TEvent, TPoint, TPointDelta> : IReadOnlyEventQueue<TEvent, TPoint, TPointDelta>, IReadOnlyCollection<EnqueuedEvent<TEvent, TPoint, TPointDelta>>, IEnumerable<EnqueuedEvent<TEvent, TPoint, TPointDelta>>, IEnumerable
Type Parameters
TEvent
Event type.
TPoint
Queue point type.
TPointDelta
Queue point delta type.
- Inherited Members
Methods
Enqueue(TEvent, TPointDelta)
Adds a new event to this queue that happens exactly once with its
DequeuePoint equal to
CurrentPoint moved by the specified delta
.
EnqueuedEvent<TEvent, TPoint, TPointDelta> Enqueue(TEvent @event, TPointDelta delta)
Parameters
event
TEventUnderlying event.
delta
TPointDeltaPoint delta used for moving DequeuePoint forward.
Returns
- EnqueuedEvent<TEvent, TPoint, TPointDelta>
New EnqueuedEvent<TEvent, TPoint, TPointDelta> instance.
Enqueue(TEvent, TPointDelta, int)
Adds a new repeatable event to this queue with its DequeuePoint equal to
CurrentPoint moved by the specified delta
.
EnqueuedEvent<TEvent, TPoint, TPointDelta> Enqueue(TEvent @event, TPointDelta delta, int repetitions)
Parameters
event
TEventUnderlying event.
delta
TPointDeltaPoint delta used for moving DequeuePoint forward on each repetition of this event.
repetitions
intNumber of repetitions.
Returns
- EnqueuedEvent<TEvent, TPoint, TPointDelta>
New EnqueuedEvent<TEvent, TPoint, TPointDelta> instance.
Exceptions
- ArgumentOutOfRangeException
When
repetitions
is less than 1.
EnqueueAt(TEvent, TPoint)
Adds a new event to this queue that happens exactly once.
EnqueuedEvent<TEvent, TPoint, TPointDelta> EnqueueAt(TEvent @event, TPoint dequeuePoint)
Parameters
event
TEventUnderlying event.
dequeuePoint
TPointQueue point at which this event should be dequeued.
Returns
- EnqueuedEvent<TEvent, TPoint, TPointDelta>
New EnqueuedEvent<TEvent, TPoint, TPointDelta> instance.
EnqueueAt(TEvent, TPoint, TPointDelta, int)
Adds a new repeatable event to this queue.
EnqueuedEvent<TEvent, TPoint, TPointDelta> EnqueueAt(TEvent @event, TPoint dequeuePoint, TPointDelta delta, int repetitions)
Parameters
event
TEventUnderlying event.
dequeuePoint
TPointQueue point at which this event should be dequeued for the first time.
delta
TPointDeltaPoint delta used for moving DequeuePoint forward on each repetition of this event.
repetitions
intNumber of repetitions.
Returns
- EnqueuedEvent<TEvent, TPoint, TPointDelta>
New EnqueuedEvent<TEvent, TPoint, TPointDelta> instance.
Exceptions
- ArgumentOutOfRangeException
When
repetitions
is less than 1.
EnqueueInfinite(TEvent, TPointDelta)
Adds a new infinitely repeatable event to this queue with its DequeuePoint
equal to CurrentPoint moved by the specified delta
.
EnqueuedEvent<TEvent, TPoint, TPointDelta> EnqueueInfinite(TEvent @event, TPointDelta delta)
Parameters
event
TEventUnderlying event.
delta
TPointDeltaPoint delta used for moving DequeuePoint forward on each repetition of this event.
Returns
- EnqueuedEvent<TEvent, TPoint, TPointDelta>
New EnqueuedEvent<TEvent, TPoint, TPointDelta> instance.
EnqueueInfiniteAt(TEvent, TPoint, TPointDelta)
Adds a new infinitely repeatable event to this queue.
EnqueuedEvent<TEvent, TPoint, TPointDelta> EnqueueInfiniteAt(TEvent @event, TPoint dequeuePoint, TPointDelta delta)
Parameters
event
TEventUnderlying event.
dequeuePoint
TPointQueue point at which this event should be dequeued for the first time.
delta
TPointDeltaPoint delta used for moving DequeuePoint forward on each repetition of this event.
Returns
- EnqueuedEvent<TEvent, TPoint, TPointDelta>
New EnqueuedEvent<TEvent, TPoint, TPointDelta> instance.