kafui

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 18, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Contains

func Contains[T comparable](s []T, e T) bool

https://stackoverflow.com/a/70802740

func CreateMainPage

func CreateMainPage(dataSource api.KafkaDataSource, pages *tview.Pages, app *tview.Application, modal *tview.Modal, msgChannel chan UIEvent) *tview.Flex

func CreateSearchInput

func CreateSearchInput(table *tview.Table, dataSource api.KafkaDataSource, pages *tview.Pages, app *tview.Application, modal *tview.Modal) *tview.InputField

func CreateTopicPage added in v0.1.1

func CreateTopicPage(dataSource api.KafkaDataSource, pages *tview.Pages, app *tview.Application, msgChannel chan UIEvent) *tview.Flex

func Init

func Init(useMock bool)

func OpenUI

func OpenUI(dataSource api.KafkaDataSource)

func ReportConsumption added in v0.1.1

func ReportConsumption(message string, textView *tview.TextView)

func SetupTableInput

func SetupTableInput(table *tview.Table, app *tview.Application, pages *tview.Pages, dataSource api.KafkaDataSource, msgChannel chan UIEvent)

func ShowNotification

func ShowNotification(message string)

Types

type ResouceName

type ResouceName []string // array because it can have multiple names
var (
	Context       ResouceName = []string{"context", "ctx", "kafka", "broker"}
	Topic         ResouceName = []string{"topics", "ts"}
	ConsumerGroup ResouceName = []string{"consumergroups", "groups", "consumers", "cgs"}
)

type SearchMode

type SearchMode string
const (
	TableSearch   SearchMode = "TableSearch"
	ResouceSearch SearchMode = "ResouceSearch"
)

type UIEvent

type UIEvent string
const (
	OnModalClose       UIEvent = "ModalClose"
	OnFocusSearch      UIEvent = "FocusSearch"
	OnStartTableSearch UIEvent = "OnStartTableSearch"
	OnPageChange       UIEvent = "PageChange"
)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL