stream

package
v0.4.3 Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2020 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LogBlock

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

func (*LogBlock) Disable

func (l *LogBlock) Disable() types.LogBlockInterface

func (*LogBlock) Do

func (l *LogBlock) Do(f func())

func (*LogBlock) DoError

func (l *LogBlock) DoError(f func() error) error

func (*LogBlock) Enable

func (l *LogBlock) Enable() types.LogBlockInterface

func (*LogBlock) Options

func (l *LogBlock) Options(f func(options types.LogBlockOptionsInterface)) types.LogBlockInterface

type LogBlockOptions

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

func (*LogBlockOptions) DisableIfLevelNotAccepted

func (opts *LogBlockOptions) DisableIfLevelNotAccepted()

func (*LogBlockOptions) Mute added in v0.4.3

func (opts *LogBlockOptions) Mute()

func (*LogBlockOptions) Style

func (opts *LogBlockOptions) Style(s *stylePkg.Style)

func (*LogBlockOptions) WithIndent

func (opts *LogBlockOptions) WithIndent()

func (*LogBlockOptions) WithoutLogOptionalLn

func (opts *LogBlockOptions) WithoutLogOptionalLn()

type LogProcess

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

func (*LogProcess) Disable

func (l *LogProcess) Disable() types.LogProcessInterface

func (*LogProcess) Do

func (l *LogProcess) Do(f func())

func (*LogProcess) DoError

func (l *LogProcess) DoError(f func() error) error

func (*LogProcess) Enable

func (l *LogProcess) Enable() types.LogProcessInterface

func (*LogProcess) End

func (l *LogProcess) End()

func (*LogProcess) Fail

func (l *LogProcess) Fail()

func (*LogProcess) Options

func (*LogProcess) Start

func (l *LogProcess) Start()

func (*LogProcess) StepEnd

func (l *LogProcess) StepEnd(format string, a ...interface{})

type LogProcessInline

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

func (*LogProcessInline) Disable

func (*LogProcessInline) Do

func (l *LogProcessInline) Do(f func())

func (*LogProcessInline) DoError

func (l *LogProcessInline) DoError(f func() error) error

func (*LogProcessInline) Enable

func (*LogProcessInline) Options

type LogProcessInlineOptions

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

func (*LogProcessInlineOptions) DisableIfLevelNotAccepted

func (opts *LogProcessInlineOptions) DisableIfLevelNotAccepted()

func (*LogProcessInlineOptions) Mute added in v0.4.3

func (opts *LogProcessInlineOptions) Mute()

func (*LogProcessInlineOptions) Style

func (opts *LogProcessInlineOptions) Style(s *stylePkg.Style)

type LogProcessOptions

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

func (*LogProcessOptions) DisableIfLevelNotAccepted

func (opts *LogProcessOptions) DisableIfLevelNotAccepted()

func (*LogProcessOptions) InfoSectionFunc

func (opts *LogProcessOptions) InfoSectionFunc(f func(err error))

func (*LogProcessOptions) Mute added in v0.4.3

func (opts *LogProcessOptions) Mute()

func (*LogProcessOptions) Style

func (opts *LogProcessOptions) Style(style *stylePkg.Style)

func (*LogProcessOptions) SuccessInfoSectionFunc

func (opts *LogProcessOptions) SuccessInfoSectionFunc(f func())

func (*LogProcessOptions) WithIndent

func (opts *LogProcessOptions) WithIndent()

func (*LogProcessOptions) WithoutElapsedTime

func (opts *LogProcessOptions) WithoutElapsedTime()

func (*LogProcessOptions) WithoutLogOptionalLn

func (opts *LogProcessOptions) WithoutLogOptionalLn()

type State

type State struct {
	fitter.State
	// contains filtered or unexported fields
}

func NewStreamState

func NewStreamState() *State

func (*State) ContentWidth

func (s *State) ContentWidth() int

func (*State) DecreaseIndent

func (s *State) DecreaseIndent()

func (*State) DisableGitlabCollapsibleSections added in v0.4.1

func (s *State) DisableGitlabCollapsibleSections()

func (*State) DisableLineWrapping

func (s *State) DisableLineWrapping()

func (*State) DisableLogProcessBorder

func (s *State) DisableLogProcessBorder()

func (*State) DisableOptionalLn

func (s *State) DisableOptionalLn()

func (*State) DisablePrefixWithTime

func (s *State) DisablePrefixWithTime()

func (*State) DisablePrettyLog

func (s *State) DisablePrettyLog()

func (*State) DisableProxyStreamDataFormatting

func (s *State) DisableProxyStreamDataFormatting()

func (*State) DisableStyle

func (s *State) DisableStyle()

func (*State) DoErrorWithIndent

func (s *State) DoErrorWithIndent(f func() error) error

func (*State) DoErrorWithProxyStreamDataFormatting

func (s *State) DoErrorWithProxyStreamDataFormatting(f func() error) error

func (*State) DoErrorWithTag

func (s *State) DoErrorWithTag(value string, style *stylePkg.Style, f func() error) error

func (*State) DoErrorWithoutIndent

func (s *State) DoErrorWithoutIndent(f func() error) error

