Skip to content

Interface IMinecraftBuffer<TBuffer>

Namespace: Void.Minecraft.Buffers
Assembly: Void.Minecraft.dll

Defines a readable and writable Minecraft buffer that can create typed slices.

public interface IMinecraftBuffer<TBuffer> : IReadMinecraftBuffer, IWriteMinecraftBuffer, ICommonMinecraftBuffer where TBuffer : struct, allows ref struct

Type Parameters

TBuffer

The concrete buffer type returned by slicing.

Implements

IReadMinecraftBuffer, IWriteMinecraftBuffer, ICommonMinecraftBuffer

Methods

Slice(int, int)

Extracts a portion of a buffer starting from a specified position for a given length.

TBuffer Slice(int position, int length)

Parameters

position int

Indicates the starting point from which the extraction begins.

length int

Specifies the number of elements to include in the extracted portion.

Returns

TBuffer

Returns a new buffer containing the specified slice of the original buffer.