util

package
v0.0.0-...-82e36bc Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2020 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Now = time.Now
)

Functions

func B2s

func B2s(b []byte) string

B2s converts byte slice to a string without memory allocation. See https://groups.google.com/forum/#!msg/Golang-Nuts/ENgbUzYvCuU/90yGx7GUAgAJ .

Note it may break if string and/or slice header will change in the future go versions.

Types

type FasthttpLogger

type FasthttpLogger struct {
	Logger zerolog.Logger
}

func (FasthttpLogger) Printf

func (f FasthttpLogger) Printf(format string, args ...interface{})

type ZerologTestWriter

type ZerologTestWriter struct {
	T *testing.T
}

func (ZerologTestWriter) Write

func (z ZerologTestWriter) Write(p []byte) (n int, err error)

Jump to

Keyboard shortcuts

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