|  | reflex::Pattern::Error Struct Reference updated Fri Dec 9 2016 |

- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Hierarchy
- Class Members

Public Types | Public Member Functions | Public Attributes | List of all members
reflex::Pattern::Error Struct Reference

Throwable error structure reflex::Pattern::Error. More...

`#include <pattern.h>`

Collaboration diagram for reflex::Pattern::Error:
[legend]

## Public Types
enum | Code { REGEX_SYNTAX, REGEX_RANGE, REGEX_LIST, CODE_OVERFLOW }
| Error codes raised during Pattern object construction. More...

## Public Member Functions
| Error (const Pattern *pattern, enum Code code, const char *message, size_t loc)
| Construct error structure. More...
void | display (std::ostream &os=std::cerr) const

## Public Attributes
const Pattern & | pattern
| the pattern object with this error More...
enum Code | code
| the error code More...
const char * | message
| a human-readable error message (not NULL) More...
size_t | loc
| location of the error in regex string Pattern::rex_ or 0 More...

## Detailed Description

Throwable error structure reflex::Pattern::Error.

## Member Enumeration Documentation

enum reflex::Pattern::Error::Code

Error codes raised during Pattern object construction.

Enumerator
REGEX_SYNTAX | regex syntax error
REGEX_RANGE | regex `{n,m}` range error
REGEX_LIST | regex `[a-b]` list error
CODE_OVERFLOW | compiled code is too large

## Constructor & Destructor Documentation

reflex::Pattern::Error::Error | ( | const Pattern * | pattern,
|  | enum Code | code,
|  | const char * | message,
|  | size_t | loc
| ) |  |
| inline

Construct error structure.

Parameters

  pattern | points to the pattern object with this error
  code | the error code
  message | a human-readable error message (not NULL)
  loc | location of the error in regex string Pattern::rex_ or 0

## Member Function Documentation

void reflex::Pattern::Error::display | ( | std::ostream & | os = `std::cerr` | ) | const

## Member Data Documentation

enum Code reflex::Pattern::Error::code

the error code

size_t reflex::Pattern::Error::loc

location of the error in regex string Pattern::rex_ or 0

const char* reflex::Pattern::Error::message

a human-readable error message (not NULL)

const Pattern& reflex::Pattern::Error::pattern

the pattern object with this error

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

- pattern.h