package
0.5.11
Repository: https://github.com/gol4ng/logger.git
Documentation: pkg.go.dev

# Functions

ContextToJSON will marshall the logger context into json.
EntryToJSON will marshall the logger Entry into json.
JSONEncoder will return Entry to json string.
NewDefaultFormatter will create a new DefaultFormatter.
NewGelf will create a new Gelf formatter.
NewGelfTCP will create a new GelfTCPFormatter.
NewJSON will create a new JSON with given json encoder it allow you tu use your own json encoder.
NewJSONEncoder will create a new JSON with default json encoder function.
NewLine will create a new Line with format (fmt).
WithColor function will enable ANSI colored formatting.
WithConditionalColor function will enable ANSI colored formatting.
WithConditionalContext function will display context printing.
WithContext function will display context printing.

# Constants

test message warning <my_key:my_value>.
warning test message <my_key:my_value>.
test message 4 <my_key:my_value>.
Version is the current Gelf version.

# Structs

DefaultFormatter is the default Entry formatter.
Gelf formatter will transform Entry into Gelf format.
GelfTCPFormatter will decorate Gelf formatter in order to add null byte between each entry http://docs.graylog.org/en/3.0/pages/gelf.html#gelf-via-tcp.
JSON formatter will transform a logger entry into JSON it takes an encode function that allows you to encode the data the encode function is useful if you do not use the default provided logger implementation.
Line formatter will transform log Entry into string.

# Type aliases

Option is the option pattern interface for the DefaultFormatter.