adapter

package
v2.2.0-beta+incompatible Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewARPDescriptor

func NewARPDescriptor(typedDescriptor *ARPDescriptor) *KVDescriptor

func NewRouteDescriptor

func NewRouteDescriptor(typedDescriptor *RouteDescriptor) *KVDescriptor

Types

type ARPDescriptor

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

type ARPDescriptorAdapter

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

func (*ARPDescriptorAdapter) Create

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

func (*ARPDescriptorAdapter) Delete

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

func (*ARPDescriptorAdapter) Dependencies

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

func (*ARPDescriptorAdapter) DerivedValues

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

func (*ARPDescriptorAdapter) Retrieve

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

func (*ARPDescriptorAdapter) Update

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

func (*ARPDescriptorAdapter) UpdateWithRecreate

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

func (*ARPDescriptorAdapter) Validate

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

func (*ARPDescriptorAdapter) ValueComparator

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

type ARPKVWithMetadata

type ARPKVWithMetadata struct {
	Key      string
	Value    *linux_l3.ARPEntry
	Metadata interface{}
	Origin   ValueOrigin
}

type RouteDescriptor

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

type RouteDescriptorAdapter

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

func (*RouteDescriptorAdapter) Create

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

func (*RouteDescriptorAdapter) Delete

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

func (*RouteDescriptorAdapter) Dependencies

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

func (*RouteDescriptorAdapter) DerivedValues

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

func (*RouteDescriptorAdapter) Retrieve

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

func (*RouteDescriptorAdapter) Update

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

func (*RouteDescriptorAdapter) UpdateWithRecreate

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

func (*RouteDescriptorAdapter) Validate

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

func (*RouteDescriptorAdapter) ValueComparator

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

type RouteKVWithMetadata

type RouteKVWithMetadata struct {
	Key      string
	Value    *linux_l3.Route
	Metadata interface{}
	Origin   ValueOrigin
}

Jump to

Keyboard shortcuts

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