00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #include "StRpsPlane.h"
00019 #include "StRpsCluster.h"
00020
00021 static const char rcsid[] = "$Id: StRpsPlane.cxx,v 2.1 2009/11/23 22:18:25 ullrich Exp $";
00022
00023 ClassImp(StRpsPlane)
00024
00025 StRpsPlane::StRpsPlane()
00026 {
00027 mOffset = mZ = mAngle = 0;
00028 mOrientation = 0;
00029 mStatus = 0;
00030 mRomanPotId = mPlaneId = 0;
00031 }
00032
00033 StRpsPlane::~StRpsPlane() { }
00034
00035 unsigned int
00036 StRpsPlane::planeId() const { return mPlaneId; }
00037
00038 double
00039 StRpsPlane::offset() const { return mOffset; }
00040
00041 double
00042 StRpsPlane::z() const { return mZ; }
00043
00044 double
00045 StRpsPlane::angle() const { return mAngle; }
00046
00047 short
00048 StRpsPlane::orientation() const { return mOrientation; }
00049
00050 unsigned char
00051 StRpsPlane::status() const { return mStatus; }
00052
00053 unsigned int
00054 StRpsPlane::numberOfClusters() const { return mClusters.size(); }
00055
00056 const StRpsCluster*
00057 StRpsPlane::cluster(unsigned int i) const
00058 {
00059 if (i < mClusters.size())
00060 return mClusters[i];
00061 else
00062 return 0;
00063 }
00064
00065 StRpsCluster*
00066 StRpsPlane::cluster(unsigned int i)
00067 {
00068 if (i < mClusters.size())
00069 return mClusters[i];
00070 else
00071 return 0;
00072 }
00073
00074 unsigned int
00075 StRpsPlane::romanPotId() const { return mRomanPotId; }
00076
00077 const StSPtrVecRpsCluster&
00078 StRpsPlane::clusters() const { return mClusters; }
00079
00080 StSPtrVecRpsCluster&
00081 StRpsPlane::clusters() { return mClusters; }
00082
00083 void
00084 StRpsPlane::addCluster(StRpsCluster* cluster)
00085 {
00086 if (cluster) {
00087 mClusters.push_back(cluster);
00088 cluster->setPlaneId(mPlaneId);
00089 cluster->setRomanPotId(mRomanPotId);
00090 }
00091 }
00092
00093 void
00094 StRpsPlane::setOffset(double val) { mOffset = val; }
00095
00096 void
00097 StRpsPlane::setZ(double val) { mZ = val; }
00098
00099 void
00100 StRpsPlane::setAngle(double val) { mAngle = val; }
00101
00102 void
00103 StRpsPlane::setOrientation(short val) { mOrientation = val; }
00104
00105 void
00106 StRpsPlane::setStatus(unsigned char val) { mStatus = val; }
00107
00108 void
00109 StRpsPlane::setPlaneId(unsigned char i) { mPlaneId = i; }
00110
00111 void
00112 StRpsPlane::setRomanPotId(unsigned char i) { mRomanPotId = i; }
00113