Class HandlerRegistry
java.lang.Object
org.apache.felix.http.base.internal.registry.HandlerRegistry
Registry for all services.
The registry is organized per servlet context and is dispatching to one
of the
PerContextHandlerRegistry
registries.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
add
(@NotNull PerContextHandlerRegistry registry) Add a new context registration.getBestMatchingRegistry
(String requestURI) org.apache.felix.http.base.internal.HttpConfig
@Nullable ServletResolution
getErrorHandler
(@NotNull String requestURI, Long serviceId, int code, Throwable exception) getFilters
(@NotNull ServletResolution pr, @NotNull jakarta.servlet.DispatcherType dispatcherType, @NotNull String requestURI) getRegistry
(long key) boolean
getRuntimeInfo
(@NotNull org.osgi.service.servlet.runtime.dto.ServletContextDTO dto, @NotNull FailedDTOHolder failedDTOHolder) void
init()
Register default context registry for Http Servicevoid
remove
(@NotNull ServletContextHelperInfo info) Remove a context registration.void
reset()
Reset to initial stateresolveServlet
(@NotNull String requestURI) resolveServletByName
(long contextId, @NotNull String name) Get the servlet handler for a servlet by namevoid
shutdown()
Shutdown
-
Constructor Details
-
HandlerRegistry
public HandlerRegistry(org.apache.felix.http.base.internal.HttpConfig config)
-
-
Method Details
-
getConfig
public org.apache.felix.http.base.internal.HttpConfig getConfig() -
init
public void init()Register default context registry for Http Service -
reset
public void reset()Reset to initial state -
shutdown
public void shutdown()Shutdown -
remove
Remove a context registration.- Parameters:
info
- The servlet context helper info
-
add
Add a new context registration.- Parameters:
registry
- The registry
-
getRegistry
-
getErrorHandler
@Nullable public @Nullable ServletResolution getErrorHandler(@NotNull @NotNull String requestURI, Long serviceId, int code, Throwable exception) -
getFilters
public FilterHandler[] getFilters(@NotNull @NotNull ServletResolution pr, @NotNull @NotNull jakarta.servlet.DispatcherType dispatcherType, @NotNull @NotNull String requestURI) -
resolveServlet
-
resolveServletByName
Get the servlet handler for a servlet by name- Parameters:
contextId
- The context idname
- The servlet name- Returns:
- The servlet handler or
null
-
getRuntimeInfo
public boolean getRuntimeInfo(@NotNull @NotNull org.osgi.service.servlet.runtime.dto.ServletContextDTO dto, @NotNull @NotNull FailedDTOHolder failedDTOHolder) -
getBestMatchingRegistry
-