Package com.scriptbasic.lexer
Class BasicKeywordRecognizer
- java.lang.Object
-
- com.scriptbasic.lexer.BasicKeywordRecognizer
-
- All Implemented Interfaces:
KeywordRecognizer,ScriptBasicKeyWords
public class BasicKeywordRecognizer extends java.lang.Object implements KeywordRecognizer, ScriptBasicKeyWords
This class recognizes a reserved keyword.- Author:
- verhasp
-
-
Field Summary
-
Fields inherited from interface com.scriptbasic.interfaces.ScriptBasicKeyWords
BASIC_KEYWORDS, BASIC_OPERATOR_LEXEME_MAX_LENGTH, BASIC_OPERATORS
-
-
Constructor Summary
Constructors Constructor Description BasicKeywordRecognizer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanisRecognized(java.lang.String identifier)The method checks the argument if present in the reserved keyword list or not.
-
-
-
Method Detail
-
isRecognized
public boolean isRecognized(java.lang.String identifier)
Description copied from interface:KeywordRecognizerThe method checks the argument if present in the reserved keyword list or not.- Specified by:
isRecognizedin interfaceKeywordRecognizer- Parameters:
identifier- the string of the identifier that may be reserved word- Returns:
trueif and only if the identifier string is a reserved keyword
-
-