Antlr4.Codegen.AbstractTarget.GenFile C# (CSharp) Method

GenFile() protected method

protected GenFile ( Grammar g, Template outputFileST, string fileName ) : void
g Antlr4.Tool.Grammar
outputFileST Template
fileName string
return void
        protected internal virtual void GenFile(Grammar g, Template outputFileST, string fileName)
        {
            GetCodeGenerator().Write(outputFileST, fileName);
        }

Usage Example

Example #1
0
        public virtual void WriteBaseVisitor(Template outputFileST, bool header)
        {
            AbstractTarget target = GetTarget();

            if (target == null)
            {
                throw new NotSupportedException("Cannot generate code without a target.");
            }

            target.GenFile(g, outputFileST, GetBaseVisitorFileName(header));
        }
All Usage Examples Of Antlr4.Codegen.AbstractTarget::GenFile