outGameController

package
v0.0.0-...-659eabc Latest Latest
Warning

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

Go to latest
Published: Aug 7, 2017 License: GPL-3.0 Imports: 14 Imported by: 0

Documentation

Overview

Package outGameController contains the functions handling requests for features regarding users outside a selected game.

It should regard,for example, game selection.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetEnabledGameIDs

func GetEnabledGameIDs(userID int64) ([]int64, bool, error)

GetEnabledGameIDs gets the IDs of the games enabled for a user.

func GetGames

func GetGames(userID int64) ([]userDataStructs.SummarizedGame, bool, error)

GetGames get the games from a requesting user, setting enabled flag. NOTE: incomplete, do not use cache without finishing function implementation.

func HandleAllGamesForUser

func HandleAllGamesForUser(context echo.Context) error

HandleAllGamesForUser handles a request to show all games summarized data (e.g. name + ID + currentlyPlaying)

func HandleGameDetail

func HandleGameDetail(context echo.Context) error

func HandleMyEnabledGamesForUser

func HandleMyEnabledGamesForUser(context echo.Context) error

HandleMyEnabledGamesForUser handles the request from a user to see his enabled games.

func UpdateCacheAllGames

func UpdateCacheAllGames(games []userDataStructs.SummarizedGame) error

UpdateCacheAllGames updates the cache with all games summarized data.

NOTE: Complexity O(N log(N)), so should be used as least as possible.

N => number of games to add.

Types

This section is empty.

Jump to

Keyboard shortcuts

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