ILIAS  trunk Revision v11.0_alpha-1723-g8e69f309bab
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
BundledRequestBuilder.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
20 
22 
25 
30 {
33 
34  public function __construct()
35  {
36  $this->legacy = new LegacyRequestBuilder();
37  $this->static = new StaticURLRequestBuilder();
38  }
39 
40  public function buildRequest(Services $http, Factory $refinery, array $handlers): ?Request
41  {
42  if (($request = $this->legacy->buildRequest(
43  $http,
44  $refinery,
45  $handlers
46  )) instanceof Request) {
47  // we have now the situation that a new static URL is requested, but the handler is not yet registered or implemented
48  // we built a legacy request using the LegacyRequestBuilder for this to let the old system handle it.
49  return $request;
50  }
51 
52  return $this->static->buildRequest($http, $refinery, $handlers);
53  }
54 
55 }
$http
Definition: deliver.php:30
buildRequest(Services $http, Factory $refinery, array $handlers)
legacy()
expected output: > ILIAS shows the rendered Component.
Definition: legacy.php:29