PHP Class LeagueWrap\Api\Staticdata

Inheritance: extends AbstractApi
Afficher le fichier Open project: paquettg/leaguewrap

Protected Properties

Свойство Type Description
$DDversion string The version of League of Legends that we want data from. By default it is not passed (null).
$dataById array A list of all calls that require to get the data by Id
$defaultRemember integer The amount of time we intend to remember the response for.
$locale string The locale you want the response in. By default it is not passed (null).
$permittedRegions array A list of all permitted regions for the Staticdata api call.
$versions array Valid version for this api call.

Méthodes publiques

Méthode Description
getChampion ( integer $championId, mixed $data = null ) : LeagueWrap\Dto\StaticData\ChampionList | Champion Gets the static champion data of all champions if $championId is null.
getChampions ( mixed $data = null ) : LeagueWrap\Dto\StaticData\ChampionList Gets all static champion data with the given $data option.
getDomain ( ) : String
getItem ( integer $itemId, mixed $data = null ) : LeagueWrap\Dto\StaticData\Item | LeagueWrap\Dto\StaticData\ItemList Gets the static item data of all items if $itemId is null.
getItems ( mixed $data = null ) : LeagueWrap\Dto\StaticData\ItemList Gets static data on all items.
getMasteries ( mixed $data = null ) : LeagueWrap\Dto\StaticData\MasteryList Gets static data on all masteries.
getMastery ( integer $masteryId, mixed $data = null ) : LeagueWrap\Dto\StaticData\MasteryList | LeagueWrap\Dto\StaticData\Mastery Gets the mastery data of all masteries if $masteryId is null.
getRealm ( ) : LeagueWrap\Dto\StaticData\Realm Get the realm information for the current region.
getRune ( integer $runeId, mixed $data = null ) : LeagueWrap\Dto\StaticData\RuneList | LeagueWrap\Dto\StaticData\Rune Gets the rune data of all runes if $runeId is null.
getRunes ( mixed $data = null ) : LeagueWrap\Dto\StaticData\RuneList Gets static data on all runes.
getSummonerSpell ( integer $summonerSpellId, mixed $data = null ) : LeagueWrap\Dto\StaticData\SummonerSpell | LeagueWrap\Dto\StaticData\SummonerSpellList Gets the summoner spell data of all spells if $summonerSpellId is null If $summonerSpellId is set it will attept to get info for that spell only.
getSummonerSpells ( mixed $data = null ) : LeagueWrap\Dto\StaticData\SummonerSpellList Gets static data on all summoner spells.
setDDversion ( string $DDversion = null ) Sets the DDversion to be used in the query. Null will return the most recent version.
setLocale ( string $locale ) Sets the locale the data should be returned in. Null returns the default local for that region.
version ( ) : Array Get the version information for the current region.

Méthodes protégées

Méthode Description
appendId ( mixed $requestId ) : boolean Check if we should append the id to the end of the url or not.
dataById ( $name ) : boolean Check if we need the data by Id
makeRequest ( string $path, mixed $requestId, array $params ) : array Make the request given the proper information.
setUpParams ( string $name = '', mixed $requestId = null, mixed $data = null, string $listData = '', string $itemData = '' ) : array Set up the boiler plate for the param array for any static data call.

Method Details

appendId() protected méthode

Check if we should append the id to the end of the url or not.
protected appendId ( mixed $requestId ) : boolean
$requestId mixed
Résultat boolean

dataById() protected méthode

Check if we need the data by Id
protected dataById ( $name ) : boolean
$name string
Résultat boolean

getChampion() public méthode

If $championI is set it will attempt to get info for that champion only.
public getChampion ( integer $championId, mixed $data = null ) : LeagueWrap\Dto\StaticData\ChampionList | Champion
$championId integer
$data mixed
Résultat LeagueWrap\Dto\StaticData\ChampionList | Champion

getChampions() public méthode

Gets all static champion data with the given $data option.
public getChampions ( mixed $data = null ) : LeagueWrap\Dto\StaticData\ChampionList
$data mixed
Résultat LeagueWrap\Dto\StaticData\ChampionList

getDomain() public méthode

public getDomain ( ) : String
Résultat String domain used for the request

getItem() public méthode

