C# Class Pegasus.CompileManager

Provides a simple interface for parsing and compiling a PEG grammar.
Datei anzeigen Open project: otac0n/Pegasus Class Usage Examples

Public Methods

Method Description
CompileFile ( string inputFile, string outputFile, Action logError ) : void

Parse and compile a PEG grammar from a file.

CompileString ( string subject, string fileName = null ) : CompileResult

Parse and compile a PEG grammar from a string.

Method Details

CompileFile() public static method

Parse and compile a PEG grammar from a file.
public static CompileFile ( string inputFile, string outputFile, Action logError ) : void
inputFile string The source filename.
outputFile string The desired destination filename, or null to use the default.
logError Action An action that will be called for every warning or error.
return void

CompileString() public static method

Parse and compile a PEG grammar from a string.
public static CompileString ( string subject, string fileName = null ) : CompileResult
subject string The PEG grammar to parse and compile.
fileName string The filename to use in errors.
return Pegasus.Compiler.CompileResult