Class CilRawMethodBody
- Namespace
- AsmResolver.PE.DotNet.Cil
- Assembly
- AsmResolver.PE.dll
When overridden from this class, represents a chunk of CIL code that implements a method body.
public abstract class CilRawMethodBody : SegmentBase, ISegment, IOffsetProvider, IWritable
- Inheritance
-
CilRawMethodBody
- Implements
- Derived
- Inherited Members
Constructors
CilRawMethodBody(IReadableSegment)
protected CilRawMethodBody(IReadableSegment code)
Parameters
codeIReadableSegment
Properties
Code
Gets or sets the raw bytes that make up the CIL code of the method body.
public IReadableSegment Code { get; set; }
Property Value
IsFat
Gets a value indicating whether the method body is using the fat format.
public abstract bool IsFat { get; }
Property Value
Methods
FromReader(IErrorListener, ref BinaryStreamReader)
Reads a raw method body from the given binary input stream.
public static CilRawMethodBody? FromReader(IErrorListener errorListener, ref BinaryStreamReader reader)
Parameters
errorListenerIErrorListenerThe object responsible for recording parser errors.
readerBinaryStreamReaderThe binary input stream to read from.
Returns
- CilRawMethodBody
The raw method body.
Exceptions
- NotSupportedException
Occurs when the method header indicates an invalid or unsupported method body format.
FromReader(ref BinaryStreamReader)
Reads a raw method body from the given binary input stream.
public static CilRawMethodBody? FromReader(ref BinaryStreamReader reader)
Parameters
readerBinaryStreamReaderThe binary input stream to read from.
Returns
- CilRawMethodBody
The raw method body.
Exceptions
- NotSupportedException
Occurs when the method header indicates an invalid or unsupported method body format.