Mercurial > hg > isophonics-drupal-site
comparison core/lib/Drupal/Core/DrupalKernelInterface.php @ 0:4c8ae668cc8c
Initial import (non-working)
author | Chris Cannam |
---|---|
date | Wed, 29 Nov 2017 16:09:58 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:4c8ae668cc8c |
---|---|
1 <?php | |
2 | |
3 namespace Drupal\Core; | |
4 | |
5 use Symfony\Component\DependencyInjection\ContainerAwareInterface; | |
6 use Symfony\Component\HttpKernel\HttpKernelInterface; | |
7 use Symfony\Component\HttpFoundation\Request; | |
8 | |
9 /** | |
10 * The interface for DrupalKernel, the core of Drupal. | |
11 * | |
12 * This interface extends Symfony's KernelInterface and adds methods for | |
13 * responding to modules being enabled or disabled during its lifetime. | |
14 */ | |
15 interface DrupalKernelInterface extends HttpKernelInterface, ContainerAwareInterface { | |
16 | |
17 /** | |
18 * Event fired when the service container finished initializing in subrequest. | |
19 * | |
20 * This event allows you to initialize overrides such as language to the | |
21 * services. | |
22 * | |
23 * @var string | |
24 */ | |
25 const CONTAINER_INITIALIZE_SUBREQUEST_FINISHED = 'kernel.container.finish_container_initialize_subrequest'; | |
26 | |
27 /** | |
28 * Boots the current kernel. | |
29 * | |
30 * @return $this | |
31 */ | |
32 public function boot(); | |
33 | |
34 /** | |
35 * Shuts down the kernel. | |
36 */ | |
37 public function shutdown(); | |
38 | |
39 /** | |
40 * Discovers available serviceProviders. | |
41 * | |
42 * @return array | |
43 * The available serviceProviders. | |
44 */ | |
45 public function discoverServiceProviders(); | |
46 | |
47 /** | |
48 * Returns all registered service providers. | |
49 * | |
50 * @param string $origin | |
51 * The origin for which to return service providers; one of 'app' or 'site'. | |
52 * | |
53 * @return array | |
54 * An associative array of ServiceProvider objects, keyed by name. | |
55 */ | |
56 public function getServiceProviders($origin); | |
57 | |
58 /** | |
59 * Gets the current container. | |
60 * | |
61 * @return \Symfony\Component\DependencyInjection\ContainerInterface | |
62 * A ContainerInterface instance. | |
63 */ | |
64 public function getContainer(); | |
65 | |
66 /** | |
67 * Returns the cached container definition - if any. | |
68 * | |
69 * This also allows inspecting a built container for debugging purposes. | |
70 * | |
71 * @return array|null | |
72 * The cached container definition or NULL if not found in cache. | |
73 */ | |
74 public function getCachedContainerDefinition(); | |
75 | |
76 /** | |
77 * Set the current site path. | |
78 * | |
79 * @param string $path | |
80 * The current site path. | |
81 * | |
82 * @throws \LogicException | |
83 * In case the kernel is already booted. | |
84 */ | |
85 public function setSitePath($path); | |
86 | |
87 /** | |
88 * Get the site path. | |
89 * | |
90 * @return string | |
91 * The current site path. | |
92 */ | |
93 public function getSitePath(); | |
94 | |
95 /** | |
96 * Gets the app root. | |
97 * | |
98 * @return string | |
99 */ | |
100 public function getAppRoot(); | |
101 | |
102 /** | |
103 * Updates the kernel's list of modules to the new list. | |
104 * | |
105 * The kernel needs to update its bundle list and container to match the new | |
106 * list. | |
107 * | |
108 * @param array $module_list | |
109 * The new list of modules. | |
110 * @param array $module_filenames | |
111 * List of module filenames, keyed by module name. | |
112 */ | |
113 public function updateModules(array $module_list, array $module_filenames = []); | |
114 | |
115 /** | |
116 * Force a container rebuild. | |
117 * | |
118 * @return \Symfony\Component\DependencyInjection\ContainerInterface | |
119 */ | |
120 public function rebuildContainer(); | |
121 | |
122 /** | |
123 * Invalidate the service container for the next request. | |
124 */ | |
125 public function invalidateContainer(); | |
126 | |
127 /** | |
128 * Prepare the kernel for handling a request without handling the request. | |
129 * | |
130 * @param \Symfony\Component\HttpFoundation\Request $request | |
131 * The current request. | |
132 * | |
133 * @return $this | |
134 * | |
135 * @deprecated in Drupal 8.0.x and will be removed before 9.0.0. Only used by | |
136 * legacy front-controller scripts. | |
137 */ | |
138 public function prepareLegacyRequest(Request $request); | |
139 | |
140 /** | |
141 * Helper method that does request related initialization. | |
142 * | |
143 * @param \Symfony\Component\HttpFoundation\Request $request | |
144 * The current request. | |
145 */ | |
146 public function preHandle(Request $request); | |
147 | |
148 /** | |
149 * Helper method that loads legacy Drupal include files. | |
150 */ | |
151 public function loadLegacyIncludes(); | |
152 | |
153 } |