Exemplo n.º 1
0
        public object GetMetaDataInterface(Guid interfaceGuid)
        {
            IMetadataImport obj;

            m_module.GetMetaDataInterface(ref interfaceGuid, out obj);
            return(obj);
        }
Exemplo n.º 2
0
        public MetaDataImport(ICorDebugModule pModule)
        {
            Guid guid = new Guid("{ 0x7dac8207, 0xd3ae, 0x4c75, { 0x9b, 0x67, 0x92, 0x80, 0x1a, 0x49, 0x7d, 0x44 } }");

            metaData = (IMetaDataImport)pModule.GetMetaDataInterface(ref guid);
            TrackedComObjects.Track(metaData);
        }
Exemplo n.º 3
0
        public MetaData(ICorDebugModule pModule)
        {
            Guid guid = new Guid("{ 0x7dac8207, 0xd3ae, 0x4c75, { 0x9b, 0x67, 0x92, 0x80, 0x1a, 0x49, 0x7d, 0x44 } }");

            metaData = (IMetaDataImport)pModule.GetMetaDataInterface(ref guid);
            ResourceManager.TrackCOMObject(metaData, typeof(IMetaDataImport));
        }
Exemplo n.º 4
0
        public DebugMetadataImporter(ICorDebugModule module)
        {
            _module = module;

            Guid interfaceGuid = typeof(IMetadataImport).GUID;
            _module.GetMetaDataInterface(ref interfaceGuid, out _metadatImport);
        }
Exemplo n.º 5
0
        /// <summary>
        /// Returns a requested metadata interface instance.
        /// </summary>
        /// <typeparam name="T">Metadata interface</typeparam>
        /// <returns>Metadata interface instance</returns>
        public T GetMetadataInterface <T>()
        {
            Object res;
            Guid   guid = typeof(T).GUID;

            comodule.GetMetaDataInterface(ref guid, out res);
            return((T)res);
        }
Exemplo n.º 6
0
        /// <summary>
        /// Typesafe wrapper around GetMetaDataInterface.
        /// </summary>
        /// <typeparam name="T">type of interface to query for</typeparam>
        /// <returns>interface to the metadata</returns>
        public T GetMetaDataInterface <T>()
        {
            // Ideally, this would be declared as Object to match the unmanaged
            // CorDebug.idl definition; but the managed wrappers we build
            // on import it as an IMetadataImport, so we need to start with
            // that.
            IMetadataImport obj;
            Guid            interfaceGuid = typeof(T).GUID;

            m_module.GetMetaDataInterface(ref interfaceGuid, out obj);
            return((T)obj);
        }
 public MetaModule(ICorDebugModule module)
 {
     m_module = new CorModule(module);
     Guid interfaceGuid = typeof(IMetadataImport).GUID;
     module.GetMetaDataInterface(ref interfaceGuid, out m_importer);
 }