Gallio.Loader The Gallio loader provides access to installed Gallio assemblies so that we can reference them even if they are not copied locally. We must avoid copying these assemblies because it is possible for multiple copies to be loaded in the same process simultaneously in different load context (Load / LoadFrom / LoadFile). When multiple copies of the same assembly are loaded their types are considered distinct and they cannot reliably exchange information with other components (like plugins). This problem was actually observed when two different Visual Studio add-ins installed in different locations were loaded at the same time. The Gallio loader may be used in situations where 3rd party integration mandates the installation of a Gallio-dependent assembly outside of the Gallio installation path. It is fairly typical for application plugin models. The loader itself will typically be loaded from the GAC or copy-local as usual. It will then springboard into the locally installed copy of Gallio which is found by searching the registry. It is also possible to specify the location of the Gallio installation explicitly instead. Once the loader has been initialized, all Gallio types should become accessible. In particular, the runtime can then be initialized. This is a and so cannot be inherited or instantiated. Gets the Gallio loader instance, or null if not initialized. Gets the Gallio runtime path. Adds a hint directory to the assembly resolver. The path of the hint directory to add Creates a private AppDomain that Gallio can reside in. The remote environment Thrown if Gallio does not appear to be installed Thrown if the operation could not be performed Gets the application version given its primary assembly. Uses the assembly file version if available. The assembly The assembly's file version Thrown if is null Gets the runtime path that will be used by default by the loader. The path is determined by looking up the location of the Gallio installation in the registry. It may be overridden by setting the development runtime path key. The installed runtime path Thrown if Gallio does not appear to be installed Initializes the Gallio loader (if not already initialized) and returns its singleton reference. The loader Thrown if Gallio does not appear to be installed Thrown if the operation could not be performed Initializes the Gallio loader (if not already initialized) and returns its singleton reference. The runtime path from which to load Gallio, or null to determine it automatically The loader Thrown if Gallio does not appear to be installed Thrown if the operation could not be performed Obtains a lifetime service object to control the lifetime policy for this instance. An object of type used to control the lifetime policy for this instance. This is the current lifetime service object for this instance if one exists; otherwise, a new lifetime service object initialized to the value of the property. Remotely initializes the Gallio loader (if not already initialized) and returns its singleton reference within a foreign AppDomain. The AppDomain in which to initialize the loader The loader Thrown if is null Thrown if Gallio does not appear to be installed Thrown if the operation could not be performed Remotely initializes the Gallio loader (if not already initialized) and returns its singleton reference within a foreign AppDomain. The AppDomain in which to initialize the loader The runtime path from which to load Gallio, or null to determine it automatically The loader Thrown if is null Thrown if Gallio does not appear to be installed Thrown if the operation could not be performed Resolves a runtime service. The resolved service Resolves a runtime service. The type of service to resolve The resolved service Sets up the runtime with a default runtime setup using the loader's runtime path and a null logger. Does nothing if the runtime has already been initialized. If you need more control over this behavior, call RuntimeBootstrap yourself. An exception that expresses a problem in a manner that may be safely communicated across a remote context to a client that may not be able to load the original exception type. Using this type prevents spurious exceptions from being thrown due to the server exposing an internal exception type that is not accessible to the client. Wraps an exception as a . The exception type The wrapped exception Thrown if is null Provides an interface for interacting with the Gallio Loader. Gets the Gallio runtime path. Thrown if the operation could not be performed Adds a hint directory to the assembly resolver. The path of the hint directory to add Thrown if is null Thrown if the operation could not be performed Resolves a runtime service. The type of service to resolve The resolved service Thrown if the operation could not be performed Resolves a runtime service. The type of service to resolve The resolved service Thrown if the operation could not be performed Sets up the runtime with a default runtime setup using the loader's runtime path and a null logger. Does nothing if the runtime has already been initialized. If you need more control over this behavior, call RuntimeBootstrap yourself. Thrown if the operation could not be performed Provides access to an instance of the Gallio runtime that is running in a foreign AppDomain. Gets the remote AppDomain. Thrown if the remote environment has been disposed Gets the remote loader. Thrown if the remote environment has been disposed