Sophie

Sophie

distrib > Mandriva > 2011.0 > i586 > media > contrib-release-debug > by-pkgid > 0f593f47b85ce09ba29c11debf159b75 > files > 11

dnstouch-debug-0.4-16mdv2011.0.i586.rpm

// Written by John Newbigin
// jn@it.swin.edu.au
// Copyright (c) 1999 John Newbigin
// Covered by the terms of the GPL.

#ifndef TOKEN_H
#define TOKEN_H

#include "string.h"
#include <stdio.h>

class TToken
{
public:
	TToken(HugeString *extraWordChars);
	~TToken();

	int AssignFile(char *FileName);
	int getToken(HugeString *string);
	int getLineNo();

private:
	char *filename;
	FILE *f;
	int lineNo;

	int state;
	int peekedChar;

	int GetChar();
	int PeekChar();
	int AcceptChar();
	
	int instring(char c, char *str);
	char *WORDCHARS;
	HugeString *newWORDCHARS;
};

#endif