Documentation ¶
Index ¶
- func RegisterRoutes(r *gin.RouterGroup, service *ServerAnalyticsService, ...)
- type PeriodData
- type PlayersOnlineRequest
- type PlayersOnlineResponse
- type PopularServersResponse
- type PopularServersResponseItem
- type ServerAnalyticsService
- func (s *ServerAnalyticsService) GetCurrentOnline() (*TotalOnlineResponse, error)
- func (s *ServerAnalyticsService) GetPlayersOnline(req PlayersOnlineRequest) (*[]PeriodData, error)
- func (s *ServerAnalyticsService) GetPopularServers() (*PopularServersResponse, error)
- func (s *ServerAnalyticsService) GetSessionCount(req SessionCountRequest) (*[]PeriodData, error)
- func (s *ServerAnalyticsService) GetUsageInMinutes(req UsageInMinutesRequest) (*[]PeriodData, error)
- type SessionCountRequest
- type SessionCountResponse
- type TotalOnlineResponse
- type UsageInMinutesRequest
- type UsageInMinutesResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterRoutes ¶
func RegisterRoutes( r *gin.RouterGroup, service *ServerAnalyticsService, memoryStore *persist.MemoryStore, )
Types ¶
type PeriodData ¶
type PlayersOnlineRequest ¶
type PlayersOnlineResponse ¶
type PlayersOnlineResponse struct {
Items []PeriodData `json:"items"`
}
type PopularServersResponse ¶
type PopularServersResponse struct {
Items []PopularServersResponseItem `json:"items"`
}
type ServerAnalyticsService ¶
type ServerAnalyticsService struct {
// contains filtered or unexported fields
}
func NewServerAnalyticsService ¶
func NewServerAnalyticsService(db *sql.DB) *ServerAnalyticsService
func (*ServerAnalyticsService) GetCurrentOnline ¶
func (s *ServerAnalyticsService) GetCurrentOnline() (*TotalOnlineResponse, error)
func (*ServerAnalyticsService) GetPlayersOnline ¶
func (s *ServerAnalyticsService) GetPlayersOnline( req PlayersOnlineRequest, ) (*[]PeriodData, error)
func (*ServerAnalyticsService) GetPopularServers ¶
func (s *ServerAnalyticsService) GetPopularServers() (*PopularServersResponse, error)
func (*ServerAnalyticsService) GetSessionCount ¶
func (s *ServerAnalyticsService) GetSessionCount( req SessionCountRequest, ) (*[]PeriodData, error)
func (*ServerAnalyticsService) GetUsageInMinutes ¶
func (s *ServerAnalyticsService) GetUsageInMinutes( req UsageInMinutesRequest, ) (*[]PeriodData, error)
type SessionCountRequest ¶
type SessionCountResponse ¶
type SessionCountResponse struct {
Items []PeriodData `json:"items"`
}
type TotalOnlineResponse ¶
type TotalOnlineResponse struct {
Count int `json:"count"`
}
type UsageInMinutesRequest ¶
type UsageInMinutesResponse ¶
type UsageInMinutesResponse struct {
Items []PeriodData `json:"items"`
}
Click to show internal directories.
Click to hide internal directories.