Ignore:
Timestamp:
01/17/05 15:23:41 (20 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars/mfbase
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mfbase/MF.cc

    r5692 r5875  
    391391}
    392392
     393// --------------------------------------------------------------------------
     394//
     395// Return a comma seperated list of all data members used in the chain.
     396// This is mainly used in MTask::AddToBranchList
     397//
     398TString MF::GetDataMember() const
     399{
     400    *fLog << dbg << "MF::GetDataMember" << endl;
     401    return fF->GetDataMember();
     402}
     403
    393404void MF::StreamPrimitive(ofstream &out) const
    394405{
  • trunk/MagicSoft/Mars/mfbase/MF.h

    r5100 r5875  
    3838
    3939    TString GetRule() const { return fF ? fF->GetRule() : MFilter::GetRule(); }
     40    TString GetDataMember() const;
    4041
    4142    Bool_t IsExpressionTrue() const;
  • trunk/MagicSoft/Mars/mfbase/MFDataChain.cc

    r3573 r5875  
    142142}
    143143
     144// --------------------------------------------------------------------------
     145//
     146//  Crahses if default constructor called.
     147//
    144148void MFDataChain::StreamPrimitive(ofstream &out) const
    145149{
     
    157161}
    158162
     163// --------------------------------------------------------------------------
     164//
     165//  Crahses if default constructor called.
     166//
    159167TString MFDataChain::GetRule() const
    160168{
    161     TString ret;// = "{";
    162     ret += fData.GetRule();
    163     //ret += "}";
     169    TString ret(fData.GetRule());
    164170    ret += fFilterType==kELowerThan?"<":">";
    165171
     
    169175    return ret;
    170176}
     177
     178// --------------------------------------------------------------------------
     179//
     180//  Crahses if default constructor called.
     181//
     182TString MFDataChain::GetDataMember() const
     183{
     184    TString ret(fData.GetDataMember());
     185    ret += ",";
     186    ret += fCond->GetDataMember();
     187    return ret;
     188}
  • trunk/MagicSoft/Mars/mfbase/MFDataChain.h

    r3573 r5875  
    4444
    4545    void Print(Option_t *opt = "") const;
     46
    4647    TString GetRule() const;
     48    TString GetDataMember() const;
    4749
    4850    void SetVariables(const TArrayD &arr)
  • trunk/MagicSoft/Mars/mfbase/MFDataMember.cc

    r3573 r5875  
    167167    return ret+str.Strip(TString::kBoth);
    168168}
     169
     170TString MFDataMember::GetDataMember() const
     171{
     172    return fData.GetDataMember();
     173}
  • trunk/MagicSoft/Mars/mfbase/MFDataMember.h

    r3573 r5875  
    3737
    3838    void Print(Option_t *opt = "") const;
     39
    3940    TString GetRule() const;
     41    TString GetDataMember() const;
    4042
    4143    void SetVariables(const TArrayD &arr) { fData.SetVariables(arr); }
  • trunk/MagicSoft/Mars/mfbase/MFilterList.cc

    r3788 r5875  
    232232    *fLog << "Done." << endl;
    233233
     234    AddToBranchList(filter->GetDataMember());
     235
    234236    return kTRUE;
    235237}
     
    415417}
    416418
     419// --------------------------------------------------------------------------
     420//
     421// Return the data members existing in this array in a comma-seperated list
     422// (This is mainly used for MTask::AddToBranchList)
     423//
     424TString MFilterList::GetDataMember() const
     425{
     426    TString str;
     427
     428    TIter Next(&fFilters);
     429    MFilter *filter = NULL;
     430    while ((filter=(MFilter*)Next()))
     431    {
     432        if (filter->GetDataMember().IsNull())
     433            continue;
     434
     435        str += ",";
     436        str += filter->GetDataMember();
     437    }
     438    return str;
     439}
     440
     441
    417442void MFilterList::SetVariables(const TArrayD &arr)
    418443{
  • trunk/MagicSoft/Mars/mfbase/MFilterList.h

    r3788 r5875  
    4949
    5050    void Print(Option_t *opt = "") const;
     51
    5152    TString GetRule() const { return GetRule(""); }
    5253    TString GetRule(Option_t *opt) const;
     54    TString GetDataMember() const;
    5355
    5456    Int_t PreProcess(MParList *pList);
Note: See TracChangeset for help on using the changeset viewer.