RooStreamParser Class Reference

#include <RooStreamParser.h>

List of all members.

Public Member Functions

 RooStreamParser (istream &is)
 RooStreamParser (istream &is, const TString &errPrefix)
virtual ~RooStreamParser ()
TString readToken ()
TString readLine ()
Bool_t expectToken (const TString &expected, Bool_t zapOnError=kFALSE)
void setPunctuation (const TString &punct)
TString getPunctuation () const
Bool_t readDouble (Double_t &value, Bool_t zapOnError=kFALSE)
Bool_t convertToDouble (const TString &token, Double_t &value)
Bool_t readInteger (Int_t &value, Bool_t zapOnError=kFALSE)
Bool_t convertToInteger (const TString &token, Int_t &value)
Bool_t readString (TString &value, Bool_t zapOnError=kFALSE)
Bool_t convertToString (const TString &token, TString &string)
Bool_t atEOL ()
Bool_t atEOF ()
void zapToEnd (Bool_t inclContLines=kFALSE)
Bool_t isPunctChar (char c) const
 RooStreamParser (istream &is)
 RooStreamParser (istream &is, const TString &errPrefix)
virtual ~RooStreamParser ()
TString readToken ()
TString readLine ()
Bool_t expectToken (const TString &expected, Bool_t zapOnError=kFALSE)
void setPunctuation (const TString &punct)
TString getPunctuation () const
Bool_t readDouble (Double_t &value, Bool_t zapOnError=kFALSE)
Bool_t convertToDouble (const TString &token, Double_t &value)
Bool_t readInteger (Int_t &value, Bool_t zapOnError=kFALSE)
Bool_t convertToInteger (const TString &token, Int_t &value)
Bool_t readString (TString &value, Bool_t zapOnError=kFALSE)
Bool_t convertToString (const TString &token, TString &string)
Bool_t atEOL ()
Bool_t atEOF ()
void zapToEnd (Bool_t inclContLines=kFALSE)
Bool_t isPunctChar (char c) const

Protected Attributes

istream * _is
Bool_t _atEOL
Bool_t _atEOF
TString _prefix
TString _punct
istream * _is


Detailed Description

Definition at line 22 of file RooStreamParser.h.


Constructor & Destructor Documentation

RooStreamParser::RooStreamParser ( istream &  is  ) 

RooStreamParser::RooStreamParser ( istream &  is,
const TString errPrefix 
)

Definition at line 65 of file RooStreamParser.cxx.

RooStreamParser::~RooStreamParser (  )  [virtual]

Definition at line 75 of file RooStreamParser.cxx.

RooStreamParser::RooStreamParser ( istream &  is  ) 

RooStreamParser::RooStreamParser ( istream &  is,
const TString errPrefix 
)

virtual RooStreamParser::~RooStreamParser (  )  [virtual]


Member Function Documentation

TString RooStreamParser::readToken (  ) 

Definition at line 119 of file RooStreamParser.cxx.

References _atEOF, _is, buffer, c, RooFit::InputArguments, isPunctChar(), kTRUE, oocoutW, and zapToEnd().

Referenced by expectToken(), readDouble(), RooCategory::readFromStream(), RooMappedCategory::readFromStream(), RooArgSet::readFromStream(), RooRealVar::readFromStream(), readInteger(), and readString().

TString RooStreamParser::readLine (  ) 

Definition at line 283 of file RooStreamParser.cxx.

References _atEOF, _is, buffer, c, and kTRUE.

Referenced by RooArgSet::readFromStream(), RooArgList::readFromStream(), RooGenericPdf::readFromStream(), and RooStringVar::readFromStream().

Bool_t RooStreamParser::expectToken ( const TString expected,
Bool_t  zapOnError = kFALSE 
)

Definition at line 368 of file RooStreamParser.cxx.

References TString::CompareTo(), error, RooFit::InputArguments, kTRUE, oocoutW, readToken(), and zapToEnd().

Referenced by RooRealVar::readFromStream(), RooArgSet::readFromStream(), and RooMappedCategory::readFromStream().

void RooStreamParser::setPunctuation ( const TString punct  ) 

Definition at line 94 of file RooStreamParser.cxx.

Referenced by RooMappedCategory::readFromStream(), and RooArgSet::readFromStream().

TString RooStreamParser::getPunctuation (  )  const [inline]

Definition at line 33 of file RooStreamParser.h.

References _punct.

Bool_t RooStreamParser::readDouble ( Double_t value,
Bool_t  zapOnError = kFALSE 
)

Definition at line 386 of file RooStreamParser.cxx.

References convertToDouble(), TString::IsNull(), kTRUE, and readToken().

Referenced by RooRealVar::readFromStream(), and RooErrorVar::readFromStream().

Bool_t RooStreamParser::convertToDouble ( const TString token,
Double_t value 
)

