org.glassfish.hk2.scopes
Class PerThread

java.lang.Object
  extended by org.glassfish.hk2.scopes.PerThread
All Implemented Interfaces:
Scope

@Service
@Scoped(value=Singleton.class)
public class PerThread
extends Object
implements Scope

Implementation of an HK2 Scope that will instantiate and store services per thread. Each thread will have a different instance of PerThread as declared via the ResolvedBinder.in(Class) or the Scoped annotation.

Author:
Jerome Dochez

Constructor Summary
PerThread()
           
 
Method Summary
 ScopeInstance current()
           
 void release()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PerThread

public PerThread()
Method Detail

current

public ScopeInstance current()
Specified by:
current in interface Scope

release

public void release()


Copyright © 2012 Oracle Corporation. All Rights Reserved.