PHP Класс Pheal\Pheal

Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$scope string ..)
$xml String Result of the last XML request, so application can use the raw xml data

Открытые методы

Метод Описание
__call ( String $name, array $arguments ) : Pheal\Core\Result Magic __call method, will translate all function calls to object to API requests
__construct ( integer $userid = null, string $key = null, string $scope = 'account' ) creates new Pheal API object
__get ( string $name ) : Pheal | null Magic __get method used to set scope
clearAccess ( ) : void clear+reset keyType/accessMask
detectAccess ( ) : boolean | Pheal\Core\Result if userid+key is given it automatically detects (api call) the keyinfo and set the correct access level for futher checks.
setAccess ( string $keyType = null, integer $accessMask ) : void Set keyType/accessMask

Приватные методы

Метод Описание
requestXml ( string $scope, string $name, array $opts = [] ) : Pheal\Core\Result method will ask caching class for valid xml, if non valid available will make API call, and return the appropriate result

Описание методов

__call() публичный Метод

Magic __call method, will translate all function calls to object to API requests
public __call ( String $name, array $arguments ) : Pheal\Core\Result
$name String name of the function
$arguments array an array of arguments
Результат Pheal\Core\Result

__construct() публичный Метод

creates new Pheal API object
public __construct ( integer $userid = null, string $key = null, string $scope = 'account' )
$userid integer the EVE userid/keyID
$key string the EVE apikey/vCode
$scope string to use, defaults to account. can be changed during runtime by modifying attribute "scope"

__get() публичный Метод

Magic __get method used to set scope
public __get ( string $name ) : Pheal | null
$name string name of the scope e.g. "mapScope"
Результат Pheal | null

clearAccess() публичный Метод

clear+reset keyType/accessMask
public clearAccess ( ) : void
Результат void

detectAccess() публичный Метод

Keep in mind this method will make an api request to account/APIKeyInfo based on the given \Pheal\Core\Config settings with the given key credentials. More important! This method will throw Exceptions on invalid keys or networks errors So place this call into your try statement
public detectAccess ( ) : boolean | Pheal\Core\Result
Результат boolean | Pheal\Core\Result

setAccess() публичный Метод

Set keyType/accessMask
public setAccess ( string $keyType = null, integer $accessMask ) : void
$keyType string must be Account/Character/Corporation or null
$accessMask integer must be integer or 0
Результат void

Описание свойств

$scope публичное свойство

..)
public string $scope
Результат string

$xml публичное свойство

Result of the last XML request, so application can use the raw xml data
public String $xml
Результат String