Logo ROOT  
Reference Guide
No Matches
Go to the documentation of this file.
2 * Project: RooFit *
3 * Package: RooFitCore *
4 * File: $Id: RooNameSet.h,v 1.16 2007/05/11 09:11:30 verkerke Exp $
5 * Authors: *
6 * WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu *
7 * DK, David Kirkby, UC Irvine, dkirkby@uci.edu *
8 * *
9 * Copyright (c) 2000-2005, Regents of the University of California *
10 * and Stanford University. All rights reserved. *
11 * *
12 * Redistribution and use in source and binary forms, *
13 * with or without modification, are permitted according to the terms *
14 * listed in LICENSE (http://roofit.sourceforge.net/license.txt) *
15 *****************************************************************************/
16#ifndef ROO_NAME_SET
17#define ROO_NAME_SET
19#include "TObject.h"
20#include "RooPrintable.h"
22class RooArgSet;
24class RooNameSet : public TObject, public RooPrintable {
27 // Constructors, assignment etc.
28 RooNameSet();
29 RooNameSet(const RooArgSet& argSet);
30 RooNameSet(const RooNameSet& other) ;
31 virtual TObject* Clone(const char*) const { return new RooNameSet(*this) ; }
32 virtual ~RooNameSet() ;
34 void refill(const RooArgSet& argSet) ;
35 RooArgSet* select(const RooArgSet& list) const ;
36 Bool_t operator==(const RooNameSet& other) const;
38 Bool_t operator<(const RooNameSet& other) const ;
40 virtual void printName(std::ostream& os) const ;
41 virtual void printTitle(std::ostream& os) const ;
42 virtual void printClassName(std::ostream& os) const ;
43 virtual void printValue(std::ostream& os) const ;
45 inline virtual void Print(Option_t *options= 0) const {
47 }
49 void setNameList(const char* givenList) ;
50 const char* content() const { return _nameList ? _nameList : ""; }
54 char* _nameList ; //[_len]
58 void extendBuffer(Int_t inc) ;
59 static void strdup(Int_t& dstlen, char* &dstbuf, const char* str);
61 ClassDef(RooNameSet,1) // A sterile version of RooArgSet, containing only the names of the contained RooAbsArgs
const char Option_t
Definition RtypesCore.h:66
#define ClassDef(name, id)
Definition Rtypes.h:325
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Definition RooArgSet.h:29
RooNameSet is a utility class that stores the names the objects in a RooArget.
Definition RooNameSet.h:24
virtual void printValue(std::ostream &os) const
Print value of nameset, i.e the list of names.
RooArgSet * select(const RooArgSet &list) const
Construct a RooArgSet of objects in input 'list' whose names match to those in the internal name list...
static void strdup(Int_t &dstlen, char *&dstbuf, const char *str)
copy src to dst, keep dstlen up to date, make sure zero length strings do not take memory
virtual TObject * Clone(const char *) const
Make a clone of an object using the Streamer facility.
Definition RooNameSet.h:31
virtual void printTitle(std::ostream &os) const
Print title of nameset.
Bool_t operator<(const RooNameSet &other) const
void setNameList(const char *givenList)
void refill(const RooArgSet &argSet)
Refill internal contents from names in given argSet.
virtual void printName(std::ostream &os) const
Print name of nameset.
Default constructor.
const char * content() const
Definition RooNameSet.h:50
void extendBuffer(Int_t inc)
virtual void printClassName(std::ostream &os) const
Print class name of nameset.
Int_t _len
Definition RooNameSet.h:53
virtual void Print(Option_t *options=0) const
This method must be overridden when a class wants to print itself.
Definition RooNameSet.h:45
char * _nameList
Definition RooNameSet.h:54
RooNameSet & operator=(const RooNameSet &)
Assignment operator.
Bool_t operator==(const RooNameSet &other) const
Comparison operator.
virtual ~RooNameSet()
RooPlotable is a 'mix-in' base class that define the standard RooFit plotting and printing methods.
virtual StyleOption defaultPrintStyle(Option_t *opt) const
virtual Int_t defaultPrintContents(Option_t *opt) const
Default choice of contents to be printed (name and value)
static std::ostream & defaultPrintStream(std::ostream *os=0)
Return a reference to the current default stream to use in Print().
virtual void printStream(std::ostream &os, Int_t contents, StyleOption style, TString indent="") const
Print description of object on ostream, printing contents set by contents integer,...
Mother of all ROOT objects.
Definition TObject.h:37