eZ\Publish\Core\Repository\LocationService::getLocationChildCount PHP Method

getLocationChildCount() public method

Returns the number of children which are readable by the current user of a location object.
public getLocationChildCount ( eZ\Publish\API\Repository\Values\Content\Location $location ) : integer
$location eZ\Publish\API\Repository\Values\Content\Location
return integer
    public function getLocationChildCount(APILocation $location)
    {
        $searchResult = $this->searchChildrenLocations($location, 0, 0);
        return $searchResult->totalCount;
    }