func (*State) DoErrorWithoutProxyStreamDataFormatting

func (s *State) DoErrorWithoutProxyStreamDataFormatting(f func() error) error

func (*State) DoWithIndent

func (s *State) DoWithIndent(f func())

func (*State) DoWithProxyStreamDataFormatting

func (s *State) DoWithProxyStreamDataFormatting(f func())

func (*State) DoWithTag

func (s *State) DoWithTag(value string, style *stylePkg.Style, f func())

func (*State) DoWithoutIndent

func (s *State) DoWithoutIndent(f func())

func (*State) DoWithoutProxyStreamDataFormatting

func (s *State) DoWithoutProxyStreamDataFormatting(f func())

func (*State) EnableGitlabCollapsibleSections added in v0.4.1

func (s *State) EnableGitlabCollapsibleSections()

func (*State) EnableLineWrapping

func (s *State) EnableLineWrapping()

func (*State) EnableLogProcessBorder

func (s *State) EnableLogProcessBorder()

func (*State) EnableOptionalLn

func (s *State) EnableOptionalLn()

func (*State) EnablePrefixWithTime

func (s *State) EnablePrefixWithTime()

func (*State) EnableProxyStreamDataFormatting

func (s *State) EnableProxyStreamDataFormatting()

func (*State) EnableStyle

func (s *State) EnableStyle()

func (*State) IncreaseIndent

func (s *State) IncreaseIndent()

func (*State) IsGitlabCollapsibleSections added in v0.4.1

func (s *State) IsGitlabCollapsibleSections() bool

func (*State) IsLineWrappingEnabled

func (s *State) IsLineWrappingEnabled() bool

func (*State) IsLogProcessBorderEnabled added in v0.4.3

func (s *State) IsLogProcessBorderEnabled() bool

func (*State) IsMuted

func (s *State) IsMuted() bool

func (*State) IsPrefixWithTimeEnabled

func (s *State) IsPrefixWithTimeEnabled() bool

func (*State) IsProxyStreamDataFormattingEnabled

func (s *State) IsProxyStreamDataFormattingEnabled() bool

func (*State) IsStyleEnabled

func (s *State) IsStyleEnabled() bool

func (*State) LogProcessDownAndRightBorderSign added in v0.4.3

func (s *State) LogProcessDownAndRightBorderSign() string

func (*State) LogProcessUpAndRightBorderSign added in v0.4.3

func (s *State) LogProcessUpAndRightBorderSign() string

func (*State) LogProcessVerticalAndRightBorderSign added in v0.4.3

func (s *State) LogProcessVerticalAndRightBorderSign() string

func (*State) LogProcessVerticalBorderSign added in v0.4.3

func (s *State) LogProcessVerticalBorderSign() string

func (*State) Mute

func (s *State) Mute()

func (*State) ProcessesBorderBetweenIndentWidth added in v0.4.3

func (s *State) ProcessesBorderBetweenIndentWidth() int

func (*State) ProcessesBorderIndentWidth added in v0.4.3

func (s *State) ProcessesBorderIndentWidth() int

func (*State) ResetIndent

func (s *State) ResetIndent()

func (*State) ResetPrefix

func (s *State) ResetPrefix()

func (*State) ResetPrefixTime

func (s *State) ResetPrefixTime()

func (*State) ResetTag

func (s *State) ResetTag()

func (*State) ServiceWidth

func (s *State) ServiceWidth() int

func (*State) SetPrefix

func (s *State) SetPrefix(value string)

func (*State) SetPrefixStyle

func (s *State) SetPrefixStyle(style *stylePkg.Style)

func (*State) SetTag

func (s *State) SetTag(value string)

func (*State) SetTagStyle

func (s *State) SetTagStyle(style *stylePkg.Style)

func (*State) SetTagWithStyle

func (s *State) SetTagWithStyle(value string, style *stylePkg.Style)

func (*State) SetWidth

func (s *State) SetWidth(value int)

func (*State) SharedState added in v0.4.3

func (s *State) SharedState() *State

func (*State) SubState

func (s *State) SubState() *State

func (*State) Unmute

func (s *State) Unmute()

func (*State) Width

func (s *State) Width() int

type Stream

type Stream struct {
	io.Writer
	*State
}

func NewStream

func NewStream(w io.Writer, state *State) *Stream

func (*Stream) FitText

func (s *Stream) FitText(text string, options types.FitTextOptions) string

func (*Stream) FormatAndLogF

func (s *Stream) FormatAndLogF(style *stylePkg.Style, format string, a ...interface{})

func (*Stream) NewLogBlock

func (s *Stream) NewLogBlock(manager types.ManagerInterface, format string, a ...interface{}) *LogBlock

func (*Stream) NewLogProcess

func (s *Stream) NewLogProcess(manager types.ManagerInterface, format string, a ...interface{}) *LogProcess

func (*Stream) NewLogProcessInline

func (s *Stream) NewLogProcessInline(manager types.ManagerInterface, format string, a ...interface{}) *LogProcessInline

func (*Stream) ProxyStream

func (s *Stream) ProxyStream() io.Writer

func (*Stream) Reset added in v0.4.3

func (s *Stream) Reset()

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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