C# Class Kafka.Client.Messages.Message

Message send to Kafka server
Format: 1 byte "magic" identifier to allow format changes 4 byte CRC32 of the payload N - 5 byte payload
Inheritance: IWritable
Afficher le fichier Open project: precog/kafka Class Usage Examples

Méthodes publiques

Méthode Description
Message ( byte payload ) : System

Initializes a new instance of the Message class.

Initializes the magic number as default and the checksum as null. It will be automatically computed.

Message ( byte payload, CompressionCodecs compressionCodec ) : System

Initializes a new instance of the Message class.

Initializes the checksum as null. It will be automatically computed.

Message ( byte payload, byte checksum ) : System

Initializes a new instance of the Message class.

Initializes with default magic number

Message ( byte payload, byte checksum, CompressionCodecs compressionCodec ) : System

Initializes a new instance of the Message class.

ToString ( ) : string

Try to show the payload as decoded to UTF-8.

WriteTo ( KafkaBinaryWriter writer ) : void

Writes message data using given writer

WriteTo ( MemoryStream output ) : void

Writes message data into given message buffer

Private Methods

Méthode Description
FromMessageBytes ( byte data ) : Message
ParseFrom ( KafkaBinaryReader reader, int size ) : Message
ParseFrom ( byte data ) : Message

Method Details

Message() public méthode

Initializes a new instance of the Message class.
Initializes the magic number as default and the checksum as null. It will be automatically computed.
public Message ( byte payload ) : System
payload byte /// The payload. ///
Résultat System

Message() public méthode

Initializes a new instance of the Message class.
Initializes the checksum as null. It will be automatically computed.
public Message ( byte payload, CompressionCodecs compressionCodec ) : System
payload byte The data for the payload.
compressionCodec CompressionCodecs
Résultat System

Message() public méthode

Initializes a new instance of the Message class.
Initializes with default magic number
public Message ( byte payload, byte checksum ) : System
payload byte /// The payload. ///
checksum byte /// The checksum. ///
Résultat System

Message() public méthode

Initializes a new instance of the Message class.
public Message ( byte payload, byte checksum, CompressionCodecs compressionCodec ) : System
payload byte The data for the payload.
checksum byte The checksum for the payload.
compressionCodec CompressionCodecs
Résultat System

ToString() public méthode

Try to show the payload as decoded to UTF-8.
public ToString ( ) : string
Résultat string

WriteTo() public méthode

Writes message data using given writer
public WriteTo ( KafkaBinaryWriter writer ) : void
writer Kafka.Client.Serialization.KafkaBinaryWriter /// The writer. ///
Résultat void

WriteTo() public méthode

Writes message data into given message buffer
public WriteTo ( MemoryStream output ) : void
output System.IO.MemoryStream /// The output. ///
Résultat void