ROOT
master
Reference Guide
RooInt.h
Go to the documentation of this file.
1
/*****************************************************************************
2
* Project: RooFit *
3
* Package: RooFitCore *
4
* File: $Id: RooInt.h,v 1.6 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_INT
17
#define ROO_INT
18
19
#include "
Rtypes.h
"
20
#include "
TNamed.h
"
21
22
class
RooInt
:
public
TNamed
{
23
public
:
24
25
RooInt
() :
_value
(0) {} ;
26
RooInt
(
Int_t
value) :
TNamed
(),
_value
(value) {} ;
27
RooInt
(
const
RooInt
& other) :
TNamed
(other),
_value
(other.
_value
) {}
28
virtual
~RooInt
() {} ;
29
30
// Double_t cast operator
31
inline
operator
Int_t
()
const
{
return
_value
; }
32
RooInt
&
operator=
(
Int_t
value) {
_value
= value ;
return
*this ; }
33
34
// Sorting interface ;
35
Int_t
Compare
(
const
TObject
* other)
const
;
36
virtual
Bool_t
IsSortable
()
const
{
return
kTRUE
; }
37
38
protected
:
39
40
Int_t
_value
;
// Payload
41
ClassDef
(
RooInt
,1)
// Container class for Int_t
42
};
43
44
#endif
kTRUE
const Bool_t kTRUE
Definition:
RtypesCore.h:95
RooInt::_value
Int_t _value
Definition:
RooInt.h:40
RooInt::RooInt
RooInt(Int_t value)
Definition:
RooInt.h:26
TNamed.h
Int_t
int Int_t
Definition:
RtypesCore.h:45
RooInt::operator=
RooInt & operator=(Int_t value)
Definition:
RooInt.h:32
bool
RooInt
RooInt is a minimal implementation of a TObject holding a Int_t value.
Definition:
RooInt.h:22
TNamed
The TNamed class is the base class for all named ROOT classes.
Definition:
TNamed.h:29
RooInt::RooInt
RooInt(const RooInt &other)
Definition:
RooInt.h:27
RooInt::Compare
Int_t Compare(const TObject *other) const
Facilitate sorting of RooInts in ROOT container classes Return -1 or +1 if 'other' is a RooInt with v...
Definition:
RooInt.cxx:43
RooInt::RooInt
RooInt()
Definition:
RooInt.h:25
RooInt::IsSortable
virtual Bool_t IsSortable() const
Definition:
RooInt.h:36
TObject
Mother of all ROOT objects.
Definition:
TObject.h:37
ClassDef
#define ClassDef(name, id)
Definition:
Rtypes.h:325
RooInt::~RooInt
virtual ~RooInt()
Definition:
RooInt.h:28
Rtypes.h
int
roofit
roofitcore
inc
RooInt.h
ROOT master - Reference Guide Generated on Sun Apr 11 2021 11:04:41 (GVA Time) using Doxygen 1.9.0