public ByteBuf GetBuffer() { int size; IntPtr dataPtr = GetDefaultDataIntPtr(out size); MemorySegmentByteBuffer byteBuf = WrapMemorySegment(dataPtr, 0 /* filledSize */); return(byteBuf); }
public MemorySegmentByteBuffer WrapMemorySegment(IntPtr dataPtr, int filledSize) { IntPtr memSegPtr = MemorySegment.GetMemSegPtrByDataPtr(dataPtr); MemorySegmentByteBuffer byteBuf = GetByteBufCore(); byteBuf.Attach(memSegPtr); byteBuf.SetWrite(filledSize); return(byteBuf); }
internal void Release(MemorySegmentByteBuffer unmanagedByteBuf) { }