private function searchByString($searchString, $rootClass, $offset, $limit)
    {
        /** @var Search $searchService */
        $searchService = $this->getServiceLocator()->get(Search::SERVICE_ID);
        /** @var ResultSet $result */
        $result = $searchService->query($searchString, $rootClass, $offset, $limit);
        $count = $result->getTotalCount();
        return $this->format($result, $count, $offset, $limit);
    }