/** * <p>Set up event handlers to handle events from the ring buffer. These handlers will process events * as soon as they become available, in parallel.</p> * * <p>This method can be used as the start of a chain. For example if the handler <code>A</code> must * process events before handler <code>B</code>:</p> * <pre><code>dw.handleEventsWith(A).then(B);</code></pre> * * <p>This call is additive, but generally should only be called once when setting up the Disruptor instance</p> * * @param handlers the event handlers that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ @SuppressWarnings("varargs") @SafeVarargs public final EventHandlerGroup<T> handleEventsWith(final EventHandler<? super T>... handlers) { return createEventProcessors(new Sequence[0], handlers); }
/** * <p>Set up batch handlers to handle events from the ring buffer. These handlers will only process events * after every {@link EventProcessor} in this group has processed the event.</p> * * <p>This method is generally used as part of a chain. For example if <code>A</code> must * process events before <code>B</code>:</p> * * <pre><code>dw.after(A).handleEventsWith(B);</code></pre> * * @param handlers the batch handlers that will process events. * @return a {@link EventHandlerGroup} that can be used to set up a event processor barrier over the created event processors. */ @SafeVarargs public final EventHandlerGroup<T> handleEventsWith(final EventHandler<? super T>... handlers) { return disruptor.createEventProcessors(sequences, handlers); }
/** * <p>Set up custom event processors to handle events from the ring buffer. The Disruptor will * automatically start these processors when {@link Disruptor#start()} is called.</p> * * <p>This method is generally used as part of a chain. For example if <code>A</code> must * process events before <code>B</code>:</p> * * <pre><code>dw.after(A).handleEventsWith(B);</code></pre> * * @param eventProcessorFactories the event processor factories to use to create the event processors that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ @SafeVarargs public final EventHandlerGroup<T> handleEventsWith(final EventProcessorFactory<T>... eventProcessorFactories) { return disruptor.createEventProcessors(sequences, eventProcessorFactories); }
/** * <p>Set up custom event processors to handle events from the ring buffer. The Disruptor will * automatically start these processors when {@link #start()} is called.</p> * * <p>This method can be used as the start of a chain. For example if the handler <code>A</code> must * process events before handler <code>B</code>:</p> * <pre><code>dw.handleEventsWith(A).then(B);</code></pre> * * <p>Since this is the start of the chain, the processor factories will always be passed an empty <code>Sequence</code> * array, so the factory isn't necessary in this case. This method is provided for consistency with * {@link EventHandlerGroup#handleEventsWith(EventProcessorFactory...)} and {@link EventHandlerGroup#then(EventProcessorFactory...)} * which do have barrier sequences to provide.</p> * * <p>This call is additive, but generally should only be called once when setting up the Disruptor instance</p> * * @param eventProcessorFactories the event processor factories to use to create the event processors that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ @SafeVarargs public final EventHandlerGroup<T> handleEventsWith(final EventProcessorFactory<T>... eventProcessorFactories) { final Sequence[] barrierSequences = new Sequence[0]; return createEventProcessors(barrierSequences, eventProcessorFactories); }
/** * <p>Set up batch handlers to handle events from the ring buffer. These handlers will only process events * after every {@link EventProcessor} in this group has processed the event.</p> * * <p>This method is generally used as part of a chain. For example if <code>A</code> must * process events before <code>B</code>:</p> * * <pre><code>dw.after(A).handleEventsWith(B);</code></pre> * * @param handlers the batch handlers that will process events. * @return a {@link EventHandlerGroup} that can be used to set up a event processor barrier over the created event processors. */ @SafeVarargs public final EventHandlerGroup<T> handleEventsWith(final EventHandler<? super T>... handlers) { return disruptor.createEventProcessors(sequences, handlers); }
/** * <p>Set up custom event processors to handle events from the ring buffer. The Disruptor will * automatically start these processors when {@link Disruptor#start()} is called.</p> * * <p>This method is generally used as part of a chain. For example if <code>A</code> must * process events before <code>B</code>:</p> * * <pre><code>dw.after(A).handleEventsWith(B);</code></pre> * * @param eventProcessorFactories the event processor factories to use to create the event processors that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ @SafeVarargs public final EventHandlerGroup<T> handleEventsWith(final EventProcessorFactory<T>... eventProcessorFactories) { return disruptor.createEventProcessors(sequences, eventProcessorFactories); }
/** * <p>Set up event handlers to handle events from the ring buffer. These handlers will process events * as soon as they become available, in parallel.</p> * * <p>This method can be used as the start of a chain. For example if the handler <code>A</code> must * process events before handler <code>B</code>:</p> * <pre><code>dw.handleEventsWith(A).then(B);</code></pre> * * <p>This call is additive, but generally should only be called once when setting up the Disruptor instance</p> * * @param handlers the event handlers that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ @SuppressWarnings("varargs") @SafeVarargs public final EventHandlerGroup<T> handleEventsWith(final EventHandler<? super T>... handlers) { return createEventProcessors(new Sequence[0], handlers); }
/** * <p>Set up custom event processors to handle events from the ring buffer. The Disruptor will * automatically start these processors when {@link #start()} is called.</p> * * <p>This method can be used as the start of a chain. For example if the handler <code>A</code> must * process events before handler <code>B</code>:</p> * <pre><code>dw.handleEventsWith(A).then(B);</code></pre> * * <p>Since this is the start of the chain, the processor factories will always be passed an empty <code>Sequence</code> * array, so the factory isn't necessary in this case. This method is provided for consistency with * {@link EventHandlerGroup#handleEventsWith(EventProcessorFactory...)} and {@link EventHandlerGroup#then(EventProcessorFactory...)} * which do have barrier sequences to provide.</p> * * <p>This call is additive, but generally should only be called once when setting up the Disruptor instance</p> * * @param eventProcessorFactories the event processor factories to use to create the event processors that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ @SafeVarargs public final EventHandlerGroup<T> handleEventsWith(final EventProcessorFactory<T>... eventProcessorFactories) { final Sequence[] barrierSequences = new Sequence[0]; return createEventProcessors(barrierSequences, eventProcessorFactories); }
/** * <p>Set up custom event processors to handle events from the ring buffer. The Disruptor will * automatically start these processors when {@link Disruptor#start()} is called.</p> * * <p>This method is generally used as part of a chain. For example if <code>A</code> must * process events before <code>B</code>:</p> * * <pre><code>dw.after(A).handleEventsWith(B);</code></pre> * * @param eventProcessorFactories the event processor factories to use to create the event processors that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ public EventHandlerGroup<T> handleEventsWith(final EventProcessorFactory<T>... eventProcessorFactories) { return disruptor.createEventProcessors(sequences, eventProcessorFactories); }
/** * <p>Set up event handlers to handle events from the ring buffer. These handlers will process events * as soon as they become available, in parallel.</p> * <p> * <p>This method can be used as the start of a chain. For example if the handler <code>A</code> must * process events before handler <code>B</code>:</p> * <pre><code>dw.handleEventsWith(A).then(B);</code></pre> * * @param handlers the event handlers that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ @SuppressWarnings("varargs") public EventHandlerGroup<T> handleEventsWith(final EventHandler<? super T>... handlers) { return createEventProcessors(new Sequence[0], handlers); }
/** * Set up batch handlers to handle events from the ring buffer. These handlers will only process events * after every {@link EventProcessor} in this group has processed the event. * <p> * <p>This method is generally used as part of a chain. For example if <code>A</code> must * process events before <code>B</code>:</p> * <p> * <pre><code>dw.after(A).handleEventsWith(B);</code></pre> * * @param handlers the batch handlers that will process events. * @return a {@link EventHandlerGroup} that can be used to set up a event processor barrier over the created event processors. */ public EventHandlerGroup<T> handleEventsWith(final EventHandler<? super T>... handlers) { return disruptor.createEventProcessors(sequences, handlers); }
/** * <p>Set up custom event processors to handle events from the ring buffer. The Disruptor will * automatically start these processors when {@link Disruptor#start()} is called.</p> * <p> * <p>This method is generally used as part of a chain. For example if <code>A</code> must * process events before <code>B</code>:</p> * <p> * <pre><code>dw.after(A).handleEventsWith(B);</code></pre> * * @param eventProcessorFactories the event processor factories to use to create the event processors that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ public EventHandlerGroup<T> handleEventsWith(final EventProcessorFactory<T>... eventProcessorFactories) { return disruptor.createEventProcessors(sequences, eventProcessorFactories); }
/** * <p>Set up event handlers to handle events from the ring buffer. These handlers will process events * as soon as they become available, in parallel.</p> * * <p>This method can be used as the start of a chain. For example if the handler <code>A</code> must * process events before handler <code>B</code>:</p> * <pre><code>dw.handleEventsWith(A).then(B);</code></pre> * * @param handlers the event handlers that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ @SuppressWarnings("varargs") public EventHandlerGroup<T> handleEventsWith(final EventHandler<? super T>... handlers) { return createEventProcessors(new Sequence[0], handlers); }
/** * Set up batch handlers to handle events from the ring buffer. These handlers will only process events * after every {@link EventProcessor} in this group has processed the event. * * <p>This method is generally used as part of a chain. For example if <code>A</code> must * process events before <code>B</code>:</p> * * <pre><code>dw.after(A).handleEventsWith(B);</code></pre> * * @param handlers the batch handlers that will process events. * @return a {@link EventHandlerGroup} that can be used to set up a event processor barrier over the created event processors. */ public EventHandlerGroup<T> handleEventsWith(final EventHandler<? super T>... handlers) { return disruptor.createEventProcessors(sequences, handlers); }
/** * <p>Set up custom event processors to handle events from the ring buffer. The Disruptor will * automatically start these processors when {@link #start()} is called.</p> * * <p>This method can be used as the start of a chain. For example if the handler <code>A</code> must * process events before handler <code>B</code>:</p> * <pre><code>dw.handleEventsWith(A).then(B);</code></pre> * * <p>Since this is the start of the chain, the processor factories will always be passed an empty <code>Sequence</code> * array, so the factory isn't necessary in this case. This method is provided for consistency with * {@link EventHandlerGroup#handleEventsWith(EventProcessorFactory...)} and {@link EventHandlerGroup#then(EventProcessorFactory...)} * which do have barrier sequences to provide.</p> * * @param eventProcessorFactories the event processor factories to use to create the event processors that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ public EventHandlerGroup<T> handleEventsWith(final EventProcessorFactory<T>... eventProcessorFactories) { final Sequence[] barrierSequences = new Sequence[0]; return createEventProcessors(barrierSequences, eventProcessorFactories); }
/** * <p>Set up custom event processors to handle events from the ring buffer. The Disruptor will * automatically start these processors when {@link #start()} is called.</p> * <p> * <p>This method can be used as the start of a chain. For example if the handler <code>A</code> must * process events before handler <code>B</code>:</p> * <pre><code>dw.handleEventsWith(A).then(B);</code></pre> * <p> * <p>Since this is the start of the chain, the processor factories will always be passed an empty <code>Sequence</code> * array, so the factory isn't necessary in this case. This method is provided for consistency with * {@link EventHandlerGroup#handleEventsWith(EventProcessorFactory...)} and {@link EventHandlerGroup#then(EventProcessorFactory...)} * which do have barrier sequences to provide.</p> * * @param eventProcessorFactories the event processor factories to use to create the event processors that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ public EventHandlerGroup<T> handleEventsWith(final EventProcessorFactory<T>... eventProcessorFactories) { final Sequence[] barrierSequences = new Sequence[0]; return createEventProcessors(barrierSequences, eventProcessorFactories); }
/** * <p>Set up batch handlers to handle events from the ring buffer. These handlers will only process events * after every {@link EventProcessor} in this group has processed the event.</p> * * <p>This method is generally used as part of a chain. For example if <code>A</code> must * process events before <code>B</code>:</p> * * <pre><code>dw.after(A).handleEventsWith(B);</code></pre> * * @param handlers the batch handlers that will process events. * @return a {@link EventHandlerGroup} that can be used to set up a event processor barrier over the created event processors. */ @SafeVarargs public final EventHandlerGroup<T> handleEventsWith(final EventHandler<? super T>... handlers) { return disruptor.createEventProcessors(sequences, handlers); }
/** * <p>Set up custom event processors to handle events from the ring buffer. The Disruptor will * automatically start these processors when {@link Disruptor#start()} is called.</p> * * <p>This method is generally used as part of a chain. For example if <code>A</code> must * process events before <code>B</code>:</p> * * <pre><code>dw.after(A).handleEventsWith(B);</code></pre> * * @param eventProcessorFactories the event processor factories to use to create the event processors that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ @SafeVarargs public final EventHandlerGroup<T> handleEventsWith(final EventProcessorFactory<T>... eventProcessorFactories) { return disruptor.createEventProcessors(sequences, eventProcessorFactories); }
/** * <p>Set up event handlers to handle events from the ring buffer. These handlers will process events * as soon as they become available, in parallel.</p> * * <p>This method can be used as the start of a chain. For example if the handler <code>A</code> must * process events before handler <code>B</code>:</p> * <pre><code>dw.handleEventsWith(A).then(B);</code></pre> * * <p>This call is additive, but generally should only be called once when setting up the Disruptor instance</p> * * @param handlers the event handlers that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ @SuppressWarnings("varargs") @SafeVarargs public final EventHandlerGroup<T> handleEventsWith(final EventHandler<? super T>... handlers) { return createEventProcessors(new Sequence[0], handlers); }
/** * <p>Set up custom event processors to handle events from the ring buffer. The Disruptor will * automatically start these processors when {@link #start()} is called.</p> * * <p>This method can be used as the start of a chain. For example if the handler <code>A</code> must * process events before handler <code>B</code>:</p> * <pre><code>dw.handleEventsWith(A).then(B);</code></pre> * * <p>Since this is the start of the chain, the processor factories will always be passed an empty <code>Sequence</code> * array, so the factory isn't necessary in this case. This method is provided for consistency with * {@link EventHandlerGroup#handleEventsWith(EventProcessorFactory...)} and {@link EventHandlerGroup#then(EventProcessorFactory...)} * which do have barrier sequences to provide.</p> * * <p>This call is additive, but generally should only be called once when setting up the Disruptor instance</p> * * @param eventProcessorFactories the event processor factories to use to create the event processors that will process events. * @return a {@link EventHandlerGroup} that can be used to chain dependencies. */ @SafeVarargs public final EventHandlerGroup<T> handleEventsWith(final EventProcessorFactory<T>... eventProcessorFactories) { final Sequence[] barrierSequences = new Sequence[0]; return createEventProcessors(barrierSequences, eventProcessorFactories); }