internal

package
v0.0.0-...-10a1391 Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2023 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewLogger

func NewLogger(config *api.EquinoxConfig) *zap.Logger

Creates a new zap.Logger from the configuration parameters provided.

func NewTestEquinoxConfig

func NewTestEquinoxConfig() *api.EquinoxConfig

Creates an EquinoxConfig for tests.

Types

type InternalClient

type InternalClient struct {
	Cluster api.Cluster
	// contains filtered or unexported fields
}

func NewInternalClient

func NewInternalClient(config *api.EquinoxConfig) (*InternalClient, error)

Returns a new InternalClient using the configuration provided.

func (*InternalClient) DataDragonGet

func (c *InternalClient) DataDragonGet(endpointPath string, target interface{}, endpointName string, methodName string) error

Performs a GET request to the Data Dragon API.

func (*InternalClient) Get

func (c *InternalClient) Get(route interface{}, endpointPath string, target interface{}, endpointName string, methodName string, authorizationHeader string) error

Performs a GET request to the Riot API.

func (*InternalClient) Logger

func (c *InternalClient) Logger(client string, endpoint string, method string) *zap.Logger

Used to access the internal logger, this is used to log events from other clients (RiotClient, LOLClient...).

func (*InternalClient) Post

func (c *InternalClient) Post(route interface{}, endpointPath string, requestBody interface{}, target interface{}, endpointName string, methodName string, authorizationHeader string) error

Performs a POST request, authorizationHeader can be blank.

func (*InternalClient) Put

func (c *InternalClient) Put(route interface{}, endpointPath string, requestBody interface{}, endpointName string, methodName string) error

Performs a PUT request.

Jump to

Keyboard shortcuts

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