feature

package
v0.195.1 Latest Latest
Warning

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

Go to latest
Published: Sep 17, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Inject

func Inject(ctx context.Context, flagger Flagger) context.Context

Inject injects a Flagger to the context.Context.

func SetMetrics

func SetMetrics(m Metrics)

SetMetrics sets the metric store for feature flags.

Types

type Dependency

type Dependency struct {
	Flagger Flagger
}

func (Dependency) Inject

func (d Dependency) Inject(ctx context.Context) context.Context

type Flag

type Flag = feature.Flag

func ByKey

func ByKey(k string) (Flag, bool)

ByKey returns the Flag corresponding to the given key.

func Flags

func Flags() []Flag

Flags returns all feature flags.

type Flagger

type Flagger = feature.Flagger

type Metrics

type Metrics = feature.Metrics

Jump to

Keyboard shortcuts

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