Diffusion .NET Client Library  6.1.5
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events Pages
PushTechnology.ClientInterface.Data.IBytes Interface Reference

The read-only interface for values that are internally represented as binary data. More...

Inheritance diagram for PushTechnology.ClientInterface.Data.IBytes:
PushTechnology.ClientInterface.Client.Content.IContent PushTechnology.ClientInterface.Data.Binary.IBinary PushTechnology.ClientInterface.Data.JSON.IJSON PushTechnology.ClientInterface.Data.Record.IRecordV2

Public Member Functions

Stream AsInputStream ()
 Returns the data as a read-only stream. More...
 
byte[] ToByteArray ()
 Returns a copy of the data as a byte array. More...
 
void CopyTo (Stream outputStream)
 Writes the data to an output stream. More...
 

Properties

int Length [get]
 Returns the length of the data in bytes. More...
 

Detailed Description

The 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.

Since: 5.8

Member Function Documentation

Stream PushTechnology.ClientInterface.Data.IBytes.AsInputStream ( )

Returns the data as a read-only stream.

Returns
The read-only stream.
void PushTechnology.ClientInterface.Data.IBytes.CopyTo ( Stream  outputStream)

Writes the data to an output stream.

Parameters
outputStreamThe target output stream.

This method avoids the allocation and copying costs of producing an intermediate byte array via ToByteArray().

Exceptions
ArgumentNullExceptionoutputStream is null.
IOExceptionAn I/O error occurs.
NotSupportedExceptionThe outputStream stream does not support writing, or the stream is already closed.
ObjectDisposedExceptionMethods were called after the outputStream stream was closed.
byte [] PushTechnology.ClientInterface.Data.IBytes.ToByteArray ( )

Returns a copy of the data as a byte array.

Returns
The copy of the binary data.

Property Documentation

int PushTechnology.ClientInterface.Data.IBytes.Length
get

Returns the length of the data in bytes.


The documentation for this interface was generated from the following file: