Package org.mule.api.store

Examples of org.mule.api.store.ObjectAlreadyExistsException


        {
            this.update(this.getInsertQuery(), key, value);
        }
        catch (ObjectStoreException e)
        {
            throw new ObjectAlreadyExistsException(e);
        }
    }
View Full Code Here


            throw new ObjectStoreException(CoreMessages.objectIsNull("key"));
        }

        if (contains(key))
        {
            throw new ObjectAlreadyExistsException();
        }

        doStore(key, value);
    }
View Full Code Here

        StoredObject<T> obj = new StoredObject<T>(id, value);
        synchronized (store)
        {
            if (store.values().contains(obj))
            {
                throw new ObjectAlreadyExistsException();
            }

            boolean written = false;
            while (!written)
            {
View Full Code Here

                    errorHappenedInChildThreads = true;
                }
            }
            if (wasAdded)
            {
                throw new ObjectAlreadyExistsException();
            }
        }
View Full Code Here

        StoredObject<T> obj = new StoredObject<T>(id, value);
        synchronized (store)
        {
            if (store.values().contains(obj))
            {
                throw new ObjectAlreadyExistsException();
            }

            boolean written = false;
            while (!written)
            {
View Full Code Here

        @Override
        public void store(Serializable key, Integer value) throws ObjectStoreException
        {
            if (store.containsKey(key))
            {
                throw new ObjectAlreadyExistsException(CoreMessages.createStaticMessage(""));
            }
            store.put(key,value);
        }
View Full Code Here

    {
        assureLoaded();

        if (realKeyToUUIDIndex.containsKey(key))
        {
            throw new ObjectAlreadyExistsException();
        }
        File newFile = createFileToStoreObject();
        realKeyToUUIDIndex.put(key, newFile.getName());
        serialize(newFile, new StoreValue<T>(key, value));
    }
View Full Code Here

    public void store(Serializable key, T value, String partitionName) throws ObjectStoreException
    {
        T oldValue = getPartition(partitionName).putIfAbsent(key, value);
        if (oldValue != null)
        {
            throw new ObjectAlreadyExistsException();
        }
        getExpirtyInfoPartition(partitionName).put(Long.valueOf(System.nanoTime()), key);
    }
View Full Code Here

            throw new ObjectStoreException(CoreMessages.objectIsNull("key"));
        }

        if (contains(key))
        {
            throw new ObjectAlreadyExistsException();
        }

        doStore(key, value);
    }
View Full Code Here

        QueueKey qKey = new QueueKey(partitionName, key);
        synchronized (this)
        {
            if (getStore().contains(qKey))
            {
                throw new ObjectAlreadyExistsException();
            }
            getStore().store(qKey, value);
        }
    }
View Full Code Here

TOP

Related Classes of org.mule.api.store.ObjectAlreadyExistsException

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.