X-Git-Url: http://git.uio.no/git/?a=blobdiff_plain;f=STEER%2FAliESDVertex.cxx;h=bc65501a5161c191f20f7352902c4a6df85ee835;hb=732a24fe12969c50908153cee19b25134fee1baa;hp=a2a320b598cb94890e76ee04a8206713d6994905;hpb=a77bb3bc8ac20ab1decefef051f9168d2eb13e4c;p=u%2Fmrichter%2FAliRoot.git diff --git a/STEER/AliESDVertex.cxx b/STEER/AliESDVertex.cxx index a2a320b598c..bc65501a516 100644 --- a/STEER/AliESDVertex.cxx +++ b/STEER/AliESDVertex.cxx @@ -174,6 +174,21 @@ AliESDVertex &AliESDVertex::operator=(const AliESDVertex &source){ } return *this; } + +void AliESDVertex::Copy(TObject &obj) const { + + // this overwrites the virtual TOBject::Copy() + // to allow run time copying without casting + // in AliESDEvent + + if(this==&obj)return; + AliESDVertex *robj = dynamic_cast(&obj); + if(!robj)return; // not an AliESDVertex + *robj = *this; + +} + + //-------------------------------------------------------------------------- void AliESDVertex::SetToZero() { //