Class AssemblyIntrospectionProviderExtensions
Provides a set of extension methods for IAssemblyIntrospectionProvider.
Inheritance
Namespace: System.Reflection
Assembly: Nuqleon.Reflection.Virtualization.dll
Syntax
public static class AssemblyIntrospectionProviderExtensions : Object
Methods
GetFiles(IAssemblyIntrospectionProvider, Assembly)
Gets the files in the file table of an assembly manifest.
Declaration
public static IReadOnlyList<FileStream> GetFiles(this IAssemblyIntrospectionProvider provider, Assembly assembly)
Parameters
| Type | Name | Description |
|---|---|---|
| IAssemblyIntrospectionProvider | provider | The reflection introspection provider. |
| System.Reflection.Assembly | assembly | The assembly to get the files for. |
Returns
| Type | Description |
|---|---|
| System.Collections.Generic.IReadOnlyList<System.IO.FileStream> | An array of streams that contain the files. |
GetLoadedModules(IAssemblyIntrospectionProvider, Assembly)
Gets all the loaded modules that are part of this assembly.
Declaration
public static IReadOnlyList<Module> GetLoadedModules(this IAssemblyIntrospectionProvider provider, Assembly assembly)
Parameters
| Type | Name | Description |
|---|---|---|
| IAssemblyIntrospectionProvider | provider | The reflection introspection provider. |
| System.Reflection.Assembly | assembly | The assembly to get the loaded modules for. |
Returns
| Type | Description |
|---|---|
| System.Collections.Generic.IReadOnlyList<System.Reflection.Module> | An array of modules. |
GetModules(IAssemblyIntrospectionProvider, Assembly)
Gets all the modules that are part of the specified assembly.
Declaration
public static IReadOnlyList<Module> GetModules(this IAssemblyIntrospectionProvider provider, Assembly assembly)
Parameters
| Type | Name | Description |
|---|---|---|
| IAssemblyIntrospectionProvider | provider | The reflection introspection provider. |
| System.Reflection.Assembly | assembly | The assembly to get the modules for. |
Returns
| Type | Description |
|---|---|
| System.Collections.Generic.IReadOnlyList<System.Reflection.Module> | An array of modules. |
GetName(IAssemblyIntrospectionProvider, Assembly)
Gets an System.Reflection.AssemblyName for the specified assembly.
Declaration
public static AssemblyName GetName(this IAssemblyIntrospectionProvider provider, Assembly assembly)
Parameters
| Type | Name | Description |
|---|---|---|
| IAssemblyIntrospectionProvider | provider | The reflection introspection provider. |
| System.Reflection.Assembly | assembly | The assembly to get the name for. |
Returns
| Type | Description |
|---|---|
| System.Reflection.AssemblyName | An object that contains the fully parsed display name for this assembly. |
GetType(IAssemblyIntrospectionProvider, Assembly, String)
Gets the System.Type object with the specified name in the specified assembly.
Declaration
public static Type GetType(this IAssemblyIntrospectionProvider provider, Assembly assembly, string name)
Parameters
| Type | Name | Description |
|---|---|---|
| IAssemblyIntrospectionProvider | provider | The reflection introspection provider. |
| System.Reflection.Assembly | assembly | The assembly to get the type from. |
| System.String | name | The full name of the type. |
Returns
| Type | Description |
|---|---|
| System.Type | An object that represents the specified class, or null if the class is not found. |
GetType(IAssemblyIntrospectionProvider, Assembly, String, Boolean)
Gets the System.Type object with the specified name in the specified assembly and optionally throws an exception if the type is not found.
Declaration
public static Type GetType(this IAssemblyIntrospectionProvider provider, Assembly assembly, string name, bool throwOnError)
Parameters
| Type | Name | Description |
|---|---|---|
| IAssemblyIntrospectionProvider | provider | The reflection introspection provider. |
| System.Reflection.Assembly | assembly | The assembly to get the type from. |
| System.String | name | The full name of the type. |
| System.Boolean | throwOnError | true to throw an exception if the type is not found; false to return null. |
Returns
| Type | Description |
|---|---|
| System.Type | An object that represents the specified class. |