apps

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2026 License: Apache-2.0 Imports: 7 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package apps is the HTTP adapter of the apps and their parameters: it reads the request, calls the app service and writes the result.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

type Handler struct {
	// contains filtered or unexported fields
}

Handler serves the app routes.

func New

func New(svc Service) *Handler

New builds the handler on the service.

func (*Handler) RegisterApp

func (h *Handler) RegisterApp(r *gin.RouterGroup)

RegisterApp adds the routes of one app, below the group that resolves it.

func (*Handler) RegisterProject

func (h *Handler) RegisterProject(r *gin.RouterGroup)

RegisterProject adds the routes below a project.

type Service

type Service interface {
	Apps(ctx context.Context, projectID uint) ([]models.App, error)
	CreateApp(ctx context.Context, projectID uint, in appsvc.AppInput) (*models.App, error)
	UpdateApp(ctx context.Context, sc appsvc.Scope, in appsvc.AppInput) (*models.App, error)
	AddParameter(ctx context.Context, sc appsvc.Scope, in appsvc.ParameterInput) (*models.AppParameter, error)
	UpdateParameter(ctx context.Context, ref appsvc.ParameterRef, in appsvc.ParameterInput) (*models.AppParameter, error)
	RemoveParameter(ctx context.Context, ref appsvc.ParameterRef) error
}

Service is what the handlers call.

Jump to

Keyboard shortcuts

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