deprecate

package
v0.273.0 Latest Latest
Warning

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

Go to latest
Published: Jul 1, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Deprecator

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

Deprecator contains information required to do deprecation checks and deprecation event trigger

func MustNewDeprecator

func MustNewDeprecator(featureDesc, weakWarningDate, strongWarningDate, crashDate string) *Deprecator

MustNewDeprecator returns a deprecator and panics if deprecator creation fails.

func NewDeprecator

func NewDeprecator(featureDesc, weakWarningDate, strongWarningDate, crashDate string) (*Deprecator, error)

NewDeprecator takes brief feature description and three dates with different level of deprecations. It returns a deprecator. Dates are considered to be in UTC timezone.

func (*Deprecator) Deprecate

func (d *Deprecator) Deprecate(ctx context.Context, scanner parser.Scanner) error

Deprecate does extracts build information from context once and does deprecation checks and trigger deprecation events.

Jump to

Keyboard shortcuts

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