PeNet.Structures.IMAGE_BASE_RELOCATION.IMAGE_BASE_RELOCATION C# (CSharp) Метод

IMAGE_BASE_RELOCATION() публичный Метод

Create a new IMAGE_BASE_RELOCATION object.
/// If the SizeOfBlock is bigger than the size /// of the Relocation Directory. ///
public IMAGE_BASE_RELOCATION ( byte buff, uint offset, uint relocSize ) : System
buff byte PE binary as byte array.
offset uint Offset to the relocation struct in the binary.
relocSize uint Size of the complete relocation directory.
Результат System
        public IMAGE_BASE_RELOCATION(byte[] buff, uint offset, uint relocSize)
            : base(buff, offset)
        {
            if (SizeOfBlock > relocSize)
                throw new ArgumentOutOfRangeException(nameof(relocSize),
                    "SizeOfBlock cannot be bigger than size of the Relocation Directory.");

            if(SizeOfBlock < 8)
                throw new Exception("SizeOfBlock cannot be smaller than 8.");

            ParseTypeOffsets();
        }