runtime

package
v0.0.0-...-e980239 Latest Latest
Warning

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

Go to latest
Published: May 14, 2022 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppRuntime

type AppRuntime struct {
	sync.Mutex
	AppHome        string
	Cfg            *config.Config
	App            *tview.Application
	Root           *tview.Pages
	PaneController *pane.Controller
	// contains filtered or unexported fields
}

func New

func New(appHome string, title string, debug bool) (*AppRuntime, error)

New Create new AppRuntime

func (*AppRuntime) ActivateNextTeam

func (c *AppRuntime) ActivateNextTeam()

func (*AppRuntime) ActivateTeam

func (c *AppRuntime) ActivateTeam(idx int)

func (*AppRuntime) AddPane

func (c *AppRuntime) AddPane(teamId, conversationId string, show bool)

func (*AppRuntime) AddTicker

func (c *AppRuntime) AddTicker(th TickHandler)

func (*AppRuntime) ConnectTeam

func (c *AppRuntime) ConnectTeam(name string)

Connect to a team, and store connection i list of connected teams

func (*AppRuntime) Debug

func (c *AppRuntime) Debug(message string)

func (*AppRuntime) Debugf

func (c *AppRuntime) Debugf(format string, args ...interface{})

func (*AppRuntime) GetActiveTeam

func (c *AppRuntime) GetActiveTeam() *connection.Connection

func (*AppRuntime) GetTeam

func (c *AppRuntime) GetTeam(teamId string) *connection.Connection

func (*AppRuntime) RemovePane

func (c *AppRuntime) RemovePane(p *pane.Pane)

func (*AppRuntime) Run

func (c *AppRuntime) Run() error

func (*AppRuntime) Stop

func (c *AppRuntime) Stop()

func (*AppRuntime) TeamCount

func (c *AppRuntime) TeamCount() int

type Command

type Command interface {
	Execute(ctx *AppRuntime)
}

func NewCommand

func NewCommand(s string, source *pane.Pane) (Command, error)

type DateChangeLogger

type DateChangeLogger struct {
	// contains filtered or unexported fields
}

func (*DateChangeLogger) OnTick

func (t *DateChangeLogger) OnTick(tick time.Time, tickSize time.Duration, ctx *AppRuntime)

type StatusPaneTimeUpdater

type StatusPaneTimeUpdater struct {
	// contains filtered or unexported fields
}

func (*StatusPaneTimeUpdater) OnTick

func (t *StatusPaneTimeUpdater) OnTick(tick time.Time, tickSize time.Duration, ctx *AppRuntime)

type TickHandler

type TickHandler interface {
	OnTick(tick time.Time, tickSize time.Duration, ctx *AppRuntime)
}

Jump to

Keyboard shortcuts

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