IRegistrationContext¶
-
interface
OCP\AppFramework\Bootstrap\
IRegistrationContext
¶ - The context object passed to IBootstrap::register
Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#46
Methods¶
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerCapability
($capability)¶ Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#55
Parameters: - $capability (string)
See: \OCP\AppFramework\Bootstrap\IAppContainer::registerCapability
Since: 20.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerCrashReporter
($reporterClass)¶ - Register an implementation of \OCP\Support\CrashReport\IReporter thatwill receive unhandled exceptions and throwables
Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#66
Parameters: - $reporterClass (string)
Returns: void
Since: 20.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerDashboardWidget
($widgetClass)¶ - Register an implementation of \OCP\Dashboard\IWidget thatwill handle the implementation of a dashboard widget
Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#77
Parameters: - $widgetClass (string)
Returns: void
Since: 20.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerService
($name, $factory, $shared=true)¶ - Register a service
Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#91
Parameters: - $name (string)
- $factory (callable)
- $shared (bool)
Returns: void
See: \OCP\AppFramework\Bootstrap\IContainer::registerService()
Since: 20.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerServiceAlias
($alias, $target)¶ Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#104
Parameters: - $alias (string)
- $target (string)
Returns: void
See: \OCP\AppFramework\Bootstrap\IContainer::registerAlias()
Since: 20.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerParameter
($name, $value)¶ Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#115
Parameters: - $name (string)
- $value (mixed)
Returns: void
See: \OCP\AppFramework\Bootstrap\IContainer::registerParameter()
Since: 20.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerEventListener
($event, $listener, $priority=0)¶ - Register a service listenerThis is equivalent to calling IEventDispatcher::addServiceListener
Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#134
Parameters: - $event (string) preferably the fully-qualified class name of the Event sub class to listen for
- $listener (string) fully qualified class name (or ::class notation) of a OCPEventDispatcherIEventListener that can be built by the DI container
- $priority (int) The higher this value, the earlier an event
listener will be triggered in the chain (defaults to 0)
See: \OCP\AppFramework\Bootstrap\IEventDispatcher::addServiceListener()
Since: 20.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerMiddleware
($class)¶ Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#145
Parameters: - $class (string)
Returns: void
See: \OCP\AppFramework\Bootstrap\IAppContainer::registerMiddleWare()
Since: 20.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerSearchProvider
($class)¶ - Register a search provider for the unified searchIt is allowed to register more than one provider per app as the searchresults can go into distinct sections, e.g. “Files” and “Files sharedwith you” in the Files app.
Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#161
Parameters: - $class (string)
Returns: void
Since: 20.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerAlternativeLogin
($class)¶ - Register an alternative login optionIt is allowed to register more than one option per app.
Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#175
Parameters: - $class (string)
Returns: void
Since: 20.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerInitialStateProvider
($class)¶ - Register an initialstate providerIt is allowed to register more than one provider per app.
Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#189
Parameters: - $class (string)
Returns: void
Since: 21.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerWellKnownHandler
($class)¶ - Register a well known protocol handlerIt is allowed to register more than one handler per app.
Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#203
Parameters: - $class (string)
Returns: void
Since: 21.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerTemplateProvider
($providerClass)¶ - Register a custom template provider class that is able to inject custom templatesin addition to the user defined ones
Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#213
Parameters: - $providerClass (string)
Since: 21.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerNotifierService
($notifierClass)¶ - Register an INotifier class
Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#222
Parameters: - $notifierClass (string)
Since: 22.0.0
-
public
OCP\AppFramework\Bootstrap\IRegistrationContext::
registerTwoFactorProvider
($twoFactorProviderClass)¶ - Register a two-factor provider
Source: lib/public/AppFramework/Bootstrap/IRegistrationContext.php#231
Parameters: - $twoFactorProviderClass (string)
Since: 22.0.0