Information Technology Reference
In-Depth Information
Namespaces Spread Across Files
A namespace is not closed. This means that you can add more type declarations to it by declar-
ing it again either later in the source file or in another source file.
For example, Figure 10-7 shows the declaration of three classes, all in the same namespace,
but declared in separate source files. The source files can be compiled into a single assembly, as
shown in Figure 10-7, or into separate assemblies, as shown in Figure 10-8.
Figure 10-7. A namespace can be spread across source files and compiled to a single assembly.
Figure 10-8. A namespace can be spread across source files and compiled to separate assemblies.
Search WWH ::




Custom Search