Working with Reflector.Diff - Modifying the options
(Page 4 of 4 )
The Options button, unsurprisingly, brings up the Options dialog. The General tab, shown in Figure 4-12, currently provides only one option (more options are envisioned for later versions of the software). The available option indicates the user’s requirement to include documentation for the assembly in the difference results. This works only if the necessary documentation is included in the underlying assembly. If it isn’t, the difference engine will prompt for this information while analyzing differences in the assemblies. This can be irritating, so be warned.

Figure 4-12. General options
The second tab, Resolution (Figure 4-13), contains the options to control how the difference engine resolves a source assembly to a destination assembly. The initial option indicates whether or not prior custom matches are stored, and how many such matches are stored. The default is to store the last 20 matches.
There is also an option that indicates whether Reflector.Diff should perform automatic Framework resolution. When a Framework assembly is selected, the engine will always try to resolve that assembly to the option indicated here. The resolution options depicted in Figure 4-13 show that if you select a Framework assembly as the source, the destination resolves to the corresponding version 1.1 assembly. The default option is cleverly positioned as the second-highest version installed on your system, so if you have .NET 1.0 and .NET 1.1 installed, the default will be 1.0.

Figure 4-13. Resolution options
However, bear in mind that custom matches override this option, so if you select version 2.0 of mscorlib and then use the Browse Destination button to select version 1.0 of mscorlib, the tool will from that point on use version 1.0 for mscorlib. The engine assumes that its users know what they’re doing here, possibly incorrectly.
Finally, the Export options (shown in Figure 4-14) control how the XML exports are performed. The default option exports the current node only. If the option to include subnodes is selected, all of the selected node’s subnodes will be exported as well. Correspondingly, the exports will take a much longer time to complete.

Figure 4-14. Export options
Getting Support
Support for Reflector.Diff is solely via bug reports and feature requests sent to the author’s email address (sean.hederman@codingsanity.com). Source code can also be found on the download page.
Reflector.Diff in a Nutshell
Reflector.Diff is still in beta development, as is evidenced by its 0.75 version number. The exported differences do not currently contain an indent level, and including documentation
currently requires the selection of side-by-side versioning in the Reflector options. In addition, better multithreading support would help to improve the responsiveness for large nodes. Improvements to address all of these issues are on the drawing
board for the next release, but since this tool is a hobby, releases are, unfortunately,
fairly widely spaced.
Still, for its purpose, Reflector.Diff is pretty useful. Looking at differences between
assemblies is an edge case, with few applications beyond research. The original purpose of the tool was to assist its author in finding changes between .NET 1.1 and .NET 2.0 Framework assemblies, which is why the support for non-Framework assemblies is a bit
of an afterthought. Furthermore, since a primary goal of the tool is to support all Framework
versions, the tool must be developed in .NET 1.0, which limits the ease of adding some additional functionality.
Nonetheless, the ability to difference assemblies is very useful. This tool has been used
to identify breaking changes in vendors’ code, resulting in quick turnaround of bug fixes. It is also used by some large corporations to help zero in on change issues, and by many developers to research changes in versions of assemblies.
Reflector.Diff gives users a quick and easy way to visually inspect changes between two versions of a DLL for research or bug tracing.
—Sean Hederman, creator of Reflector.Diff
Please check back next week for the continuation of this article.
| DISCLAIMER: The content provided in this article is not warranted or guaranteed by Developer Shed, Inc. The content provided is intended for entertainment and/or educational purposes in order to introduce to the reader key ideas, concepts, and/or product reviews. As such it is incumbent upon the reader to employ real-world tactics for security and implementation of best practices. We are not liable for any negative consequences that may result from implementing any information covered in our articles or tutorials. If this is a hardware review, it is not recommended to open and/or modify your hardware. |
|
This article is excerpted from chapter four of the book Windows Developer Power Tools, written by James Avery and Jim Holmes (O'Reilly; ISBN: 0596527543). Check it out today at your favorite bookstore. Buy this book now.
|
|