Class NonInjectionRequestScope.Instance
- java.lang.Object
-
- org.glassfish.jersey.client.innate.inject.NonInjectionRequestScope.Instance
-
- All Implemented Interfaces:
RequestContext
- Enclosing class:
- NonInjectionRequestScope
public static final class NonInjectionRequestScope.Instance extends Object implements RequestContext
Implementation of the request scope instance.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description NonInjectionRequestScope.InstancegetReference()Get a "new" reference of the scope instance.voidrelease()Release a single reference to the current request scope instance.StringtoString()
-
-
-
Method Detail
-
getReference
public NonInjectionRequestScope.Instance getReference()
Get a "new" reference of the scope instance. This will increase the internal reference counter which prevents the scope instance to be destroyed until arelease()method is explicitly called (once per eachgetReference()method call).- Specified by:
getReferencein interfaceRequestContext- Returns:
- referenced scope instance.
-
release
public void release()
Release a single reference to the current request scope instance.Once all instance references are released, the instance will be recycled.
- Specified by:
releasein interfaceRequestContext
-
-