Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:31:05

0001 
0002 #ifndef VertexCategories_h
0003 #define VertexCategories_h
0004 
0005 #include <ostream>
0006 #include <vector>
0007 
0008 class VertexCategories {
0009 public:
0010   //! Categories available to vertexes
0011   enum Category {
0012     Fake = 0,
0013     Reconstructed = Fake,
0014     SignalEvent,
0015     BWeakDecay,
0016     CWeakDecay,
0017     TauDecay,
0018     KsDecay,
0019     LambdaDecay,
0020     JpsiDecay,
0021     XiDecay,
0022     OmegaDecay,
0023     SigmaPlusDecay,
0024     SigmaMinusDecay,
0025     LongLivedDecay,
0026     KnownProcess,
0027     UndefinedProcess,
0028     UnknownProcess,
0029     PrimaryProcess,
0030     HadronicProcess,
0031     DecayProcess,
0032     ComptonProcess,
0033     AnnihilationProcess,
0034     EIoniProcess,
0035     HIoniProcess,
0036     MuIoniProcess,
0037     PhotonProcess,
0038     MuPairProdProcess,
0039     ConversionsProcess,
0040     EBremProcess,
0041     SynchrotronRadiationProcess,
0042     MuBremProcess,
0043     MuNuclProcess,
0044     PrimaryVertex,
0045     SecondaryVertex,
0046     TertiaryVertex,
0047     TierciaryVertex = TertiaryVertex,
0048     Unknown
0049   };
0050 
0051   //! Name of the different categories
0052   static const char *const Names[];
0053 
0054   //! Main types associated to the class
0055   typedef std::vector<bool> Flags;
0056 
0057   //! Void constructor
0058   VertexCategories() { reset(); }
0059 
0060   //! Returns track flag for a given category
0061   bool is(Category category) const { return flags_[category]; }
0062 
0063   //! Returns flags with the category descriptions
0064   const Flags &flags() const { return flags_; }
0065 
0066 protected:
0067   //! Reset the categories flags
0068   void reset() { flags_ = Flags(Unknown + 1, false); }
0069 
0070   // Check for unkown classification
0071   void unknownVertex();
0072 
0073   //! Flag containers
0074   Flags flags_;
0075 };
0076 
0077 // Operation overload for printing the categories
0078 std::ostream &operator<<(std::ostream &, VertexCategories const &);
0079 
0080 #endif