If $itemId is set it will attempt to get info for that item only.
public getItem ( integer $itemId, mixed $data = null ) : LeagueWrap\Dto\StaticData\Item | LeagueWrap\Dto\StaticData\ItemList
$itemId integer
$data mixed
Résultat LeagueWrap\Dto\StaticData\Item | LeagueWrap\Dto\StaticData\ItemList

getItems() public méthode

Gets static data on all items.
public getItems ( mixed $data = null ) : LeagueWrap\Dto\StaticData\ItemList
$data mixed
Résultat LeagueWrap\Dto\StaticData\ItemList

getMasteries() public méthode

Gets static data on all masteries.
public getMasteries ( mixed $data = null ) : LeagueWrap\Dto\StaticData\MasteryList
$data mixed
Résultat LeagueWrap\Dto\StaticData\MasteryList

getMastery() public méthode

If $masteryId is a set it will attempt to get info for that mastery only.
public getMastery ( integer $masteryId, mixed $data = null ) : LeagueWrap\Dto\StaticData\MasteryList | LeagueWrap\Dto\StaticData\Mastery
$masteryId integer
$data mixed
Résultat LeagueWrap\Dto\StaticData\MasteryList | LeagueWrap\Dto\StaticData\Mastery

getRealm() public méthode

Get the realm information for the current region.
public getRealm ( ) : LeagueWrap\Dto\StaticData\Realm
Résultat LeagueWrap\Dto\StaticData\Realm

getRune() public méthode

If $runeId is set it will attempt to get info for that rune only.
public getRune ( integer $runeId, mixed $data = null ) : LeagueWrap\Dto\StaticData\RuneList | LeagueWrap\Dto\StaticData\Rune
$runeId integer
$data mixed
Résultat LeagueWrap\Dto\StaticData\RuneList | LeagueWrap\Dto\StaticData\Rune

getRunes() public méthode

Gets static data on all runes.
public getRunes ( mixed $data = null ) : LeagueWrap\Dto\StaticData\RuneList
$data mixed
Résultat LeagueWrap\Dto\StaticData\RuneList

getSummonerSpell() public méthode

Gets the summoner spell data of all spells if $summonerSpellId is null If $summonerSpellId is set it will attept to get info for that spell only.
public getSummonerSpell ( integer $summonerSpellId, mixed $data = null ) : LeagueWrap\Dto\StaticData\SummonerSpell | LeagueWrap\Dto\StaticData\SummonerSpellList
$summonerSpellId integer
$data mixed
Résultat LeagueWrap\Dto\StaticData\SummonerSpell | LeagueWrap\Dto\StaticData\SummonerSpellList

getSummonerSpells() public méthode

Gets static data on all summoner spells.
public getSummonerSpells ( mixed $data = null ) : LeagueWrap\Dto\StaticData\SummonerSpellList
$data mixed
Résultat LeagueWrap\Dto\StaticData\SummonerSpellList

makeRequest() protected méthode

Make the request given the proper information.
protected makeRequest ( string $path, mixed $requestId, array $params ) : array
$path string
$requestId mixed
$params array
Résultat array

setDDversion() public méthode

Sets the DDversion to be used in the query. Null will return the most recent version.
public setDDversion ( string $DDversion = null )
$DDversion string

setLocale() public méthode

Sets the locale the data should be returned in. Null returns the default local for that region.
public setLocale ( string $locale )
$locale string

setUpParams() protected méthode

Set up the boiler plate for the param array for any static data call.
protected setUpParams ( string $name = '', mixed $requestId = null, mixed $data = null, string $listData = '', string $itemData = '' ) : array
$name string of api call
$requestId mixed
$data mixed
$listData string
$itemData string
Résultat array

version() public méthode

Get the version information for the current region.
public version ( ) : Array
Résultat Array

Property Details

$DDversion protected_oe property

The version of League of Legends that we want data from. By default it is not passed (null).
protected string $DDversion
Résultat string

$dataById protected_oe property

A list of all calls that require to get the data by Id
protected array $dataById
Résultat array

$defaultRemember protected_oe property

The amount of time we intend to remember the response for.
protected int $defaultRemember
Résultat integer

$locale protected_oe property

The locale you want the response in. By default it is not passed (null).
protected string $locale
Résultat string

$permittedRegions protected_oe property

A list of all permitted regions for the Staticdata api call.
protected array $permittedRegions
Résultat array

$versions protected_oe property

Valid version for this api call.
protected array $versions
Résultat array