Package org.apache.jcs.access.exception

Examples of org.apache.jcs.access.exception.ObjectExistsException


    public void putSafe( Object key, Object value )
        throws CacheException
    {
        if ( cacheControl.get( ( Serializable ) key ) != null )
        {
            throw new ObjectExistsException( "Object exists for key " + key );
        }
        else
        {
            put( key, value );
        }
View Full Code Here


    public void putSafe( Object key, Object value )
        throws CacheException
    {
        if ( this.cacheControl.get( (Serializable) key ) != null )
        {
            throw new ObjectExistsException( "putSafe failed.  Object exists in the cache for key [" + key
                + "].  Remove first or use a non-safe put to override the value." );
        }
        put( key, value );
    }
View Full Code Here

TOP

Related Classes of org.apache.jcs.access.exception.ObjectExistsException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.