Changeset 1501 for trunk/MagicSoft


Ignore:
Timestamp:
08/14/02 14:01:05 (22 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r1497 r1501  
    11                                                                  -*-*- END -*-*-
     2
     3 2002/08/14: Thomas Bretz
     4
     5   * mbase/MTask.[h,cc], mbase/MTaskList.[h,cc]:
     6     - added second argument to PrintStatistics
     7
     8
    29
    310 2002/08/12: Thomas Bretz
  • trunk/MagicSoft/Mars/NEWS

    r1495 r1501  
    7474     file having crab starfield, but also for all following files - fixed
    7575
     76   - PrintStatistics can now be instructud to print also the title, too.
    7677
    7778
  • trunk/MagicSoft/Mars/mbase/MTask.cc

    r1489 r1501  
    257257// identified.
    258258//
    259 void MTask::PrintStatistics(const Int_t lvl) const
     259void MTask::PrintStatistics(const Int_t lvl, Bool_t title) const
    260260{
    261261    *fLog << all << setw(lvl) << " " << GetDescriptor() << "\t";
    262     *fLog << dec << fNumExecutions << endl;
     262    *fLog << dec << fNumExecutions;
     263    if (title)
     264        *fLog << "\t" << fTitle;
     265    *fLog << endl;
    263266}
    264267
  • trunk/MagicSoft/Mars/mbase/MTask.h

    r1481 r1501  
    7070    void SetFilter(MFilter *filter) { fFilter=filter; }
    7171    const MFilter *GetFilter() const      { return fFilter; }
    72     virtual void PrintStatistics(const Int_t lvl=0) const;
     72    virtual void PrintStatistics(const Int_t lvl=0, Bool_t title=kFALSE) const;
    7373
    7474    UInt_t GetNumExecutions() { return fNumExecutions; }
  • trunk/MagicSoft/Mars/mbase/MTaskList.cc

    r1487 r1501  
    481481//  identified. Use MTaskList::PrintStatistics without an argument.
    482482//
    483 void MTaskList::PrintStatistics(const Int_t lvl) const
     483void MTaskList::PrintStatistics(const Int_t lvl, Bool_t title) const
    484484{
    485485    if (lvl==0)
     
    488488        *fLog << "Execution Statistics: " << endl;
    489489        *fLog << "---------------------" << endl;
    490         *fLog << GetDescriptor() << endl;
     490        *fLog << GetDescriptor();
     491        if (title)
     492            *fLog << "\t" << fTitle;
     493        *fLog << endl;
    491494    }
    492495    else
    493496    {
    494         *fLog << setw(lvl) << " " << GetDescriptor() << endl;
     497        *fLog << setw(lvl) << " " << GetDescriptor();
     498        if (title)
     499            *fLog << "\t" << fTitle;
     500        *fLog << endl;
    495501    }
    496502
     
    498504    //  create the Iterator for the TaskList
    499505    //
    500     fTasks->ForEach(MTask, PrintStatistics)(lvl+1);
     506    fTasks->ForEach(MTask, PrintStatistics)(lvl+1, title);
    501507
    502508    if (lvl==0)
    503509        *fLog << endl;
    504510}
     511
    505512
    506513// --------------------------------------------------------------------------
  • trunk/MagicSoft/Mars/mbase/MTaskList.h

    r1477 r1501  
    5555
    5656    void Print(Option_t *opt = "") const;
    57     void PrintStatistics(const Int_t lvl=0) const;
     57    void PrintStatistics(const Int_t lvl=0, Bool_t title=kFALSE) const;
    5858    void SetOwner(Bool_t enable=kTRUE);
    5959
Note: See TracChangeset for help on using the changeset viewer.