// CRegex.cp
// CRegex.h
// ----------------------------------------------------------------------------------
// Finds regular expressions in the dictionary class.
//
//
// Note: This file is proprietary and confidential to Art Pollard
//	and Lextek Internation.  
// Copyright 1994 Art Pollard / LexTek International
//
//
// ----------------------------------------------------------------------------------
// History:
// 		Art Pollard			June 94
//			Original
//		Clark Goble			08/14/94
//			Checked it over and made a few modifications as part of the
//			C++ conversion.
// ----------------------------------------------------------------------------------




#ifndef _CREGEX_
#define _CREGEX_

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "UMatch.h"
#include "CMnDct.h"


class CRegex {
public:
	 CRegex();
     ~CRegex();

	short FindFirstMatch(CMainDict *Dict, char *Word, CallBackProc CallBack);
	short FindNextMatch(CMainDict *Dict, char *Word, CallBackProc CallBack);
protected:

	short   NumWordsFound;
	short   NumCharsSame;
	char  TempWord[MAXWORDLENGTH];
	char  CurrentWordBuff[MAXWORDLENGTH];

	short  Same(char *Word1,char *Word2);
	char Cursor[MAXWORDLENGTH];
	short  Done;
}; // CRegex

#endif


