示例#1
0
        /*-------------------- Constructors ---------------------------------*/

        internal ModuleRef(string name, bool entryPoint, byte[] hashValue)
            : base(name)
        {
            modFile    = new ModuleFile(name, hashValue, entryPoint);
            ismscorlib = name.ToLower() == "mscorlib.dll";
            tabIx      = MDTable.ModuleRef;
        }
示例#2
0
 internal sealed override void Resolve(PEReader buff)
 {
     modFile = buff.GetFileDesc(name);
     if (modFile != null)
     {
         modFile.fileModule = this;
     }
 }
示例#3
0
 internal static void Read(PEReader buff, TableRow[] files)
 {
     for (int i = 0; i < files.Length; i++)
     {
         uint flags = buff.ReadUInt32();
         if (flags == HasMetaData)
             files[i] = new ModuleFile(buff.GetString(), buff.GetBlob());
         else
             files[i] = new ResourceFile(buff.GetString(), buff.GetBlob());
     }
 }
示例#4
0
 internal sealed override void BuildTables(MetaDataOut md)
 {
     md.AddToTable(MDTable.ExportedType, this);
     nameSpaceIx = md.AddToStringsHeap(NameSpace);
     nameIx      = md.AddToStringsHeap(Name);
     if (implementation is ModuleRef)
     {
         ModuleFile mFile = ((ModuleRef)implementation).modFile;
         mFile.BuildMDTables(md);
         implementation = mFile;
     }
 }
示例#5
0
 internal static void Read(PEReader buff, TableRow[] files)
 {
     for (int i = 0; i < files.Length; i++)
     {
         uint flags = buff.ReadUInt32();
         if (flags == HasMetaData)
         {
             files[i] = new ModuleFile(buff.GetString(), buff.GetBlob());
         }
         else
         {
             files[i] = new ResourceFile(buff.GetString(), buff.GetBlob());
         }
     }
 }
示例#6
0
 internal override sealed void Resolve(PEReader buff)
 {
     modFile = buff.GetFileDesc(name);
     if (modFile != null)
         modFile.fileModule = this;
 }
示例#7
0
 internal ModuleRef(ModuleFile file)
     : base(file.Name())
 {
     modFile = file;
     tabIx = MDTable.ModuleRef;
 }
示例#8
0
 /*-------------------- Constructors ---------------------------------*/
 internal ModuleRef(string name, bool entryPoint, byte[] hashValue)
     : base(name)
 {
     modFile = new ModuleFile(name, hashValue, entryPoint);
     ismscorlib = name.ToLower() == "mscorlib.dll";
     tabIx = MDTable.ModuleRef;
 }
示例#9
0
 internal ModuleRef(ModuleFile file)
     : base(file.Name())
 {
     modFile = file;
     tabIx   = MDTable.ModuleRef;
 }