featuregate

package
v1.4.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FeatureGate

type FeatureGate interface {
	// IsEnabled returns state of the feature,
	// if feature name is unknown will always return false
	IsEnabled(feature string) bool
	// Init set state for the features from the provided map.
	// completely removes the previous state
	Init(features map[string]bool)
	// String returns string representation of the feature state
	String() string
}

FeatureGate provides methods to check state of the feature

func New

func New() FeatureGate

New returns default implementation of the FeatureGate interface

Jump to

Keyboard shortcuts

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