CMS 3D CMS Logo

Public Member Functions | Private Attributes

reco::tau::RecoTauObjectEmbedder< T > Class Template Reference

Inheritance diagram for reco::tau::RecoTauObjectEmbedder< T >:
reco::tau::RecoTauModifierPlugin reco::tau::RecoTauEventHolderPlugin reco::tau::RecoTauNamedPlugin

List of all members.

Public Member Functions

virtual void beginEvent ()
virtual void operator() (PFTau &) const
 RecoTauObjectEmbedder (const edm::ParameterSet &pset)
virtual ~RecoTauObjectEmbedder ()

Private Attributes

edm::Handle< edm::Association
< T > > 
jetMatch_
edm::InputTag jetMatchSrc_

Detailed Description

template<typename T>
class reco::tau::RecoTauObjectEmbedder< T >

Definition at line 56 of file RecoTauObjectEmbedderPlugin.cc.


Constructor & Destructor Documentation

template<typename T >
reco::tau::RecoTauObjectEmbedder< T >::RecoTauObjectEmbedder ( const edm::ParameterSet pset) [inline, explicit]

Definition at line 58 of file RecoTauObjectEmbedderPlugin.cc.

        :RecoTauModifierPlugin(pset),
        jetMatchSrc_(pset.getParameter<edm::InputTag>("jetTruthMatch")) {}
template<typename T >
virtual reco::tau::RecoTauObjectEmbedder< T >::~RecoTauObjectEmbedder ( ) [inline, virtual]

Definition at line 61 of file RecoTauObjectEmbedderPlugin.cc.

{}

Member Function Documentation

template<typename T >
void reco::tau::RecoTauObjectEmbedder< T >::beginEvent ( ) [virtual]

Reimplemented from reco::tau::RecoTauModifierPlugin.

Definition at line 71 of file RecoTauObjectEmbedderPlugin.cc.

template<typename T >
void reco::tau::RecoTauObjectEmbedder< T >::operator() ( PFTau tau) const [virtual]

Implements reco::tau::RecoTauModifierPlugin.

Definition at line 76 of file RecoTauObjectEmbedderPlugin.cc.

References edm::Ref< C, T, F >::isNonnull(), reco::PFTau::jetRef(), reco::tau::helpers::nCharged(), reco::tau::helpers::nGammas(), reco::BaseTau::setalternatLorentzVect(), reco::PFTau::setbremsRecoveryEOverPLead(), and reco::tau::translateDecayMode().

                                                          {
  // Get the matched object that is matched to the same jet as the current tau,
  // if it exists
  edm::Ref<T> matchedObject = (*jetMatch_)[tau.jetRef()];
  if (matchedObject.isNonnull()) {
    // Store our matched object information
    tau.setalternatLorentzVect(matchedObject->p4());
    // Store our generator decay mode
    tau.setbremsRecoveryEOverPLead(
        reco::tau::translateDecayMode(
            helpers::nCharged(*matchedObject),
            helpers::nGammas(*matchedObject)/2)
        );
  } else {
    tau.setbremsRecoveryEOverPLead(-10);
  }
}

Member Data Documentation

Definition at line 66 of file RecoTauObjectEmbedderPlugin.cc.

template<typename T >
edm::InputTag reco::tau::RecoTauObjectEmbedder< T >::jetMatchSrc_ [private]

Definition at line 65 of file RecoTauObjectEmbedderPlugin.cc.