ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitProd/TreeFiller/interface/AssociationMap.h
(Generate patch)

Comparing UserCode/MitProd/TreeFiller/interface/AssociationMap.h (file contents):
Revision 1.4 by loizides, Wed Jul 30 08:39:08 2008 UTC vs.
Revision 1.5 by sixie, Mon Aug 18 11:10:31 2008 UTC

# Line 32 | Line 32 | namespace mithep
32        Int_t      GetEdmProductId()          const { return edmProductId_; }
33        Int_t      GetEntries()               const { return fwdMap_.size(); }
34        MitClass   GetMit(EdmClass edmObj)    const;
35 +      bool       HasMit(EdmClass edmObj)    const;
36        void       Reset()                          { fwdMap_.clear(); revMap_.clear(); }
37        void       SetEdmProductId(Int_t id)        { edmProductId_ = id; }
38  
# Line 74 | Line 75 | inline EdmClass mithep::AssociationMap<E
75           << "Error! MITHEP Object (" << typeid(mitObj).name()
76           << ") not found in AssociationMap (" << typeid(*this).name() << ")." << std::endl;
77   }
78 +
79 + //--------------------------------------------------------------------------------------------------
80 + template <class EdmClass, class MitClass>
81 + inline bool mithep::AssociationMap<EdmClass,MitClass>::HasMit(EdmClass edmObj) const
82 + {
83 +  typename fwdMapType::const_iterator iter = fwdMap_.find(edmObj);
84 +
85 +  if (iter != fwdMap_.end())
86 +    return true;
87 +  else
88 +    return false;
89 + }
90 +      
91   #endif

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines