eZ\Publish\Core\Search\Elasticsearch\Content\Handler::bulkIndexLocations PHP Method

bulkIndexLocations() public method

Indexes several Locations.
public bulkIndexLocations ( array $locations )
$locations array
    public function bulkIndexLocations(array $locations)
    {
        $documents = array();
        foreach ($locations as $location) {
            $documents[] = $this->mapper->mapLocation($location);
        }
        $this->gateway->bulkIndex($documents);
    }