public function loadBookmarks(Request $request): RestValue
    {
        $offset = $request->query->getInt('offset', 0);
        $limit = $request->query->getInt('limit', 25);

        $restLocations = [];
        $bookmarks = $this->bookmarkService->loadBookmarks($offset, $limit);
        foreach ($bookmarks as $bookmark) {
            $restLocations[] = new Values\RestLocation(
                $bookmark,
                $this->locationService->getLocationChildCount($bookmark)
            );
        }

        return new Values\BookmarkList($bookmarks->totalCount, $restLocations);
    }
public function loadBookmarks(Request $request): RestValue
    {
        $offset = $request->query->getInt('offset', 0);
        $limit = $request->query->getInt('limit', 25);

        $restLocations = [];
        $bookmarks = $this->bookmarkService->loadBookmarks($offset, $limit);
        foreach ($bookmarks as $bookmark) {
            $restLocations[] = new Values\RestLocation(
                $bookmark,
                $this->locationService->getLocationChildCount($bookmark)
            );
        }

        return new Values\BookmarkList($bookmarks->totalCount, $restLocations);
    }
public function loadBookmarks ( Request $ request ) : RestValue { $ offset = $ request -> query -> getInt ( 'offset' , 0 ) ; $ limit = $ request -> query -> getInt ( 'limit' , 25 ) ; $ restLocations = [ ] ; $ bookmarks = $ this -> bookmarkService -> loadBookmarks ( $ offset , $ limit ) ; foreach ( $ bookmarks as $ bookmark ) { $ restLocations [ ] = new Values \ RestLocation ( $ bookmark , $ this -> locationService -> getLocationChildCount ( $ bookmark ) ) ; } return new Values \ BookmarkList ( $ bookmarks -> totalCount , $ restLocations ) ; }
List bookmarked locations.

@param \Symfony\Component\HttpFoundation\Request $request

@throws \eZ\Publish\API\Repository\Exceptions\InvalidArgumentException

@return \eZ\Publish\Core\REST\Common\Value
List bookmarked locations .