add recorder options

This commit is contained in:
ginuerzh
2023-09-18 21:12:08 +08:00
parent 801f835e9a
commit c258a114c4

View File

@ -1,6 +1,8 @@
package recorder package recorder
import "context" import (
"context"
)
type Recorder interface { type Recorder interface {
Record(ctx context.Context, b []byte) error Record(ctx context.Context, b []byte) error
@ -9,6 +11,13 @@ type Recorder interface {
type RecorderObject struct { type RecorderObject struct {
Recorder Recorder Recorder Recorder
Record string Record string
Options *Options
}
type Options struct {
Direction bool
TimestampFormat string
Hexdump bool
} }
const ( const (