CMS 3D CMS Logo

Public Types | Public Member Functions | Static Public Attributes | Protected Attributes

reco::FlavorHistory Class Reference

#include <FlavorHistory.h>

List of all members.

Public Types

enum  FLAVOR_T {
  FLAVOR_NULL = 0, FLAVOR_GS, FLAVOR_EXC, FLAVOR_ME,
  FLAVOR_DECAY, N_FLAVOR_TYPES
}

Public Member Functions

 FlavorHistory ()
 FlavorHistory (FLAVOR_T flavorSource, reco::CandidatePtr const &parton, reco::CandidatePtr const &progenitor, reco::CandidatePtr const &sister, reco::ShallowClonePtrCandidate const &matchedJet, reco::ShallowClonePtrCandidate const &sisterJet)
 FlavorHistory (FLAVOR_T flavorSource, edm::Handle< reco::CandidateCollection > h_partons, int iparton, int iprogenitor, int isister, reco::ShallowClonePtrCandidate const &matchedJet, reco::ShallowClonePtrCandidate const &sisterJet)
 FlavorHistory (FLAVOR_T flavorSource, edm::Handle< edm::View< reco::Candidate > > h_partons, int iparton, int iprogenitor, int isister, reco::ShallowClonePtrCandidate const &matchedJet, reco::ShallowClonePtrCandidate const &sisterJet)
FLAVOR_T flavorSource () const
bool hasMatchedJet () const
bool hasParton () const
bool hasProgenitor () const
bool hasSister () const
bool hasSisterJet () const
const
reco::ShallowClonePtrCandidate
matchedJet () const
bool operator< (FlavorHistory const &right) const
bool operator== (FlavorHistory const &right) const
bool operator> (FlavorHistory const &right) const
const reco::CandidatePtrparton () const
const reco::CandidatePtrprogenitor () const
const reco::CandidatePtrsister () const
const
reco::ShallowClonePtrCandidate
sisterJet () const
 ~FlavorHistory ()

Static Public Attributes

static const int bQuarkId = 5
static const int cQuarkId = 4
static const int gluonId = 21
static const int tQuarkId = 6

Protected Attributes

FLAVOR_T flavorSource_
reco::ShallowClonePtrCandidate matchedJet_
reco::CandidatePtr parton_
reco::CandidatePtr progenitor_
reco::CandidatePtr sister_
reco::ShallowClonePtrCandidate sisterJet_

Detailed Description

Stores information about the flavor history of a parton

Author:
: Stephen Mrenna (FNAL), Salvatore Rappoccio (JHU)

Definition at line 48 of file FlavorHistory.h.


Member Enumeration Documentation

Enumerator:
FLAVOR_NULL 
FLAVOR_GS 
FLAVOR_EXC 
FLAVOR_ME 
FLAVOR_DECAY 
N_FLAVOR_TYPES 

Definition at line 51 of file FlavorHistory.h.

                { FLAVOR_NULL=0,   // No flavor, unset
                  FLAVOR_GS,       // gluon splitting
                  FLAVOR_EXC,      // flavor excitation
                  FLAVOR_ME,       // matrix element
                  FLAVOR_DECAY,    // flavor decay
                  N_FLAVOR_TYPES };// total number

Constructor & Destructor Documentation

FlavorHistory::FlavorHistory ( )

Definition at line 7 of file FlavorHistory.cc.

FlavorHistory::FlavorHistory ( FLAVOR_T  flavorSource,
reco::CandidatePtr const &  parton,
reco::CandidatePtr const &  progenitor,
reco::CandidatePtr const &  sister,
reco::ShallowClonePtrCandidate const &  matchedJet,
reco::ShallowClonePtrCandidate const &  sisterJet 
)
FlavorHistory::FlavorHistory ( FLAVOR_T  flavorSource,
edm::Handle< edm::View< reco::Candidate > >  h_partons,
int  iparton,
int  iprogenitor,
int  isister,
reco::ShallowClonePtrCandidate const &  matchedJet,
reco::ShallowClonePtrCandidate const &  sisterJet 
)

Definition at line 28 of file FlavorHistory.cc.

                                                                               :
  flavorSource_(flavorSource),
  parton_    ( parton     >= 0 && static_cast<unsigned int>(parton)     < h_partons->size() ? CandidatePtr(h_partons,parton)     : CandidatePtr()),
  progenitor_( progenitor >= 0 && static_cast<unsigned int>(progenitor) < h_partons->size() ? CandidatePtr(h_partons,progenitor) : CandidatePtr()),
  sister_    ( sister     >= 0 && static_cast<unsigned int>(sister)     < h_partons->size() ? CandidatePtr(h_partons,sister)     : CandidatePtr()),
  matchedJet_( matchedJet ),
  sisterJet_ ( sisterJet )
{
  
}
FlavorHistory::FlavorHistory ( FLAVOR_T  flavorSource,
edm::Handle< reco::CandidateCollection h_partons,
int  iparton,
int  iprogenitor,
int  isister,
reco::ShallowClonePtrCandidate const &  matchedJet,
reco::ShallowClonePtrCandidate const &  sisterJet 
)

