Documentation
¶
Index ¶
- Constants
- Variables
- type KeyMap
- type Manager
- func (m *Manager) AddWorker(id int, workerType, name, logPath string) *components.ProgressBar
- func (m *Manager) GetWorker(id int) *WorkerInfo
- func (m *Manager) IsRunning() bool
- func (m *Manager) RemoveWorker(id int)
- func (m *Manager) Start() error
- func (m *Manager) Stop()
- func (m *Manager) UpdateWorkerStatus(id int, status string, healthy bool)
- type Model
- type TickMsg
- type ViewType
- type WorkerInfo
Constants ¶
View Source
const ( MinTerminalWidth = 80 LargeWidth = 120 )
View Source
const RefreshInterval = 2 * time.Second
Variables ¶
View Source
var ErrTUIManagerAlreadyRunning = errors.New("TUI manager is already running")
Functions ¶
This section is empty.
Types ¶
type KeyMap ¶
type KeyMap struct {
Quit key.Binding
Help key.Binding
Dashboard key.Binding
Worker key.Binding
NextTab key.Binding
PrevTab key.Binding
ScrollUp key.Binding
ScrollDown key.Binding
PageUp key.Binding
PageDown key.Binding
}
KeyMap defines key bindings for the TUI.
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager manages the TUI interface for multiple workers.
func NewManager ¶
NewManager creates a new TUI manager.
func (*Manager) AddWorker ¶
func (m *Manager) AddWorker(id int, workerType, name, logPath string) *components.ProgressBar
AddWorker adds a new worker to track.
func (*Manager) GetWorker ¶
func (m *Manager) GetWorker(id int) *WorkerInfo
GetWorker gets a worker by ID.
func (*Manager) RemoveWorker ¶
RemoveWorker removes a worker from tracking.
type Model ¶
type Model struct {
// contains filtered or unexported fields
}
Model represents the main TUI model.
func (*Model) AddWorker ¶
func (m *Model) AddWorker(id int, workerType, name, logPath string, bar *components.ProgressBar)
AddWorker adds a new worker to track.
func (*Model) UpdateWorkerStatus ¶
UpdateWorkerStatus updates a worker's status.
type WorkerInfo ¶
type WorkerInfo struct {
ID int
Name string
Type string
LogPath string
Bar *components.ProgressBar
Status string
Healthy bool
LastUpdated time.Time
}
WorkerInfo contains information about a worker.
Click to show internal directories.
Click to hide internal directories.