opa

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2024 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Name = "opa"
)

Variables

View Source
var File_plugins_opa_config_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Config

type Config struct {

	// Types that are assignable to ConfigType:
	//
	//	*Config_Remote
	//	*Config_Local
	ConfigType isConfig_ConfigType `protobuf_oneof:"config_type"`
	// contains filtered or unexported fields
}

func (*Config) Descriptor deprecated

func (*Config) Descriptor() ([]byte, []int)

Deprecated: Use Config.ProtoReflect.Descriptor instead.

func (*Config) GetConfigType

func (m *Config) GetConfigType() isConfig_ConfigType

func (*Config) GetLocal

func (x *Config) GetLocal() *Local

func (*Config) GetRemote

func (x *Config) GetRemote() *Remote

func (*Config) ProtoMessage

func (*Config) ProtoMessage()

func (*Config) ProtoReflect

func (x *Config) ProtoReflect() protoreflect.Message

func (*Config) Reset

func (x *Config) Reset()

func (*Config) String

func (x *Config) String() string

func (*Config) Validate

func (m *Config) Validate() error

Validate checks the field values on Config with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Config) ValidateAll

func (m *Config) ValidateAll() error

ValidateAll checks the field values on Config with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in ConfigMultiError, or nil if none found.

type ConfigMultiError

type ConfigMultiError []error

ConfigMultiError is an error wrapping multiple validation errors returned by Config.ValidateAll() if the designated constraints aren't met.

func (ConfigMultiError) AllErrors

func (m ConfigMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (ConfigMultiError) Error

func (m ConfigMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type ConfigValidationError

type ConfigValidationError struct {
	// contains filtered or unexported fields
}

ConfigValidationError is the validation error returned by Config.Validate if the designated constraints aren't met.

func (ConfigValidationError) Cause

func (e ConfigValidationError) Cause() error

Cause function returns cause value.

func (ConfigValidationError) Error

func (e ConfigValidationError) Error() string

Error satisfies the builtin error interface

func (ConfigValidationError) ErrorName

func (e ConfigValidationError) ErrorName() string

ErrorName returns error name.

func (ConfigValidationError) Field

func (e ConfigValidationError) Field() string

Field function returns field value.

func (ConfigValidationError) Key

func (e ConfigValidationError) Key() bool

Key function returns key value.

func (ConfigValidationError) Reason

func (e ConfigValidationError) Reason() string

Reason function returns reason value.

type Config_Local

type Config_Local struct {
	Local *Local `protobuf:"bytes,2,opt,name=local,proto3,oneof"`
}

type Config_Remote

type Config_Remote struct {
	Remote *Remote `protobuf:"bytes,1,opt,name=remote,proto3,oneof"`
}

type Local

type Local struct {
	Text string `protobuf:"bytes,1,opt,name=text,proto3" json:"text,omitempty"`
	// contains filtered or unexported fields
}

func (*Local) Descriptor deprecated

func (*Local) Descriptor() ([]byte, []int)

Deprecated: Use Local.ProtoReflect.Descriptor instead.

func (*Local) GetText

func (x *Local) GetText() string

func (*Local) ProtoMessage

func (*Local) ProtoMessage()

func (*Local) ProtoReflect

func (x *Local) ProtoReflect() protoreflect.Message

func (*Local) Reset

func (x *Local) Reset()

func (*Local) String

func (x *Local) String() string

func (*Local) Validate

func (m *Local) Validate() error

Validate checks the field values on Local with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Local) ValidateAll

func (m *Local) ValidateAll() error

ValidateAll checks the field values on Local with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in LocalMultiError, or nil if none found.

type LocalMultiError

type LocalMultiError []error

LocalMultiError is an error wrapping multiple validation errors returned by Local.ValidateAll() if the designated constraints aren't met.

func (LocalMultiError) AllErrors

func (m LocalMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (LocalMultiError) Error

func (m LocalMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type LocalValidationError

type LocalValidationError struct {
	// contains filtered or unexported fields
}

LocalValidationError is the validation error returned by Local.Validate if the designated constraints aren't met.

func (LocalValidationError) Cause

func (e LocalValidationError) Cause() error

Cause function returns cause value.

func (LocalValidationError) Error

func (e LocalValidationError) Error() string

Error satisfies the builtin error interface

func (LocalValidationError) ErrorName

func (e LocalValidationError) ErrorName() string

ErrorName returns error name.

func (LocalValidationError) Field

func (e LocalValidationError) Field() string

Field function returns field value.

func (LocalValidationError) Key

func (e LocalValidationError) Key() bool

Key function returns key value.

func (LocalValidationError) Reason

func (e LocalValidationError) Reason() string

Reason function returns reason value.

type Remote

type Remote struct {
	Url    string `protobuf:"bytes,1,opt,name=url,proto3" json:"url,omitempty"`
	Policy string `protobuf:"bytes,2,opt,name=policy,proto3" json:"policy,omitempty"`
	// contains filtered or unexported fields
}

func (*Remote) Descriptor deprecated

func (*Remote) Descriptor() ([]byte, []int)

Deprecated: Use Remote.ProtoReflect.Descriptor instead.

func (*Remote) GetPolicy

func (x *Remote) GetPolicy() string

func (*Remote) GetUrl

func (x *Remote) GetUrl() string

func (*Remote) ProtoMessage

func (*Remote) ProtoMessage()

func (*Remote) ProtoReflect

func (x *Remote) ProtoReflect() protoreflect.Message

func (*Remote) Reset

func (x *Remote) Reset()

func (*Remote) String

func (x *Remote) String() string

func (*Remote) Validate

func (m *Remote) Validate() error

Validate checks the field values on Remote with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Remote) ValidateAll

func (m *Remote) ValidateAll() error

ValidateAll checks the field values on Remote with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in RemoteMultiError, or nil if none found.

type RemoteMultiError

type RemoteMultiError []error

RemoteMultiError is an error wrapping multiple validation errors returned by Remote.ValidateAll() if the designated constraints aren't met.

func (RemoteMultiError) AllErrors

func (m RemoteMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (RemoteMultiError) Error

func (m RemoteMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type RemoteValidationError

type RemoteValidationError struct {
	// contains filtered or unexported fields
}

RemoteValidationError is the validation error returned by Remote.Validate if the designated constraints aren't met.

func (RemoteValidationError) Cause

func (e RemoteValidationError) Cause() error

Cause function returns cause value.

func (RemoteValidationError) Error

func (e RemoteValidationError) Error() string

Error satisfies the builtin error interface

func (RemoteValidationError) ErrorName

func (e RemoteValidationError) ErrorName() string

ErrorName returns error name.

func (RemoteValidationError) Field

func (e RemoteValidationError) Field() string

Field function returns field value.

func (RemoteValidationError) Key

func (e RemoteValidationError) Key() bool

Key function returns key value.

func (RemoteValidationError) Reason

func (e RemoteValidationError) Reason() string

Reason function returns reason value.

Jump to

Keyboard shortcuts

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