Definition at line 45 of file FlavorHistory.cc.

                                                                               :
  flavorSource_(flavorSource),
  parton_    ( parton     >= 0 && static_cast<unsigned int>(parton)     < h_partons->size() ? CandidatePtr(h_partons,parton)     : CandidatePtr()),
  progenitor_( progenitor >= 0 && static_cast<unsigned int>(progenitor) < h_partons->size() ? CandidatePtr(h_partons,progenitor) : CandidatePtr()),
  sister_    ( sister     >= 0 && static_cast<unsigned int>(sister)     < h_partons->size() ? CandidatePtr(h_partons,sister)     : CandidatePtr()),
  matchedJet_( matchedJet ),
  sisterJet_ ( sisterJet )
{
  
}
reco::FlavorHistory::~FlavorHistory ( ) [inline]

Definition at line 85 of file FlavorHistory.h.

{}

Member Function Documentation

FLAVOR_T reco::FlavorHistory::flavorSource ( ) const [inline]

Definition at line 89 of file FlavorHistory.h.

References flavorSource_.

Referenced by reco::FlavorHistoryEvent::cache(), and operator<<().

{ return flavorSource_; }
bool reco::FlavorHistory::hasMatchedJet ( ) const [inline]

Definition at line 93 of file FlavorHistory.h.

References edm::Ptr< T >::isNonnull(), reco::ShallowClonePtrCandidate::masterClonePtr(), and matchedJet_.

Referenced by operator<<().

{ return matchedJet_.masterClonePtr().isNonnull(); }
bool reco::FlavorHistory::hasParton ( ) const [inline]

Definition at line 90 of file FlavorHistory.h.

References edm::Ptr< T >::isNonnull(), and parton_.

Referenced by operator<<().

{ return parton_.isNonnull(); }
bool reco::FlavorHistory::hasProgenitor ( ) const [inline]

Definition at line 92 of file FlavorHistory.h.

References edm::Ptr< T >::isNonnull(), and progenitor_.

Referenced by operator<<().

{ return progenitor_.isNonnull();}
bool reco::FlavorHistory::hasSister ( ) const [inline]

Definition at line 91 of file FlavorHistory.h.

References edm::Ptr< T >::isNonnull(), and sister_.

Referenced by operator<<().

{ return sister_.isNonnull(); }
bool reco::FlavorHistory::hasSisterJet ( ) const [inline]

Definition at line 94 of file FlavorHistory.h.

References edm::Ptr< T >::isNonnull(), reco::ShallowClonePtrCandidate::masterClonePtr(), and sisterJet_.

Referenced by operator<<().

{ return sisterJet_.masterClonePtr().isNonnull(); }
const reco::ShallowClonePtrCandidate& reco::FlavorHistory::matchedJet ( ) const [inline]

Definition at line 99 of file FlavorHistory.h.

References matchedJet_.

Referenced by reco::FlavorHistoryEvent::cache(), and operator<<().

{ return matchedJet_; }
bool reco::FlavorHistory::operator< ( FlavorHistory const &  right) const [inline]

Definition at line 104 of file FlavorHistory.h.

References edm::Ptr< T >::key(), and parton_.

                                                       {
    return parton_.key() < right.parton_.key();
  }
bool reco::FlavorHistory::operator== ( FlavorHistory const &  right) const [inline]

Definition at line 110 of file FlavorHistory.h.

References edm::Ptr< T >::key(), and parton_.

                                                        {
    return parton_.key() == right.parton_.key();
  }
bool reco::FlavorHistory::operator> ( FlavorHistory const &  right) const [inline]

Definition at line 107 of file FlavorHistory.h.

References edm::Ptr< T >::key(), and parton_.

                                                       {
    return parton_.key() > right.parton_.key();
  }
const reco::CandidatePtr& reco::FlavorHistory::parton ( ) const [inline]

Definition at line 95 of file FlavorHistory.h.

References parton_.

Referenced by reco::FlavorHistoryEvent::cache(), and operator<<().

{ return parton_; }
const reco::CandidatePtr& reco::FlavorHistory::progenitor ( ) const [inline]

Definition at line 97 of file FlavorHistory.h.

References progenitor_.

Referenced by operator<<().

{ return progenitor_; }
const reco::CandidatePtr& reco::FlavorHistory::sister ( ) const [inline]

Definition at line 96 of file FlavorHistory.h.

References sister_.

Referenced by operator<<().

{ return sister_; }
const reco::ShallowClonePtrCandidate& reco::FlavorHistory::sisterJet ( ) const [inline]

Definition at line 101 of file FlavorHistory.h.

References sisterJet_.

Referenced by operator<<().

{ return sisterJet_; }

Member Data Documentation

const int reco::FlavorHistory::bQuarkId = 5 [static]

Definition at line 60 of file FlavorHistory.h.

Referenced by reco::FlavorHistorySelectorUtil::select().

const int reco::FlavorHistory::cQuarkId = 4 [static]

Definition at line 61 of file FlavorHistory.h.

Referenced by reco::FlavorHistorySelectorUtil::select().

Definition at line 117 of file FlavorHistory.h.

Referenced by flavorSource().

const int reco::FlavorHistory::gluonId = 21 [static]

Definition at line 58 of file FlavorHistory.h.

Definition at line 121 of file FlavorHistory.h.

Referenced by hasMatchedJet(), and matchedJet().

Definition at line 118 of file FlavorHistory.h.

Referenced by hasParton(), operator<(), operator==(), operator>(), and parton().

Definition at line 119 of file FlavorHistory.h.

Referenced by hasProgenitor(), and progenitor().

Definition at line 120 of file FlavorHistory.h.

Referenced by hasSister(), and sister().

Definition at line 122 of file FlavorHistory.h.

Referenced by hasSisterJet(), and sisterJet().

const int reco::FlavorHistory::tQuarkId = 6 [static]

Definition at line 59 of file FlavorHistory.h.