Changes after review

This commit is contained in:
Tim Nagel 2015-03-11 14:30:10 +11:00
commit 4c87d24fc1
11 changed files with 141 additions and 262 deletions

View file

@ -1,4 +1,5 @@
<?php
/**
* This file is part of the FOSElasticaBundle project.
*
@ -13,48 +14,31 @@ namespace FOS\ElasticaBundle\Event;
use Symfony\Component\EventDispatcher\Event;
/**
* Populate Event
* Type Populate Event
*
* @author Oleg Andreyev <oleg.andreyev@intexsys.lv>
*/
class TypePopulateEvent extends Event
class TypePopulateEvent extends IndexPopulateEvent
{
const PRE_TYPE_POPULATE = 'elastica.index.type_pre_populate';
const POST_TYPE_POPULATE = 'elastica.index.type_post_populate';
/**
* @var string
*/
private $index;
/**
* @var string
*/
private $type;
/**
* @var array
*/
private $options;
/**
* @param string $index
* @param string $type
* @param bool $reset
* @param array $options
*/
public function __construct($index, $type, $options)
public function __construct($index, $type, $reset, $options)
{
$this->index = $index;
$this->type = $type;
$this->options = $options;
}
parent::__construct($index, $reset, $options);
/**
* @return string
*/
public function getIndex()
{
return $this->index;
$this->type = $type;
}
/**
@ -64,17 +48,4 @@ class TypePopulateEvent extends Event
{
return $this->type;
}
/**
* @return array
*/
public function getOptions()
{
return $this->options;
}
public function setOptions($options)
{
$this->options = $options;
}
}