FeatureParamRepository

package
v0.4.2 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2025 License: BSD-2-Clause Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Interface

type Interface interface {
	ListAllParams(c context.Context) map[uuid.UUID][]*db.FeatureParam
	ListParams(c context.Context, keyId uuid.UUID) []*db.FeatureParam
	CreateParam(c context.Context, featureId uuid.UUID, keyId uuid.UUID, name string, value int) (uuid.UUID, error)
	UpdateParam(c context.Context, featureId uuid.UUID, keyId uuid.UUID, paramId uuid.UUID, name string, value int) error
	DeleteParam(c context.Context, paramId uuid.UUID) error

	DeleteAllByKeyId(c context.Context, tx postgres.SQLTx, keyId uuid.UUID) error
	DeleteAllByFeatureId(c context.Context, tx postgres.SQLTx, featureId uuid.UUID) error
}

type Repository

type Repository struct {
	repository.Mock
	// contains filtered or unexported fields
}

func New

func New(name string) *Repository

func (*Repository) CreateParam

func (t *Repository) CreateParam(c context.Context, featureId uuid.UUID, keyId uuid.UUID, name string, value int) (uuid.UUID, error)

func (*Repository) DeleteAllByFeatureId added in v0.4.0

func (t *Repository) DeleteAllByFeatureId(c context.Context, tx postgres.SQLTx, featureId uuid.UUID) error

func (*Repository) DeleteAllByKeyId added in v0.4.0

func (t *Repository) DeleteAllByKeyId(c context.Context, tx postgres.SQLTx, keyId uuid.UUID) error

func (*Repository) DeleteParam

func (t *Repository) DeleteParam(c context.Context, paramId uuid.UUID) error

func (*Repository) Init

func (t *Repository) Init(app interfaces.IEngine, _ map[string]interface{}) error

func (*Repository) ListAllParams added in v0.4.0

func (t *Repository) ListAllParams(c context.Context) map[uuid.UUID][]*db.FeatureParam

func (*Repository) ListParams added in v0.4.0

func (t *Repository) ListParams(c context.Context, keyId uuid.UUID) []*db.FeatureParam

func (*Repository) UpdateParam

func (t *Repository) UpdateParam(c context.Context, featureId uuid.UUID, keyId uuid.UUID, paramId uuid.UUID, name string, value int) error

Jump to

Keyboard shortcuts

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