Ignore:
Timestamp:
03/02/01 13:43:09 (24 years ago)
Author:
tbretz
Message:
*** empty log message ***
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mdatacheck/MViewAdcSpectra.cc

    r544 r667  
    2626MViewAdcSpectra::~MViewAdcSpectra()
    2727{
    28   // default destructor 
     28    // default destructor
     29    delete fHistosAdc;
    2930}
    3031
     
    4445  // connect them in the required way.
    4546 
    46   MParList *plist  = new MParList;
    47   MTaskList *tasks = new MTaskList;
    48   plist->AddToList(tasks);
     47  //
     48  //   create the data containers for the raw data
     49  //
     50  MParList plist;
     51 
     52  MRawRunHeader runheader;
     53  plist.AddToList(&runheader);
    4954
    50   //   create the data containers for the raw data
     55  MRawEvtHeader evtheader;
     56  plist.AddToList(&evtheader);
    5157 
    52   MRawRunHeader *runheader = new MRawRunHeader;
    53   plist->AddToList(runheader);
     58  MRawEvtData evtdata;
     59  plist.AddToList(&evtdata);
     60 
     61  MRawCrateArray cratearray;
     62  plist.AddToList(&cratearray);
     63 
     64  MTime evttime("MTime");
     65  plist.AddToList(&evttime);
    5466
    55   MRawEvtHeader *evtheader = new MRawEvtHeader;
    56   plist->AddToList(evtheader);
    57  
    58   MRawEvtData *evtdata = new MRawEvtData;
    59   plist->AddToList(evtdata);
    60  
    61   MRawCrateArray *cratearray = new MRawCrateArray;
    62   plist->AddToList(cratearray);
    63  
    64   MTime *evttime = new MTime("MTime");
    65   plist->AddToList(evttime);
     67  fHistosAdc= new MHistosAdc;
     68  plist.AddToList( fHistosAdc ) ;
    6669
    67   MHistosAdc *histosAdc = new MHistosAdc() ;
    68   plist->AddToList( histosAdc ) ;
    69  
     70  //
    7071  //    set up the tasks for this job
     72  //
     73  MTaskList tasks;
     74  plist.AddToList(&tasks);
    7175
    72   MReadTree *readin  =  new MReadTree ( inputfile, treeName ) ;
    73   tasks->AddToList( readin ) ;
     76  MReadTree readin ( inputfile, treeName ) ;
     77  tasks.AddToList( &readin ) ;
    7478
    7579  //  MDumpEvtHeader *dumpheader = new MDumpEvtHeader() ;
    7680  //  tasks->AddToList( dumpheader ) ;
    7781 
    78   MFillAdcSpect *fillspect = new MFillAdcSpect() ;
    79   tasks->AddToList( fillspect ) ;
     82  MFillAdcSpect fillspect;
     83  tasks.AddToList( &fillspect ) ;
    8084
    81   MShowSpect *showspect = new MShowSpect( "MHistosAdc" ) ;
    82   tasks->AddToList( showspect ) ;
     85  MShowSpect showspect( "MHistosAdc" ) ;
     86  tasks.AddToList( &showspect ) ;
    8387
    8488  //    set up the loop for the processing
    8589 
    8690  MEvtLoop magic;
    87   magic.SetParList(plist);
     91  magic.SetParList(&plist);
    8892
    8993  //    start the loop running
     
    9195  magic.Eventloop() ;
    9296 
    93 
    94   cout << " End of this job " << endl ;
    95 
    96   return kTRUE ;
     97  return kTRUE ;
    9798
    9899}
Note: See TracChangeset for help on using the changeset viewer.