test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Member Functions
fwlite::EventBase Class Referenceabstract

#include <EventBase.h>

Inheritance diagram for fwlite::EventBase:
edm::EventBase fwlite::ChainEvent fwlite::Event fwlite::EventContainer fwlite::MultiChainEvent

Public Member Functions

virtual bool atEnd () const =0
 
 EventBase ()
 
virtual Long64_t fileIndex () const
 
virtual std::string const getBranchNameFor (std::type_info const &, char const *, char const *, char const *) const =0
 
virtual bool getByLabel (std::type_info const &, char const *, char const *, char const *, void *) const =0
 
virtual bool getByLabel (std::type_info const &, char const *, char const *, char const *, edm::WrapperHolder &) const =0
 
virtual EventBase const & operator++ ()=0
 
virtual Long64_t secondaryFileIndex () const
 
virtual EventBase const & toBegin ()=0
 
virtual ~EventBase ()
 
- Public Member Functions inherited from edm::EventBase
int bunchCrossing () const
 
virtual edm::EventAuxiliary const & eventAuxiliary () const =0
 
 EventBase ()
 
edm::EventAuxiliary::ExperimentType experimentType () const
 
template<typename T >
bool getByLabel (InputTag const &, Handle< T > &) const
 
template<>
bool getByLabel (edm::InputTag const &tag, Handle< FWGenericObject > &result) const
 Specialize the getByLabel method to work with a Handle<FWGenericObject> More...
 
edm::EventID id () const
 
bool isRealData () const
 
edm::LuminosityBlockNumber_t luminosityBlock () const
 
int orbitNumber () const
 
virtual ProcessHistory const & processHistory () const =0
 
edm::Timestamp time () const
 
virtual TriggerNames const & triggerNames (edm::TriggerResults const &triggerResults) const =0
 
virtual TriggerResultsByName triggerResultsByName (std::string const &process) const =0
 

Private Member Functions

virtual edm::BasicHandle getByLabelImpl (std::type_info const &, std::type_info const &, const edm::InputTag &) const
 

Additional Inherited Members

- Static Protected Member Functions inherited from edm::EventBase
static TriggerNames const * triggerNames_ (edm::TriggerResults const &triggerResults)
 

Detailed Description

Definition at line 32 of file EventBase.h.

Constructor & Destructor Documentation

EventBase::EventBase ( )

Definition at line 30 of file EventBase.cc.

31  {
32  }
EventBase::~EventBase ( )
virtual

Reimplemented from edm::EventBase.

Definition at line 34 of file EventBase.cc.

35  {
36  }

Member Function Documentation

virtual bool fwlite::EventBase::atEnd ( ) const
pure virtual
virtual Long64_t fwlite::EventBase::fileIndex ( ) const
inlinevirtual

Reimplemented in fwlite::MultiChainEvent, fwlite::EventContainer, and fwlite::ChainEvent.

Definition at line 65 of file EventBase.h.

Referenced by fwlite::EventContainer::fileIndex(), and python.Events::fileIndicies().

65 { return -1; }
virtual std::string const fwlite::EventBase::getBranchNameFor ( std::type_info const &  ,
char const *  ,
char const *  ,
char const *   
) const
pure virtual
virtual bool fwlite::EventBase::getByLabel ( std::type_info const &  ,
char const *  ,
char const *  ,
char const *  ,
void *   
) const
pure virtual
virtual bool fwlite::EventBase::getByLabel ( std::type_info const &  ,
char const *  ,
char const *  ,
char const *  ,
edm::WrapperHolder  
) const
pure virtual
edm::BasicHandle EventBase::getByLabelImpl ( std::type_info const &  iWrapperInfo,
std::type_info const &  ,
const edm::InputTag iTag 
) const
privatevirtual

Implements edm::EventBase.

Definition at line 39 of file EventBase.cc.

References compareJSON::const, getByLabel(), edm::InputTag::instance(), edm::WrapperHolder::isPresent(), edm::WrapperHolder::isValid(), edm::InputTag::label(), edm::makeHandleExceptionFactory(), edm::InputTag::process(), edm::errors::ProductNotFound, s_prov, and relativeConstraints::value.

39  {
41  getByLabel(iWrapperInfo,
42  iTag.label().c_str(),
43  iTag.instance().empty()?static_cast<char const*>(0):iTag.instance().c_str(),
44  iTag.process().empty()?static_cast<char const*> (0):iTag.process().c_str(),
45  edp);
46  if(!edp.isValid() || !edp.isPresent()) {
47  edm::TypeID productType(iWrapperInfo);
48  edm::BasicHandle failed(edm::makeHandleExceptionFactory([=]()->std::shared_ptr<cms::Exception>{
49  std::shared_ptr<cms::Exception> whyFailed(std::make_shared<edm::Exception>(edm::errors::ProductNotFound));
50  *whyFailed
51  << "getByLabel: Found zero products matching all criteria\n"
52  << "Looking for type: " << productType << "\n"
53  << "Looking for module label: " << iTag.label() << "\n"
54  << "Looking for productInstanceName: " << iTag.instance() << "\n"
55  << (iTag.process().empty() ? "" : "Looking for process: ") << iTag.process() << "\n"
56  << "The data is registered in the file but is not available for this event\n";
57  return whyFailed;
58  }));
59  return failed;
60  }
61 
63  return value;
64  }
virtual bool getByLabel(std::type_info const &, char const *, char const *, char const *, void *) const =0
std::shared_ptr< HandleExceptionFactory > makeHandleExceptionFactory(T &&iFunctor)
string const
Definition: compareJSON.py:14
std::string const & label() const
Definition: InputTag.h:42
std::string const & process() const
Definition: InputTag.h:46
static const edm::Provenance s_prov(boost::shared_ptr< edm::BranchDescription const >(&s_branch, edm::do_nothing_deleter()), s_id)
bool isValid() const
Definition: WrapperHolder.h:27
bool isPresent() const
Definition: WrapperHolder.h:64
std::string const & instance() const
Definition: InputTag.h:43
virtual EventBase const& fwlite::EventBase::operator++ ( )
pure virtual
virtual Long64_t fwlite::EventBase::secondaryFileIndex ( ) const
inlinevirtual

Reimplemented in fwlite::MultiChainEvent, and fwlite::EventContainer.

Definition at line 66 of file EventBase.h.

Referenced by python.Events::fileIndicies(), and fwlite::EventContainer::secondaryFileIndex().

66 { return -1; }
virtual EventBase const& fwlite::EventBase::toBegin ( )
pure virtual