SyslogMessage.Encode Method
Namespace: Rebex.Net
Assembly: Rebex.Syslog.dll (version 8.0.9673)
Encode(SyslogMessageFormat, Encoding)
Encodes the message and returns its raw representation.
Declaration
public byte[] Encode(SyslogMessageFormat format = SyslogMessageFormat.Modern, Encoding encoding = null)
Parameters
| Type | Name | Description |
|---|---|---|
| SyslogMessageFormat | format | The format to be used to serialize the syslog message. |
| Encoding | encoding | The encoding for message part (Text). Default is "iso-8859-1" (Latin-1) encoding. |
Returns
| Type | Description |
|---|---|
| Byte[] |
Encode(SyslogMessageFormat, SyslogTimestampMode, Encoding)
Encodes the message and returns its raw representation.
Declaration
public byte[] Encode(SyslogMessageFormat format, SyslogTimestampMode mode, Encoding encoding = null)
Parameters
| Type | Name | Description |
|---|---|---|
| SyslogMessageFormat | format | The format to be used to serialize the syslog message. |
| SyslogTimestampMode | mode | The mode to be used to serialize the Timestamp when Modern is used. |
| Encoding | encoding | The encoding for message part (Text). Default is "iso-8859-1" (Latin-1) encoding. |
Returns
| Type | Description |
|---|---|
| Byte[] |