# class Regexp | A regexp matching class. More...
Full name | `TelEngine::Regexp`
Definition | `#include <yateclass.h>`
Inherits | TelEngine::String [public ]
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

#### Public Methods

- Regexp ()
- explicit Regexp (const char* value, bool extended = false, bool insensitive = false)
- Regexp (const Regexp& value)
- virtual ~Regexp ()
- inline Regexp& operator= (const char* value)
- bool compile () const
- bool matches (const char* value) const
- virtual bool matches (const String& value) const
- void setFlags (bool extended, bool insensitive)
- bool isExtended () const
- bool isCaseInsensitive () const

#### Protected Methods

- virtual void changed ()

## Detailed Description

A regular expression matching class.

Regexp () | ### Regexp

Creates a new, empty regexp.

explicit Regexp (const char* value, bool extended = false, bool insensitive = false) | ### Regexp

Creates a new initialized regexp.

Parameters:

value | Initial value of the regexp.
extended | True to use POSIX Extended Regular Expression syntax
insensitive | True to not differentiate case

Regexp (const Regexp& value) | ### Regexp

Copy constructor.

Parameters:

value | Initial value of the regexp.

~Regexp () | ### ~Regexp

[virtual]

Destroys the regexp, disposes the memory.

inline Regexp& operator= (const char* value) | ### operator=

Assignment from char* operator.

Reimplemented from String.

bool compile () | ### compile

[const]

Makes sure the regular expression is compiled

Returns: True if successfully compiled, false on error

bool matches (const char* value) | ### matches

[const]

Checks if the pattern matches a given value

Parameters:

value | String to check for match

Returns: True if matches, false otherwise

Reimplemented from String.

bool matches (const String& value) | ### matches

[const virtual]

Checks if the pattern matches a string

Parameters:

value | String to check for match

Returns: True if matches, false otherwise

Reimplemented from String.

void setFlags (bool extended, bool insensitive) | ### setFlags

Change the expression matching flags

Parameters:

extended | True to use POSIX Extended Regular Expression syntax
insensitive | True to not differentiate case

bool isExtended () | ### isExtended

[const]

Return the POSIX Extended syntax flag

Returns: True if using POSIX Extended Regular Expression syntax

bool isCaseInsensitive () | ### isCaseInsensitive

[const]

Return the Case Insensitive flag

Returns: True if not differentiating case

void changed () | ### changed

[protected virtual]

Called whenever the value changed (except in constructors) to recompile.

Reimplemented from String.

Generated by: paulc on bussard on Mon Feb 10 13:15:47 2014, using kdoc 2.0a54.