The Gaudi Framework  master (82fdf313)
Loading...
Searching...
No Matches
IQueueingEventProcessor.h
Go to the documentation of this file.
1/***********************************************************************************\
2* (c) Copyright 1998-2019 CERN for the benefit of the LHCb and ATLAS collaborations *
3* *
4* This software is distributed under the terms of the Apache version 2 licence, *
5* copied verbatim in the file "LICENSE". *
6* *
7* In applying this licence, CERN does not waive the privileges and immunities *
8* granted to it by virtue of its status as an Intergovernmental Organization *
9* or submit itself to any jurisdiction. *
10\***********************************************************************************/
11#pragma once
12
16#include <optional>
17#include <tuple>
18
19namespace Gaudi::Interfaces {
23
25 using ResultType = std::tuple<StatusCode, EventContext>;
26
29 virtual void push( EventContext&& ctx ) = 0;
30
33 virtual bool empty() const = 0;
34
37 virtual std::optional<ResultType> pop() = 0;
38 };
39} // namespace Gaudi::Interfaces
This class represents an entry point to all the event specific data.
The IEventProcessor is the interface to process events.
Extend IEventProcessor for asynchronous scheduling of events via queue-like interface.
virtual std::optional< ResultType > pop()=0
Get the next available result.
virtual bool empty() const =0
Tell if the processor has events in the queues.
DeclareInterfaceID(IQueueingEventProcessor, 1, 0)
std::tuple< StatusCode, EventContext > ResultType
Type of objects in the output queue.
virtual void push(EventContext &&ctx)=0
Schedule the processing of an event.