Show / Hide Table of Contents

    Class DataReader

    Inheritance
    Object
    MarshalByRefObject
    DataReader
    Implements
    IDisposable
    IDataReader
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Windows.Storage.Streams
    Assembly: Windows.Storage.Streams.dll
    Syntax
    public sealed class DataReader : MarshalByRefObject, IDisposable, IDataReader

    Constructors

    | Improve this Doc View Source

    DataReader(IInputStream)

    Creates and initializes a new instance of the data reader.

    Declaration
    public DataReader(IInputStream inputStream)
    Parameters
    Type Name Description
    IInputStream inputStream

    The input stream.

    Properties

    | Improve this Doc View Source

    ByteOrder

    Gets or sets the byte order of the data in the input stream.

    Declaration
    public ByteOrder ByteOrder { get; }
    Property Value
    Type Description
    ByteOrder

    One of the enumeration values.

    Remarks

    nanoFramework doesn't this feature. ByteOrder is always LittleEndian.

    | Improve this Doc View Source

    InputStreamOptions

    Gets or sets the read options for the input stream.

    Declaration
    public InputStreamOptions InputStreamOptions { get; set; }
    Property Value
    Type Description
    InputStreamOptions

    One of the enumeration values.

    | Improve this Doc View Source

    UnconsumedBufferLength

    Gets the size of the buffer that has not been read.

    Declaration
    public uint UnconsumedBufferLength { get; }
    Property Value
    Type Description
    UInt32

    The size of the buffer that has not been read, in bytes.

    | Improve this Doc View Source

    UnicodeEncoding

    Gets or sets the Unicode character encoding for the input stream.

    Declaration
    public UnicodeEncoding UnicodeEncoding { get; }
    Property Value
    Type Description
    UnicodeEncoding

    One of the enumeration values.

    Remarks

    nanoFramework doesn't this feature. UnicodeEncoding is always Utf8.

    Methods

    | Improve this Doc View Source

    DetachStream()

    Detaches a stream that was previously attached to the reader.

    Declaration
    public IInputStream DetachStream()
    Returns
    Type Description
    IInputStream

    The detached stream.

    | Improve this Doc View Source

    Dispose()

    Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

    Declaration
    public void Dispose()
    | Improve this Doc View Source

    FromBuffer(IBuffer)

    Creates a new instance of the data reader with data from the specified buffer.

    Declaration
    public static DataReader FromBuffer(IBuffer buffer)
    Parameters
    Type Name Description
    IBuffer buffer

    The buffer.

    Returns
    Type Description
    DataReader

    The data reader.

    | Improve this Doc View Source

    Load(UInt32)

    Loads data from the input stream.

    Declaration
    public uint Load(uint count)
    Parameters
    Type Name Description
    UInt32 count

    The count of bytes to load into the intermediate buffer.

    Returns
    Type Description
    UInt32

    The operation.

    | Improve this Doc View Source

    ReadBoolean()

    Reads a Boolean value from the input stream.

    Declaration
    public bool ReadBoolean()
    Returns
    Type Description
    Boolean

    The value.

    | Improve this Doc View Source

    ReadBuffer(UInt32)

    Reads a buffer from the input stream.

    Declaration
    public IBuffer ReadBuffer(uint length)
    Parameters
    Type Name Description
    UInt32 length

    The length of the buffer, in bytes.

    Returns
    Type Description
    IBuffer

    The buffer.

    | Improve this Doc View Source

    ReadByte()

    Reads a byte value from the input stream.

    Declaration
    public byte ReadByte()
    Returns
    Type Description
    Byte

    The value.

    | Improve this Doc View Source

    ReadBytes(Byte[])

    Reads an array of byte values from the input stream.

    Declaration
    public void ReadBytes(byte[] value)
    Parameters
    Type Name Description
    Byte[] value

    The array of values.

    | Improve this Doc View Source

    ReadDateTime()

    Reads a date and time value from the input stream.

    Declaration
    public DateTime ReadDateTime()
    Returns
    Type Description
    DateTime

    The value.

    | Improve this Doc View Source

    ReadDouble()

    Reads a floating-point value from the input stream.

    Declaration
    public double ReadDouble()
    Returns
    Type Description
    Double

    The value.

    | Improve this Doc View Source

    ReadGuid()

    Reads a GUID value from the input stream.

    Declaration
    public Guid ReadGuid()
    Returns
    Type Description
    Guid

    The value.

    | Improve this Doc View Source

    ReadInt16()

    Reads a 16-bit integer value from the input stream.

    Declaration
    public short ReadInt16()
    Returns
    Type Description
    Int16

    The value.

    | Improve this Doc View Source

    ReadInt32()

    Reads a 32-bit integer value from the input stream.

    Declaration
    public int ReadInt32()
    Returns
    Type Description
    Int32

    The value.

    | Improve this Doc View Source

    ReadInt64()

    Reads a 64-bit integer value from the input stream.

    Declaration
    public long ReadInt64()
    Returns
    Type Description
    Int64

    The value.

    | Improve this Doc View Source

    ReadSingle()

    Reads a floating-point value from the input stream.

    Declaration
    public float ReadSingle()
    Returns
    Type Description
    Single

    The value.

    | Improve this Doc View Source

    ReadString(UInt32)

    Reads a string value from the input stream.

    Declaration
    public string ReadString(uint codeUnitCount)
    Parameters
    Type Name Description
    UInt32 codeUnitCount

    The length of the string.

    Returns
    Type Description
    String

    The value.

    | Improve this Doc View Source

    ReadTimeSpan()

    Reads a time interval from the input stream.

    Declaration
    public TimeSpan ReadTimeSpan()
    Returns
    Type Description
    TimeSpan

    The value.

    | Improve this Doc View Source

    ReadUInt16()

    Reads a 16-bit unsigned integer from the input stream.

    Declaration
    public ushort ReadUInt16()
    Returns
    Type Description
    UInt16

    The value.

    | Improve this Doc View Source

    ReadUInt32()

    Reads a 32-bit unsigned integer from the input stream.

    Declaration
    public uint ReadUInt32()
    Returns
    Type Description
    UInt32

    The value.

    | Improve this Doc View Source

    ReadUInt64()

    Reads a 64-bit unsigned integer from the input stream.

    Declaration
    public ulong ReadUInt64()
    Returns
    Type Description
    UInt64

    The value.

    Implements

    IDisposable
    IDataReader

    Extension Methods

    LogDispatcher.GetCurrentClassLogger(Object)
    • Improve this Doc
    • View Source
    Back to top Copyright © 2018 nanoFramework Contributors
    Generated by DocFX