12 lines
200 B
Go
12 lines
200 B
Go
package main
|
|
|
|
import "context"
|
|
|
|
type Validator interface {
|
|
Validate(ctx context.Context, b []byte) error //context parameter
|
|
}
|
|
|
|
type ValidatorProvider interface {
|
|
New(p string) (Validator, error)
|
|
}
|