pod

package
v0.0.0-...-2f5b9ad Latest Latest
Warning

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

Go to latest
Published: Nov 11, 2023 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindPod

func FindPod(items []list.Item, search Item) int

func New

func New() list.Model

func Route

func Route(cmds ...tea.Cmd) []tea.Cmd

Types

type AddedPodMsg

type AddedPodMsg struct {
	Pod Item
}

type ErrorMsg

type ErrorMsg struct {
	Err error
}

type Item

type Item struct {
	K8sPod             v1.Pod
	ExtendedProperties []Property
}

func LoadExtensions

func LoadExtensions(extensions []api.IPodExtension, res []v1.Pod) []Item

func (Item) FilterValue

func (n Item) FilterValue() string

func (*Item) LoadCustomProperties

func (n *Item) LoadCustomProperties(properties ...api.IPodExtension)

type ItemDelegate

type ItemDelegate struct {
	IsFocused bool
}

func (ItemDelegate) Height

func (n ItemDelegate) Height() int

func (ItemDelegate) Render

func (n ItemDelegate) Render(w io.Writer, l list.Model, index int, listItem list.Item)

func (ItemDelegate) Spacing

func (n ItemDelegate) Spacing() int

func (ItemDelegate) Update

func (n ItemDelegate) Update(_ tea.Msg, m *list.Model) tea.Cmd

type ListMsg

type ListMsg struct {
	Pods            []Item
	ResourceVersion string
}

type Message

type Message interface {
	// contains filtered or unexported methods
}

type MessageHandler

type MessageHandler struct {
	Extensions                   []api.IPodExtension
	AvailableNamespaceOperations []api.INamespaceOperation
	// contains filtered or unexported fields
}

func NewHandler

func NewHandler(service k8mpasskube.IPodService, extensions []api.IPodExtension, ops []api.INamespaceOperation) *MessageHandler

func (*MessageHandler) CheckConditionsThatApply

func (handler *MessageHandler) CheckConditionsThatApply(namespace string) tea.Cmd

func (*MessageHandler) GetPods

func (handler *MessageHandler) GetPods(namespace string) tea.Cmd

func (*MessageHandler) NextEvent

func (handler *MessageHandler) NextEvent() tea.Msg

func (*MessageHandler) RunComand

func (handler *MessageHandler) RunComand(command api.INamespaceOperation, namespace string) tea.Cmd

func (*MessageHandler) StopWatching

func (handler *MessageHandler) StopWatching()

func (*MessageHandler) WatchPods

func (handler *MessageHandler) WatchPods(ctx context.Context, resourceVersion string, namespace string) tea.Cmd

type ModifiedPodMsg

type ModifiedPodMsg struct {
	Pod Item
}

type NextEventMsg

type NextEventMsg struct{}

type Property

type Property struct {
	Key   string
	Value string
	Order int
}

type RemovedPodMsg

type RemovedPodMsg struct {
	Pod Item
}

type RoutedMsg

type RoutedMsg struct {
	Embedded tea.Msg
}

type WatchingPodsMsg

type WatchingPodsMsg struct{}

Jump to

Keyboard shortcuts

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