# < Summary

Information

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

Line coverage
36%

Covered lines: | 9
Uncovered lines: | 16
Coverable lines: | 25
Total lines: | 81
Line coverage: | 36%

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
--- | --- | --- | ---
get_IsAlwaysDisplay() | 100% | 1 | 100%
get_Message() | 100% | 1 | 0%
get_Language() | 100% | 1 | 0%
get_BufferCapacity() | 100% | 1 | 0%
LoadData() | 100% | 1 | 100%
SaveData() | 100% | 1 | 0%
Process(...) | 100% | 1 | 100%

# File(s)

## \home\appveyor\projects\ssh-net\src\Renci.SshNet\Messages\Transport\DebugMessage.cs

| # | Line |  | Line coverage
--- | --- | --- | --- | ---
|  | `1` |  | `namespace Renci.SshNet.Messages.Transport`
|  | `2` |  | `{`
|  | `3` |  | `/// <summary>`
|  | `4` |  | `/// Represents SSH_MSG_DEBUG message.`
|  | `5` |  | `/// </summary>`
|  | `6` |  | `[Message("SSH_MSG_DEBUG", 4)]`
|  | `7` |  | `public class DebugMessage : Message`
|  | `8` |  | `{`
|  | `9` |  | `private byte[] _message;`
|  | `10` |  | `private byte[] _language;`
|  | `11` |  | ``
|  | `12` |  | `/// <summary>`
|  | `13` |  | `/// Gets a value indicating whether the message to be always displayed.`
|  | `14` |  | `/// </summary>`
|  | `15` |  | `/// <value>`
|  | `16` |  | `/// <see langword="true"/> if the message always to be displayed; otherwise, <see langword="false"/>.`
|  | `17` |  | `/// </value>`
| 1280 | `18` |  | `public bool IsAlwaysDisplay { get; private set; }`
|  | `19` |  | ``
|  | `20` |  | `/// <summary>`
|  | `21` |  | `/// Gets debug message.`
|  | `22` |  | `/// </summary>`
|  | `23` |  | `public string Message`
|  | `24` |  | `{`
| 0 | `25` |  | `get { return Utf8.GetString(_message, 0, _message.Length); }`
|  | `26` |  | `}`
|  | `27` |  | ``
|  | `28` |  | `/// <summary>`
|  | `29` |  | `/// Gets message language.`
|  | `30` |  | `/// </summary>`
|  | `31` |  | `public string Language`
|  | `32` |  | `{`
| 0 | `33` |  | `get { return Utf8.GetString(_language, 0, _language.Length); }`
|  | `34` |  | `}`
|  | `35` |  | ``
|  | `36` |  | `/// <summary>`
|  | `37` |  | `/// Gets the size of the message in bytes.`
|  | `38` |  | `/// </summary>`
|  | `39` |  | `/// <value>`
|  | `40` |  | `/// The size of the messages in bytes.`
|  | `41` |  | `/// </value>`
|  | `42` |  | `protected override int BufferCapacity`
|  | `43` |  | `{`
|  | `44` |  | `get`
| 0 | `45` |  | `{`
| 0 | `46` |  | `var capacity = base.BufferCapacity;`
| 0 | `47` |  | `capacity += 1; // IsAlwaysDisplay`
| 0 | `48` |  | `capacity += 4; // Message length`
| 0 | `49` |  | `capacity += _message.Length; // Message`
| 0 | `50` |  | `capacity += 4; // Language length`
| 0 | `51` |  | `capacity += _language.Length; // Language`
| 0 | `52` |  | `return capacity;`
| 0 | `53` |  | `}`
|  | `54` |  | `}`
|  | `55` |  | ``
|  | `56` |  | `/// <summary>`
|  | `57` |  | `/// Called when type specific data need to be loaded.`
|  | `58` |  | `/// </summary>`
|  | `59` |  | `protected override void LoadData()`
| 1280 | `60` |  | `{`
| 1280 | `61` |  | `IsAlwaysDisplay = ReadBoolean();`
| 1280 | `62` |  | `_message = ReadBinary();`
| 1280 | `63` |  | `_language = ReadBinary();`
| 1280 | `64` |  | `}`
|  | `65` |  | ``
|  | `66` |  | `/// <summary>`
|  | `67` |  | `/// Called when type specific data need to be saved.`
|  | `68` |  | `/// </summary>`
|  | `69` |  | `protected override void SaveData()`
| 0 | `70` |  | `{`
| 0 | `71` |  | `Write(IsAlwaysDisplay);`
| 0 | `72` |  | `WriteBinaryString(_message);`
| 0 | `73` |  | `WriteBinaryString(_language);`
| 0 | `74` |  | `}`
|  | `75` |  | ``
|  | `76` |  | `internal override void Process(Session session)`
| 1280 | `77` |  | `{`
| 1280 | `78` |  | `session.OnDebugReceived(this);`
| 1280 | `79` |  | `}`
|  | `80` |  | `}`
|  | `81` |  | `}`

# Methods/Properties

get_IsAlwaysDisplay()
get_Message()
get_Language()
get_BufferCapacity()
LoadData()
SaveData()
Process(Renci.SshNet.Session)