patchvalidator

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Validate

func Validate(p patch.Patch) error

Validate validates patch.

Types

type AddPublicKeysValidator

type AddPublicKeysValidator struct {
}

AddPublicKeysValidator implements validator for "add-public-keys" patch.

func NewAddPublicKeysValidator

func NewAddPublicKeysValidator() *AddPublicKeysValidator

NewAddPublicKeysValidator creates new validator.

func (*AddPublicKeysValidator) Validate

func (v *AddPublicKeysValidator) Validate(p patch.Patch) error

Validate validates patch.

type AddServicesValidator

type AddServicesValidator struct {
}

AddServicesValidator implements validator for "add-public-keys" patch.

func NewAddServicesValidator

func NewAddServicesValidator() *AddServicesValidator

NewAddServicesValidator creates new validator.

func (*AddServicesValidator) Validate

func (v *AddServicesValidator) Validate(p patch.Patch) error

Validate validates patch.

type AlsoKnownAsValidator added in v1.0.0

type AlsoKnownAsValidator struct {
}

AlsoKnownAsValidator implements validator for "add-also-known-as" and "remove-also-known-as" patches. Both patches take have as value URIs so the validation for both add and remove are the same.

func NewAlsoKnownAsValidator added in v1.0.0

func NewAlsoKnownAsValidator() *AlsoKnownAsValidator

NewAlsoKnownAsValidator creates new validator.

func (*AlsoKnownAsValidator) Validate added in v1.0.0

func (v *AlsoKnownAsValidator) Validate(p patch.Patch) error

Validate validates patch.

type JSONValidator

type JSONValidator struct {
}

JSONValidator implements validator for "ietf-json-patch" patch.

func NewJSONValidator

func NewJSONValidator() *JSONValidator

NewJSONValidator creates new validator.

func (*JSONValidator) Validate

func (v *JSONValidator) Validate(p patch.Patch) error

Validate validates patch.

type RemovePublicKeysValidator

type RemovePublicKeysValidator struct {
}

RemovePublicKeysValidator implements validator for "remove-public-keys" patch.

func NewRemovePublicKeysValidator

func NewRemovePublicKeysValidator() *RemovePublicKeysValidator

NewRemovePublicKeysValidator creates validator for "remove-public-keys" patch.

func (*RemovePublicKeysValidator) Validate

func (v *RemovePublicKeysValidator) Validate(p patch.Patch) error

Validate validates patch.

type RemoveServicesValidator

type RemoveServicesValidator struct {
}

RemoveServicesValidator implements validator for "remove-services" patch.

func NewRemoveServicesValidator

func NewRemoveServicesValidator() *RemoveServicesValidator

NewRemoveServicesValidator creates new validator.

func (*RemoveServicesValidator) Validate

func (v *RemoveServicesValidator) Validate(p patch.Patch) error

Validate validates patch.

type ReplaceValidator

type ReplaceValidator struct {
}

ReplaceValidator implements validator for "replace" patch.

func NewReplaceValidator

func NewReplaceValidator() *ReplaceValidator

NewReplaceValidator creates new validator.

func (*ReplaceValidator) Validate

func (v *ReplaceValidator) Validate(p patch.Patch) error

Validate validates patch.

Jump to

Keyboard shortcuts

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