Show / Hide Table of Contents

    Class MetadataReaderExtensions

    Provides some useful extension methods to MetadataReader.

    Inheritance
    Object
    MetadataReaderExtensions
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Alphaleonis.Reflection.Metadata
    Assembly: Alphaleonis.Reflection.Metadata.dll
    Syntax
    public static class MetadataReaderExtensions

    Methods

    | Improve this Doc View Source

    ParseAssemblyName(MetadataReader, AssemblyDefinition)

    Gets the AssemblyName of the given AssemblyDefinition.

    Declaration
    public static AssemblyName ParseAssemblyName(this MetadataReader metadataReader, AssemblyDefinition assemblyDefinition)
    Parameters
    Type Name Description
    MetadataReader metadataReader

    The MetadataReader to act on.

    AssemblyDefinition assemblyDefinition

    The assembly definition.

    Returns
    Type Description
    AssemblyName

    An AssemblyName representing the specified assemblyDefinition.

    Remarks

    This is similar to the AssemblyDefinition.GetAssemblyName from System.Reflection.Metadata, with the difference that this method will give set culture to neutral and the public key token to null instead of leaving them empty.

    | Improve this Doc View Source

    ParseAssemblyName(MetadataReader, AssemblyReference)

    Gets the AssemblyName of the given AssemblyReference.

    Declaration
    public static AssemblyName ParseAssemblyName(this MetadataReader metadataReader, AssemblyReference assemblyReference)
    Parameters
    Type Name Description
    MetadataReader metadataReader

    The MetadataReader to act on.

    AssemblyReference assemblyReference

    The assembly reference.

    Returns
    Type Description
    AssemblyName

    An AssemblyName representing the specified assemblyReference.

    Remarks

    This is similar to the AssemblyDefinition.GetAssemblyName from System.Reflection.Metadata, with the difference that this method will give set culture to neutral and the public key token to null instead of leaving them empty.

    • Improve this Doc
    • View Source
    Back to top Copyright © 2018 Peter Palotas