PERWAPI.PEReader.GetBlobConst C# (CSharp) Méthode

GetBlobConst() private méthode

private GetBlobConst ( int constType ) : Constant
constType int
Résultat Constant
        internal Constant GetBlobConst(int constType)
        {
            uint ix;
            if (md.largeBlob) ix = ReadUInt32();
            else ix = ReadUInt16();
            blob.GoToIndex(ix);
            uint blobSize = blob.ReadCompressedNum();
            if (constType == (int)ElementType.String)
                return new StringConst(blob.ReadBytes((int)blobSize));
            return ReadConst(constType,blob);
        }

Usage Example

Exemple #1
0
 internal ConstantElem(PEReader buff)
 {
     byte constType = buff.ReadByte();
     byte pad = buff.ReadByte();
     parentIx = buff.GetCodedIndex(CIx.HasConstant);
     //valIx = buff.GetBlobIx();
     cValue = buff.GetBlobConst(constType);
     sortTable = true;
     tabIx = MDTable.Constant;
 }