Code cleanup/polish

This commit is contained in:
nathan 2016-02-10 19:05:27 +01:00
parent eb45aa15f3
commit 309992aab9
2 changed files with 1 additions and 4 deletions

View File

@ -65,8 +65,7 @@ class ObjectPool<T> {
public
T takeUninterruptibly() {
try {
T take = take();
return take;
return take();
} catch (InterruptedException e) {
return null;
}

View File

@ -21,7 +21,6 @@ abstract class PoolableObject<T> {
/**
* Called when an object is returned to the pool, useful for resetting an objects state, for example.
*/
@SuppressWarnings("UnusedParameters")
public
void onReturn(T object) {
}
@ -29,7 +28,6 @@ abstract class PoolableObject<T> {
/**
* Called when an object is taken from the pool, useful for setting an objects state, for example.
*/
@SuppressWarnings("UnusedParameters")
public
void onTake(T object) {
}