# < Summary

Information

Class: | Renci.SshNet.Channels.ServerChannel
Assembly: | Renci.SshNet
File(s): | \home\appveyor\projects\ssh-net\src\Renci.SshNet\Channels\ServerChannel.cs

Line coverage
100%

Covered lines: | 8
Uncovered lines: | 0
Coverable lines: | 8
Total lines: | 39
Line coverage: | 100%

Branch coverage
N/A

Covered branches: | 0
Total branches: | 0
Branch coverage: | N/A

Method coverage

Feature is only available for sponsors

Upgrade to PRO version

# Metrics

Method | Branch coverage | Cyclomatic complexity | Line coverage
--- | --- | --- | ---
.ctor(...) | 100% | 1 | 100%
SendMessage(...) | 100% | 1 | 100%

# File(s)

## \home\appveyor\projects\ssh-net\src\Renci.SshNet\Channels\ServerChannel.cs

| # | Line |  | Line coverage
--- | --- | --- | --- | ---
|  | `1` |  | `using Renci.SshNet.Messages.Connection;`
|  | `2` |  | ``
|  | `3` |  | `namespace Renci.SshNet.Channels`
|  | `4` |  | `{`
|  | `5` |  | `internal abstract class ServerChannel : Channel`
|  | `6` |  | `{`
|  | `7` |  | `/// <summary>`
|  | `8` |  | `/// Initializes a new instance of the <see cref="ServerChannel"/> class.`
|  | `9` |  | `/// </summary>`
|  | `10` |  | `/// <param name="session">The session.</param>`
|  | `11` |  | `/// <param name="localChannelNumber">The local channel number.</param>`
|  | `12` |  | `/// <param name="localWindowSize">Size of the window.</param>`
|  | `13` |  | `/// <param name="localPacketSize">Size of the packet.</param>`
|  | `14` |  | `/// <param name="remoteChannelNumber">The remote channel number.</param>`
|  | `15` |  | `/// <param name="remoteWindowSize">The window size of the remote party.</param>`
|  | `16` |  | `/// <param name="remotePacketSize">The maximum size of a data packet that we can send to the remote party.</para`
|  | `17` |  | `protected ServerChannel(ISession session,`
|  | `18` |  | `uint localChannelNumber,`
|  | `19` |  | `uint localWindowSize,`
|  | `20` |  | `uint localPacketSize,`
|  | `21` |  | `uint remoteChannelNumber,`
|  | `22` |  | `uint remoteWindowSize,`
|  | `23` |  | `uint remotePacketSize)`
| 17 | `24` |  | `: base(session, localChannelNumber, localWindowSize, localPacketSize)`
| 17 | `25` |  | `{`
| 17 | `26` |  | `InitializeRemoteInfo(remoteChannelNumber, remoteWindowSize, remotePacketSize);`
| 17 | `27` |  | `}`
|  | `28` |  | ``
|  | `29` |  | `protected void SendMessage(ChannelOpenConfirmationMessage message)`
| 17 | `30` |  | `{`
|  | `31` |  | `// No need to check whether channel is open when trying to open a channel`
| 17 | `32` |  | `Session.SendMessage(message);`
|  | `33` |  | ``
|  | `34` |  | `// When we act as server, consider the channel open when we've sent the`
|  | `35` |  | `// confirmation message to the peer`
| 17 | `36` |  | `IsOpen = true;`
| 17 | `37` |  | `}`
|  | `38` |  | `}`
|  | `39` |  | `}`

# Methods/Properties

.ctor(Renci.SshNet.ISession,System.UInt32,System.UInt32,System.UInt32,System.UInt32,System.UInt32,System.UInt32)
SendMessage(Renci.SshNet.Messages.Connection.ChannelOpenConfirmationMessage)