Show / Hide Table of Contents

# Class MessageReader

##### Inheritance

System.Object
MessageReader

##### Inherited Members

System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()

###### Namespace:Microsoft.SqlTools.ServiceLayer.Hosting.Protocol

###### Assembly:Microsoft.SqlTools.ServiceLayer.dll

##### Syntax

    public class MessageReader

### Constructors

| Improve this Doc View Source

#### MessageReader(Stream, IMessageSerializer, Encoding)

##### Declaration

    public MessageReader(Stream inputStream, IMessageSerializer messageSerializer, Encoding messageEncoding = null)

##### Parameters

Type | Name | Description
--- | --- | ---
System.IO.Stream | inputStream |
IMessageSerializer | messageSerializer |
System.Text.Encoding | messageEncoding |

### Fields

| Improve this Doc View Source

#### BufferResizeTrigger

##### Declaration

    public const double BufferResizeTrigger = 0.25

##### Field Value

Type | Description
--- | ---
System.Double |

| Improve this Doc View Source

#### DefaultBufferSize

##### Declaration

    public const int DefaultBufferSize = 8192

##### Field Value

Type | Description
--- | ---
System.Int32 |

### Methods

| Improve this Doc View Source

#### ReadMessage()

##### Declaration

    public Task<Message> ReadMessage()

##### Returns

Type | Description
--- | ---
System.Threading.Tasks.Task<Message> |