v1

package
v1.0.0-beta.2 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2024 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrGithub        = consoleerrors.CreateConsoleError("LatestReleaseHandler")
	ErrFailedToFetch = errors.New("repositoryError")
)
View Source
var ErrLogin = consoleerrors.CreateConsoleError("LoginHandler")
View Source
var ErrValidation8021xConfig = dto.NotValidError{Console: consoleerrors.CreateConsoleError("8021xConfigAPI")}
View Source
var ErrValidationDevices = dto.NotValidError{Console: consoleerrors.CreateConsoleError("ProfileAPI")}
View Source
var ErrValidationDomains = dto.NotValidError{Console: consoleerrors.CreateConsoleError("DomainsAPI")}
View Source
var ErrValidationProfile = dto.NotValidError{Console: consoleerrors.CreateConsoleError("ProfileAPI")}
View Source
var ErrValidationWifiConfig = dto.NotValidError{Console: consoleerrors.CreateConsoleError("WifiConfigsAPI")}

Functions

func ErrorResponse

func ErrorResponse(c *gin.Context, err error)

func NewAmtRoutes

func NewAmtRoutes(handler *gin.RouterGroup, d devices.Feature, amt amtexplorer.Feature, l logger.Interface)

func NewCIRAConfigRoutes

func NewCIRAConfigRoutes(handler *gin.RouterGroup, t ciraconfigs.Feature, l logger.Interface)

func NewDeviceRoutes

func NewDeviceRoutes(handler *gin.RouterGroup, t devices.Feature, l logger.Interface)

func NewDomainRoutes

func NewDomainRoutes(handler *gin.RouterGroup, t domains.Feature, l logger.Interface)

func NewIEEE8021xConfigRoutes

func NewIEEE8021xConfigRoutes(handler *gin.RouterGroup, t ieee8021xconfigs.Feature, l logger.Interface)

func NewProfileRoutes

func NewProfileRoutes(handler *gin.RouterGroup, t profiles.Feature, l logger.Interface)

func NewWirelessConfigRoutes

func NewWirelessConfigRoutes(handler *gin.RouterGroup, t wificonfigs.Feature, l logger.Interface)

func RepositoryError

func RepositoryError(status string) error

Types

type CIRAConfigCountResponse

type CIRAConfigCountResponse struct {
	Count int              `json:"totalCount"`
	Data  []dto.CIRAConfig `json:"data"`
}

type DeviceCountResponse

type DeviceCountResponse struct {
	Count int          `json:"totalCount"`
	Data  []dto.Device `json:"data"`
}

type DeviceStatResponse

type DeviceStatResponse struct {
	TotalCount        int `json:"totalCount"`
	ConnectedCount    int `json:"connectedCount"`
	DisconnectedCount int `json:"disconnectedCount"`
}

type DomainCountResponse

type DomainCountResponse struct {
	Count int          `json:"totalCount"`
	Data  []dto.Domain `json:"data"`
}

type IEEE8021xConfigCountResponse

type IEEE8021xConfigCountResponse struct {
	Count int                   `json:"totalCount"`
	Data  []dto.IEEE8021xConfig `json:"data"`
}

type LoginRoute

type LoginRoute struct {
	Config *config.Config
}

func NewLoginRoute

func NewLoginRoute(configData *config.Config) *LoginRoute

NewVersionRoute creates a new version route

func (LoginRoute) JWTAuthMiddleware

func (lr LoginRoute) JWTAuthMiddleware() gin.HandlerFunc

JWT Middleware

func (LoginRoute) Login

func (lr LoginRoute) Login(c *gin.Context)

FetchLatestRelease fetches the latest release information from GitHub API

type OData

type OData struct {
	Top   int  `form:"$top,default=25"`
	Skip  int  `form:"$skip"`
	Count bool `form:"$count"`
}

type ProfileCountResponse

type ProfileCountResponse struct {
	Count int           `json:"totalCount"`
	Data  []dto.Profile `json:"data"`
}

type VersionRoute

type VersionRoute struct {
	Config *config.Config
}

func NewVersionRoute

func NewVersionRoute(configData *config.Config) *VersionRoute

NewVersionRoute creates a new version route

func (VersionRoute) FetchLatestRelease

func (vr VersionRoute) FetchLatestRelease(c *gin.Context, repo string) (*github.Release, error)

FetchLatestRelease fetches the latest release information from GitHub API

func (VersionRoute) LatestReleaseHandler

func (vr VersionRoute) LatestReleaseHandler(c *gin.Context)

LatestReleaseHandler is the Gin handler function to check for the latest release

type WirelessConfigRoutes

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

Jump to

Keyboard shortcuts

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