confluent-kafka-dotnet
Show / Hide Table of Contents

Struct SerializationContext

Context relevant to a serialization or deserialization operation.

Inherited Members
ValueType.Equals(object)
ValueType.GetHashCode()
ValueType.ToString()
object.Equals(object, object)
object.GetType()
object.ReferenceEquals(object, object)
Namespace: Confluent.Kafka
Assembly: Confluent.Kafka.dll
Syntax
public struct SerializationContext

Constructors

SerializationContext(MessageComponentType, string, Headers)

Create a new SerializationContext object instance.

Declaration
public SerializationContext(MessageComponentType component, string topic, Headers headers = null)
Parameters
Type Name Description
MessageComponentType component

The component of the message the serialization operation relates to.

string topic

The topic the data is being written to or read from.

Headers headers

The collection of message headers (or null). Specifying null or an empty list are equivalent. The order of headers is maintained, and duplicate header keys are allowed.

Properties

Component

The component of the message the serialization operation relates to.

Declaration
public readonly MessageComponentType Component { get; }
Property Value
Type Description
MessageComponentType

Empty

The default SerializationContext value (representing no context defined).

Declaration
public static SerializationContext Empty { get; }
Property Value
Type Description
SerializationContext

Headers

The collection of message headers (or null). Specifying null or an empty list are equivalent. The order of headers is maintained, and duplicate header keys are allowed.

Declaration
public readonly Headers Headers { get; }
Property Value
Type Description
Headers

Topic

The topic the data is being written to or read from.

Declaration
public readonly string Topic { get; }
Property Value
Type Description
string
In this article