There are a few other tricks you can do once you have a reference to an assembly. Some aren't very practical but they're good to know nonethelessthe one in this section falls under that second category. It's possible to list all the classes in an assembly. Class information is obtained through a reference to a System.Type object. You learned about System.Type in Chapter 7, "Types." In the following example we obtain an array of System.Type objects for all the classes in the assembly. To enumerate through all classes in an assembly:
Tip
|