| @@ 225-237 (lines=13) @@ | ||
| 222 | * |
|
| 223 | * @throws \RuntimeException If not found |
|
| 224 | */ |
|
| 225 | protected function getModelsFolder() |
|
| 226 | { |
|
| 227 | $folder = $this->client->getFolder() . '/components/' . $this->option . '/models'; |
|
| 228 | ||
| 229 | if (is_dir($folder)) |
|
| 230 | { |
|
| 231 | return $folder; |
|
| 232 | } |
|
| 233 | ||
| 234 | throw new \RuntimeException( |
|
| 235 | sprintf("Cannot find the models folder for `%s` component in `%s` folder.", $this->option, $this->client->getName()) |
|
| 236 | ); |
|
| 237 | } |
|
| 238 | ||
| 239 | /** |
|
| 240 | * Get the folder where the tables are. |
|
| @@ 246-258 (lines=13) @@ | ||
| 243 | * |
|
| 244 | * @throws \RuntimeException If not found |
|
| 245 | */ |
|
| 246 | protected function getTablesFolder() |
|
| 247 | { |
|
| 248 | $folder = $this->client->getFolder() . '/components/' . $this->option . '/tables'; |
|
| 249 | ||
| 250 | if (is_dir($folder)) |
|
| 251 | { |
|
| 252 | return $folder; |
|
| 253 | } |
|
| 254 | ||
| 255 | throw new \RuntimeException( |
|
| 256 | sprintf("Cannot find the tables folder for `%s` component in `%s` folder.", $this->option, $this->client->getName()) |
|
| 257 | ); |
|
| 258 | } |
|
| 259 | ||
| 260 | /** |
|
| 261 | * Get the component prefix. |
|