Documentation ¶
Index ¶
- func FullColorfulCallerEncoder(caller zapcore.EntryCaller, enc zapcore.PrimitiveArrayEncoder)
- func NewZapColorfulDevelopmentSugarLogger(options ...zap.Option) (tendermintlog.Logger, error)
- func ShortColorfulCallerEncoder(caller zapcore.EntryCaller, enc zapcore.PrimitiveArrayEncoder)
- type Buffer
- func (b *Buffer) AppendBool(v bool)
- func (b *Buffer) AppendByte(v byte)
- func (b *Buffer) AppendFloat(f float64, bitSize int)
- func (b *Buffer) AppendInt(i int64)
- func (b *Buffer) AppendString(s string)
- func (b *Buffer) AppendUint(i uint64)
- func (b *Buffer) Bytes() []byte
- func (b *Buffer) Cap() int
- func (b *Buffer) Free()
- func (b *Buffer) Len() int
- func (b *Buffer) Reset()
- func (b *Buffer) String() string
- func (b *Buffer) TrimNewline()
- func (b *Buffer) Write(bs []byte) (int, error)
- type Pool
- type TendermintLogger
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FullColorfulCallerEncoder ¶
func FullColorfulCallerEncoder(caller zapcore.EntryCaller, enc zapcore.PrimitiveArrayEncoder)
FullColorfulCallerEncoder serializes a caller in package/file:line format, trimming all but the final directory from the full path.
func NewZapColorfulDevelopmentSugarLogger ¶
func NewZapColorfulDevelopmentSugarLogger(options ...zap.Option) (tendermintlog.Logger, error)
func ShortColorfulCallerEncoder ¶
func ShortColorfulCallerEncoder(caller zapcore.EntryCaller, enc zapcore.PrimitiveArrayEncoder)
ShortColorfulCallerEncoder serializes a caller in package/file:line format, trimming all but the final directory from the full path.
Types ¶
type Buffer ¶
type Buffer struct {
// contains filtered or unexported fields
}
Buffer is a thin wrapper around a byte slice. It's intended to be pooled, so the only way to construct one is via a Pool.
func (*Buffer) AppendBool ¶
AppendBool appends a bool to the underlying buffer.
func (*Buffer) AppendByte ¶
AppendByte writes a single byte to the Buffer.
func (*Buffer) AppendFloat ¶
AppendFloat appends a float to the underlying buffer. It doesn't quote NaN or +/- Inf.
func (*Buffer) AppendInt ¶
AppendInt appends an integer to the underlying buffer (assuming base 10).
func (*Buffer) AppendString ¶
AppendString writes a string to the Buffer.
func (*Buffer) AppendUint ¶
AppendUint appends an unsigned integer to the underlying buffer (assuming base 10).
func (*Buffer) Free ¶
func (b *Buffer) Free()
Free returns the Buffer to its Pool.
Callers must not retain references to the Buffer after calling Free.
func (*Buffer) Reset ¶
func (b *Buffer) Reset()
Reset resets the underlying byte slice. Subsequent writes re-use the slice's backing array.
func (*Buffer) TrimNewline ¶
func (b *Buffer) TrimNewline()
TrimNewline trims any final "\n" byte from the end of the buffer.
type Pool ¶
type Pool struct {
// contains filtered or unexported fields
}
A Pool is a type-safe wrapper around a sync.Pool.
type TendermintLogger ¶
type TendermintLogger = tendermintlog.Logger