github.com/v2pro/plz@v0.0.0-20221028024117-e5f9aec5b631/countlog/output/compact/default.go (about)

     1  package compact
     2  
     3  import (
     4  	"github.com/v2pro/plz/countlog/spi"
     5  	"github.com/v2pro/plz/msgfmt"
     6  )
     7  
     8  type defaultFormatter struct {
     9  	fmt msgfmt.Formatter
    10  }
    11  
    12  func (formatter *defaultFormatter) Format(space []byte, event *spi.Event) []byte {
    13  	return formatter.fmt.Format(space, event.Properties)
    14  }