Most aspects of programming with NGWS are the same for all compatible languages: each supported language compiler produces self-describing, managed intermediate language (IL) code. All managed IL code runs against the NGWS runtime, which provides cross-language integration, automatic memory management, cross-language exception handling, enhanced security, and a simplified model for component interaction.
NGWS also provides a common base class library organized into a single hierarchical tree of namespaces. At the root is the System namespace, which contains objects, including pre-defined types such as classes and interfaces, that can be used from any supported language. System objects – contained in mscorlib.dll– are used by all applications. The base class library also includes namespaces for both abstract base classes and derived class implementations for many other useful classes, including those for file IO, messaging, networking, and security. You can use these classes "as is" or derive your own classes from them.
Runtime-based class libraries are organized into hierarchical namespaces, and namespaces are stored in portable executable (PE) files – typically DLLs and EXEs. You can have several namespaces – including nested namespaces – in one PE file, and you can split a namespace across multiple PE files. One or more PE files are combined together to create an assembly, which is a physical unit that can be deployed, versioned, and reused. The runtime uses assemblies to located and bind to the referenced types.
The most commonly used objects are relatively easy to locate: Objects in the System.* namespace are documented in the cpref.chm and the new window/form objects are documented in sdkstart.chm, both located (by default) in the \Docs subdirectory of the SDK. There are several other tools for working with the included namespaces, as well as any custom namespaces (see Appendix A: Exploring Namespaces)
Since all supported languages compile to the same IL and use the same runtime and associated base class library, programs in each of the supported languages appear similar. In fact, the runtime specifies a set of language features called the Common Language Specification (CLS), which includes the basic language features that languages must support for interoperability. For our "Hello World" sample programs, we only need to write to the Console to show that our program is executing properly. Therefore, we will be using WriteLine method of the Console class of the System namespace. When we start working with a componentized application in a later section we will see how to create a traditional Windows graphical application.