utils

package
v0.0.8 Latest Latest
Warning

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

Go to latest
Published: Sep 2, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// NotSmiteErrMsg is an error message from making non Smite requests to the Smite URL
	NotSmiteErrMsg = "is only available for Smite requests"
	// NotPaladinsErrMsg is an error message from making non Paladins requests to the Paladins URL
	NotPaladinsErrMsg = "is only available for Paladins requests"
	// NotRankedErrMsg is an error message from making a request to an endpoint marked as "Ranked Only"
	NotRankedErrMsg = "only applies to queues: Joust1v1Ranked, Joust3v3Ranked, and ConquestRanked (440, 450, and 451)"
)

Variables

This section is empty.

Functions

func Contains

func Contains(a []string, b string) bool

Contains checks if string slice 'a' contains string 'b'

func FormatTime

func FormatTime(t time.Time) string

FormatTime formats a go timestamp to the format expected/returned by the HiRez API

func GenerateDesiredOutput

func GenerateDesiredOutput(desiredOutput interface{}) ([]byte, error)

func IsNotRanked

func IsNotRanked(queueID string) bool

IsNotRanked returns true if the passed in queueID is not a ranked queueID

func IsPaladinsPath

func IsPaladinsPath(basePath string) bool

IsPaladinsPath checks that the client BasePath is for Paladins

func IsSmitePath

func IsSmitePath(basePath string) bool

IsSmitePath checks that the client BasePath is for Smite

Types

This section is empty.

Jump to

Keyboard shortcuts

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