T
- external request context typepublic interface ExternalRequestScope<T> extends AutoCloseable
An implementation must be registered via META-INF/services mechanism. Only one implementation will be utilized during runtime. If more than one implementation is registered, no one will get used and an error message will be logged out.
Modifier and Type | Method and Description |
---|---|
void |
close()
Finish the actual request.
|
ExternalRequestContext<T> |
open(org.glassfish.hk2.api.ServiceLocator locator)
Invoked when a new request gets started.
|
void |
resume(ExternalRequestContext<T> c,
org.glassfish.hk2.api.ServiceLocator locator)
Resume request associated with provided context.
|
void |
suspend(ExternalRequestContext<T> c,
org.glassfish.hk2.api.ServiceLocator locator)
Suspend request associated with provided context.
|
ExternalRequestContext<T> open(org.glassfish.hk2.api.ServiceLocator locator)
locator
- HK2 service locatorvoid suspend(ExternalRequestContext<T> c, org.glassfish.hk2.api.ServiceLocator locator)
c
- external request contextlocator
- HK2 service locatorvoid resume(ExternalRequestContext<T> c, org.glassfish.hk2.api.ServiceLocator locator)
c
- external request contextlocator
- HK2 service locatorvoid close()
close
in interface AutoCloseable
Copyright © 2007-2015, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.