ROOT
6.07/09
Reference Guide
ROOT Home Page
Main Page
Tutorials
User's Classes
Namespaces
All Classes
Files
Release Notes
File List
File Members
roofit
roofitcore
inc
RooMapCatEntry.h
Go to the documentation of this file.
1
/*****************************************************************************
2
* Project: RooFit *
3
* Package: RooFitCore *
4
* File: $Id: RooMapCatEntry.h,v 1.13 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_MAP_CAT_ENTRY
17
#define ROO_MAP_CAT_ENTRY
18
19
#include "
Riosfwd.h
"
20
#include "
TNamed.h
"
21
#include "
TRegexp.h
"
22
#include "
RooCatType.h
"
23
24
class
RooMapCatEntry
:
public
TNamed
{
25
public
:
26
inline
RooMapCatEntry
() :
TNamed
(),
_regexp
(
""
),
_cat
() {}
27
virtual
~RooMapCatEntry
() {} ;
28
RooMapCatEntry
(
const
char
*
exp
,
const
RooCatType
* cat) ;
29
RooMapCatEntry
(
const
RooMapCatEntry
& other) ;
30
virtual
TObject
*
Clone
(
const
char
* newName=0)
const
{
31
RooMapCatEntry
* ca =
new
RooMapCatEntry
(*
this
);
32
if
(newName) { ca->
SetName
(newName) ; }
33
return
ca ;
34
}
35
36
inline
Bool_t
ok
() {
return
(
_regexp
.
Status
()==
TRegexp::kOK
) ; }
37
Bool_t
match
(
const
char
* testPattern)
const
;
38
inline
const
RooCatType
&
outCat
()
const
{
return
_cat
; }
39
40
protected
:
41
42
TString
mangle
(
const
char
* exp)
const
;
43
44
TRegexp
_regexp
;
45
RooCatType
_cat
;
46
47
ClassDef
(
RooMapCatEntry
,1)
// Utility class, holding a map expression from a index label regexp to a RooCatType
48
} ;
49
50
51
#endif
RooMapCatEntry::_cat
RooCatType _cat
Definition:
RooMapCatEntry.h:45
RooMapCatEntry::outCat
const RooCatType & outCat() const
Definition:
RooMapCatEntry.h:38
TNamed::SetName
virtual void SetName(const char *name)
Set the name of the TNamed.
Definition:
TNamed.cxx:131
TRegexp
Regular expression class.
Definition:
TRegexp.h:35
RooMapCatEntry::RooMapCatEntry
RooMapCatEntry()
Definition:
RooMapCatEntry.h:26
TString
Basic string class.
Definition:
TString.h:137
Bool_t
bool Bool_t
Definition:
RtypesCore.h:59
RooMapCatEntry::~RooMapCatEntry
virtual ~RooMapCatEntry()
Definition:
RooMapCatEntry.h:27
TNamed.h
ClassDef
#define ClassDef(name, id)
Definition:
Rtypes.h:254
TNamed
The TNamed class is the base class for all named ROOT classes.
Definition:
TNamed.h:33
RooCatType
RooCatType is an auxilary class for RooAbsCategory and defines a a single category state...
Definition:
RooCatType.h:23
RooMapCatEntry::_regexp
TRegexp _regexp
Definition:
RooMapCatEntry.h:44
RooMapCatEntry::Clone
virtual TObject * Clone(const char *newName=0) const
Make a clone of an object using the Streamer facility.
Definition:
RooMapCatEntry.h:30
RooMapCatEntry::mangle
TString mangle(const char *exp) const
Definition:
RooMapCatEntry.cxx:53
RooMapCatEntry::match
Bool_t match(const char *testPattern) const
Definition:
RooMapCatEntry.cxx:46
TRegexp::kOK
Definition:
TRegexp.h:38
TRegexp.h
TObject
Mother of all ROOT objects.
Definition:
TObject.h:44
RooMapCatEntry
Definition:
RooMapCatEntry.h:24
TRegexp::Status
EStatVal Status()
Check status of regexp.
Definition:
TRegexp.cxx:231
Riosfwd.h
RooMapCatEntry::ok
Bool_t ok()
Definition:
RooMapCatEntry.h:36
exp
double exp(double)
RooCatType.h