output

package
v0.0.0-...-684ac28 Latest Latest
Warning

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

Go to latest
Published: Jun 7, 2019 License: Apache-2.0 Imports: 32 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FANCYTABLE = "fancytable"
	UP         = "▲"
	DOWN       = "▼"
)
View Source
const (
	JSONAPI = "jsonapi"
)
View Source
const KEYBINDS = `` /* 459-byte string literal not displayed */
View Source
const (
	LOG = "log"
)
View Source
const (
	TILE38 = "tile38"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AircraftByRange

type AircraftByRange []types.AircraftData

func (AircraftByRange) Len

func (P AircraftByRange) Len() int

Len implements Sort interface

func (AircraftByRange) Less

func (P AircraftByRange) Less(i, j int) bool

Less implements Sort interface

func (AircraftByRange) Swap

func (P AircraftByRange) Swap(i, j int)

Swap implements Sort interface

type AircraftBySpeed

type AircraftBySpeed []types.AircraftData

func (AircraftBySpeed) Len

func (P AircraftBySpeed) Len() int

Len implements Sort interface

func (AircraftBySpeed) Less

func (P AircraftBySpeed) Less(i, j int) bool

Less implements Sort interface

func (AircraftBySpeed) Swap

func (P AircraftBySpeed) Swap(i, j int)

Swap implements Sort interface

type AircraftList

type AircraftList []*types.AircraftData

func (AircraftList) Len

func (a AircraftList) Len() int

List utilities

func (AircraftList) Less

func (a AircraftList) Less(i, j int) bool

func (AircraftList) Swap

func (a AircraftList) Swap(i, j int)

type FancyTable

type FancyTable struct {
	*termui.Table

	Beastinfo *config.BeastInfo
	// contains filtered or unexported fields
}

func NewFancyTableOutput

func NewFancyTableOutput(info *config.BeastInfo, group *sync.WaitGroup, done chan<- interface{}) *FancyTable

func (*FancyTable) ChangeSort

func (o *FancyTable) ChangeSort(e ui.Event)

func (*FancyTable) Close

func (o *FancyTable) Close()

func (*FancyTable) FieldsToStrings

func (o *FancyTable) FieldsToStrings(sortedAircraft []types.AircraftData) ([][]string, [][]ui.Style)

FieldsToStrings converts a []Process to a [][]string

func (*FancyTable) Select

func (o *FancyTable) Select()

Select looks up the aircraft info in the registry DB and displays it in the proper cell

func (*FancyTable) Sort

func (o *FancyTable) Sort()

Sort sorts either the grouped or ungrouped []Process based on the sortMethod. Called with every update, when the sort method is changed, and when processes are grouped and ungrouped.

func (*FancyTable) Tab

func (o *FancyTable) Tab()

func (*FancyTable) UpdateDisplay

func (o *FancyTable) UpdateDisplay(knownAircraft []*types.AircraftData)

type HelpMenu

type HelpMenu struct {
	ui.Block
}

func NewHelpMenu

func NewHelpMenu() *HelpMenu

func (*HelpMenu) Draw

func (self *HelpMenu) Draw(buf *ui.Buffer)

func (*HelpMenu) Resize

func (self *HelpMenu) Resize(termWidth, termHeight int)

type JsonOutput

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

func NewJsonOutput

func NewJsonOutput() *JsonOutput

func (JsonOutput) FeedHandler

func (o JsonOutput) FeedHandler(w http.ResponseWriter, r *http.Request)

func (JsonOutput) MetricsHandler

func (o JsonOutput) MetricsHandler(w http.ResponseWriter, r *http.Request)

func (JsonOutput) UpdateDisplay

func (o JsonOutput) UpdateDisplay(knownAircraft []*types.AircraftData)

type LogOutput

type LogOutput struct {
	ACLogFile *os.File
	Beastinfo *config.BeastInfo
	Aclog     *log.Logger
}

func NewLogOutput

func NewLogOutput(info *config.BeastInfo) *LogOutput

func (LogOutput) UpdateDisplay

func (o LogOutput) UpdateDisplay(knownAircraft []*types.AircraftData)

type Output

type Output interface {
	UpdateDisplay(aircraftMap []*types.AircraftData) //*types.AircraftMap)

}

type Tile38Output

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

func NewTile38Output

func NewTile38Output() *Tile38Output

func (*Tile38Output) UpdateDisplay

func (o *Tile38Output) UpdateDisplay(knownAircraft []*types.AircraftData)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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