PHP Class Smile\ElasticsuiteCore\Search\Request\ContainerConfiguration\RelevanceConfig\Factory

Author: Aurelien FOUCRET ([email protected])
Datei anzeigen Open project: smile-sa/elasticsuite Class Usage Examples

Public Methods

Method Description
__construct ( Magento\Framework\ObjectManagerInterface $objectManager, string $instanceName = 'Smile\ElasticsuiteCore\Api\Search\Request\Container\RelevanceConfigurationInterface' ) Constructor.
create ( integer $storeId, string $containerName ) : Smile\ElasticsuiteCore\Api\Search\Request\Container\RelevanceConfigurationInterface Retrieve relevance configuration for a container.

Protected Methods

Method Description
getConfigValue ( string $path, string $scopeCode ) : mixed Read value into the config by path and scope.
loadConfiguration ( string $scopeCode ) : array Load the relevance configuration by scope code.

Private Methods

Method Description
createFuzzinessConfiguration ( array $configurationParams ) : Smile\ElasticsuiteCore\Api\Search\Request\Container\RelevanceConfiguration\FuzzinessConfigurationInterface Create a Fuzziness Configuration Object
getCutoffFrequencyConfiguration ( string $scopeCode ) : float Retrieve cutoff frequency for a container.
getFuzzinessConfiguration ( string $scopeCode ) : Smile\ElasticsuiteCore\Api\Search\Request\Container\RelevanceConfiguration\FuzzinessConfigurationInterface | null Retrieve fuzziness configuration object.
getMinimumShouldMatch ( string $scopeCode ) : string Retrieve minimum should match config for a container.
getPhoneticConfiguration ( string $scopeCode ) : Smile\ElasticsuiteCore\Api\Search\Request\Container\RelevanceConfiguration\PhoneticConfigurationInterface | null Retrieve phonetic configuration object
getPhraseMatchBoostConfiguration ( string $scopeCode ) : boolean | integer Retrieve phrase boost configuration for a container.
getScopeCode ( integer $storeId, string | null $containerName ) : string Retrieve current scope code
getTieBreaker ( string $scopeCode ) : float Retrieve tie breaker config for a container.

Method Details

__construct() public method

Constructor.
public __construct ( Magento\Framework\ObjectManagerInterface $objectManager, string $instanceName = 'Smile\ElasticsuiteCore\Api\Search\Request\Container\RelevanceConfigurationInterface' )
$objectManager Magento\Framework\ObjectManagerInterface Object manager.
$instanceName string Config class name.

create() public method

Retrieve relevance configuration for a container.
public create ( integer $storeId, string $containerName ) : Smile\ElasticsuiteCore\Api\Search\Request\Container\RelevanceConfigurationInterface
$storeId integer Store id.
$containerName string Container identifier.
return Smile\ElasticsuiteCore\Api\Search\Request\Container\RelevanceConfigurationInterface

getConfigValue() protected method

Read value into the config by path and scope.
protected getConfigValue ( string $path, string $scopeCode ) : mixed
$path string Config path.
$scopeCode string Scope coode.
return mixed

loadConfiguration() protected method

Load the relevance configuration by scope code.
protected loadConfiguration ( string $scopeCode ) : array
$scopeCode string Container scope code.
return array