LSSTApplications  10.0+286,10.0+36,10.0+46,10.0-2-g4f67435,10.1+152,10.1+37,11.0,11.0+1,11.0-1-g47edd16,11.0-1-g60db491,11.0-1-g7418c06,11.0-2-g04d2804,11.0-2-g68503cd,11.0-2-g818369d,11.0-2-gb8b8ce7
LSSTDataManagementBasePackage
Public Member Functions | Static Public Member Functions | List of all members
lsst::pex::policy::ParserError Class Reference

#include <parserexceptions.h>

Inheritance diagram for lsst::pex::policy::ParserError:
lsst::pex::policy::EOFError lsst::pex::policy::SyntaxError lsst::pex::policy::FormatSyntaxError lsst::pex::policy::UnsupportedSyntax

Public Member Functions

 ParserError (POL_EARGS_TYPED)
 
 ParserError (POL_EARGS_TYPED, const std::string &msg)
 
 ParserError (POL_EARGS_TYPED, const std::string &msg, int lineno)
 
virtual char const * getType () const throw ()
 
virtual
lsst::pex::exceptions::Exception
clone () const
 

Static Public Member Functions

static std::string makeLocatedMessage (const std::string &msg, int lineno)
 

Detailed Description

an parent exception for errors that occur during the parsing of policy files.

Definition at line 46 of file parserexceptions.h.

Constructor & Destructor Documentation

lsst::pex::policy::ParserError::ParserError ( POL_EARGS_TYPED  )
inline

Create an exception the exception with a default message.

Definition at line 52 of file parserexceptions.h.

53  : lsst::pex::exceptions::RuntimeError(
54  POL_EARGS_UNTYPED, "Unspecified parsing error encountered")
55  { }
#define POL_EARGS_UNTYPED
Definition: exceptions.h:38
lsst::pex::policy::ParserError::ParserError ( POL_EARGS_TYPED  ,
const std::string &  msg 
)
inline

Create an exception the exception with a given message.

Parameters
msga message describing the problem.

Definition at line 61 of file parserexceptions.h.

62  : lsst::pex::exceptions::RuntimeError(POL_EARGS_UNTYPED, msg)
63  { }
#define POL_EARGS_UNTYPED
Definition: exceptions.h:38
lsst::pex::policy::ParserError::ParserError ( POL_EARGS_TYPED  ,
const std::string &  msg,
int  lineno 
)
inline

Create an exception the exception with a given message.

Parameters
msga message describing the problem.
linenoa line number in the file (or stream) being parsed where the problem occurred. The first line of the file is typically line 1.

Definition at line 72 of file parserexceptions.h.

73  : lsst::pex::exceptions::RuntimeError(
75  { }
#define POL_EARGS_UNTYPED
Definition: exceptions.h:38
static std::string makeLocatedMessage(const std::string &msg, int lineno)

Member Function Documentation

virtual lsst::pex::exceptions::Exception* lsst::pex::policy::ParserError::clone ( ) const
virtual
virtual char const* lsst::pex::policy::ParserError::getType ( ) const
throw (
)
virtual
static std::string lsst::pex::policy::ParserError::makeLocatedMessage ( const std::string &  msg,
int  lineno 
)
inlinestatic

Definition at line 77 of file parserexceptions.h.

77  {
78  std::ostringstream out;
79  out << "Policy Parsing Error:" << lineno << ": " << msg << std::ends;
80  return out.str();
81  }

The documentation for this class was generated from the following file: