Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type UsageManager ¶
type UsageManager struct {
// contains filtered or unexported fields
}
UsageManager is the struct defined to group and contain all the methods that interact with the usage endpoints. Parameters: - db: a DbParameter reference to be able to use the DBManager methods. - monit: a StatusManager reference to be able to use the status subsystem methods.
func New ¶
func New(db *dbManager.DbParameter, monit *statusManager.StatusManager) *UsageManager
New is the function to create the struct UsageManager. Parameters: - DbParameter: reference pointing to the DbParameter that allows the interaction with the DBManager methods. - monit: a reference to the StatusManager to be able to interact with the status subsystem. Returns: - UsageManager: struct to interact with UsageManager subsystem functionalities.
func (*UsageManager) GetSystemUsage ¶
func (m *UsageManager) GetSystemUsage(ctx context.Context, params usage_management.GetSystemUsageParams) middleware.Responder
GetSystemUsage (Swagger func) is the function behind the (GET) API Endpoint /usage Its job is to get the usage of all the accounts in the system during the provided time-window with the posibility of filtering the results by the type of resource.
func (*UsageManager) GetUsage ¶
func (m *UsageManager) GetUsage(ctx context.Context, params usage_management.GetUsageParams) middleware.Responder
GetUsage (Swagger func) is the function behind the (GET) API Endpoint /usage/{id} Its job is to get the usage of the provided account in the system during the provided time-window with the posibility of filtering the results by the type of resource.