]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PHOS/AliPHOSv2.cxx
Break segmentation cured
[u/mrichter/AliRoot.git] / PHOS / AliPHOSv2.cxx
CommitLineData
bea63bea 1/**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
6 * *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
15
16/* $Id$ */
bea63bea 17//_________________________________________________________________________
5f20d3fb 18// Version of AliPHOSv1 which keeps all hits in TreeH
19// AddHit, StepManager,and FinishEvent are redefined
bea63bea 20//
5f20d3fb 21//*-- Author: Gines MARTINEZ (SUBATECH)
ed4205d8 22//*-- Modified Nov. 22 2000 by Dmitri Peressounko
23// All hits are stored.
24// Note, that primaries will not be assigned to digits:
25// becouse of tiny energy deposition at each step.
26//
bea63bea 27
28// --- ROOT system ---
5f20d3fb 29
30#include "TBRIK.h"
31#include "TNode.h"
bea63bea 32#include "TRandom.h"
33
34// --- Standard library ---
35
36#include <stdio.h>
37#include <string.h>
38#include <stdlib.h>
39#include <strstream.h>
40
41// --- AliRoot header files ---
42
43#include "AliPHOSv2.h"
44#include "AliPHOSHit.h"
45#include "AliPHOSDigit.h"
5f20d3fb 46#include "AliPHOSReconstructioner.h"
bea63bea 47#include "AliRun.h"
48#include "AliConst.h"
49
50ClassImp(AliPHOSv2)
51
5f20d3fb 52//____________________________________________________________________________
53AliPHOSv2::AliPHOSv2()
54{
55 // default ctor
ed4205d8 56
5f20d3fb 57}
58
bea63bea 59//____________________________________________________________________________
60AliPHOSv2::AliPHOSv2(const char *name, const char *title):
e04976bd 61AliPHOSv1(name,title)
bea63bea 62{
5f20d3fb 63 // ctor
bea63bea 64}
65
66//____________________________________________________________________________
5f20d3fb 67AliPHOSv2::~AliPHOSv2()
bea63bea 68{
5f20d3fb 69 // dtor
bea63bea 70}
71
72//____________________________________________________________________________
7eb9d12d 73void AliPHOSv2::AddHit(Int_t shunt, Int_t primary, Int_t tracknumber, Int_t Id, Float_t * hits, Int_t pid)
5f20d3fb 74{
75 // Add a hit to the hit list.
5f20d3fb 76
5f20d3fb 77 AliPHOSHit *newHit ;
5f20d3fb 78
7eb9d12d 79 newHit = new AliPHOSHit(shunt, primary, tracknumber, Id, hits, pid) ;
5f20d3fb 80
ed4205d8 81 new((*fHits)[fNhits]) AliPHOSHit(*newHit) ;
fca6f6ef 82 fNhits++ ;
bea63bea 83
fca6f6ef 84 delete newHit;
5f20d3fb 85
bea63bea 86}
87
fca6f6ef 88