Class TopicPartitionError
Represents a Kafka (topic, partition, error) tuple.
Inheritance
Inherited Members
Namespace: Confluent.Kafka
Assembly: cs.temp.dll.dll
Syntax
public class TopicPartitionError
Constructors
TopicPartitionError(TopicPartition, Error)
Initializes a new TopicPartitionError instance.
Declaration
public TopicPartitionError(TopicPartition tp, Error error)
Parameters
Type | Name | Description |
---|---|---|
TopicPartition | tp | Kafka topic name and partition values. |
Error | error | A Kafka error. |
TopicPartitionError(String, Int32, Error)
Initializes a new TopicPartitionError instance.
Declaration
public TopicPartitionError(string topic, int partition, Error error)
Parameters
Type | Name | Description |
---|---|---|
System.String | topic | A Kafka topic name. |
System.Int32 | partition | A Kafka partition value. |
Error | error | A Kafka error. |
Properties
Error
Gets the Kafka error.
Declaration
public Error Error { get; }
Property Value
Type | Description |
---|---|
Error |
Partition
Gets the Kafka partition.
Declaration
public int Partition { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Topic
Gets the Kafka topic name.
Declaration
public string Topic { get; }
Property Value
Type | Description |
---|---|
System.String |
TopicPartition
Gets the TopicPartition component of this TopicPartitionError instance.
Declaration
public TopicPartition TopicPartition { get; }
Property Value
Type | Description |
---|---|
TopicPartition |
Methods
Equals(Object)
Tests whether this TopicPartitionError instance is equal to the specified object.
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj | The object to test. |
Returns
Type | Description |
---|---|
System.Boolean | true if obj is a TopicPartitionError and all properties are equal. false otherwise. |
Overrides
GetHashCode()
Returns a hash code for this TopicPartitionError.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
System.Int32 | An integer that specifies a hash value for this TopicPartitionError. |
Overrides
ToString()
Returns a string representation of the TopicPartitionError object.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
System.String | A string representation of the TopicPartitionError object. |
Overrides
Operators
Equality(TopicPartitionError, TopicPartitionError)
Tests whether TopicPartitionError instance a is equal to TopicPartitionError instance b.
Declaration
public static bool operator ==(TopicPartitionError a, TopicPartitionError b)
Parameters
Type | Name | Description |
---|---|---|
TopicPartitionError | a | The first TopicPartitionError instance to compare. |
TopicPartitionError | b | The second TopicPartitionError instance to compare. |
Returns
Type | Description |
---|---|
System.Boolean | true if TopicPartitionError instances a and b are equal. false otherwise. |
Inequality(TopicPartitionError, TopicPartitionError)
Tests whether TopicPartitionError instance a is not equal to TopicPartitionError instance b.
Declaration
public static bool operator !=(TopicPartitionError a, TopicPartitionError b)
Parameters
Type | Name | Description |
---|---|---|
TopicPartitionError | a | The first TopicPartitionError instance to compare. |
TopicPartitionError | b | The second TopicPartitionError instance to compare. |
Returns
Type | Description |
---|---|
System.Boolean | true if TopicPartitionError instances a and b are not equal. false otherwise. |