public Lexer(OutputModelFactory factory, LexerFile file) : base(factory) { this.file = file; // who contains us? Grammar g = factory.GetGrammar(); channels = new LinkedHashMap<string, int>(g.channelNameToValueMap); modes = ((LexerGrammar)g).modes.Keys; } }