fNofPads(0),
fMotifMap(0)
{
- //
- // Default ctor.
- //
+ ///
+ /// Default ctor.
+ ///
#ifdef WITH_ROOT
fMotifPositions.SetOwner(kTRUE);
#endif
fNofPads(0),
fMotifMap(motifMap)
{
- //
- // Normal ctor. Must be fed with the PCB's name (id), the pad dimensions
- // and the global dimension of the virtual enveloppe of the PCB
- // (usually 400x400 mm)
+ ///
+ /// Normal ctor. Must be fed with the PCB's name (id), the pad dimensions
+ /// and the global dimension of the virtual enveloppe of the PCB
+ /// (usually 400x400 mm)
#ifdef WITH_ROOT
fMotifPositions.SetOwner(kTRUE);
#endif
fNofPads(0),
fMotifMap(0x0)
{
- //
- // Copy constructor
+ ///
+ /// Copy constructor
#ifdef WITH_ROOT
fMotifPositions.SetOwner(kTRUE);
fNofPads(ms->GetMotifType()->GetNofPads()),
fMotifMap(0x0)
{
- //
- // Very special ctor to be used by trigger stations only (and for a very
- // specific case).
- //
- // Note that in this very case, we only allow one (special) motif per PCB.
- // This limitation might not be justified, except that it's all we need
- // so far ;-)
- //
+ ///
+ /// Very special ctor to be used by trigger stations only (and for a very
+ /// specific case).
+ ///
+ /// Note that in this very case, we only allow one (special) motif per PCB.
+ /// This limitation might not be justified, except that it's all we need
+ /// so far ;-)
+ ///
AliDebug(1,Form("this=%p (ctor special motif)",this));
AliMpPCB&
AliMpPCB::operator=(const AliMpPCB& o)
{
- // Assignment operator
+ /// Assignment operator
AliDebug(1,Form("this=%p (assignment op) : begin",this));
o.Copy(*this);
//_____________________________________________________________________________
AliMpPCB::~AliMpPCB()
{
- //
- // Dtor.
- //
+ ///
+ /// Dtor.
+ ///
AliDebug(1,Form("this=%p",this));
#ifndef WITH_ROOT
for ( size_t i = 0; i < fMotifPositions.size(); ++i )
Double_t
AliMpPCB::ActiveXmin() const
{
- //
- // Returns the mininum x for which there is a pad in this PCB.
- // Different from Xmin only for PCB which are not full of pads.
- //
+ ///
+ /// Returns the mininum x for which there is a pad in this PCB.
+ /// Different from Xmin only for PCB which are not full of pads.
+ ///
return fActiveXmin;
}
Double_t
AliMpPCB::ActiveXmax() const
{
- //
- // Returns the maximum x for which there is a pad in this PCB.
- // Different from Xmax only for PCB which are not full of pads.
- //
+ ///
+ /// Returns the maximum x for which there is a pad in this PCB.
+ /// Different from Xmax only for PCB which are not full of pads.
+ ///
return fActiveXmax;
}
void
AliMpPCB::Add(AliMpMotifType* mt, Int_t ix, Int_t iy)
{
- //
- // Add a motif to this PCB. (ix,iy) indicates one corner position of the motif
- // where the sign of ix and iy is used to indicate which corner is the
- // reference (then for values, abs(ix) and abs(iy) are used indeed) :
- //
- // (ix>0,iy>0) : bottom-left corner
- // (ix<0,iy>0) : bottom-right corner
- // (ix<0,iy<0) : top-right corner
- // (ix>0,iy<0) : top-left corner.
+ ///
+ /// Add a motif to this PCB. (ix,iy) indicates one corner position of the motif
+ /// where the sign of ix and iy is used to indicate which corner is the
+ /// reference (then for values, abs(ix) and abs(iy) are used indeed) :
+ ///
+ /// (ix>0,iy>0) : bottom-left corner
+ /// (ix<0,iy>0) : bottom-right corner
+ /// (ix<0,iy<0) : top-right corner
+ /// (ix>0,iy<0) : top-left corner.
TString id(Form("%s-%e-%e",mt->GetID().Data(),PadSizeX(),PadSizeY()));
AliMpArea
AliMpPCB::Area() const
{
+ /// Return the area of this PCB
+
return AliMpArea(TVector2( (Xmin()+Xmax())/2.0,DY()),
TVector2( DX(), DY() ) );
}
TObject*
AliMpPCB::Clone(const char* /*newname*/) const
{
- //
- // Return a full copy of this object.
- //
+ ///
+ /// Return a full copy of this object.
+ ///
AliDebug(1,"begin");
TObject* object = new AliMpPCB(*this);
AliDebug(1,"end");
AliMpPCB*
AliMpPCB::Clone(const TArrayI& manuids, Int_t ixOffset, Double_t xOffset) const
{
- //
- // Get a full copy of *this, and then apply 2 changes to it :
- //
- // a) define the relationship motifType <-> manu id
- // b) define the x-offset
- // c) shift ix indices backwards to insure that e.g. the first
- // pcb of a slat will start at ix=0 (only relevant for rounded pcbs).
- //
+ ///
+ /// Get a full copy of *this, and then apply 2 changes to it :
+ ///
+ /// a) define the relationship motifType <-> manu id
+ /// b) define the x-offset
+ /// c) shift ix indices backwards to insure that e.g. the first
+ /// pcb of a slat will start at ix=0 (only relevant for rounded pcbs).
+ ///
AliDebug(1,"begin");
void
AliMpPCB::Copy(TObject& o) const
{
- // Copy *this into o
+ /// Copy *this into o
AliDebug(1,"begin");
Double_t
AliMpPCB::ActiveDX() const
{
- //
- // Half-length (in x-direction) occupied by pads
- //
+ ///
+ /// Half-length (in x-direction) occupied by pads
+ ///
return GetNofPadsX()*fPadSizeX/2.0;
}
Double_t
AliMpPCB::DX() const
{
- //
- // Half-length (in x-direction) of the PCB.
- // This length is the one of the virtual enveloppe of the PCB and might
- // be bigger than the length occupied by pads (e.g. for rounded or short
- // PCBs).
- // See also ActiveDX().
- //
+ ///
+ /// Half-length (in x-direction) of the PCB.
+ /// This length is the one of the virtual enveloppe of the PCB and might
+ /// be bigger than the length occupied by pads (e.g. for rounded or short
+ /// PCBs).
+ /// See also ActiveDX().
+ ///
return fEnveloppeSizeX/2.0;
}
Double_t
AliMpPCB::ActiveDY() const
{
- //
- // Half-length (in y-direction) occupied by pads
- //
+ ///
+ /// Half-length (in y-direction) occupied by pads
+ ///
return GetNofPadsY()*fPadSizeY/2.0;
}
Double_t
AliMpPCB::DY() const
{
- //
- // Half-length (in y-direction) of the PCB.
- // This length is the one of the virtual enveloppe of the PCB and might
- // be bigger than the length occupied by pads (e.g. for rounded or short
- // PCBs).
- // See also ActiveDY().
- //
+ ///
+ /// Half-length (in y-direction) of the PCB.
+ /// This length is the one of the virtual enveloppe of the PCB and might
+ /// be bigger than the length occupied by pads (e.g. for rounded or short
+ /// PCBs).
+ /// See also ActiveDY().
+ ///
return fEnveloppeSizeY/2.0;
}
AliMpMotifPosition*
AliMpPCB::FindMotifPosition(Int_t ix, Int_t iy) const
{
- //
- // Returns the motifPosition located at the position referenced by
- // integer indices (ix,iy).
- //
+ ///
+ /// Returns the motifPosition located at the position referenced by
+ /// integer indices (ix,iy).
+ ///
#ifdef WITH_ROOT
for (Size_t i = 0; i < fMotifPositions.GetEntriesFast(); ++i )
AliMpMotifPosition*
AliMpPCB::FindMotifPosition(Double_t x, Double_t y) const
{
- //
- // Returns the motifPosition located at position (x,y)
- //
+ ///
+ /// Returns the motifPosition located at position (x,y)
+ ///
#ifdef WITH_ROOT
for (Size_t i = 0; i < fMotifPositions.GetEntriesFast(); ++i )
const char*
AliMpPCB::GetID() const
{
- //
- // Returns the name of this PCB.
- //
+ ///
+ /// Returns the name of this PCB.
+ ///
return fId.Data();
}
AliMpMotifPosition*
AliMpPCB::GetMotifPosition(AliMpPCB::Size_t i) const
{
- //
- // Get the i-th motifPosition stored in this PCB's internal array.
- //
+ ///
+ /// Get the i-th motifPosition stored in this PCB's internal array.
+ ///
#ifdef WITH_ROOT
if ( i >= fMotifPositions.GetEntriesFast() ) return 0;
Int_t
AliMpPCB::GetNofPadsX() const
{
- //
- // Returns the number of pads in x-direction.
- //
+ ///
+ /// Returns the number of pads in x-direction.
+ ///
return fIxmax-fIxmin+1;
}
Int_t
AliMpPCB::GetNofPadsY() const
{
- //
- // Returns the number of pads in y-direction.
- //
+ ///
+ /// Returns the number of pads in y-direction.
+ ///
return fIymax-fIymin+1;
}
AliMpPCB::Size_t
AliMpPCB::GetSize() const
{
- //
- // Returns the number of motifPositions stored in this PCB.
- //
+ ///
+ /// Returns the number of motifPositions stored in this PCB.
+ ///
#ifdef WITH_ROOT
return fMotifPositions.GetEntriesFast();
Int_t
AliMpPCB::Ixmin() const
{
- //
- // Returns the index value of the leftmost pad.
- //
+ ///
+ /// Returns the index value of the leftmost pad.
+ ///
return fIxmin;
}
Int_t
AliMpPCB::Ixmax() const
{
- //
- // Returns the index value of the rightmost pad.
- //
+ ///
+ /// Returns the index value of the rightmost pad.
+ ///
return Ixmin() + GetNofPadsX() - 1;
}
Int_t
AliMpPCB::Iymin() const
{
- //
- // Returns the index value of the bottom pad.
- //
+ ///
+ /// Returns the index value of the bottom pad.
+ ///
return fIymin;
}
Int_t
AliMpPCB::Iymax() const
{
- //
- // Returns the index value of the top pad.
- //
+ ///
+ /// Returns the index value of the top pad.
+ ///
return Iymin() + GetNofPadsY() - 1;
}
Double_t
AliMpPCB::PadSizeX() const
{
- //
- // Returns the pad size in x-direction (in mm)
- //
+ ///
+ /// Returns the pad size in x-direction (in mm)
+ ///
return fPadSizeX;
}
Double_t
AliMpPCB::PadSizeY() const
{
- //
- // Returns the pad size in y-direction (in mm)
- //
+ ///
+ /// Returns the pad size in y-direction (in mm)
+ ///
return fPadSizeY;
}
void
AliMpPCB::Print(Option_t* option) const
{
- //
- // Printout of this PCB.
- // If option="M", the contained motifs are printed too.
- //
+ ///
+ /// Printout of this PCB.
+ /// If option="M", the contained motifs are printed too.
+ ///
cout << "PCB " << GetID() << " PADSIZES=(" << fPadSizeX << ","
<< fPadSizeY << ") iMin=(" << fIxmin << "," << fIymin << ") "
void
AliMpPCB::Save() const
{
- //
- // Save this PCB in the file
+ ///
+ /// Save this PCB in the file
TString fileName(fId);
fileName += ".pcb";
Double_t
AliMpPCB::X() const
{
- //
- // Returns the x-position of the PCB center.
- //
+ ///
+ /// Returns the x-position of the PCB center.
+ ///
return fXoffset + DX();
}
Double_t
AliMpPCB::Xmin() const
{
- //
- // Returns the leftmost x-position in this PCB.
- //
+ ///
+ /// Returns the leftmost x-position in this PCB.
+ ///
return X() - DX();
}
Double_t
AliMpPCB::Xmax() const
{
- //
- // Returns the rightmost x-position in this PCB.
- //
+ ///
+ /// Returns the rightmost x-position in this PCB.
+ ///
return X() + DX();
}
Double_t
AliMpPCB::Y() const
{
- //
- // Returns the y-position of the PCB center.
- //
+ ///
+ /// Returns the y-position of the PCB center.
+ ///
return DY(); // this works as PCB are organized in a single row within slats.
}
Double_t
AliMpPCB::Ymin() const
{
- //
- // Returns the smallest y-position in this PCB.
- //
+ ///
+ /// Returns the smallest y-position in this PCB.
+ ///
return Y() - DY();
}
Double_t
AliMpPCB::Ymax() const
{
- //
- // Returns the largest y-position in this PCB.
- //
+ ///
+ /// Returns the largest y-position in this PCB.
+ ///
return Y() + DY();
}