Ignore:
Timestamp:
07/25/08 15:17:20 (17 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars/mtools
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mtools/MTFillMatrix.cc

    r8907 r9041  
    7676// fill.WriteMatrices("myfile.root");
    7777//
     78//
     79// Task List execution
     80// ----------------------------------------------
     81//
     82// The tasklist is excuted in the follwowing order:
     83//   - fReader      set by SetReader
     84//   - fPreTasks    in the order as set with the SetPreTask functions
     85//   - fPreCuts     in the order as set with the SetPreCut  functions
     86//   - Selection    the event selection
     87//   - fPostTasks   in the order as set with the SetPostTask functions
     88//   - Fill Matrix
     89//   - Write output
     90//
    7891/////////////////////////////////////////////////////////////////////////////
    7992#include "MTFillMatrix.h"
     
    163176MTFillMatrix::MTFillMatrix(const char *name, const char *title)
    164177: fReference(0), fReader(0), fDestMatrix1(0), fDestMatrix2(0),
    165   fNumDestEvents1(0), fNumDestEvents2(0), fWriteFile1(0), fWriteFile2(0)
     178  fNumDestEvents1(0), fNumDestEvents2(0), fNumMaxEvents(0),
     179  fWriteFile1(0), fWriteFile2(0)
    166180{
    167181    Init(name, title);
     
    180194MTFillMatrix::MTFillMatrix(const MH3 *ref, const char *name, const char *title)
    181195: fReference(0), fReader(0), fDestMatrix1(0), fDestMatrix2(0),
    182   fNumDestEvents1(0), fNumDestEvents2(0), fWriteFile1(0), fWriteFile2(0)
     196  fNumDestEvents1(0), fNumDestEvents2(0), fNumMaxEvents(0),
     197  fWriteFile1(0), fWriteFile2(0)
    183198{
    184199    Init(name, title);
     
    413428    evtloop.SetLogStream(fLog);
    414429
    415     const Bool_t rc = evtloop.Eventloop();
     430    const Bool_t rc = evtloop.Eventloop(fNumMaxEvents);
    416431
    417432    if (selector)
  • trunk/MagicSoft/Mars/mtools/MTFillMatrix.h

    r8644 r9041  
    2727    Int_t     fNumDestEvents2;
    2828
     29    Int_t     fNumMaxEvents;
     30
    2931    MTask    *fWriteFile1;
    3032    MTask    *fWriteFile2;
     
    5254        fDestMatrix1 = matrix;
    5355        if (num>0)
    54             fNumDestEvents1 = num;
     56            SetNumDestEvents1(num);
    5557    }
    5658    void SetWriteFile1(MTask *write, UInt_t num=0)
     
    5860        fWriteFile1 = write;
    5961        if (num>0)
    60             fNumDestEvents1 = num;
    61     }
    62     void SetNumDestEvents1(UInt_t num)
    63     {
    64         fNumDestEvents1 = num;
     62            SetNumDestEvents1(num);
    6563    }
    6664    void SetDestMatrix2(MHMatrix *matrix, UInt_t num=0)
     
    6866        fDestMatrix2 = matrix;
    6967        if (num>0)
    70             fNumDestEvents2 = num;
     68            SetNumDestEvents2(num);
    7169    }
    7270    void SetWriteFile2(MTask *write, UInt_t num=0)
     
    7472        fWriteFile2 = write;
    7573        if (num>0)
    76             fNumDestEvents2 = num;
     74            SetNumDestEvents2(num);
    7775    }
    78     void SetNumDestEvents2(UInt_t num)
    79     {
    80         fNumDestEvents2 = num;
    81     }
     76    void SetNumDestEvents1(UInt_t num) { fNumDestEvents1 = num; }
     77    void SetNumDestEvents2(UInt_t num) { fNumDestEvents2 = num; }
     78    void SetMaxEvents(UInt_t num)      { fNumMaxEvents = num; }
    8279
    8380    void SetReader(MRead *task) { fReader = task; }
Note: See TracChangeset for help on using the changeset viewer.