craete initialize() to get each schema from .json
This commit is contained in:
14
plugins/plugin_definition/plugin.go
Normal file
14
plugins/plugin_definition/plugin.go
Normal file
@@ -0,0 +1,14 @@
|
||||
package plugin_definition
|
||||
|
||||
import "context"
|
||||
|
||||
// Validator interface for schema validation
|
||||
type Validator interface {
|
||||
Validate(ctx context.Context, b []byte) error
|
||||
}
|
||||
|
||||
// ValidatorProvider interface for creating validators
|
||||
type ValidatorProvider interface {
|
||||
Get(p string) (Validator, error)
|
||||
Initialize(schemaDir string) error
|
||||
}
|
||||
Reference in New Issue
Block a user