1 | <?php |
||
19 | class IndexPopulateEvent extends IndexEvent |
||
20 | { |
||
21 | /** |
||
22 | * @Event("FOS\ElasticaBundle\Event\IndexPopulateEvent") |
||
23 | */ |
||
24 | const PRE_INDEX_POPULATE = 'elastica.index.index_pre_populate'; |
||
25 | |||
26 | /** |
||
27 | * @Event("FOS\ElasticaBundle\Event\IndexPopulateEvent") |
||
28 | */ |
||
29 | const POST_INDEX_POPULATE = 'elastica.index.index_post_populate'; |
||
30 | |||
31 | /** |
||
32 | * @var bool |
||
33 | */ |
||
34 | private $reset; |
||
35 | |||
36 | /** |
||
37 | * @var array |
||
38 | */ |
||
39 | private $options; |
||
40 | |||
41 | /** |
||
42 | * @param string $index |
||
43 | * @param bool $reset |
||
44 | * @param array $options |
||
45 | */ |
||
46 | 5 | public function __construct($index, $reset, $options) |
|
53 | |||
54 | /** |
||
55 | * @return bool |
||
56 | */ |
||
57 | 3 | public function isReset() |
|
61 | |||
62 | /** |
||
63 | * @return array |
||
64 | */ |
||
65 | public function getOptions() |
||
69 | |||
70 | /** |
||
71 | * @param bool $reset |
||
72 | */ |
||
73 | 1 | public function setReset($reset) |
|
77 | |||
78 | /** |
||
79 | * @param string $name |
||
80 | * |
||
81 | * @return mixed |
||
82 | * |
||
83 | * @throws \InvalidArgumentException if option does not exist |
||
84 | */ |
||
85 | 2 | public function getOption($name) |
|
93 | |||
94 | /** |
||
95 | * @param string $name |
||
96 | * @param mixed $value |
||
97 | */ |
||
98 | public function setOption($name, $value) |
||
102 | } |
||
103 |