IRegistrationContext
in
The context object passed to IBootstrap::register
Tags
Table of Contents
- registerAlternativeLogin() : void
- Register an alternative login option
- registerCapability() : void
- registerCrashReporter() : void
- Register an implementation of \OCP\Support\CrashReport\IReporter that will receive unhandled exceptions and throwables
- registerDashboardWidget() : void
- Register an implementation of \OCP\Dashboard\IPanel that will handle the implementation of a dashboard panel
- registerEventListener() : void
- Register a service listener
- registerMiddleware() : void
- registerParameter() : void
- registerSearchProvider() : void
- Register a search provider for the unified search
- registerService() : void
- Register a service
- registerServiceAlias() : void
Methods
registerAlternativeLogin()
Register an alternative login option
public
registerAlternativeLogin(string $class) : void
It is allowed to register more than one option per app.
Parameters
- $class : string
Tags
registerCapability()
public
registerCapability(string $capability) : void
Parameters
- $capability : string
Tags
registerCrashReporter()
Register an implementation of \OCP\Support\CrashReport\IReporter that will receive unhandled exceptions and throwables
public
registerCrashReporter(string $reporterClass) : void
Parameters
- $reporterClass : string
Tags
registerDashboardWidget()
Register an implementation of \OCP\Dashboard\IPanel that will handle the implementation of a dashboard panel
public
registerDashboardWidget(string $widgetClass) : void
Parameters
- $widgetClass : string
Tags
registerEventListener()
Register a service listener
public
registerEventListener(string $event, string $listener, int $priority) : void
This is equivalent to calling IEventDispatcher::addServiceListener
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 \OCP\EventDispatcher\IEventListener that can be built by the DI container
- $priority : int
Tags
registerMiddleware()
public
registerMiddleware(string $class) : void
Parameters
- $class : string
Tags
registerParameter()
public
registerParameter(string $name, mixed $value) : void
Parameters
- $name : string
- $value : mixed
Tags
registerSearchProvider()
Register a search provider for the unified search
public
registerSearchProvider(string $class) : void
It is allowed to register more than one provider per app as the search results can go into distinct sections, e.g. "Files" and "Files shared with you" in the Files app.
Parameters
- $class : string
Tags
registerService()
Register a service
public
registerService(string $name, callable $factory[, bool $shared = true ]) : void
Parameters
- $name : string
- $factory : callable
- $shared : bool = true
Tags
registerServiceAlias()
public
registerServiceAlias(string $alias, string $target) : void
Parameters
- $alias : string
- $target : string