Class RangeByteBuffer
- Namespace
- FellowOakDicom.IO.Buffer
- Assembly
- fo-dicom.core.dll
public class RangeByteBuffer : IByteBuffer
- Inheritance
-
RangeByteBuffer
- Implements
- Inherited Members
- Extension Methods
Constructors
RangeByteBuffer(IByteBuffer, long, int)
public RangeByteBuffer(IByteBuffer buffer, long offset, int length)
Parameters
buffer
IByteBufferoffset
longlength
int
RangeByteBuffer(IByteBuffer, long, int, IMemoryProvider)
public RangeByteBuffer(IByteBuffer buffer, long offset, int length, IMemoryProvider memoryProvider)
Parameters
buffer
IByteBufferoffset
longlength
intmemoryProvider
IMemoryProvider
Properties
Data
Gets the data.
public byte[] Data { get; }
Property Value
- byte[]
Internal
public IByteBuffer Internal { get; }
Property Value
IsMemory
Gets whether data is buffered in memory or not.
public bool IsMemory { get; }
Property Value
Length
public int Length { get; }
Property Value
Offset
public long Offset { get; }
Property Value
Size
Gets the size of the buffered data.
public long Size { get; }
Property Value
Methods
CopyToStream(Stream)
Copies the contents of this buffer to the provided stream
public void CopyToStream(Stream stream)
Parameters
stream
StreamA stream that will receive the contents of this buffer
CopyToStreamAsync(Stream, CancellationToken)
Copies the contents of this buffer to the provided stream
public Task CopyToStreamAsync(Stream stream, CancellationToken cancellationToken)
Parameters
stream
StreamA stream that will receive the contents of this buffer
cancellationToken
CancellationTokenA cancellation token that halts the execution of the copy operation
Returns
GetByteRange(long, int, byte[])
Gets a subset of the data and fills it in the provided output buffer
public void GetByteRange(long offset, int count, byte[] output)