| @@ -1,5 +1,18 @@ | ||
| 1 | 1 | <?php |
| 2 | +/** | |
| 3 | + * ControllerFactory.php | |
| 4 | + * | |
| 5 | + * The ControllerFactory class file. | |
| 6 | + * | |
| 7 | + * PHP versions 5 | |
| 8 | + * | |
| 9 | + * @author Alexander Schneider <alexanderschneider85@gmail.com> | |
| 10 | + * @copyright 2008-2017 Alexander Schneider | |
| 11 | + * @license http://www.gnu.org/licenses/gpl-2.0.html GNU General Public License, version 2 | |
| 12 | + * @version SVN: $id$ | |
| 13 | + * @link http://wordpress.org/extend/plugins/user-access-manager/ | |
| 14 | + */ | |
| 2 | 15 | |
| 3 | 16 | declare(strict_types=1); |
| 4 | 17 | |
| 5 | 18 | namespace UserAccessManager\Controller; |
| @@ -7,36 +20,36 @@ | ||
| 7 | 20 | use UserAccessManager\Access\AccessHandler; |
| 8 | 21 | use UserAccessManager\Cache\Cache; |
| 9 | 22 | use UserAccessManager\Config\MainConfig; |
| 10 | 23 | use UserAccessManager\Config\WordpressConfig; |
| 11 | -use UserAccessManager\Controller\Backend\Administration\AboutController; | |
| 24 | +use UserAccessManager\Controller\Backend\AboutController; | |
| 12 | 25 | use UserAccessManager\Controller\Backend\BackendController; |
| 13 | 26 | use UserAccessManager\Controller\Backend\CacheController; |
| 14 | -use UserAccessManager\Controller\Backend\ObjectMembership\DynamicGroupsController; | |
| 15 | -use UserAccessManager\Controller\Backend\ObjectMembership\ObjectController; | |
| 16 | -use UserAccessManager\Controller\Backend\ObjectMembership\ObjectInformationFactory; | |
| 17 | -use UserAccessManager\Controller\Backend\ObjectMembership\PostObjectController; | |
| 18 | -use UserAccessManager\Controller\Backend\Administration\SettingsController; | |
| 19 | -use UserAccessManager\Controller\Backend\Administration\SetupController; | |
| 20 | -use UserAccessManager\Controller\Backend\ObjectMembership\TermObjectController; | |
| 21 | -use UserAccessManager\Controller\Backend\Administration\UserGroupController; | |
| 22 | -use UserAccessManager\Controller\Backend\ObjectMembership\UserObjectController; | |
| 27 | +use UserAccessManager\Controller\Backend\DynamicGroupsController; | |
| 28 | +use UserAccessManager\Controller\Backend\ObjectController; | |
| 29 | +use UserAccessManager\Controller\Backend\ObjectInformationFactory; | |
| 30 | +use UserAccessManager\Controller\Backend\PostObjectController; | |
| 31 | +use UserAccessManager\Controller\Backend\SettingsController; | |
| 32 | +use UserAccessManager\Controller\Backend\SetupController; | |
| 33 | +use UserAccessManager\Controller\Backend\TermObjectController; | |
| 34 | +use UserAccessManager\Controller\Backend\UserGroupController; | |
| 35 | +use UserAccessManager\Controller\Backend\UserObjectController; | |
| 23 | 36 | use UserAccessManager\Controller\Frontend\FrontendController; |
| 24 | -use UserAccessManager\Controller\Frontend\Content\PostController; | |
| 37 | +use UserAccessManager\Controller\Frontend\PostController; | |
| 25 | 38 | use UserAccessManager\Controller\Frontend\RedirectController; |
| 26 | -use UserAccessManager\Controller\Frontend\Authentication\ShortCodeController; | |
| 27 | -use UserAccessManager\Controller\Frontend\Content\TermController; | |
| 39 | +use UserAccessManager\Controller\Frontend\ShortCodeController; | |
| 40 | +use UserAccessManager\Controller\Frontend\TermController; | |
| 28 | 41 | use UserAccessManager\Database\Database; |
| 29 | 42 | use UserAccessManager\File\FileHandler; |
| 30 | -use UserAccessManager\File\Delivery\FileObjectFactory; | |
| 43 | +use UserAccessManager\File\FileObjectFactory; | |
| 31 | 44 | use UserAccessManager\Form\FormFactory; |
| 32 | 45 | use UserAccessManager\Form\FormHelper; |
| 33 | 46 | use UserAccessManager\Object\ObjectHandler; |
| 34 | 47 | use UserAccessManager\Object\ObjectMapHandler; |
| 35 | 48 | use UserAccessManager\Setup\SetupHandler; |
| 36 | -use UserAccessManager\User\UserHandler; | |
| 37 | 49 | use UserAccessManager\UserGroup\UserGroupAssignmentHandler; |
| 38 | 50 | use UserAccessManager\UserGroup\UserGroupFactory; |
| 51 | +use UserAccessManager\User\UserHandler; | |
| 39 | 52 | use UserAccessManager\UserGroup\UserGroupHandler; |
| 40 | 53 | use UserAccessManager\Util\DateUtil; |
| 41 | 54 | use UserAccessManager\Util\Util; |
| 42 | 55 | use UserAccessManager\Wrapper\Php; |
| @@ -41,35 +54,194 @@ | ||
| 41 | 54 | use UserAccessManager\Util\Util; |
| 42 | 55 | use UserAccessManager\Wrapper\Php; |
| 43 | 56 | use UserAccessManager\Wrapper\Wordpress; |
| 44 | 57 | |
| 58 | +/** | |
| 59 | + * Class ControllerFactory | |
| 60 | + * | |
| 61 | + * @package UserAccessManager\Controller | |
| 62 | + */ | |
| 45 | 63 | class ControllerFactory |
| 46 | 64 | { |
| 65 | + /** | |
| 66 | + * @var Php | |
| 67 | + */ | |
| 68 | + private $php; | |
| 69 | + | |
| 70 | + /** | |
| 71 | + * @var Wordpress | |
| 72 | + */ | |
| 73 | + private $wordpress; | |
| 74 | + | |
| 75 | + /** | |
| 76 | + * @var Database | |
| 77 | + */ | |
| 78 | + private $database; | |
| 79 | + | |
| 80 | + /** | |
| 81 | + * @var WordpressConfig | |
| 82 | + */ | |
| 83 | + private $wordpressConfig; | |
| 84 | + | |
| 85 | + /** | |
| 86 | + * @var MainConfig | |
| 87 | + */ | |
| 88 | + private $mainConfig; | |
| 89 | + | |
| 90 | + /** | |
| 91 | + * @var Util | |
| 92 | + */ | |
| 93 | + private $util; | |
| 94 | + | |
| 95 | + /** | |
| 96 | + * @var DateUtil | |
| 97 | + */ | |
| 98 | + private $dateUtil; | |
| 99 | + | |
| 100 | + /** | |
| 101 | + * @var Cache | |
| 102 | + */ | |
| 103 | + private $cache; | |
| 104 | + | |
| 105 | + /** | |
| 106 | + * @var ObjectHandler | |
| 107 | + */ | |
| 108 | + private $objectHandler; | |
| 109 | + | |
| 110 | + /** | |
| 111 | + * @var ObjectMapHandler | |
| 112 | + */ | |
| 113 | + private $objectMapHandler; | |
| 114 | + | |
| 115 | + /** | |
| 116 | + * @var UserHandler | |
| 117 | + */ | |
| 118 | + private $userHandler; | |
| 119 | + | |
| 120 | + /** | |
| 121 | + * @var UserGroupHandler | |
| 122 | + */ | |
| 123 | + private $userGroupHandler; | |
| 124 | + | |
| 125 | + /** | |
| 126 | + * @var UserGroupFactory | |
| 127 | + */ | |
| 128 | + private $userGroupFactory; | |
| 129 | + | |
| 130 | + /** | |
| 131 | + * @var UserGroupAssignmentHandler | |
| 132 | + */ | |
| 133 | + private $userGroupAssignmentHandler; | |
| 134 | + | |
| 135 | + /** | |
| 136 | + * @var AccessHandler | |
| 137 | + */ | |
| 138 | + private $accessHandler; | |
| 139 | + | |
| 140 | + /** | |
| 141 | + * @var FileHandler | |
| 142 | + */ | |
| 143 | + private $fileHandler; | |
| 144 | + | |
| 145 | + /** | |
| 146 | + * @var FileObjectFactory | |
| 147 | + */ | |
| 148 | + private $fileObjectFactory; | |
| 149 | + | |
| 150 | + /** | |
| 151 | + * @var SetupHandler | |
| 152 | + */ | |
| 153 | + private $setupHandler; | |
| 154 | + | |
| 155 | + /** | |
| 156 | + * @var FormFactory | |
| 157 | + */ | |
| 158 | + private $formFactory; | |
| 159 | + | |
| 160 | + /** | |
| 161 | + * @var FormHelper | |
| 162 | + */ | |
| 163 | + private $formHelper; | |
| 164 | + | |
| 165 | + /** | |
| 166 | + * @var ObjectInformationFactory | |
| 167 | + */ | |
| 168 | + private $objectInformationFactory; | |
| 169 | + | |
| 170 | + /** | |
| 171 | + * ControllerFactory constructor. | |
| 172 | + * @param Php $php | |
| 173 | + * @param Wordpress $wordpress | |
| 174 | + * @param Database $database | |
| 175 | + * @param WordpressConfig $wordpressConfig | |
| 176 | + * @param MainConfig $mainConfig | |
| 177 | + * @param Util $util | |
| 178 | + * @param DateUtil $dateUtil | |
| 179 | + * @param Cache $cache | |
| 180 | + * @param ObjectHandler $objectHandler | |
| 181 | + * @param ObjectMapHandler $objectMapHandler | |
| 182 | + * @param UserHandler $userHandler | |
| 183 | + * @param UserGroupHandler $userGroupHandler | |
| 184 | + * @param UserGroupFactory $userGroupFactory | |
| 185 | + * @param UserGroupAssignmentHandler $userGroupAssignmentHandler | |
| 186 | + * @param AccessHandler $accessHandler | |
| 187 | + * @param FileHandler $fileHandler | |
| 188 | + * @param FileObjectFactory $fileObjectFactory | |
| 189 | + * @param SetupHandler $setupHandler | |
| 190 | + * @param FormFactory $formFactory | |
| 191 | + * @param FormHelper $formHelper | |
| 192 | + * @param ObjectInformationFactory $objectInformationFactory | |
| 193 | + */ | |
| 47 | 194 | public function __construct( |
| 48 | - private Php $php, | |
| 49 | - private Wordpress $wordpress, | |
| 50 | - private Database $database, | |
| 51 | - private WordpressConfig $wordpressConfig, | |
| 52 | - private MainConfig $mainConfig, | |
| 53 | - private Util $util, | |
| 54 | - private DateUtil $dateUtil, | |
| 55 | - private Cache $cache, | |
| 56 | - private ObjectHandler $objectHandler, | |
| 57 | - private ObjectMapHandler $objectMapHandler, | |
| 58 | - private UserHandler $userHandler, | |
| 59 | - private UserGroupHandler $userGroupHandler, | |
| 60 | - private UserGroupFactory $userGroupFactory, | |
| 61 | - private UserGroupAssignmentHandler $userGroupAssignmentHandler, | |
| 62 | - private AccessHandler $accessHandler, | |
| 63 | - private FileHandler $fileHandler, | |
| 64 | - private FileObjectFactory $fileObjectFactory, | |
| 65 | - private SetupHandler $setupHandler, | |
| 66 | - private FormFactory $formFactory, | |
| 67 | - private FormHelper $formHelper, | |
| 68 | - private ObjectInformationFactory $objectInformationFactory | |
| 195 | + Php $php, | |
| 196 | + Wordpress $wordpress, | |
| 197 | + Database $database, | |
| 198 | + WordpressConfig $wordpressConfig, | |
| 199 | + MainConfig $mainConfig, | |
| 200 | + Util $util, | |
| 201 | + DateUtil $dateUtil, | |
| 202 | + Cache $cache, | |
| 203 | + ObjectHandler $objectHandler, | |
| 204 | + ObjectMapHandler $objectMapHandler, | |
| 205 | + UserHandler $userHandler, | |
| 206 | + UserGroupHandler $userGroupHandler, | |
| 207 | + UserGroupFactory $userGroupFactory, | |
| 208 | + UserGroupAssignmentHandler $userGroupAssignmentHandler, | |
| 209 | + AccessHandler $accessHandler, | |
| 210 | + FileHandler $fileHandler, | |
| 211 | + FileObjectFactory $fileObjectFactory, | |
| 212 | + SetupHandler $setupHandler, | |
| 213 | + FormFactory $formFactory, | |
| 214 | + FormHelper $formHelper, | |
| 215 | + ObjectInformationFactory $objectInformationFactory | |
| 69 | 216 | ) { |
| 217 | + $this->php = $php; | |
| 218 | + $this->wordpress = $wordpress; | |
| 219 | + $this->database = $database; | |
| 220 | + $this->wordpressConfig = $wordpressConfig; | |
| 221 | + $this->mainConfig = $mainConfig; | |
| 222 | + $this->util = $util; | |
| 223 | + $this->dateUtil = $dateUtil; | |
| 224 | + $this->cache = $cache; | |
| 225 | + $this->objectHandler = $objectHandler; | |
| 226 | + $this->objectMapHandler = $objectMapHandler; | |
| 227 | + $this->userHandler = $userHandler; | |
| 228 | + $this->userGroupHandler = $userGroupHandler; | |
| 229 | + $this->userGroupFactory = $userGroupFactory; | |
| 230 | + $this->userGroupAssignmentHandler = $userGroupAssignmentHandler; | |
| 231 | + $this->accessHandler = $accessHandler; | |
| 232 | + $this->fileHandler = $fileHandler; | |
| 233 | + $this->fileObjectFactory = $fileObjectFactory; | |
| 234 | + $this->setupHandler = $setupHandler; | |
| 235 | + $this->formFactory = $formFactory; | |
| 236 | + $this->formHelper = $formHelper; | |
| 237 | + $this->objectInformationFactory = $objectInformationFactory; | |
| 70 | 238 | } |
| 71 | 239 | |
| 240 | + /** | |
| 241 | + * Creates and returns a new backend controller. | |
| 242 | + * @return BackendController | |
| 243 | + */ | |
| 72 | 244 | public function createBackendController(): BackendController |
| 73 | 245 | { |
| 74 | 246 | return new BackendController( |
| 75 | 247 | $this->php, |
| @@ -75,12 +247,17 @@ | ||
| 75 | 247 | $this->php, |
| 76 | 248 | $this->wordpress, |
| 77 | 249 | $this->wordpressConfig, |
| 78 | 250 | $this->userHandler, |
| 251 | + $this->fileHandler, | |
| 79 | 252 | $this->setupHandler |
| 80 | 253 | ); |
| 81 | 254 | } |
| 82 | 255 | |
| 256 | + /** | |
| 257 | + * Creates and returns a new backend about controller. | |
| 258 | + * @return AboutController | |
| 259 | + */ | |
| 83 | 260 | public function createBackendAboutController(): AboutController |
| 84 | 261 | { |
| 85 | 262 | return new AboutController( |
| 86 | 263 | $this->php, |
| @@ -89,15 +266,14 @@ | ||
| 89 | 266 | ); |
| 90 | 267 | } |
| 91 | 268 | |
| 92 | 269 | /** |
| 93 | - * @template TController of ObjectController | |
| 94 | - * @param class-string<TController> $controllerClass | |
| 95 | - * @return TController | |
| 270 | + * Creates and returns a new backend object controller. | |
| 271 | + * @return ObjectController | |
| 96 | 272 | */ |
| 97 | - private function createObjectController(string $controllerClass): ObjectController | |
| 273 | + public function createBackendObjectController(): ObjectController | |
| 98 | 274 | { |
| 99 | - return new $controllerClass( | |
| 275 | + return new ObjectController( | |
| 100 | 276 | $this->php, |
| 101 | 277 | $this->wordpress, |
| 102 | 278 | $this->wordpressConfig, |
| 103 | 279 | $this->mainConfig, |
| @@ -111,38 +287,111 @@ | ||
| 111 | 287 | $this->objectInformationFactory |
| 112 | 288 | ); |
| 113 | 289 | } |
| 114 | 290 | |
| 115 | - public function createBackendObjectController(): ObjectController | |
| 116 | - { | |
| 117 | - return $this->createObjectController(ObjectController::class); | |
| 118 | - } | |
| 119 | - | |
| 291 | + /** | |
| 292 | + * Creates and returns a new backend cache controller. | |
| 293 | + * @return CacheController | |
| 294 | + */ | |
| 120 | 295 | public function createBackendCacheController(): CacheController |
| 121 | 296 | { |
| 122 | - return new CacheController($this->cache); | |
| 297 | + return new CacheController( | |
| 298 | + $this->cache | |
| 299 | + ); | |
| 123 | 300 | } |
| 124 | 301 | |
| 302 | + /** | |
| 303 | + * Creates and returns a new backend post object controller. | |
| 304 | + * @return PostObjectController | |
| 305 | + */ | |
| 125 | 306 | public function createBackendPostObjectController(): PostObjectController |
| 126 | 307 | { |
| 127 | - return $this->createObjectController(PostObjectController::class); | |
| 308 | + return new PostObjectController( | |
| 309 | + $this->php, | |
| 310 | + $this->wordpress, | |
| 311 | + $this->wordpressConfig, | |
| 312 | + $this->mainConfig, | |
| 313 | + $this->database, | |
| 314 | + $this->dateUtil, | |
| 315 | + $this->objectHandler, | |
| 316 | + $this->userHandler, | |
| 317 | + $this->userGroupHandler, | |
| 318 | + $this->userGroupAssignmentHandler, | |
| 319 | + $this->accessHandler, | |
| 320 | + $this->objectInformationFactory | |
| 321 | + ); | |
| 128 | 322 | } |
| 129 | 323 | |
| 324 | + /** | |
| 325 | + * Creates and returns a new backend term object controller. | |
| 326 | + * @return TermObjectController | |
| 327 | + */ | |
| 130 | 328 | public function createBackendTermObjectController(): TermObjectController |
| 131 | 329 | { |
| 132 | - return $this->createObjectController(TermObjectController::class); | |
| 330 | + return new TermObjectController( | |
| 331 | + $this->php, | |
| 332 | + $this->wordpress, | |
| 333 | + $this->wordpressConfig, | |
| 334 | + $this->mainConfig, | |
| 335 | + $this->database, | |
| 336 | + $this->dateUtil, | |
| 337 | + $this->objectHandler, | |
| 338 | + $this->userHandler, | |
| 339 | + $this->userGroupHandler, | |
| 340 | + $this->userGroupAssignmentHandler, | |
| 341 | + $this->accessHandler, | |
| 342 | + $this->objectInformationFactory | |
| 343 | + ); | |
| 133 | 344 | } |
| 134 | 345 | |
| 346 | + /** | |
| 347 | + * Creates and returns a new backend user object controller. | |
| 348 | + * @return UserObjectController | |
| 349 | + */ | |
| 135 | 350 | public function createBackendUserObjectController(): UserObjectController |
| 136 | 351 | { |
| 137 | - return $this->createObjectController(UserObjectController::class); | |
| 352 | + return new UserObjectController( | |
| 353 | + $this->php, | |
| 354 | + $this->wordpress, | |
| 355 | + $this->wordpressConfig, | |
| 356 | + $this->mainConfig, | |
| 357 | + $this->database, | |
| 358 | + $this->dateUtil, | |
| 359 | + $this->objectHandler, | |
| 360 | + $this->userHandler, | |
| 361 | + $this->userGroupHandler, | |
| 362 | + $this->userGroupAssignmentHandler, | |
| 363 | + $this->accessHandler, | |
| 364 | + $this->objectInformationFactory | |
| 365 | + ); | |
| 138 | 366 | } |
| 139 | 367 | |
| 368 | + /** | |
| 369 | + * Creates and returns a new backend dynamic group controller. | |
| 370 | + * @return DynamicGroupsController | |
| 371 | + */ | |
| 140 | 372 | public function createBackendDynamicGroupsController(): DynamicGroupsController |
| 141 | 373 | { |
| 142 | - return $this->createObjectController(DynamicGroupsController::class); | |
| 374 | + return new DynamicGroupsController( | |
| 375 | + $this->php, | |
| 376 | + $this->wordpress, | |
| 377 | + $this->wordpressConfig, | |
| 378 | + $this->mainConfig, | |
| 379 | + $this->database, | |
| 380 | + $this->dateUtil, | |
| 381 | + $this->objectHandler, | |
| 382 | + $this->userHandler, | |
| 383 | + $this->userGroupHandler, | |
| 384 | + $this->userGroupAssignmentHandler, | |
| 385 | + $this->accessHandler, | |
| 386 | + $this->objectInformationFactory | |
| 387 | + ); | |
| 143 | 388 | } |
| 144 | 389 | |
| 390 | + /** | |
| 391 | + * Creates and returns a new backend setup controller. | |
| 392 | + * @return SettingsController | |
| 393 | + */ | |
| 145 | 394 | public function createBackendSettingsController(): SettingsController |
| 146 | 395 | { |
| 147 | 396 | return new SettingsController( |
| 148 | 397 | $this->php, |
| @@ -155,8 +404,12 @@ | ||
| 155 | 404 | $this->formHelper |
| 156 | 405 | ); |
| 157 | 406 | } |
| 158 | 407 | |
| 408 | + /** | |
| 409 | + * Creates and returns a new backend setup controller. | |
| 410 | + * @return SetupController | |
| 411 | + */ | |
| 159 | 412 | public function createBackendSetupController(): SetupController |
| 160 | 413 | { |
| 161 | 414 | return new SetupController( |
| 162 | 415 | $this->php, |
| @@ -166,8 +419,12 @@ | ||
| 166 | 419 | $this->setupHandler |
| 167 | 420 | ); |
| 168 | 421 | } |
| 169 | 422 | |
| 423 | + /** | |
| 424 | + * Creates and returns a new backend user group controller. | |
| 425 | + * @return UserGroupController | |
| 426 | + */ | |
| 170 | 427 | public function createBackendUserGroupController(): UserGroupController |
| 171 | 428 | { |
| 172 | 429 | return new UserGroupController( |
| 173 | 430 | $this->php, |
| @@ -178,8 +435,12 @@ | ||
| 178 | 435 | $this->formHelper |
| 179 | 436 | ); |
| 180 | 437 | } |
| 181 | 438 | |
| 439 | + /** | |
| 440 | + * Creates and returns a new frontend controller. | |
| 441 | + * @return FrontendController | |
| 442 | + */ | |
| 182 | 443 | public function createFrontendController(): FrontendController |
| 183 | 444 | { |
| 184 | 445 | return new FrontendController( |
| 185 | 446 | $this->php, |
| @@ -189,8 +450,12 @@ | ||
| 189 | 450 | $this->accessHandler |
| 190 | 451 | ); |
| 191 | 452 | } |
| 192 | 453 | |
| 454 | + /** | |
| 455 | + * Creates and returns a new frontend post controller. | |
| 456 | + * @return PostController | |
| 457 | + */ | |
| 193 | 458 | public function createFrontendPostController(): PostController |
| 194 | 459 | { |
| 195 | 460 | return new PostController( |
| 196 | 461 | $this->php, |
| @@ -196,17 +461,21 @@ | ||
| 196 | 461 | $this->php, |
| 197 | 462 | $this->wordpress, |
| 198 | 463 | $this->wordpressConfig, |
| 199 | 464 | $this->mainConfig, |
| 465 | + $this->database, | |
| 200 | 466 | $this->util, |
| 201 | 467 | $this->objectHandler, |
| 202 | 468 | $this->userHandler, |
| 203 | 469 | $this->userGroupHandler, |
| 204 | - $this->accessHandler, | |
| 205 | - $this->database | |
| 470 | + $this->accessHandler | |
| 206 | 471 | ); |
| 207 | 472 | } |
| 208 | 473 | |
| 474 | + /** | |
| 475 | + * Creates and returns a new frontend redirect controller. | |
| 476 | + * @return RedirectController | |
| 477 | + */ | |
| 209 | 478 | public function createFrontendRedirectController(): RedirectController |
| 210 | 479 | { |
| 211 | 480 | return new RedirectController( |
| 212 | 481 | $this->php, |
| @@ -222,8 +491,12 @@ | ||
| 222 | 491 | $this->fileObjectFactory |
| 223 | 492 | ); |
| 224 | 493 | } |
| 225 | 494 | |
| 495 | + /** | |
| 496 | + * Creates and returns a new frontend short code controller. | |
| 497 | + * @return ShortCodeController | |
| 498 | + */ | |
| 226 | 499 | public function createFrontendShortCodeController(): ShortCodeController |
| 227 | 500 | { |
| 228 | 501 | return new ShortCodeController( |
| 229 | 502 | $this->php, |
| @@ -232,8 +505,12 @@ | ||
| 232 | 505 | $this->userGroupHandler |
| 233 | 506 | ); |
| 234 | 507 | } |
| 235 | 508 | |
| 509 | + /** | |
| 510 | + * Creates and returns a new frontend term controller. | |
| 511 | + * @return TermController | |
| 512 | + */ | |
| 236 | 513 | public function createFrontendTermController(): TermController |
| 237 | 514 | { |
| 238 | 515 | return new TermController( |
| 239 | 516 | $this->php, |
| @@ -241,11 +518,11 @@ | ||
| 241 | 518 | $this->wordpressConfig, |
| 242 | 519 | $this->mainConfig, |
| 243 | 520 | $this->util, |
| 244 | 521 | $this->objectHandler, |
| 522 | + $this->objectMapHandler, | |
| 245 | 523 | $this->userHandler, |
| 246 | 524 | $this->userGroupHandler, |
| 247 | - $this->accessHandler, | |
| 248 | - $this->objectMapHandler | |
| 525 | + $this->accessHandler | |
| 249 | 526 | ); |
| 250 | 527 | } |
| 251 | 528 | } |