variable

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2023 License: MPL-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GetVariablesInput

type GetVariablesInput struct {
	// Sort specifies the field to sort on and direction
	Sort *db.VariableSortableField
	// PaginationOptions supports cursor based pagination
	PaginationOptions *db.PaginationOptions
	// NamespacePaths filters the variables by the specified paths
	NamespacePaths []string
	// Include Values
	IncludeValues bool
}

GetVariablesInput is the input for querying a list of variables

type Service

type Service interface {
	GetVariables(ctx context.Context, namespacePath string) ([]models.Variable, error)
	GetVariableByID(ctx context.Context, id string) (*models.Variable, error)
	GetVariablesByIDs(ctx context.Context, ids []string) ([]models.Variable, error)
	SetVariables(ctx context.Context, input *SetVariablesInput) error
	CreateVariable(ctx context.Context, input *models.Variable) (*models.Variable, error)
	UpdateVariable(ctx context.Context, variable *models.Variable) (*models.Variable, error)
	DeleteVariable(ctx context.Context, variable *models.Variable) error
}

Service implements all variable related functionality

func NewService

func NewService(
	logger logger.Logger,
	dbClient *db.Client,
	activityService activityevent.Service,
) Service

NewService creates an instance of Service

type SetVariablesInput

type SetVariablesInput struct {
	NamespacePath string
	Category      models.VariableCategory
	Variables     []models.Variable
}

SetVariablesInput is the input for setting namespace variables

Jump to

Keyboard shortcuts

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