Definition at line 17 of file Particle.java.
Public Member Functions | |
Particle () | |
Particle (String desc, double E) | |
double | getEnergy () |
void | setEnergy (double e) |
String | getName () |
String | toString () |
void | setName (String p) |
boolean | equals (Object obj) |
int | hashCode () |
Static Public Attributes | |
String | PROTON = "p" |
String | ANTIPROTON = "pbar" |
String | POSITRON = "e+" |
String | ELECTRON = "e-" |
String | PHOTON = "gamma" |
Private Attributes | |
double | energy |
String | name |
int | hashCode_ |
boolean | dirtyHashCode_ |
|
Create an empty particle. Definition at line 54 of file Particle.java. 00054 {}
|
|
Create an particle with energy and description. Definition at line 58 of file Particle.java. 00058 { 00059 name=desc; 00060 energy=E; 00061 dirtyHashCode_=true; 00062 }
|
|
Override the Object equals method. Use the particle name and energy. Definition at line 90 of file Particle.java. References Particle.getEnergy(), and Particle.getName(). Referenced by Collision.equals(). 00090 { 00091 00092 if (obj==null) { return false; } 00093 00094 if ( !this.getClass().equals(obj.getClass()) ) { return false; } 00095 00096 Particle c = (Particle)obj; 00097 return (name.equals(c.getName()) && 00098 Match.compareDouble(energy,c.getEnergy())); 00099 }
|
|
Definition at line 64 of file Particle.java. Referenced by Particle.equals(). 00064 {
00065 return energy;
00066 }
|
|
Definition at line 72 of file Particle.java. Referenced by Particle.equals(), MCProcessType.getBeams(), MCProcessType.hasPhoton(), and MCProcessType.hasProton(). 00072 { return name; }
|
|
Definition at line 101 of file Particle.java. 00101 { 00102 if (dirtyHashCode_){ 00103 hashCode_ = (new Double(energy)).hashCode()+name.hashCode(); 00104 dirtyHashCode_=false; 00105 } 00106 return hashCode_; 00107 }
|
|
Definition at line 68 of file Particle.java. Referenced by DBManager.fill(). 00068 { 00069 dirtyHashCode_=true; 00070 energy=e; 00071 }
|
|
Set particle 1 Definition at line 82 of file Particle.java. Referenced by DBManager.fill(). 00082 { 00083 dirtyHashCode_=true; 00084 name = p; 00085 }
|
|
Definition at line 75 of file Particle.java. Referenced by MCProcessType.toString(), and Collision.toString(). 00075 { 00076 return energy+" GeV "+name; 00077 }
|
|
Should agree with HepML http://hepforge.cedar.ac.uk/hepml/schemas/particle.xsd Definition at line 33 of file Particle.java. |
|
Definition at line 22 of file Particle.java. |
|
Should agree with HepML http://hepforge.cedar.ac.uk/hepml/schemas/particle.xsd Definition at line 43 of file Particle.java. |
|
Definition at line 19 of file Particle.java. |
|
Definition at line 21 of file Particle.java. |
|
Definition at line 20 of file Particle.java. |
|
Should agree with HepML http://hepforge.cedar.ac.uk/hepml/schemas/particle.xsd Definition at line 48 of file Particle.java. |
|
Should agree with HepML http://hepforge.cedar.ac.uk/hepml/schemas/particle.xsd Definition at line 38 of file Particle.java. |
|
Should agree with HepML http://hepforge.cedar.ac.uk/hepml/schemas/particle.xsd Definition at line 28 of file Particle.java. |
Generated Wed Jan 17 09:14:27 GMT 2007