120121122123124125126127
{ this.update(this.getInsertQuery(), key, value); } catch (ObjectStoreException e) { throw new ObjectAlreadyExistsException(e); } }
48495051525354555657
throw new ObjectStoreException(CoreMessages.objectIsNull("key")); } if (contains(key)) { throw new ObjectAlreadyExistsException(); } doStore(key, value); }
7576777879808182838485
StoredObject<T> obj = new StoredObject<T>(id, value); synchronized (store) { if (store.values().contains(obj)) { throw new ObjectAlreadyExistsException(); } boolean written = false; while (!written) {
164165166167168169170171
errorHappenedInChildThreads = true; } } if (wasAdded) { throw new ObjectAlreadyExistsException(); } }
6667686970717273747576
177178179180181182183184185
@Override public void store(Serializable key, Integer value) throws ObjectStoreException { if (store.containsKey(key)) { throw new ObjectAlreadyExistsException(CoreMessages.createStaticMessage("")); } store.put(key,value); }
118119120121122123124125126127128
{ assureLoaded(); if (realKeyToUUIDIndex.containsKey(key)) { throw new ObjectAlreadyExistsException(); } File newFile = createFileToStoreObject(); realKeyToUUIDIndex.put(key, newFile.getName()); serialize(newFile, new StoreValue<T>(key, value)); }
535455565758596061
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); }
46474849505152535455
43444546474849505152
QueueKey qKey = new QueueKey(partitionName, key); synchronized (this) { if (getStore().contains(qKey)) { throw new ObjectAlreadyExistsException(); } getStore().store(qKey, value); } }