class Kafka::TopicPartitionList

Overview

A growable list of Topic+Partitions.

Defined in:

kafka/topic_partition_list.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(rkparlist : LibKafka::TopicPartitionListT) #

[View source]
def self.new(size) #

Create a new list/vector Topic+Partition container.


[View source]

Instance Method Detail

def add(topic : String, partition : Int32) #

Add topic+partition to list.


[View source]
def add_range(topic : String, start : Int32, stop : Int32) #

Add range of partitions from start to stop inclusive.


[View source]
def copy : TopicPartitionList #

Make a copy of an existing list.


[View source]
def del(topic : String, partition : Int32) #

Delete partition from list.


[View source]
def del_by_idx(idx : LibC::Int) #

Delete partition from list.


[View source]
def destroy #

Free all resources used by the list and the list itself.


[View source]
def to_unsafe : LibKafka::TopicPartitionListT | Pointer(LibKafka::TopicPartitionListT) #

[View source]
def topic_partition_list_find(topic : String, partition : Int32) #

Find element by topic and partition.


[View source]
def topic_partition_list_set_offset(topic : String, partition : Int32, offset : Int64) #

Set offset for topic and partition.


[View source]