Class FileByteBuffer
- Namespace
 - FellowOakDicom.IO.Buffer
 
- Assembly
 - fo-dicom.core.dll
 
public sealed class FileByteBuffer : IByteBuffer
  - Inheritance
 - 
      
      FileByteBuffer
 
- Implements
 
- Inherited Members
 
- Extension Methods
 
Constructors
FileByteBuffer(IFileReference, long, long)
public FileByteBuffer(IFileReference file, long position, long length)
  Parameters
fileIFileReferencepositionlonglengthlong
FileByteBuffer(IFileReference, long, long, IMemoryProvider)
public FileByteBuffer(IFileReference file, long position, long length, IMemoryProvider memoryProvider)
  Parameters
fileIFileReferencepositionlonglengthlongmemoryProviderIMemoryProvider
Properties
Data
Gets the data.
public byte[] Data { get; }
  Property Value
- byte[]
 
File
public IFileReference File { get; }
  Property Value
IsMemory
Gets whether data is buffered in memory or not.
public bool IsMemory { get; }
  Property Value
Position
public long Position { 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
streamStreamA 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
streamStreamA stream that will receive the contents of this buffer
cancellationTokenCancellationTokenA 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)