public ILexemeFactory Get(LexerRuleType lexerRuleType) { ILexemeFactory lexemeFactory = null; if (!_registry.TryGetValue(lexerRuleType, out lexemeFactory)) { return(null); } return(lexemeFactory); }
public void Register(ILexemeFactory factory) { _registry.Add(factory.LexerRuleType, factory); }
public void Register(ILexemeFactory factory) { _registry.Add(factory.LexerRuleType.GetHashCode(), factory); }
public Lexer(IInputStream inputStream, IKeywordLexemeTypeMap lexemeMapper, ILexemeFactory lexemeFactory) { this.inputStream = inputStream; this.lexemeMapper = lexemeMapper; this.lexemeFactory = lexemeFactory; }
public void Register(ILexemeFactory factory) { _registry.Add(factory.LexerRuleType, factory); }