110 _i[0] = other.
_i[0] ;
111 _i[1] = other.
_i[1] ;
112 _d[0] = other.
_d[0] ;
113 _d[1] = other.
_d[1] ;
114 _s[0] = other.
_s[0] ;
115 _s[1] = other.
_s[1] ;
116 _s[2] = other.
_s[2] ;
117 _o[0] = other.
_o[0] ;
118 _o[1] = other.
_o[1] ;
120 _c = new RooArgSet[2] ;
121 _c[0].add(other._c[0]) ;
122 _c[1].add(other._c[1]) ;
140 if (&other==
this)
return *this ;
145 _i[0] = other.
_i[0] ;
146 _i[1] = other.
_i[1] ;
147 _d[0] = other.
_d[0] ;
148 _d[1] = other.
_d[1] ;
149 _s[0] = other.
_s[0] ;
150 _s[1] = other.
_s[1] ;
151 _s[2] = other.
_s[2] ;
152 _o[0] = other.
_o[0] ;
153 _o[1] = other.
_o[1] ;
156 _c[0].removeAll() ;
_c[0].add(other.
_c[0]) ;
157 _c[1].removeAll() ;
_c[1].add(other.
_c[1]) ;
178 if (
_c)
delete[]
_c ;
197 return _c ? &
_c[idx] : nullptr ;
209 _c[idx].removeAll() ;
215 std::array<bool, 13> needs;
218 needs[2] =
_i[1] != 0;
219 needs[3] =
_d[0] != 0;
220 needs[4] =
_d[1] != 0;
221 needs[5] = !
_s[0].empty();
222 needs[6] = !
_s[1].empty();
226 needs[10] = !
_s[2].empty();
228 needs[12] =
_c && !
_c[1].empty();
233 for (
int i = needs.size() - 1; i >= 0; --i) {
238 std::stringstream ss;
241 ss <<
"RooCmdArg(\"" <<
GetName() <<
"\", " <<
_i[0];
250 ss <<
", " << (!
_s[0].empty() ?
"\"" +
_s[0] +
"\"" :
"\"\"");
252 ss <<
", " << (!
_s[1].empty() ?
"\"" +
_s[1] +
"\"" :
"\"\"");
254 ss <<
", " << (
_o[0] ?
"\"" + std::string(
_o[0]->
GetName()) +
"\"" :
"0");
256 ss <<
", " << (
_o[1] ?
"\"" + std::string(
_o[1]->
GetName()) +
"\"" :
"0");
261 for (std::size_t i = 0; i <
_argList.size(); ++i) {
263 ss << cmdArg->constructorCode() <<
"\n";
272 ss <<
", " << (!
_s[2].empty() ?
"\"" +
_s[2] +
"\"" :
"\"\"");
292 std::cout <<
GetName() <<
":\ndoubles\t" <<
_d[0] <<
" " <<
_d[1] <<
"\nints\t" <<
_i[0] <<
" " <<
_i[1]
293 <<
"\nstrings\t" <<
_s[0] <<
" " <<
_s[1] <<
" " <<
_s[2] <<
"\nobjects\t" <<
_o[0] <<
" " <<
_o[1]
int Int_t
Signed integer 4 bytes (int).
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Named container for two doubles, two integers two object points and three string pointers that can be...
const RooArgSet * getSet(Int_t idx) const
Return RooArgSet stored in slot idx.
RooArgSet * _c
Payload RooArgSets.
void Print(const char *="") const override
This method must be overridden when a class wants to print itself.
RooLinkedList _argList
Payload sub-arguments.
void addArg(const RooCmdArg &arg)
Utility function to add nested RooCmdArg to payload of this RooCmdArg.
Int_t _i[2]
Payload integers.
RooCmdArg & operator=(const RooCmdArg &other)
Assignment operator.
static const RooCmdArg & none()
Return reference to null argument.
std::string constructorCode() const
void setSet(Int_t idx, const RooArgSet &set)
std::string _s[3]
Payload strings.
bool _procSubArgs
If true argument requires recursive processing.
RooCmdArg()
Default constructor.
TObject * _o[2]
Payload objects.
static const RooCmdArg _none
Static instance of null object.
double _d[2]
Payload doubles.
bool _prefixSubArgs
Prefix sub-arguments with container name?
~RooCmdArg() override
Destructor.
TObject * At(int index) const
Return object stored in sequential position given by index.
virtual void SetTitle(const char *title="")
Set the title of the TNamed.
const char * GetName() const override
Returns name of object.
const char * GetTitle() const override
Returns title of object.
virtual void SetName(const char *name)
Set the name of the TNamed.
TObject()
TObject constructor.
Bool_t Contains(const char *pat, ECaseCompare cmp=kExact) const
std::string getColonSeparatedNameString(RooArgSet const &argSet, char delim=':')