waitlivemsg

package
v1.0.0-alpha-119 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2017 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GreenTickSymbol

func GreenTickSymbol() string

GreenTickSymbol for stop messages

func RedCrossSymbol

func RedCrossSymbol() string

RedCrossSymbol for stop messages

Types

type Message

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

Message to print

func EmptyLine

func EmptyLine() *Message

EmptyLine creates a Message with an empty line it has the side-effect of using no symbols as prefixes

func NewMessage

func NewMessage(text string) *Message

NewMessage creates a Message with a given text

func (*Message) End

func (m *Message) End()

End message

func (*Message) GetText

func (m *Message) GetText() string

GetText of the message

func (*Message) NoSymbol

func (m *Message) NoSymbol()

NoSymbol hides the symbol for the given message

func (*Message) SetSymbolEnd

func (m *Message) SetSymbolEnd(symbolEnd string)

SetSymbolEnd of message

func (*Message) SetText

func (m *Message) SetText(text string)

SetText of message

type WaitLiveMsg

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

WaitLiveMsg is used for "waiting" live message

func (*WaitLiveMsg) AddMessage

func (w *WaitLiveMsg) AddMessage(msg *Message)

AddMessage to display

func (*WaitLiveMsg) Duration

func (w *WaitLiveMsg) Duration() time.Duration

Duration in seconds

func (*WaitLiveMsg) RemoveMessage

func (w *WaitLiveMsg) RemoveMessage(msg *Message)

RemoveMessage from the messages slice

func (*WaitLiveMsg) ResetDuration

func (w *WaitLiveMsg) ResetDuration()

ResetDuration to restart counter

func (*WaitLiveMsg) ResetMessages

func (w *WaitLiveMsg) ResetMessages()

ResetMessages to display

func (*WaitLiveMsg) SetMessage

func (w *WaitLiveMsg) SetMessage(msg *Message)

SetMessage to display

func (*WaitLiveMsg) SetMessages

func (w *WaitLiveMsg) SetMessages(msgs []*Message)

SetMessages to display

func (*WaitLiveMsg) SetStream

func (w *WaitLiveMsg) SetStream(ws *uilive.Writer)

SetStream to output to

func (*WaitLiveMsg) Stop

func (w *WaitLiveMsg) Stop()

Stop the waiting message

func (*WaitLiveMsg) Wait

func (w *WaitLiveMsg) Wait()

Wait starts the waiting message

Jump to

Keyboard shortcuts

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