Definition at line 400 of file RooStreamParser.cxx.

References TString::Data(), data, error, RooNumber::infinity(), RooFit::InputArguments, TString::Length(), oocoutE, and strcasecmp.

Referenced by readDouble(), and RooRealVar::readFromStream().

Bool_t RooStreamParser::readInteger ( Int_t value,
Bool_t  zapOnError = kFALSE 
)

Definition at line 426 of file RooStreamParser.cxx.

References convertToInteger(), TString::IsNull(), kTRUE, and readToken().

Referenced by RooRealVar::readFromStream().

Bool_t RooStreamParser::convertToInteger ( const TString token,
Int_t value 
)

Definition at line 439 of file RooStreamParser.cxx.

References TString::Data(), data, error, RooFit::InputArguments, TString::Length(), oocoutE, and strtol().

Referenced by readInteger().

Bool_t RooStreamParser::readString ( TString value,
Bool_t  zapOnError = kFALSE 
)

Definition at line 459 of file RooStreamParser.cxx.

References convertToString(), TString::IsNull(), kTRUE, readToken(), and value.

Referenced by RooStringVar::readFromStream().

Bool_t RooStreamParser::convertToString ( const TString token,
TString string 
)

Definition at line 473 of file RooStreamParser.cxx.

References buffer, TString::Data(), RooFit::InputArguments, len, TString::Length(), oocoutW, and ptr.

Referenced by readString().

Bool_t RooStreamParser::atEOL (  ) 

Definition at line 83 of file RooStreamParser.cxx.

References _is, and nc.

Referenced by RooArgSet::readFromStream(), RooRealVar::readFromStream(), and RooArgList::readFromStream().

Bool_t RooStreamParser::atEOF (  )  [inline]

Definition at line 45 of file RooStreamParser.h.

References _atEOF.

Referenced by RooArgSet::readFromStream(), and RooRealVar::readFromStream().

void RooStreamParser::zapToEnd ( Bool_t  inclContLines = kFALSE  ) 

Definition at line 332 of file RooStreamParser.cxx.

References _is, and buffer.

Referenced by expectToken(), RooRealVar::readFromStream(), RooArgSet::readFromStream(), RooArgList::readFromStream(), and readToken().

Bool_t RooStreamParser::isPunctChar ( char  c  )  const

Definition at line 104 of file RooStreamParser.cxx.

References i, and kTRUE.

Referenced by readToken().

TString RooStreamParser::readToken (  ) 

TString RooStreamParser::readLine (  ) 

Bool_t RooStreamParser::expectToken ( const TString expected,
Bool_t  zapOnError = kFALSE 
)

void RooStreamParser::setPunctuation ( const TString punct  ) 

TString RooStreamParser::getPunctuation (  )  const [inline]

Definition at line 33 of file RooStreamParser.h.

References _punct.

Bool_t RooStreamParser::readDouble ( Double_t value,
Bool_t  zapOnError = kFALSE 
)

Bool_t RooStreamParser::convertToDouble ( const TString token,
Double_t value 
)

Bool_t RooStreamParser::readInteger ( Int_t value,
Bool_t  zapOnError = kFALSE 
)

Bool_t RooStreamParser::convertToInteger ( const TString token,
Int_t value 
)

Bool_t RooStreamParser::readString ( TString value,
Bool_t  zapOnError = kFALSE 
)

Bool_t RooStreamParser::convertToString ( const TString token,
TString string 
)

Bool_t RooStreamParser::atEOL (  ) 

Bool_t RooStreamParser::atEOF (  )  [inline]

Definition at line 45 of file RooStreamParser.h.

References _atEOF.

void RooStreamParser::zapToEnd ( Bool_t  inclContLines = kFALSE  ) 

Bool_t RooStreamParser::isPunctChar ( char  c  )  const


Member Data Documentation

istream* RooStreamParser::_is [protected]

Definition at line 52 of file RooStreamParser.h.

Referenced by atEOL(), readLine(), readToken(), and zapToEnd().

Bool_t RooStreamParser::_atEOL [protected]

Definition at line 53 of file RooStreamParser.h.

Bool_t RooStreamParser::_atEOF [protected]

Definition at line 54 of file RooStreamParser.h.

Referenced by atEOF(), readLine(), and readToken().

TString RooStreamParser::_prefix [protected]

Definition at line 55 of file RooStreamParser.h.

TString RooStreamParser::_punct [protected]

Definition at line 56 of file RooStreamParser.h.

Referenced by getPunctuation().

istream* RooStreamParser::_is [protected]

Definition at line 52 of file RooStreamParser.h.


The documentation for this class was generated from the following files:
Generated on Tue Jul 5 16:34:02 2011 for ROOT_528-00b_version by  doxygen 1.5.1