1 | <?php |
||
22 | class ManagerBuilder |
||
23 | { |
||
24 | /** |
||
25 | * @var Builder[] |
||
26 | */ |
||
27 | protected $builders = []; |
||
28 | |||
29 | /** |
||
30 | * Load Doctrine managers from settings array. |
||
31 | * |
||
32 | * @param array $settings |
||
33 | * |
||
34 | * @throws \RuntimeException |
||
35 | * |
||
36 | * @return $this |
||
37 | */ |
||
38 | public function loadSettings(array $settings) |
||
54 | |||
55 | /** |
||
56 | * Register ORM entity managers. |
||
57 | * |
||
58 | * @param array $settings |
||
59 | * |
||
60 | * @throws \RuntimeException |
||
61 | */ |
||
62 | protected function registerEntityManagers(array $settings) |
||
76 | |||
77 | /** |
||
78 | * Register MongoDB ODM document managers. |
||
79 | * |
||
80 | * @param array $settings |
||
81 | * |
||
82 | * @throws \RuntimeException |
||
83 | */ |
||
84 | protected function registerMongoDBDocumentManagers(array $settings) |
||
98 | |||
99 | /** |
||
100 | * Register CouchDB ODM document managers. |
||
101 | * |
||
102 | * @param array $settings |
||
103 | * |
||
104 | * @throws \RuntimeException |
||
105 | */ |
||
106 | protected function registerCouchDBDocumentManagers(array $settings) |
||
120 | |||
121 | /** |
||
122 | * Add manager builder. |
||
123 | * |
||
124 | * @param Builder $builder |
||
125 | * |
||
126 | * @throws \RuntimeException |
||
127 | * |
||
128 | * @return $this |
||
129 | */ |
||
130 | public function addBuilder(Builder $builder) |
||
146 | |||
147 | /** |
||
148 | * Get registered builder's managers. |
||
149 | * |
||
150 | * @return \Doctrine\Common\Persistence\ObjectManager[] |
||
151 | */ |
||
152 | public function getManagers() |
||
161 | |||
162 | /** |
||
163 | * Get registered builder's manager. |
||
164 | * |
||
165 | * @param string $name |
||
166 | * |
||
167 | * @throws \RuntimeException |
||
168 | * |
||
169 | * @return \Doctrine\Common\Persistence\ObjectManager |
||
170 | */ |
||
171 | public function getManager($name) |
||
179 | |||
180 | /** |
||
181 | * Get console application. |
||
182 | * |
||
183 | * @return Application |
||
184 | */ |
||
185 | public function getCLIApplication() |
||
200 | } |
||
201 |