DynamicShopMessages
in package
Class DynamicShopMessages
Table of Contents
- $cacheKey : string
- $dataCache : DataCache
- $endpointUrl : string
- __construct() : mixed
- ExternalSnippetsControl constructor.
- messages() : JsonHttpControllerResponse
- Returns the snippets as a json response.
- _getCacheResponse() : bool|string
- Get the cached response.
- _getRequestResponse() : bool|string
- Get dynamic messages with cURL request to Gambio's servers.
Properties
$cacheKey
protected
string
$cacheKey
= 'dynamic-shop-messages'
$dataCache
protected
DataCache
$dataCache
$endpointUrl
protected
string
$endpointUrl
Methods
__construct()
ExternalSnippetsControl constructor.
public
__construct() : mixed
Return values
mixed —messages()
Returns the snippets as a json response.
public
messages() : JsonHttpControllerResponse
Return values
JsonHttpControllerResponse —_getCacheResponse()
Get the cached response.
protected
_getCacheResponse() : bool|string
Return values
bool|string —Returns the JSON string or false if the cache is outdated.
_getRequestResponse()
Get dynamic messages with cURL request to Gambio's servers.
protected
_getRequestResponse() : bool|string
Return values
bool|string —Returns the response JSON string or false if an error occurred.