SettingsService extends Service
in package
Uses ServiceTrait, CacheTrait

This is the settings service class.

This class will retrieve the settings from LogiCommerce API and transform them to objects. All the needed settings operations previous to Framework must be done here.

Tags
see
SettingsService::getSettings()
see
SettingsService::getBlogSettings()
see
SettingsService::getCatalogSettings()
see
SettingsService::getGeneralSettings()
see
SettingsService::getGeoIpSettings()
see
SettingsService::getLegalSettings()
see
SettingsService::getOrdersSettings()
see
SettingsService::getSeoSettings()
see
SettingsService::getSitemapSettings()
see
SettingsService::getStockSettings()
see
SettingsService::getTaxSettings()
see
SettingsService::getUserAccountsSettings()
see
SettingsService::getCountries()
see
SettingsService::getCurrencies()
see
SettingsService::getLanguages()
see
BlogSettings
see
CatalogSettings
see
CountrySettings
see
Currency
see
EcommerceSettings
see
GeneralSettings
see
GeoIPSettings
see
Language
see
LegalSettings
see
OrdersSettings
see
SeoSettings
see
SitemapSettings
see
StockSettings
see
TaxSettings
see
UserAccountsSettings
see
SettingsService::addGetBlogSettings()
see
SettingsService::addGetCountries()
see
SettingsService::addGetCurrencies()
see
SettingsService::addGetLanguages()
see
BatchRequests
see
Service
see
ServiceTrait
uses
ServiceTrait

Table of Contents

DELETE  = \SDK\Core\Enums\MethodType::DELETE
GET  = \SDK\Core\Enums\MethodType::GET
ITEMS  = 'items'
POST  = \SDK\Core\Enums\MethodType::POST
PUT  = \SDK\Core\Enums\MethodType::PUT
addGetBlogSettings() Add the request to get the website blog settings  : void
addGetCountries() Add the request to get the website configured and available countries  : void
addGetCurrencies() Add the request to get the website configured and available currencies  : void
addGetLanguages() Add the request to get the website configured and available languages  : void
getBlogSettings() Returns the website blog settings  : BlogSettings
getCatalogSettings() Returns the website catalog settings  : CatalogSettings
getCountries() Returns the website configured and available countries  : ElementCollection|null
getCurrencies() Returns the website configured and available currencies  : ElementCollection|null
getGeneralSettings() Returns the website general settings  : GeneralSettings
getGeoIpSettings() Returns the website GeoIP settings  : GeoIPSettings
getInstance() Returns the requested model instance.  : Service
getLanguages() Returns the website configured and available languages  : ElementCollection|null
getLegalSettings() Returns the website legal settings  : LegalSettings
getOrdersSettings() Returns the website orders settings  : OrdersSettings
getSeoSettings() Returns the website seo settings  : SeoSettings
getSettings() Returns all the website settings  : EcommerceSettings
getSitemapSettings() Returns the website sitemap settings  : SitemapSettings
getStockSettings() Returns the website stock settings  : StockSettings
getTaxSettings() Returns the website tax settings  : TaxSettings
getUserAccountsSettings() Returns the website user accounts settings  : UserAccountsSettings
__construct()  : mixed
call()  : array<string|int, mixed>
extractParameters()  : array<string|int, mixed>
getCollection()  : mixed
getConnection()  : Connection
getElement()  : Element|null
getElements()  : ElementCollection|null
getResourceElement()  : Element|null
getResponse()  : ElementCollection|null
prepareElement()  : Element|null
prepareElements()  : array<string|int, mixed>
replaceWildcards()  : string

Constants

DELETE

protected mixed DELETE = \SDK\Core\Enums\MethodType::DELETE

GET

protected mixed GET = \SDK\Core\Enums\MethodType::GET

ITEMS

protected mixed ITEMS = 'items'

POST

protected mixed POST = \SDK\Core\Enums\MethodType::POST

PUT

protected mixed PUT = \SDK\Core\Enums\MethodType::PUT

Methods

addGetBlogSettings()

Add the request to get the website blog settings

public addGetBlogSettings(BatchRequests $batchRequests, string $batchName) : void
Parameters
$batchRequests : BatchRequests
$batchName : string

the name that will identify the request on the batch return.

Return values
void

addGetCountries()

Add the request to get the website configured and available countries

public addGetCountries(BatchRequests $batchRequests, string $batchName[, string $languageCode = null ]) : void
Parameters
$batchRequests : BatchRequests
$batchName : string

the name that will identify the request on the batch return.

$languageCode : string = null

Optional. String that sets the language for the countries to be returned.

Return values
void

addGetCurrencies()

Add the request to get the website configured and available currencies

public addGetCurrencies(BatchRequests $batchRequests, string $batchName) : void
Parameters
$batchRequests : BatchRequests
$batchName : string

the name that will identify the request on the batch return.

Return values
void

addGetLanguages()

Add the request to get the website configured and available languages

public addGetLanguages(BatchRequests $batchRequests, string $batchName) : void
Parameters
$batchRequests : BatchRequests
$batchName : string

the name that will identify the request on the batch return.

Return values
void

getCountries()

Returns the website configured and available countries

public getCountries([string $languageCode = null ]) : ElementCollection|null
Parameters
$languageCode : string = null

Optional. String that sets the language for the countries to be returned.

Return values
ElementCollection|null

getInstance()

Returns the requested model instance.

public static getInstance() : Service

If is not setted, this method will set it.

Return values
Service

__construct()

protected __construct() : mixed
Return values
mixed

call()

protected call(Request $request[, string $apiUrl = null ]) : array<string|int, mixed>
Parameters
$request : Request
$apiUrl : string = null
Return values
array<string|int, mixed>

extractParameters()

protected extractParameters([ParametersGroup|null $parametersGroup = null ]) : array<string|int, mixed>
Parameters
$parametersGroup : ParametersGroup|null = null
Return values
array<string|int, mixed>

getCollection()

protected getCollection(array<string|int, mixed> $data, string $class) : mixed
Parameters
$data : array<string|int, mixed>
$class : string
Return values
mixed

getElement()

protected getElement(string $class, string $resource[, int $id = null ][, mixed $params = null ]) : Element|null
Parameters
$class : string
$resource : string
$id : int = null
$params : mixed = null
Return values
Element|null

getResourceElement()

protected getResourceElement(string $class, string $resource[, mixed $params = [] ]) : Element|null
Parameters
$class : string
$resource : string
$params : mixed = []
Return values
Element|null

getResponse()

protected getResponse(array<string|int, mixed> $data, string $class) : ElementCollection|null
Parameters
$data : array<string|int, mixed>
$class : string
Return values
ElementCollection|null

prepareElement()

protected prepareElement(array<string|int, mixed> $data, string $class) : Element|null
Parameters
$data : array<string|int, mixed>
$class : string
Return values
Element|null

prepareElements()

protected prepareElements(array<string|int, mixed> $data, string $class) : array<string|int, mixed>
Parameters
$data : array<string|int, mixed>
$class : string
Return values
array<string|int, mixed>

replaceWildcards()

protected replaceWildcards(string $resource, array<string|int, mixed> $wildcards) : string
Parameters
$resource : string
$wildcards : array<string|int, mixed>
Return values
string

Search results