AtomicTools.cs 823 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. using System;
  2. using System.IO;
  3. using System.Diagnostics;
  4. using System.Collections.Generic;
  5. using System.Collections.Immutable;
  6. using System.Linq;
  7. using System.Reflection;
  8. using System.Reflection.Metadata;
  9. using System.Reflection.PortableExecutable;
  10. using System.Reflection.Metadata.Ecma335;
  11. using System.Text;
  12. using AtomicEngine;
  13. using File = System.IO.File;
  14. namespace AtomicTools
  15. {
  16. public class AtomicTools
  17. {
  18. public static String InspectAssembly (String pathToAssembly)
  19. {
  20. try {
  21. var inspector = new AssemblyInspector ();
  22. inspector.Inspect (pathToAssembly);
  23. return inspector.DumpToJSON();
  24. } catch (Exception ex) {
  25. Console.WriteLine (ex.Message);
  26. }
  27. return "";
  28. }
  29. }
  30. }