IDataStreamFactory

Description

interface Tinman.Core.IO.Streams.IDataStreamFactory

Extended by

IFileOps

Base interface for classes that can produce IDataStream objects.

Public / Methods

To​Data​Stream


[OwnerReturn] [OwnerThis]
public method ToDataStream → (2)

bufferSize opt : int32 = 0

[>=0]
The buffer size to use, in bytes. Set to 0 to use the default buffer size.

needLength opt : bool = false

Shall the returned data stream report a proper length with its IDataStream.Length property? If set to false, the stream may still report a proper length (for example, if doing so would not incur any significant overhead, see IFile.IsLocal). This parameter should be set to true only if the calling code actually requires proper length values (for example, to read a data block at the end of a file) and should be left false when length values are nice-to-have only (for example, to compute a progress value for some background operation).

returns → IDataStream

The data stream.

Creates a IDataStream object for accessing the data of this object.