public void EmitJs(TextWriter output, string content) { var tree = SyntaxTree.ParseCompilationUnit(content); var root = (CompilationUnitSyntax)tree.GetRoot(); var emitter = new JavaScriptWalker(output); emitter.Visit(root); }
public void EmitJs(TextWriter output, string content) { var tree = SyntaxTree.ParseText(content); var root = (CompilationUnitSyntax)tree.GetRoot(); var emitter = new JavaScriptWalker(output); emitter.Visit(root); }
private void Compile(TextWriter output, string content, string path) { var tree = SyntaxTree.ParseCompilationUnit(content, path); var root = (CompilationUnitSyntax)tree.GetRoot(); var collector = new ClassCollector(); collector.Visit(root); foreach (var @class in collector.Classes) { var emitter = new JavaScriptWalker(output); emitter.Visit(@class); } }
private void Compile(TextWriter output, string content, string path) { var tree = SyntaxTree.ParseText(content, path); var root = (CompilationUnitSyntax)tree.GetRoot(); var collector = new ClassCollector(); collector.Visit(root); foreach (var @class in collector.Classes) { var emitter = new JavaScriptWalker(output); emitter.Visit(@class); } }