Diffusion .NET API
5.9.24
|
Represents a read-only interface for values that are internally represented as binary data. More...
Public Member Functions | |
Stream | AsInputStream () |
Returns a stream that provides the data. More... | |
byte[] | ToByteArray () |
Returns a copy of the data as a byte array. More... | |
void | CopyTo (Stream outputStream) |
Writes the bytes to an output stream. More... | |
Properties | |
int | Length [get] |
Returns the length of the data in bytes. More... | |
Represents a read-only interface for values that are internally represented as binary data.
This interface provides access to copies of the binary data, making instances effectively immutable. Methods of derived interfaces and classes that relax this restriction and expose access to the internal data should be clearly documented.
Since: 5.7
Stream PushTechnology.ClientInterface.Data.IBytes.AsInputStream | ( | ) |
Returns a stream that provides the data.
void PushTechnology.ClientInterface.Data.IBytes.CopyTo | ( | Stream | outputStream | ) |
Writes the bytes to an output stream.
outputStream | The target output stream. |
This method avoids the allocation and copying costs of producing an intermediate byte array via ToByteArray().
ArgumentNullException | The target output stream is null. |
IOException | Writing to the target output stream failed. |
byte [] PushTechnology.ClientInterface.Data.IBytes.ToByteArray | ( | ) |
Returns a copy of the data as a byte array.
|
get |
Returns the length of the data in bytes.