Loading [MathJax]/extensions/tex2jax.js
The Gaudi Framework  master (d98a2936)
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
IEvtSelector.h
Go to the documentation of this file.
1 /***********************************************************************************\
2 * (c) Copyright 1998-2025 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 
13 #include <GaudiKernel/IInterface.h>
15 #include <GaudiKernel/StatusCode.h>
16 #include <string>
17 
26 class GAUDI_API IEvtSelector : virtual public IInterface {
27 public:
30 
31  class Context {
32  public:
33  virtual ~Context() = default;
34  virtual void* identifier() const = 0;
35  };
36 
42  virtual StatusCode createContext( Context*& c ) const = 0;
43 
51  virtual StatusCode next( Context& c ) const = 0;
52 
58  virtual StatusCode next( Context& c, int jump ) const = 0;
59 
66  virtual StatusCode previous( Context& c ) const = 0;
67 
73  virtual StatusCode previous( Context& c, int jump ) const = 0;
74 
78  virtual StatusCode last( Context& refContext ) const = 0;
79 
85  virtual StatusCode rewind( Context& c ) const = 0;
86 
93  virtual StatusCode createAddress( const Context& c, IOpaqueAddress*& iop ) const = 0;
94 
99  virtual StatusCode releaseContext( Context*& ) const = 0;
100 
107  virtual StatusCode resetCriteria( const std::string& cr, Context& c ) const = 0;
108 };
IEvtSelector::DeclareInterfaceID
DeclareInterfaceID(IEvtSelector, 2, 0)
InterfaceID.
IEvtSelector::next
virtual StatusCode next(Context &c) const =0
Fetch the next event or the first event if it will be use soon after the creation of the context.
IOpaqueAddress
Definition: IOpaqueAddress.h:28
IEvtSelector
Definition: IEvtSelector.h:26
gaudirun.c
c
Definition: gaudirun.py:525
IEvtSelector::last
virtual StatusCode last(Context &refContext) const =0
Access last item in the iteration.
IEvtSelector::previous
virtual StatusCode previous(Context &c, int jump) const =0
Same of previous(Context& c) the possibility to jump the previous n-1 events.
IEvtSelector::Context
Definition: IEvtSelector.h:31
StatusCode.h
IEvtSelector::createAddress
virtual StatusCode createAddress(const Context &c, IOpaqueAddress *&iop) const =0
Create an IOpaqueAddress object from the event fetched.
IEvtSelector::resetCriteria
virtual StatusCode resetCriteria(const std::string &cr, Context &c) const =0
Will set a new criteria for the selection of the next list of events and will change the state of the...
IEvtSelector::rewind
virtual StatusCode rewind(Context &c) const =0
Will set the state of the context in a way that the next event read is the first of the list.
StatusCode
Definition: StatusCode.h:64
IInterface.h
IOpaqueAddress.h
IEvtSelector::next
virtual StatusCode next(Context &c, int jump) const =0
Same of next(const Context&) plus the possibility to jump the next n-1 events.
IEvtSelector::Context::~Context
virtual ~Context()=default
IInterface
Definition: IInterface.h:225
IEvtSelector::previous
virtual StatusCode previous(Context &c) const =0
Fetch the previous event.
IEvtSelector::createContext
virtual StatusCode createContext(Context *&c) const =0
Create and return a context object that will keep track of the state of selection.
IEvtSelector::Context::identifier
virtual void * identifier() const =0
IEvtSelector::releaseContext
virtual StatusCode releaseContext(Context *&) const =0
Release the Context object.
GAUDI_API
#define GAUDI_API
Definition: Kernel.h:49