Class KafkaProducerRecord<K,V>

java.lang.Object
io.vertx.rxjava3.kafka.client.producer.KafkaProducerRecord<K,V>
All Implemented Interfaces:
io.vertx.lang.rx.RxDelegate

public class KafkaProducerRecord<K,V> extends Object implements io.vertx.lang.rx.RxDelegate
Vert.x Kafka producer record.

NOTE: This class has been automatically generated from the original non RX-ified interface using Vert.x codegen.

  • Field Details

    • __TYPE_ARG

      public static final io.vertx.lang.rx.TypeArg<KafkaProducerRecord> __TYPE_ARG
    • __typeArg_0

      public final io.vertx.lang.rx.TypeArg<K> __typeArg_0
    • __typeArg_1

      public final io.vertx.lang.rx.TypeArg<V> __typeArg_1
  • Constructor Details

    • KafkaProducerRecord

      public KafkaProducerRecord(KafkaProducerRecord delegate)
    • KafkaProducerRecord

      public KafkaProducerRecord(Object delegate, io.vertx.lang.rx.TypeArg<K> typeArg_0, io.vertx.lang.rx.TypeArg<V> typeArg_1)
  • Method Details

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getDelegate

      public KafkaProducerRecord getDelegate()
      Specified by:
      getDelegate in interface io.vertx.lang.rx.RxDelegate
    • create

      public static <K,V> KafkaProducerRecord<K,V> create(String topic, K key, V value, Long timestamp, Integer partition)
      Create a concrete instance of a Vert.x producer record
      Parameters:
      topic - the topic this record is being sent to
      key - the key (or null if no key is specified)
      value - the value
      timestamp - the timestamp of this record
      partition - the partition to which the record will be sent (or null if no partition was specified)
      Returns:
      Vert.x producer record
    • create

      public static <K,V> KafkaProducerRecord<K,V> create(String topic, K key, V value)
      Create a concrete instance of a Vert.x producer record
      Parameters:
      topic - the topic this record is being sent to
      key - the key (or null if no key is specified)
      value - the value
      Returns:
      Vert.x producer record
    • create

      public static <K,V> KafkaProducerRecord<K,V> create(String topic, V value)
      Create a concrete instance of a Vert.x producer record
      Parameters:
      topic - the topic this record is being sent to
      value - the value
      Returns:
      Vert.x producer record
    • topic

      public String topic()
      Returns:
      the topic this record is being sent to
    • key

      public K key()
      Returns:
      the key (or null if no key is specified)
    • value

      public V value()
      Returns:
      the value
    • timestamp

      public Long timestamp()
      Returns:
      the timestamp of this record
    • partition

      public Integer partition()
      Returns:
      the partition to which the record will be sent (or null if no partition was specified)
    • addHeader

      public KafkaProducerRecord<K,V> addHeader(String key, String value)
      Like addHeader(String, String) but with a key/value pair
      Parameters:
      key -
      value -
      Returns:
    • addHeader

      public KafkaProducerRecord<K,V> addHeader(String key, Buffer value)
      Like addHeader(String, String) but with a key/value pair
      Parameters:
      key -
      value -
      Returns:
    • addHeader

      public KafkaProducerRecord<K,V> addHeader(KafkaHeader header)
      Add an header to this record.
      Parameters:
      header - the header
      Returns:
      current KafkaProducerRecord instance
    • addHeaders

      public KafkaProducerRecord<K,V> addHeaders(List<KafkaHeader> headers)
      Add a list of headers to this record.
      Parameters:
      headers - the headers
      Returns:
      current KafkaProducerRecord instance
    • headers

      public List<KafkaHeader> headers()
      Returns:
      the headers of this record
    • newInstance

      public static <K,V> KafkaProducerRecord<K,V> newInstance(KafkaProducerRecord arg)
    • newInstance

      public static <K,V> KafkaProducerRecord<K,V> newInstance(KafkaProducerRecord arg, io.vertx.lang.rx.TypeArg<K> __typeArg_K, io.vertx.lang.rx.TypeArg<V> __typeArg_V)