<?php namespace IQDEV\Search; use IQDEV\Search\Document\ProductCollection; use IQDEV\Search\Facet\FacetCollection; class Result { private ProductCollection $products; private FacetCollection $facets; private int $total = 0; public function __construct() { $this->products = new ProductCollection(); $this->facets = new FacetCollection(); } public function setTotal(int $total): void { $this->total = $total; } public function getTotal(): int { return $this->total; } public function getProducts(): ProductCollection { return $this->products; } public function getFacets(): FacetCollection { return $this->facets; } }