* method can be passed at construction of an object that will be used by
* multiple threads.
* </p>
- *
+ *
* <p>
* This class is mostly used by infrastructure code (utilities) and test tools.
* </p>
* distributed context where it can be sent to another JVM.
* </p>
*
+ * <p>
+ * This class currently does not do any cleanup. So it should not be used in production code
+ * but only in test utilities.
+ * </p>
+ *
* @param T
* Interface to proxy.
* @author Erik Brakkee
}
/**
- * Constructs the factory with a callback to create thread-specific objects
- * automatically.
+ * Constructs the factory with a callback to create thread-specific objects
+ * automatically.
*
* @param aClass
* Interface class of the service to proxy.
svc = new ThreadLocal<T>() {
@Override
protected T initialValue() {
- if ( aCallback != null ) {
+ if (aCallback != null) {
return aCallback.create();
}
- return null;
+ return null;
}
};
clazz = aClass;