// LCDMcPart.h
// Nov. 8 2000 M.Iwasaki Apply necessary modifications:
//                       1) position momentum ->Use TLorentzVector and TVector3
//                       2) Change the definition of 'position'
//                              Position     particle product point
//                              TermPosition particle decay point
//                       3) Change/add classes
// Sep.10 1998 R.Shanks  Creation

#ifndef LCDMCPART_H
#define LCDMCPART_H

#include "TObject.h"
#include "TVector3.h"
#include "TLorentzVector.h"

class LCDMcPart: public TObject {
public:
  LCDMcPart();
  LCDMcPart(Int_t ID);
  LCDMcPart(LCDMcPart* part);
  ~LCDMcPart(){}
  
  void SetUpParticle(Int_t id, Double_t charge, Int_t status, 
		     Int_t parentidx,
		     const TLorentzVector& mom, const TVector3& term_pos);
  void SetUpParticle(Int_t id, Float_t charge, Int_t status, 
		     Int_t parentidx,
		     const TLorentzVector& mom, const TVector3& term_pos);
  
  Int_t     GetParticleID()   { return m_partID;   } //Particle ID
  Int_t     GetStatus()       { return m_status;   } //Status code
  Double_t  GetCharge()       { return m_charge;   } //Charge
  Int_t     GetParentIdx()    { return m_parent;   } //Parent pointer

  void      SetParticleID(Int_t id)    { m_partID    = id;     }
  void      SetStatus(Int_t status)    { m_status    = status; }
  void      SetCharge(Double_t charge) { m_charge    = charge; }
  void      SetCharge(Float_t  charge) { m_charge    = charge; }
  void      SetParentIdx(Int_t parent) { m_parent    = parent; }

  TVector3        GetPosition()        //Produce position in cm   
    { return m_position;   } 
  TVector3        GetTermPosition()    //Terminate position in cm
    { return m_term_pos;   } 
  TLorentzVector  Get4Momentum()       //(Px,Py,Pz,E) in GeV
    { return m_4momentum;  }
  TVector3*       GetPositionPtr()     //Produce position in cm
    { return &m_position;  }
  TVector3*       GetTermPositionPtr() //Terminate position in cm
    { return &m_term_pos;  }
  TLorentzVector* Get4MomentumPtr()    //(Px,Py,Pz,E) in GeV
    { return &m_4momentum; }
  
  void  SetPosition(const TVector3& position)       { m_position  = position; }
  void  SetTermPosition(const TVector3& term_pos)   { m_term_pos  = term_pos; }
  void  Set4Momentum(const TLorentzVector& momentum){ m_4momentum = momentum; }
  
private:
  Int_t          m_partID;    // STDHEP particle ID number
  Int_t          m_status;    // STDHEP status code
  Float_t        m_charge;    // Particle charge
  Int_t          m_parent;    // Index of the parent McPart object
  TVector3       m_position;  // Particle production position in cm
  TVector3       m_term_pos;  // Particle termination position in cm
  TLorentzVector m_4momentum; // Particle 4-momentum (Px,Py,Pz,E) in GeV
  
public:
  ClassDef(LCDMcPart,2)// Monte Carlo particle object
};
    
#endif
    
    
