Assembly Explorer 1.0






4.46/5 (21 votes)
Jan 4, 2003
2 min read

112156

3059
Simple utility to browse assembly object hierarchy
Introduction
In our project we developed a bunch of utility classes. For each one of them we had to create some kind of test application just to enter parameters and display result of method invoked. At some point I decided that WinForm we just created should be the last one. Why could not we create entry form on the fly for each method in utility class, we want to test? With this thought in mind, I dig out mine old little utility that uses reflection to display assembly hierarchy, and make couple of additions.
What we have now is a simple application that can display object hierarchy of any assembly, including properties and attributes of each member. I think, it’s doing it in more user-friendly way than ildasm.exe does. You can display detailed view (as TreeView) or simplified flat view. In addition it can run static methods with parameters of basic data types.
Using the code
Just use File>Open and browse the tree.
Points of Interest
You are welcome to use this code as an example of working with reflection, including dynamic object loading and method invocation.
Some ideas how we can make this utility more useful:
- Having assembly object tree, we can use CodeDom to generate code for “black box” assembly. May be for new implementation, or to create proxy that intercepts method calls and doing some preprocessing magic.
- We can create UML model for given assembly. Rational using XML as format for their XDE model files so it should not be too difficult.
I’ll be glad to receive any comments or suggestions.
History
Version 1.0.2 - Recently opened assemblies added to File menu. Compiled exe added to zip. (Thanks to S.Rod. for suggestions)
Version 1.0.3 - Bug fixing in recent files on exit.