repository

package
v1.7.4-temp Latest Latest
Warning

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

Go to latest
Published: Dec 30, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package repository provides interfaces for interacting with computility-related data.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ComputilityAccountRecordRepositoryAdapter

ComputilityAccountRecordRepositoryAdapter is an interface for interacting with computility account record repositories.

type ComputilityAccountRepositoryAdapter

type ComputilityAccountRepositoryAdapter interface {
	Add(*domain.ComputilityAccount) error
	Delete(primitive.Identity) error
	FindByAccountIndex(domain.ComputilityAccountIndex) (domain.ComputilityAccount, error)
	CheckAccountExist(primitive.Account) (bool, error)

	DecreaseAccountAssignedQuota(domain.ComputilityAccount, int) error
	IncreaseAccountAssignedQuota(domain.ComputilityAccount, int) error

	ConsumeQuota(domain.ComputilityAccount, int) error
	ReleaseQuota(domain.ComputilityAccount, int) error

	CancelAccount(domain.ComputilityAccountIndex) error
}

ComputilityAccountRepositoryAdapter is an interface for interacting with computility account repositories.

type ComputilityDetailRepositoryAdapter

type ComputilityDetailRepositoryAdapter interface {
	Add(*domain.ComputilityDetail) error
	Delete(primitive.Identity) error
	FindByIndex(*domain.ComputilityIndex) (domain.ComputilityDetail, error)
	GetMembers(primitive.Account) ([]domain.ComputilityDetail, error)
}

ComputilityDetailRepositoryAdapter is an interface for interacting with computility detail repositories.

type ComputilityOrgRepositoryAdapter

type ComputilityOrgRepositoryAdapter interface {
	Delete(primitive.Identity) error
	FindByOrgName(primitive.Account) (domain.ComputilityOrg, error)
	SetQuotaByOrgName(domain.ComputilityOrg, int) (domain.ComputilityOrg, error)

	OrgAssignQuota(domain.ComputilityOrg, int) error
	OrgRecallQuota(domain.ComputilityOrg, int) error
}

ComputilityOrgRepositoryAdapter is an interface for interacting with computility org repositories.

Jump to

Keyboard shortcuts

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