slinterfaces

package
v0.0.0-...-7884915 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2021 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IAppLogger

type IAppLogger interface {
	LogErrorf(cmd string, message string, data ...interface{})
	LogWarnf(cmd string, message string, data ...interface{})
	LogInfof(cmd string, message string, data ...interface{})
	LogDebugf(cmd string, message string, data ...interface{})

	LogError(cmd string, data ...interface{})
	LogErrorE(cmd string, data error)
	LogErrorEf(cmd string, message string, e error)
	LogWarn(cmd string, data ...interface{})
	LogInfo(cmd string, data ...interface{})
	LogDebug(cmd string, data ...interface{})

	StartLogging() []error
	FinishLogging() []error
}

main interface for the SimpleLogger

type ISimpleChannel

type ISimpleChannel interface {
	GetLog() kitlog.Logger
	SetLog(log kitlog.Logger)

	GetFileName() string

	GetSessionID() string

	//log functions
	GetLogLevel() kitlevel.Option
	SetLogLevel(kitlevel.Option)

	Open() (ISimpleChannel, error)
	Close() error

	GetDetails() string
}

main interface for the Simple Channel

type ISimpleLogger

type ISimpleLogger interface {

	//Print To Screen functions
	GetPrintToScreen() PrintLevel
	SetPrintToScreen(PrintLevel)

	LogErrorf(cmd string, message string, data ...interface{})
	LogWarnf(cmd string, message string, data ...interface{})
	LogInfof(cmd string, message string, data ...interface{})
	LogDebugf(cmd string, message string, data ...interface{})

	LogError(cmd string, data ...interface{})
	LogErrorE(cmd string, data error)
	LogErrorEf(cmd string, message string, e error)
	LogWarn(cmd string, data ...interface{})
	LogInfo(cmd string, data ...interface{})
	LogDebug(cmd string, data ...interface{})

	OpenSessionFileLog(logfilename string, sessionid string) error
	GetSessionIDs() []string

	CloseChannel(sessionid string) []error
	CloseAllChannels() []error

	OpenChannel(sessionid string) []error
	OpenAllChannels() []error

	AddChannel(log ISimpleChannel)
	GetChannel(sessionid string) ISimpleChannel
	GetChannels() map[string]ISimpleChannel
	SetChannelLogLevel(sessionid string, lvl kitlevel.Option)
	PrintDetails()
}

main interface for the SimpleLogger

type ISimpleOutput

type ISimpleOutput interface {
	GetSessionID() string

	Open() (ISimpleChannel, error)
	Close() error

	GetDetails() string
}

main interface for the Simple Output

type PrintLevel

type PrintLevel int
const (
	PrintNone  PrintLevel = 0
	PrintInfo  PrintLevel = 1
	PrintDebug PrintLevel = 2
)

Jump to

Keyboard shortcuts

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