Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

IMetaDataAssemblyImport Interface

Provides methods to access and examine the contents of an assembly manifest.


interface IMetaDataAssemblyImport : IUnknown {
        
    HRESULT CloseEnum (
        HCORENUM hEnum
    );
        
    HRESULT EnumAssemblyRefs (
        [in][out] HCORENUM    *phEnum, 
        [out] mdAssemblyRef rAssemblyRefs[], 
        [in]  ULONG       cMax, 
        [out] ULONG       *pcTokens
    );
        
    HRESULT EnumExportedTypes (
        [in][out] HCORENUM    *phEnum, 
        [out] mdExportedType   rExportedTypes[], 
        [in]  ULONG       cMax, 
        [out] ULONG       *pcTokens
    );
        
    HRESULT EnumFiles (
        [in][out] HCORENUM    *phEnum, 
        [out] mdFile      rFiles[], 
        [in]  ULONG       cMax, 
        [out] ULONG       *pcTokens
    );
        
    HRESULT EnumManifestResources (
        [in][out] HCORENUM    *phEnum, 
        [out] mdManifestResource  rManifestResources[], 
        [in]  ULONG       cMax, 
        [out] ULONG       *pcTokens
    ); 
        
    HRESULT FindAssembliesByName (
        [in]  LPCWSTR  szAppBase, 
        [in]  LPCWSTR  szPrivateBin, 
        [in]  LPCWSTR  szAssemblyName, 
        [out] IUnknown *ppIUnk[], 
        [in]  ULONG    cMax, 
        [out] ULONG    *pcAssemblies
    );
        
    HRESULT FindExportedTypeByName (
        [in]  LPCWSTR     szName, 
        [in]  mdToken     mdtExportedType, 
        [out] mdExportedType   *ptkExportedType
     );
        
    HRESULT FindManifestResourceByName (
        [in]  LPCWSTR     szName, 
        [out] mdManifestResource *ptkManifestResource
    ); 
        
    HRESULT GetAssemblyFromScope (
        [out] mdAssembly  *ptkAssembly
    );
        
    HRESULT GetAssemblyProps (
        [in]  mdAssembly  mda,
        [out] const void  **ppbPublicKey, 
        [out] ULONG       *pcbPublicKey,
        [out] ULONG       *pulHashAlgId,
        [out] LPWSTR      szName,
        [out] ULONG       cchName,
        [out] ULONG       *pchName,
        [out] ASSEMBLYMETADATA *pMetaData,
        [out] DWORD       *pdwAssemblyFlags
    );
        
    HRESULT GetAssemblyRefProps (
        [in]  mdAssemblyRef mdar, 
        [in]  const void  **ppbPublicKeyOrToken, 
          [out] ULONG       *pcbPublicKeyOrToken, 
        [out] LPWSTR      szName, 
        [in]  ULONG       cchName, 
        [out] ULONG       *pchName, 
        [out] ASSEMBLYMETADATA *pMetaData, 
        [out] const void  **ppbHashValue, 
        [out] ULONG       *pcbHashValue, 
        [out] DWORD       *pdwAssemblyRefFlags
    );
        
    HRESULT GetExportedTypeProps (
        [in]  mdExportedType   mdct, 
        [out] LPWSTR      szName, 
        [in]  ULONG       cchName, 
        [out] ULONG       *pchName, 
        [out] mdToken     *ptkImplementation, 
        [out] mdTypeDef   *ptkTypeDef, 
        [out] DWORD       *pdwExportedTypeFlags
    );
        
    HRESULT GetFileProps (
        [in]  mdFile      mdf, 
        [out] LPWSTR      szName, 
        [in]  ULONG       cchName, 
        [out] ULONG       *pchName, 
        [out] const void  **ppbHashValue, 
        [out] ULONG       *pcbHashValue, 
        [out] DWORD       *pdwFileFlags
    );
        
    HRESULT GetManifestResourceProps (
        [in]  mdManifestResource  mdmr, 
        [out] LPWSTR      szName, 
        [in]  ULONG       cchName, 
        [out] ULONG       *pchName, 
        [out] mdToken     *ptkImplementation, 
        [out] DWORD       *pdwOffset, 
        [out] DWORD       *pdwResourceFlags
    );
        
};

Method Description

IMetaDataAssemblyImport::CloseEnum Method

Releases the handle to the specified enumerator.

IMetaDataAssemblyImport::EnumAssemblyRefs Method

Gets an interface pointer to an enumerator that contains the mdAssemblyRef tokens of the assemblies referenced by the assembly in the current metadata scope.

IMetaDataAssemblyImport::EnumExportedTypes Method

Gets an interface pointer to an enumerator that contains the mdExportedType tokens of the COM types referenced by the assembly in the current metadata scope.

IMetaDataAssemblyImport::EnumFiles Method

Gets an interface pointer to an enumerator that contains the mdFile tokens of the files referenced by the assembly in the current metadata scope.

IMetaDataAssemblyImport::EnumManifestResources Method

Gets an interface pointer to an enumerator that contains the mdManifestResource tokens of the resources referenced by the assembly in the current metadata scope.

IMetaDataAssemblyImport::FindAssembliesByName Method

Gets an array of mdAssemblyRef tokens for the assemblies with the specified name.

IMetaDataAssemblyImport::FindExportedTypeByName Method

Gets an mdExportedType token for the COM type with the specified name.

IMetaDataAssemblyImport::FindManifestResourceByName Method

Gets an mdManifestResource token for the resource with the specified name.

IMetaDataAssemblyImport::GetAssemblyFromScope Method

Gets the token for the assembly in the current metadata scope.

IMetaDataAssemblyImport::GetAssemblyProps Method

Gets the property settings of the specified assembly.

IMetaDataAssemblyImport::GetAssemblyRefProps Method

Gets the property settings of the specified mdAssemblyRef token.

IMetaDataAssemblyImport::GetExportedTypeProps Method

Gets the property settings of the specified COM type.

IMetaDataAssemblyImport::GetFileProps Method

Gets the property settings of the specified file.

IMetaDataAssemblyImport::GetManifestResourceProps Method

Gets the property settings of the specified manifest resource.

Platform: Windows 2000, Windows XP, Windows Server 2003 family

Header: Cor.h

Library: Used as a resource in Mscoree.dll

.NET Framework Version: 2.0, 1.1, 1.0

Community Additions

ADD
Show:
© 2015 Microsoft