public static string Disassemble(this MethodBody body) { var writer = new PlainTextOutput(); var dasm = new MethodBodyDisassembler(writer); dasm.Disassemble(body); return writer.ToString(); }
public ReflectionDisassembler(ITextOutput output, bool detectControlStructure, CancellationToken cancellationToken) { if (output == null) throw new ArgumentNullException("output"); this.output = output; this.cancellationToken = cancellationToken; this.detectControlStructure = detectControlStructure; this.methodBodyDisassembler = new MethodBodyDisassembler(output, detectControlStructure, cancellationToken); }