Documentation ¶
Index ¶
- Constants
- Variables
- type ConfirmRequest
- type Handler
- func (h *Handler) Authorize(ctx *gin.Context)
- func (h *Handler) Close()
- func (h *Handler) ConfirmAccount(ctx *gin.Context)
- func (h *Handler) CreateAlert(ctx *gin.Context)
- func (h *Handler) CreateSensors(ctx *gin.Context)
- func (h *Handler) CreateStation(ctx *gin.Context)
- func (h *Handler) DeleteAlert(ctx *gin.Context)
- func (h *Handler) DeleteSensors(ctx *gin.Context)
- func (h *Handler) DeleteStation(ctx *gin.Context)
- func (h *Handler) Echo(ctx *gin.Context)
- func (h *Handler) Historical(ctx *gin.Context)
- func (h *Handler) Login(ctx *gin.Context)
- func (h *Handler) OptionalAuth(ctx *gin.Context)
- func (h *Handler) QueryAccount(ctx *gin.Context)
- func (h *Handler) QueryAlert(ctx *gin.Context)
- func (h *Handler) QueryStation(ctx *gin.Context)
- func (h *Handler) Register(ctx *gin.Context)
- func (h *Handler) RequestConfirmAccount(ctx *gin.Context)
- func (h *Handler) RequestPasswordReset(ctx *gin.Context)
- func (h *Handler) ResetPassword(ctx *gin.Context)
- func (h *Handler) SearchAlerts(ctx *gin.Context)
- func (h *Handler) SearchStations(ctx *gin.Context)
- func (h *Handler) UpdateAccount(ctx *gin.Context)
- func (h *Handler) UpdateAlert(ctx *gin.Context)
- func (h *Handler) UpdateStation(ctx *gin.Context)
- type ResetRequest
- type Response
- type UpdateAccountRequest
Constants ¶
View Source
const ( RegisterRoute = "/register" LoginRoute = "/login" SensorRoute = "/sensor" StationRoute = "/station" StationRouteWithParams = StationRoute + "/:" + UUIDParam HistoricalRoute = "/historical" AccountRoute = "/account" EchoRoute = "/echo" AlertRoute = "/alert" AlertRouteWithParam = AlertRoute + "/:" + UUIDParam ResetPasswordRoute = "/reset/password" ConfirmAccountRoute = "/confirm/account" )
View Source
const (
RootRoute = "/"
)
View Source
const (
SessionVariable = "SESSION_VARIABLE"
)
View Source
const (
UUIDParam = "uuid"
)
Variables ¶
View Source
var ( SucceedResponse = Response{Message: "Succeed"} )
Functions ¶
This section is empty.
Types ¶
type ConfirmRequest ¶
type ConfirmRequest struct {
ConfirmCode string `json:"confirmCode"`
}
type Handler ¶
type Handler struct { Controller *models.Controller MessageProducer *memphis.Producer *gin.Engine }
func New ¶
func New(c *models.Controller, msgProducer *memphis.Producer) *Handler
func (*Handler) ConfirmAccount ¶
func (*Handler) CreateAlert ¶
func (*Handler) CreateSensors ¶
func (*Handler) CreateStation ¶
func (*Handler) DeleteAlert ¶
func (*Handler) DeleteSensors ¶
func (*Handler) DeleteStation ¶
func (*Handler) Historical ¶
func (*Handler) OptionalAuth ¶ added in v0.0.3
func (*Handler) QueryAccount ¶
func (*Handler) QueryAlert ¶
func (*Handler) QueryStation ¶
func (*Handler) RequestConfirmAccount ¶
func (*Handler) RequestPasswordReset ¶
func (*Handler) ResetPassword ¶
func (*Handler) SearchAlerts ¶
func (*Handler) SearchStations ¶
func (*Handler) UpdateAccount ¶
func (*Handler) UpdateAlert ¶
func (*Handler) UpdateStation ¶
type ResetRequest ¶
type UpdateAccountRequest ¶
Click to show internal directories.
Click to hide internal directories.