$idsOnly
$idsOnly : boolean
Base class for all adapters which support the response of records with ids only.
The adapter classes could conceivably be placed in the \Core\Server namespace, but that would potentially discourage fiddling with and extending these classes. The adapters are main components of the external API of this library. Most other classes are just used to make the adapters work.
$configuration : \FACTFinder\Core\ConfigurationInterface
$request : \FACTFinder\Core\Server\Request
$urlBuilder : \FACTFinder\Core\Client\UrlBuilder
$lastResponse : \FACTFinder\Core\Server\Response
__construct(string $loggerClass, \FACTFinder\Core\ConfigurationInterface $configuration, \FACTFinder\Core\Server\Request $request, \FACTFinder\Core\Client\UrlBuilder $urlBuilder, \FACTFinder\Core\AbstractEncodingConverter $encodingConverter = null)
| string | $loggerClass | Class name of logger to use. The class should implement FACTFinder\Util\LoggerInterface. |
| \FACTFinder\Core\ConfigurationInterface | $configuration | Configuration object to use. |
| \FACTFinder\Core\Server\Request | $request | The request object from which to obtain the server data. |
| \FACTFinder\Core\Client\UrlBuilder | $urlBuilder | Client URL builder object to use. |
| \FACTFinder\Core\AbstractEncodingConverter | $encodingConverter | Encoding converter object to use |
getSimilarAttributes() : array<mixed,mixed>
Returns the attributes based on which similar records are determined as well as the source product's values of those attributes. If no ID has been set, there will be a warning raised and an empty array will be returned.
Attribute names as keys and attribute values as values.
getSimilarRecords() : \FACTFinder\Data\Result
Returns similar records for the ID previously specified. If no ID has been set, there will be a warning raised and an empty result will be returned.
useResponseContentProcessor(object $callable)
Pass in a function to process the response content. This method is not used within the library, but may be convenient when writing custom adapters.
| object | $callable | A function (or invokable object) that processes a single string parameter. |
if $callable is not callable.