base/common/src/main/com/thesett/common/util/concurrent/BatchSynchQueueBase.java
public boolean offer(E e)
    {
        if (e == null)
        {
            throw new IllegalArgumentException("The 'e' parameter may not be null.");
        }

        ReentrantLock lock = this.lock;
        lock.lock();

        try
        {
            return insert(e, false);
        }
        finally
        {
            lock.unlock();
        }
    }
public boolean offer(E e)
    {
        if (e == null)
        {
            throw new IllegalArgumentException("The 'e' parameter may not be null.");
        }

        ReentrantLock lock = this.lock;
        lock.lock();

        try
        {
            return insert(e, false);
        }
        finally
        {
            lock.unlock();
        }
    }
public boolean offer ( E e ) { if ( e == null ) { throw new IllegalArgumentException ( "The 'e' parameter may not be null." ) ; } ReentrantLock lock = this . lock ; lock . lock ( ) ; try { return insert ( e , false ) ; } finally { lock . unlock ( ) ; } }
Inserts the specified element into this queue, if possible. When using queues that may impose insertion
restrictions (for example capacity bounds), method <tt>offer</tt> is generally preferable to method
{@link java.util.Collection#add}, which can fail to insert an element only by throwing an exception.

@param  e The element to insert, may not be null.

@return <tt>true</tt> if it was possible to add the element to this queue, else <tt>false</tt>

@throws IllegalArgumentException If the specified element is <tt>null</tt>.
Inserts the specified element into this queue if possible . When using queues that may impose insertion restrictions ( for example capacity bounds ) method <tt > offer< / tt > is generally preferable to method { @link java . util . Collection#add } which can fail to insert an element only by throwing an exception .