org.openjena.atlas.lib
Class PoolSync<T>

java.lang.Object
  extended by org.openjena.atlas.lib.PoolSync<T>
All Implemented Interfaces:
Pool<T>

public class PoolSync<T>
extends Object
implements Pool<T>

Synchronization wrapper for a pool


Constructor Summary
PoolSync(Pool<T> pool)
           
 
Method Summary
static
<T> Pool<T>
create(Pool<T> pool)
           
 T get()
          Get an item from the pool - return null if the pool is empty
 boolean isEmpty()
           
 void put(T item)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PoolSync

public PoolSync(Pool<T> pool)
Method Detail

create

public static <T> Pool<T> create(Pool<T> pool)

put

public final void put(T item)
Specified by:
put in interface Pool<T>

get

public final T get()
Description copied from interface: Pool
Get an item from the pool - return null if the pool is empty

Specified by:
get in interface Pool<T>

isEmpty

public final boolean isEmpty()
Specified by:
isEmpty in interface Pool<T>


Licenced under the Apache License, Version 2.0