taggedfeatures

package
v0.0.0-...-07af6e5 Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2023 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_common_taggedfeatures_skeleton_proto protoreflect.FileDescriptor

Functions

func NewHolderFromConfig

func NewHolderFromConfig(ctx context.Context, config *Config, memberType interface{}) (features.TaggedFeatures, error)

Types

type Config

type Config struct {
	Features map[string]*anypb.Any `` /* 157-byte string literal not displayed */
	// contains filtered or unexported fields
}

func LoadJSONConfig

func LoadJSONConfig(ctx context.Context, interfaceType, defaultImpl string, message json.RawMessage) (*Config, error)

func (*Config) Descriptor deprecated

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

Deprecated: Use Config.ProtoReflect.Descriptor instead.

func (*Config) GetFeatures

func (x *Config) GetFeatures() map[string]*anypb.Any

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

type Holder

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

func NewHolder

func NewHolder(ctx context.Context, memberType interface{}) *Holder

func (*Holder) AddFeaturesByTag

func (h *Holder) AddFeaturesByTag(tag string, feature features.Feature) error

func (*Holder) Close

func (h *Holder) Close() error

func (*Holder) GetFeaturesByTag

func (h *Holder) GetFeaturesByTag(tag string) (features.Feature, error)

func (*Holder) GetFeaturesTag

func (h *Holder) GetFeaturesTag() ([]string, error)

func (*Holder) RemoveFeaturesByTag

func (h *Holder) RemoveFeaturesByTag(tag string) error

func (*Holder) Start

func (h *Holder) Start() error

Jump to

Keyboard shortcuts

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