Line data Source code
1 : //--------------------------------------------------------------------------
2 : //
3 : // Environment:
4 : // This software is part of the EvtGen package developed jointly
5 : // for the BaBar and CLEO collaborations. If you use all or part
6 : // of it, please give an appropriate acknowledgement.
7 : //
8 : // Copyright Information: See EvtGen/COPYRIGHT
9 : // Copyright (C) 1998 Caltech, UCSB
10 : //
11 : // Module: EvtId.cc
12 : //
13 : // Description: Class for particle Id used in EvtGen.
14 : //
15 : // Modification history:
16 : //
17 : // RYD May 26, 1998 Module created
18 : //
19 : //------------------------------------------------------------------------
20 : //
21 : #include "EvtGenBase/EvtPatches.hh"
22 :
23 : #include "EvtGenBase/EvtId.hh"
24 : #include "EvtGenBase/EvtPDL.hh"
25 : #include <iostream>
26 : using std::ostream;
27 :
28 :
29 : ostream& operator<<(ostream& s, const EvtId& id){
30 :
31 0 : s<<"(Id="<<id._id<<" Alias="<<id._alias<<")";
32 :
33 0 : return s;
34 :
35 : }
36 :
37 :
38 : int EvtId::isConjugate(const EvtId & id) const {
39 0 : return EvtPDL::getStdHep(*this) == - EvtPDL::getStdHep(id);
40 : }
41 :
42 : std::string EvtId::getName() const {
43 :
44 0 : return EvtPDL::name(*this);
45 :
46 : }
|