Class BundleHttpContext
java.lang.Object
org.nuxeo.ecm.webengine.jaxrs.servlet.config.BundleHttpContext
- All Implemented Interfaces:
org.osgi.service.http.HttpContext
A HttpContext that delegates resource lookup to contributed
ResourcesDescriptor
in the inverse order of the
contribution (preserving the ordering imposed by extension mechanism)
A BundleHttpContext is created for every declated servlet when it is registered against to HttpService. The context is removed when the servlet is unregistered.
- Author:
- Bogdan Stefanescu
-
Field Summary
Modifier and TypeFieldDescriptionprotected org.osgi.framework.Bundle
protected ResourceResolver
protected ResourcesDescriptor[]
Fields inherited from interface org.osgi.service.http.HttpContext
AUTHENTICATION_TYPE, AUTHORIZATION, REMOTE_USER
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetMimeType
(String name) getResource
(String name) boolean
handleSecurity
(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) void
setResources
(ResourcesDescriptor[] resources)
-
Field Details
-
bundle
protected org.osgi.framework.Bundle bundle -
resolver
-
resources
-
-
Constructor Details
-
BundleHttpContext
-
-
Method Details
-
setResources
-
getMimeType
- Specified by:
getMimeType
in interfaceorg.osgi.service.http.HttpContext
-
getResource
- Specified by:
getResource
in interfaceorg.osgi.service.http.HttpContext
-
handleSecurity
public boolean handleSecurity(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws IOException - Specified by:
handleSecurity
in interfaceorg.osgi.service.http.HttpContext
- Throws:
IOException
-