diff options
Diffstat (limited to 'maildrop/rematchstr.h')
| -rw-r--r-- | maildrop/rematchstr.h | 30 | 
1 files changed, 30 insertions, 0 deletions
| diff --git a/maildrop/rematchstr.h b/maildrop/rematchstr.h new file mode 100644 index 0000000..040289e --- /dev/null +++ b/maildrop/rematchstr.h @@ -0,0 +1,30 @@ +#ifndef	rematchstr_h +#define	rematchstr_h + + +#include	"config.h" +#include	<sys/types.h> +#include	"rematch.h" + +//////////////////////////////////////////////////////////////////////////// +// +// ReMatchStr - derive from ReMatch when text matched against a regular +// expression comes from the message body itself. +// +//////////////////////////////////////////////////////////////////////////// + +class ReMatchStr : public ReMatch { + +	const char *str; +	const char *pos; + +public: +	ReMatchStr(const char *p) : str(p), pos(p)	{} +	~ReMatchStr(); + +	int	NextChar(); +	int	CurrentChar(); +	off_t GetCurrentPos(); +	void	SetCurrentPos(off_t); +} ; +#endif | 
