
Examine the Innards of Assemblies #64
Chapter 7, Help and Research
|
249
HACK
the intermediate language of a .NET assembly into either C# or Visual Basic
code. In addition to converting IL to C# or Visual Basic code, Reflector pro-
vides an outline of the assembly’s classes and its members, the ability to
view the IL for an assembly, and support for third-party add-ins.
Download and Run Reflector
Reflector is a free program created by Lutz Roeder, a Microsoft employee. It
is one of those essentials that every serious .NET developer should have in
her toolbox. Reflector is updated frequently; the latest version is available at
http://www.aisto.com/roeder/dotnet. At the time of this writing, when you
download Reflector, you download a zip file containing just two files:
Reflector.exe and ReadMe.htm. After unzipping these two files to some
directory, you can run Reflector by simply double-clicking the Reflector.exe
file.
By default, Reflector opens a handful of common assemblies: mscorlib,
System, System.Data, System.Drawing, and so on. Each opened assembly is
listed in Reflector’s main window (see Figure 7-23). Clicking on the
+ icon
next to an assembly will expand the tree, showing the assembly’s
namespaces. Each namespace has a corresponding
+ icon next to it as well
that, when clicked, will show the namespace’s classes. Additionally, each
class can be expanded to show the class’s members—its events, fields, ...