Interface EventTranslator<T>

  • Type Parameters:
    T - event implementation storing the data for sharing during exchange or parallel coordination of an event.

    public interface EventTranslator<T>
    Implementations translate (write) data representations into events claimed from the RingBuffer.

    When publishing to the RingBuffer, provide an EventTranslator. The RingBuffer will select the next available event by sequence and provide it to the EventTranslator (which should update the event), before publishing the sequence update.

    • Method Detail

      • translateTo

        void translateTo​(T event,
                         long sequence)
        Translate a data representation into fields set in given event
        Parameters:
        event - into which the data should be translated.
        sequence - that is assigned to event.