void Decompile(ModuleDef module, BamlDocument document, IDecompiler lang, IDecompilerOutput output, CancellationToken token) { var decompiler = new XamlDecompiler(); var xaml = decompiler.Decompile(module, document, token, BamlDecompilerOptions.Create(lang), null); var xamlText = new XamlOutputCreator(xamlOutputOptionsProvider.Default).CreateText(xaml); documentWriterService.Write(output, xamlText, ContentTypes.Xaml); }
public IList<string> Decompile(ModuleDef module, byte[] data, CancellationToken token, BamlDecompilerOptions bamlDecompilerOptions, Stream output, XamlOutputOptions outputOptions) { var doc = BamlReader.ReadDocument(new MemoryStream(data), token); var asmRefs = new List<string>(); var xaml = new XamlDecompiler().Decompile(module, doc, token, bamlDecompilerOptions, asmRefs); var resData = Encoding.UTF8.GetBytes(new XamlOutputCreator(outputOptions).CreateText(xaml)); output.Write(resData, 0, resData.Length); return asmRefs; }
void Decompile(ModuleDef module, BamlDocument document, ILanguage lang, IDecompilerOutput output, CancellationToken token) { var decompiler = new XamlDecompiler(); var xaml = decompiler.Decompile(module, document, token, BamlDecompilerOptions.Create(lang), null); output.Write(xaml.ToString(), BoxedTextColor.Text); }
void Decompile(ModuleDef module, BamlDocument document, Language lang, ITextOutput output, out IHighlightingDefinition highlight, CancellationToken token) { var decompiler = new XamlDecompiler(); var xaml = decompiler.Decompile(module, document, token); output.Write(xaml.ToString(), TextTokenType.Text); highlight = HighlightingManager.Instance.GetDefinitionByExtension(".xml"); }
void Decompile(ModuleDef module, BamlDocument document, ILanguage lang, ITextOutput output, out string ext, CancellationToken token) { var decompiler = new XamlDecompiler(); var xaml = decompiler.Decompile(module, document, token, BamlDecompilerOptions.Create(lang), null); output.Write(xaml.ToString(), TextTokenKind.Text); ext = ".xml"; }
void Decompile(ModuleDef module, BamlDocument document, IDecompiler lang, IDecompilerOutput output, CancellationToken token) { var decompiler = new XamlDecompiler(); var xaml = decompiler.Decompile(module, document, token, BamlDecompilerOptions.Create(lang), null); var xamlText = new XamlOutputCreator(xamlOutputOptionsProvider.Default).CreateText(xaml); documentWriterService.Write(output, xamlText, ContentTypes.Xaml); }
void Decompile(ModuleDef module, BamlDocument document, Language lang, ITextOutput output, out IHighlightingDefinition highlight, CancellationToken token) { var decompiler = new XamlDecompiler(); var xaml = decompiler.Decompile(module, document, token); output.Write(xaml.ToString(), TextTokenType.Text); highlight = HighlightingManager.Instance.GetDefinitionByExtension(".xml"); }
void Decompile(ModuleDef module, BamlDocument document, ILanguage lang, ITextOutput output, out string ext, CancellationToken token) { var decompiler = new XamlDecompiler(); var xaml = decompiler.Decompile(module, document, token, BamlDecompilerOptions.Create(lang), null); output.Write(xaml.ToString(), TextTokenKind.Text); ext = ".xml"; }
public IList <string> Decompile(ModuleDef module, byte[] data, CancellationToken token, BamlDecompilerOptions bamlDecompilerOptions, Stream output, XamlOutputOptions outputOptions) { var doc = BamlReader.ReadDocument(new MemoryStream(data), token); var asmRefs = new List <string>(); var xaml = new XamlDecompiler().Decompile(module, doc, token, bamlDecompilerOptions, asmRefs); var resData = Encoding.UTF8.GetBytes(new XamlOutputCreator(outputOptions).CreateText(xaml)); output.Write(resData, 0, resData.Length); return(asmRefs); }