Property | Type | Description | |
---|---|---|---|
$providers | array | A array containing the cached providers. | |
$request | References to the request that travels through the application. | ||
$response |
Method | Description | |
---|---|---|
__construct ( |
||
getClientInfo ( ) : array | null | Simply proxies call to Response object. | |
getHttpClient ( ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient | Returns HttpClient object for setting user-agent string or other CURL available options. | |
getLastError ( ) : string | null | Proxies call to Request object and returns message from the error object. | |
getProvider ( string $provider ) : |
Gets provider object by name. If there is no such provider in providers array, it will try to create it, then save it, and then return. |
Method | Description | |
---|---|---|
addProvider ( string $provider ) | Creates provider by class name, and if success saves it to providers array. Provider class must exist in PROVIDERS_NAMESPACE. | |
buildProvider ( string $className ) : object | Build Provider object with reflection API. | |
resolveProviderClass ( $provider ) : string |
public __construct ( |
||
$request | ||
$response |
protected addProvider ( string $provider ) | ||
$provider | string |
protected buildProvider ( string $className ) : object | ||
$className | string | |
return | object |
public getClientInfo ( ) : array | null | ||
return | array | null |
public getHttpClient ( ) : seregazhuk\PinterestBot\Api\Contracts\HttpClient | ||
return | seregazhuk\PinterestBot\Api\Contracts\HttpClient |
public getLastError ( ) : string | null | ||
return | string | null |
public getProvider ( string $provider ) : |
||
$provider | string | |
return |
protected resolveProviderClass ( $provider ) : string | ||
$provider | ||
return | string |
protected array $providers | ||
return | array |
protected Request,seregazhuk\PinterestBot\Api $request | ||
return |