http

package
v0.0.0-...-07d2a04 Latest Latest
Warning

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

Go to latest
Published: Dec 21, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewServer

func NewServer(port int, dbConn *db.Queries) *http.Server

Types

type Sensor

type Sensor struct {
	CreatedAt  time.Time `json:"created_at"`
	UpdatedAt  time.Time `json:"updated_at"`
	SensorName string    `json:"sensor_name"`
	ID         int32     `json:"id,omitempty"`
}

type SensorMetadata

type SensorMetadata struct {
	ID             int32       `json:"id"`
	SensorID       int32       `json:"sensor_id"`
	SensorType     pgtype.Text `json:"sensor_type"`
	Manufacturer   pgtype.Text `json:"manufacturer"`
	ModelNumber    pgtype.Text `json:"model_number"`
	SensorLocation pgtype.Text `json:"sensor_location"`
	AdditionalData []byte      `json:"additional_data"`
}

type Server

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

func (*Server) CreateSensorHandler

func (s *Server) CreateSensorHandler(c *gin.Context)

func (*Server) CreateSensorMetadataHandler

func (s *Server) CreateSensorMetadataHandler(c *gin.Context)

func (*Server) CreateSensorReadingHandler

func (s *Server) CreateSensorReadingHandler(c *gin.Context)

func (*Server) DeleteSensorHandler

func (s *Server) DeleteSensorHandler(c *gin.Context)

func (*Server) DeleteSensorMetdataHandler

func (s *Server) DeleteSensorMetdataHandler(c *gin.Context)

func (*Server) GetSensorByIdHandler

func (s *Server) GetSensorByIdHandler(c *gin.Context)

func (*Server) GetSensorMetadataByIdHandler

func (s *Server) GetSensorMetadataByIdHandler(c *gin.Context)

func (*Server) GetSensorMetadataHandler

func (s *Server) GetSensorMetadataHandler(c *gin.Context)

func (*Server) GetSensorReadingsDailyByIdHandler

func (s *Server) GetSensorReadingsDailyByIdHandler(c *gin.Context)

func (*Server) GetSensorReadingsDailyHandler

func (s *Server) GetSensorReadingsDailyHandler(c *gin.Context)

func (*Server) GetSensorReadingsHandler

func (s *Server) GetSensorReadingsHandler(c *gin.Context)

func (*Server) GetSensorReadingsHourlyByIdHandler

func (s *Server) GetSensorReadingsHourlyByIdHandler(c *gin.Context)

func (*Server) GetSensorReadingsHourlyHandler

func (s *Server) GetSensorReadingsHourlyHandler(c *gin.Context)

func (*Server) GetSensorReadingsMinutesByIdHandler

func (s *Server) GetSensorReadingsMinutesByIdHandler(c *gin.Context)

func (*Server) GetSensorReadingsMinutesHandler

func (s *Server) GetSensorReadingsMinutesHandler(c *gin.Context)

func (*Server) GetSensorsHandler

func (s *Server) GetSensorsHandler(c *gin.Context)

func (*Server) HelloWorldHandler

func (s *Server) HelloWorldHandler(c *gin.Context)

func (*Server) RegisterRoutes

func (s *Server) RegisterRoutes() http.Handler

func (*Server) UpdateSensorHandler

func (s *Server) UpdateSensorHandler(c *gin.Context)

func (*Server) UpdateSensorMetadataHandler

func (s *Server) UpdateSensorMetadataHandler(c *gin.Context)

func (*Server) YeetHandler

func (s *Server) YeetHandler(c *gin.Context)

Jump to

Keyboard shortcuts

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