Documentation
¶
Overview ¶
Package cli implements printing functionality for CLI output.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AppCli ¶
type AppCli struct {
// contains filtered or unexported fields
}
AppCli implements Streams interface.
type In ¶ added in v0.0.9
type In struct {
// contains filtered or unexported fields
}
In is an input stream used by the DockerCli to read user input
func NewIn ¶ added in v0.0.9
func NewIn(in io.ReadCloser) *In
NewIn returns a new In object from a ReadCloser
func (*In) CheckTty ¶ added in v0.0.9
CheckTty checks if we are trying to attach to a container tty from a non-tty client input stream, and if so, returns an error.
func (*In) FD ¶ added in v0.0.9
func (s *In) FD() uintptr
FD returns the file descriptor number for this stream
func (*In) IsTerminal ¶ added in v0.0.9
func (s *In) IsTerminal() bool
IsTerminal returns true if this stream is connected to a terminal
func (*In) RestoreTerminal ¶ added in v0.0.9
func (s *In) RestoreTerminal()
RestoreTerminal restores normal mode to the terminal
func (*In) SetIsTerminal ¶ added in v0.0.9
func (s *In) SetIsTerminal(isTerminal bool)
SetIsTerminal sets the boolean used for isTerminal
func (*In) SetRawTerminal ¶ added in v0.0.9
SetRawTerminal sets raw mode on the input terminal
type Out ¶ added in v0.0.9
type Out struct {
// contains filtered or unexported fields
}
Out is an output stream used by the DockerCli to write normal program output.
func (*Out) FD ¶ added in v0.0.9
func (s *Out) FD() uintptr
FD returns the file descriptor number for this stream
func (*Out) GetTtySize ¶ added in v0.0.9
GetTtySize returns the height and width in characters of the tty
func (*Out) IsTerminal ¶ added in v0.0.9
func (s *Out) IsTerminal() bool
IsTerminal returns true if this stream is connected to a terminal
func (*Out) RestoreTerminal ¶ added in v0.0.9
func (s *Out) RestoreTerminal()
RestoreTerminal restores normal mode to the terminal
func (*Out) SetIsTerminal ¶ added in v0.0.9
func (s *Out) SetIsTerminal(isTerminal bool)
SetIsTerminal sets the boolean used for isTerminal
func (*Out) SetRawTerminal ¶ added in v0.0.9
SetRawTerminal sets raw mode on the input terminal
type Streams ¶
Streams is an interface which exposes the standard input and output streams
func InMemoryStreams ¶ added in v0.0.9
func InMemoryStreams() Streams
InMemoryStreams provides in-memory in/out/err streams.
func StandardStreams ¶ added in v0.0.9
func StandardStreams() Streams
StandardStreams sets a cli in, out and err streams with the standard streams.