libassa
3.5.1
Main Page
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
assa
Regexp.h
Go to the documentation of this file.
1
// -*- c++ -*-
2
//------------------------------------------------------------------------------
3
// Regexp.h
4
//------------------------------------------------------------------------------
5
// Copyright (C) 1997-2003 Vladislav Grinchenko <vlg@users.sourceforge.net>
6
//
7
// This library is free software; you can redistribute it and/or
8
// modify it under the terms of the GNU Library General Public
9
// License as published by the Free Software Foundation; either
10
// version 2 of the License, or (at your option) any later version.
11
//------------------------------------------------------------------------------
12
#ifndef REGEXP_H
13
#define REGEXP_H
14
15
#include "
assa/Assure.h
"
16
#include <sys/types.h>
17
18
#ifdef __cplusplus
19
extern
"C"
{
20
#endif
21
22
#include <regex.h>
23
24
#ifdef __cplusplus
25
}
26
#endif
/* C++ */
27
28
29
#include <string>
30
31
namespace
ASSA {
32
43
class
Regexp
{
44
public
:
48
Regexp
(
const
std::string& pattern_);
49
53
~Regexp
();
54
60
int
match
(
const
char
* text_);
61
64
const
char
*
get_error
()
const
{
return
m_error_msg
; }
65
68
const
char
*
get_pattern
()
const
{
return
m_pattern
; }
69
70
private
:
71
char
*
m_pattern
;
72
char
*
m_error_msg
;
73
regex_t*
m_compiled_pattern
;
74
};
75
}
// @end namespace
76
77
#endif
/* REGEXP_H */
78
79
80
Generated on Tue Jun 19 2012 08:05:11 for libassa by
1.8.1.1