{"modulePath":"github.com/get-eventually/go-eventually","version":"v0.1.0-alpha.4","isLatest":false,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package logger\n\nPackage logger defines a common logger interface used by the library various components.\n\n## Functions\n\n```go\nfunc Debug(l Logger, msg string, fields ...Field)\n```\nDebug delegates the debug log call to the provided logger, if not nil.\n\n```go\nfunc Error(l Logger, msg string, fields ...Field)\n```\nError delegates the error log call to the provided logger, if not nil.\n\n```go\nfunc Info(l Logger, msg string, fields ...Field)\n```\nInfo delegates the info log call to the provided logger, if not nil.\n\n## Types\n\n```go\ntype Field struct {\n\tKey   string\n\tValue interface{}\n}\n```\nField represents a structured field to be added to a Log entry.\n\n```go\nfunc With(key string, value interface{}) Field\n```\nWith is an helper function to add a field in a functional way.\n\n```go\ntype Logger interface {\n\tDebug(msg string, fields ...Field)\n\tInfo(msg string, fields ...Field)\n\tError(msg string, fields ...Field)\n}\n```\nLogger is a structured logger capable of printing information about the execution of a component at various levels.\n\n```go\ntype Nop struct{}\n```\nNop is a nop logger implementation.\n\n```go\nfunc (Nop) Debug(msg string, fields ...Field)\n```\nDebug prints literally nothing.\n\n```go\nfunc (Nop) Error(msg string, fields ...Field)\n```\nError prints literally nothing.\n\n```go\nfunc (Nop) Info(msg string, fields ...Field)\n```\nInfo prints literally nothing.\n\n```go\ntype Test struct {\n\t// contains filtered or unexported fields\n}\n```\nTest is a logger.Logger implementation using testing.T instance.\n\n```go\nfunc NewTest(t *testing.T) Test\n```\nNewTest returns a new logger using the provided testing.T instance.\n\n```go\nfunc (t Test) Debug(msg string, fields ...Field)\n```\nDebug uses t.Logf to print a debug message.\n\n```go\nfunc (t Test) Error(msg string, fields ...Field)\n```\nError uses t.Logf to print an error message.\n\n```go\nfunc (t Test) Info(msg string, fields ...Field)\n```\nInfo uses t.Logf to print an info message.\n\n","path":"github.com/get-eventually/go-eventually/logger","name":"logger","synopsis":"Package logger defines a common logger interface used by the library various components.","isRedistributable":true}
