Documentation ¶
Index ¶
- Constants
- type Manager
- func (m *Manager) Error(g *gocui.Gui, message string)
- func (m *Manager) Keybinding(g *gocui.Gui) error
- func (m *Manager) Layout(g *gocui.Gui) error
- func (m *Manager) NewDector(g *gocui.Gui, init string) error
- func (m *Manager) NewFollower(g *gocui.Gui, key string) error
- func (m *Manager) NewInformer(g *gocui.Gui, key string) error
- func (m *Manager) NewRemover(g *gocui.Gui, key string) error
- func (m *Manager) NewSwitcher(g *gocui.Gui) error
- func (m *Manager) ReturnDector(g *gocui.Gui) (string, error)
- func (m *Manager) ReturnFollower(g *gocui.Gui) error
- func (m *Manager) ReturnInformer(g *gocui.Gui) error
- func (m *Manager) ReturnRemover(g *gocui.Gui, delete bool) error
- func (m *Manager) ReturnSwitcher(g *gocui.Gui) (runtime.UseCase, error)
- func (m *Manager) Warn(g *gocui.Gui, message string)
- type ManagerIface
- type Presentor
Constants ¶
const ( // Core is the core view. Core string = "core" // Dector is the dector view. Dector string = "dector" // Switcher is the switcher view. Switcher string = "switcher" // Informer is the informer view. Informer string = "informer" // Follower is th follower view. Follower string = "follower" // Remover is the remover view. Remover string = "remover" // Messenger is the messenger view. Messenger string = "messenger" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager is the manager of UI.
func NewManager ¶
NewManager create a new UI manager. The namespace of the manager is depends on the configuration of the user.
func (*Manager) Error ¶
Error show up the message on the Messenger. It's recommended to use in GUI level such as keybinding and laytout.
func (*Manager) Keybinding ¶
Keybinding keybinding of views in the manager.
func (*Manager) NewFollower ¶
NewFollower create a new view to follow logs of a object.
func (*Manager) NewInformer ¶
NewInformer create a new view to display the information of a object.
func (*Manager) NewRemover ¶
NewRemover switch to the remover and confirm to delete or not.
func (*Manager) NewSwitcher ¶
NewSwitcher create and switch to the Switcher
func (*Manager) ReturnDector ¶
ReturnDector return the result from the dector and back to the Core.
func (*Manager) ReturnFollower ¶
ReturnFollower switch to the Core.
func (*Manager) ReturnInformer ¶
ReturnInformer switch to the Core.
func (*Manager) ReturnRemover ¶
ReturnRemover switch to the Core.
func (*Manager) ReturnSwitcher ¶
ReturnSwitcher return the service from the switcher and back to the Core.
type ManagerIface ¶
type ManagerIface interface { Layout(g *gocui.Gui) error Keybinding(g *gocui.Gui) error // Dector NewDector(g *gocui.Gui, init string) error ReturnDector(g *gocui.Gui) (string error) // Switcher NewSwitcher(g *gocui.Gui) error ReturnSwitcher(g *gocui.Gui) (svc.UseCase, error) // Informer NewInformer(g *gocui.Gui) error ReturnInformer(g *gocui.Gui) error // Follower NewFollower(g *gocui.Gui, key string) error ReturnFollower(g *gocui.Gui) error // Remover NewRemover(g *gocui.Gui, key string) error ReturnRemover(g *gocui.Gui, delete bool) error // Messenger Warn(*gocui.Gui, string) Error(*gocui.Gui, string) }
ManagerIface is the interface of manager.