view

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2020 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package view provides TermUI definitions for displaying collected http traffic statistics to the running terminal.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Init

func Init(ctx context.Context, n int) (topN, reqCnts, alerts *widgets.List)

Init constructs termui UI data structures and returns them so data controllers can update the UI.

UI will attempt to scale based on the given Terminal dimensions, but it will not update dimensions if the window is changed after startup.

func Run

func Run(can context.CancelFunc, topN, reqCnts, alerts *widgets.List)

Run catches key events which are needed for scrolling Alert notices in the UI, and catching shutdown commands. Calling can context.CancelFunc() signals the controllers to exit by closing the main context.Context.

Types

This section is empty.

Jump to

Keyboard shortcuts

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