adapter

package
v2.2.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2019 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewACLDescriptor

func NewACLDescriptor(typedDescriptor *ACLDescriptor) *KVDescriptor

Types

type ACLDescriptor

type ACLDescriptor struct {
	Name                 string
	KeySelector          KeySelector
	ValueTypeName        string
	KeyLabel             func(key string) string
	ValueComparator      func(key string, oldValue, newValue *vpp_acl.ACL) bool
	NBKeyPrefix          string
	WithMetadata         bool
	MetadataMapFactory   MetadataMapFactory
	Validate             func(key string, value *vpp_acl.ACL) error
	Create               func(key string, value *vpp_acl.ACL) (metadata *aclidx.ACLMetadata, err error)
	Delete               func(key string, value *vpp_acl.ACL, metadata *aclidx.ACLMetadata) error
	Update               func(key string, oldValue, newValue *vpp_acl.ACL, oldMetadata *aclidx.ACLMetadata) (newMetadata *aclidx.ACLMetadata, err error)
	UpdateWithRecreate   func(key string, oldValue, newValue *vpp_acl.ACL, metadata *aclidx.ACLMetadata) bool
	Retrieve             func(correlate []ACLKVWithMetadata) ([]ACLKVWithMetadata, error)
	IsRetriableFailure   func(err error) bool
	DerivedValues        func(key string, value *vpp_acl.ACL) []KeyValuePair
	Dependencies         func(key string, value *vpp_acl.ACL) []Dependency
	RetrieveDependencies []string /* descriptor name */
}

type ACLDescriptorAdapter

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

func (*ACLDescriptorAdapter) Create

func (da *ACLDescriptorAdapter) Create(key string, value proto.Message) (metadata Metadata, err error)

func (*ACLDescriptorAdapter) Delete

func (da *ACLDescriptorAdapter) Delete(key string, value proto.Message, metadata Metadata) error

func (*ACLDescriptorAdapter) Dependencies

func (da *ACLDescriptorAdapter) Dependencies(key string, value proto.Message) []Dependency

func (*ACLDescriptorAdapter) DerivedValues

func (da *ACLDescriptorAdapter) DerivedValues(key string, value proto.Message) []KeyValuePair

func (*ACLDescriptorAdapter) Retrieve

func (da *ACLDescriptorAdapter) Retrieve(correlate []KVWithMetadata) ([]KVWithMetadata, error)

func (*ACLDescriptorAdapter) Update

func (da *ACLDescriptorAdapter) Update(key string, oldValue, newValue proto.Message, oldMetadata Metadata) (newMetadata Metadata, err error)

func (*ACLDescriptorAdapter) UpdateWithRecreate

func (da *ACLDescriptorAdapter) UpdateWithRecreate(key string, oldValue, newValue proto.Message, metadata Metadata) bool

func (*ACLDescriptorAdapter) Validate

func (da *ACLDescriptorAdapter) Validate(key string, value proto.Message) (err error)

func (*ACLDescriptorAdapter) ValueComparator

func (da *ACLDescriptorAdapter) ValueComparator(key string, oldValue, newValue proto.Message) bool

type ACLKVWithMetadata

type ACLKVWithMetadata struct {
	Key      string
	Value    *vpp_acl.ACL
	Metadata *aclidx.ACLMetadata
	Origin   ValueOrigin
}

Jump to

Keyboard shortcuts

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