AssemblyAdapter Class

Namespace
Kampute.DocToolkit.Metadata.Adapters
Assembly
  • Kampute.DocToolkit.dll

Definition

An adapter that wraps an Assembly and provides metadata access.
public class AssemblyAdapter : AttributeAwareMetadataAdapter<Assembly>, IAssembly
Inheritance
Implements

Remarks

This class serves as a bridge between the reflection-based Assembly and the metadata representation defined by the IAssembly interface. It provides access to assembly-level information regardless of whether the assembly was loaded via Common Language Runtime (CLR) or Metadata Load Context (MLC).

Thread Safety

All public members of the type are guaranteed to be thread-safe.

Constructors

AssemblyAdapter(Assembly)Initializes a new instance of the AssemblyAdapter class.

Properties

AttributesGets a dictionary of metadata attributes of the assembly.
ExportedTypesGets the types exported by the assembly.
IdentityGets the identity of the assembly.
IsReflectionOnlyGets a value indicating whether the assembly is loaded in reflection-only context.
IsStronglyNamedGets a value indicating whether the assembly is strongly named.
ModulesGets the modules defined in the assembly.
NameGets the name of the metadata element.
NamespacesGets the namespaces exported by the assembly and their associated types.
ReferencedAssembliesGets the identity of assemblies referenced by this assembly.
RepositoryGets the repository used to create and cache member metadata of the assembly.

Methods

CreateAttributeMetadata(CustomAttributeData)Creates a custom attribute metadata instance for the given attribute data.
GetCustomAttributes()Retrieves the underlying custom attributes of the member.
GetExportedTypes()Retrieves the types exported by the assembly.
GetMetadataAttributes()Retrieves the assembly's metadata attributes as key-value pairs.
NormalizeTypeName(string)Normalizes a type name by replacing '+' with '.' to handle nested types.
TryGetType(string, out IType)Attempts to retrieve metadata of a type exported by the assembly using its full name.