@Review(value="\"shared\" flag should be in WebContainerContext, new Whiteboard context (ServletContextHelper) shouldbe shared by default an this interface should be for \"pax-web shared contexts\".\"sharing\" in new Whiteboard is about allowing the contribution of web elements to cross-bundle webapp.\"sharing\" in PaxWeb Whiteboard is about accessing more bundles in search for resources.") public interface MultiBundleWebContainerContext extends WebContainerContext
WebContainerContext that can be shared between different bundles. Users may obtain such context by
name using WebContainer.createDefaultSharedHttpContext(String) and register different bundles for shared
context access.WebContainerContext.DefaultContextIds| Modifier and Type | Method and Description |
|---|---|
boolean |
deregisterBundle(org.osgi.framework.Bundle bundle)
Unrgister given
Bundle as a bundle using given shared context. |
default boolean |
isShared()
Should this context (as defined in "102 Http Service" specification, not in "140 Whiteboard Service"
specification) be allowed to be used by different bundles?
|
boolean |
registerBundle(org.osgi.framework.Bundle bundle)
Register given
Bundle as a bundle using given shared context. |
finishSecurity, getBundle, getContextId, getRealPath, getResourcePathsboolean registerBundle(org.osgi.framework.Bundle bundle)
Bundle as a bundle using given shared context.bundle - boolean deregisterBundle(org.osgi.framework.Bundle bundle)
Bundle as a bundle using given shared context.bundle - default boolean isShared()
WebContainerContextShould this context (as defined in "102 Http Service" specification, not in "140 Whiteboard Service" specification) be allowed to be used by different bundles?
In Whiteboard Service scenario (to wrap ServletContextHelper)
the context should be shared by default and there's no real way to make a context not shared.
In Http Service scenario, but default, a context is not shared. It means that if a web element is being registered through such context, but with different bundle, exception should be thrown.
isShared in interface WebContainerContextCopyright © 2006–2024 OPS4J - Open Participation Software for Java. All rights reserved.