Interface Pool<V>
- All Known Implementing Classes:
AbstractUnifiedSet, UnifiedSet, UnifiedSetWithHashingStrategy
public interface Pool<V>
-
Method Summary
-
Method Details
-
get
-
clear
void clear() -
put
Putskeyinto the pool. If there is no existing object that is equal to key, key will be added to the pool and the return value will be the same instance. If there is an existing object in the pool that is equal tokey, the pool will remain unchanged and the pooled instance will be is returned.- Parameters:
key- the value to add if not in the pool- Returns:
- the object reference in the pool equal to key (either key itself or the existing reference)
-
size
int size() -
removeFromPool
-