adapter

package
v1.0.0-beta.202 Latest Latest
Warning

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

Go to latest
Published: Mar 13, 2025 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MapFromEntityFactory

func MapFromEntityFactory(entity *db.Meter) (meter.Meter, error)

MapFromEntityFactory creates a function that maps a meter db entity to a meter model.

func New

func New(config Config) (meter.Service, error)

func NewManage

func NewManage(config ManageConfig) (meter.ManageService, error)

Types

type Config

type Config struct {
	Client *db.Client
	Logger *slog.Logger
}

func (Config) Validate

func (c Config) Validate() error

type ManageConfig

type ManageConfig struct {
	Config

	EntitlementRepository entitlement.EntitlementRepo
	FeatureRepository     feature.FeatureRepo
	NamespaceManager      *namespace.Manager
	StreamingConnector    streaming.Connector
}

func (ManageConfig) Validate

func (c ManageConfig) Validate() error

Jump to

Keyboard shortcuts

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