Documentation
¶
Index ¶
Constants ¶
View Source
const (
DATE_FORMAT string = "2006-01-02 15:04:05"
)
Variables ¶
This section is empty.
Functions ¶
Types ¶
type ErrorLogger ¶ added in v0.1.0
type ErrorLogger struct {
// contains filtered or unexported fields
}
func NewLogger ¶ added in v0.1.0
func NewLogger(outFile *os.File, prefix string) ErrorLogger
Return a new error logger
func (*ErrorLogger) Fatal ¶ added in v0.1.0
func (self *ErrorLogger) Fatal(err error, message string)
Log the error and stop execution
func (*ErrorLogger) Fatalf ¶ added in v0.1.0
func (self *ErrorLogger) Fatalf(err error, message string, params ...interface{})
Log the formatted error and stop execution
func (*ErrorLogger) Log ¶ added in v0.1.0
func (self *ErrorLogger) Log(err error, message string)
log a message if the error is not nil
func (*ErrorLogger) Logf ¶ added in v0.1.0
func (self *ErrorLogger) Logf(err error, message string, params ...interface{})
log a formated message if the error is not nil
Click to show internal directories.
Click to hide internal directories.