Package org.infinispan.loaders.modifications

Examples of org.infinispan.loaders.modifications.Store


      return result;
   }

   @Override
   public void store(InternalCacheEntry entry) {
      put(new Store(entry), 1);
   }
View Full Code Here


   protected void applyModifications(List<? extends Modification> mods) throws CacheLoaderException {
      for (Modification m : mods) {
         switch (m.getType()) {
            case STORE:
               Store s = (Store) m;
               store(s.getStoredEntry());
               break;
            case CLEAR:
               clear();
               break;
            case REMOVE:
View Full Code Here

   protected void applyModifications(List<? extends Modification> mods) throws CacheLoaderException {
      for (Modification m : mods) {
         switch (m.getType()) {
            case STORE:
               Store s = (Store) m;
               store(s.getStoredEntry());
               break;
            case CLEAR:
               clear();
               break;
            case REMOVE:
View Full Code Here

      }

      private Object visitSingleStore(InvocationContext ctx, Object key) throws Throwable {
         if (!skipKey(key)) {
            if (generateStatistics) putCount++;
            modifications.add(new Store(getStoredEntry(key, ctx)));
            affectedKeys.add(key);
         }
         return null;
      }
View Full Code Here

      @Override
      @SuppressWarnings("unchecked")
      public Object visitPutKeyValueCommand(InvocationContext ctx, PutKeyValueCommand command) throws Throwable {
         if (generateStatistics) putCount++;
         modifications.add(new Store(getStoredEntry(command.getKey(), ctx)));
         affectedKeys.add(command.getKey());
         return null;
      }
View Full Code Here

      @SuppressWarnings("unchecked")
      public Object visitPutMapCommand(InvocationContext ctx, PutMapCommand command) throws Throwable {
         Map<Object, Object> map = command.getMap();
         if (generateStatistics) putCount += map.size();
         affectedKeys.addAll(map.keySet());
         for (Object key : map.keySet()) modifications.add(new Store(getStoredEntry(key, ctx)));
         return null;
      }
View Full Code Here

      transactions = new ConcurrentHashMap<GlobalTransaction, List<? extends Modification>>(64, 0.75f, concurrencyLevel);
   }

   @Override
   public void store(InternalCacheEntry ed) {
      enqueue(new Store(ed));
   }
View Full Code Here

      private void handle(Modification mod, boolean nested) {
         boolean asyncProcessorNeeded = false;
         switch (mod.getType()) {
            case STORE:
               Store store = (Store) mod;
               stateMapLock.lock();
               state.put(store.getStoredEntry().getKey(), store);
               stateMapLock.unlock();
               asyncProcessorNeeded = true;
               break;
            case REMOVE:
               Remove remove = (Remove) mod;
View Full Code Here

    */
   public void doWork() throws Exception {
      for (Modification modification : mods)
         switch (modification.getType()) {
            case STORE:
               Store s = (Store) modification;
               cs.store(s.getStoredEntry());
               break;
            case CLEAR:
               cs.clear();
               break;
            case REMOVE:
View Full Code Here

      @Override
      @SuppressWarnings("unchecked")
      public Object visitPutKeyValueCommand(InvocationContext ctx, PutKeyValueCommand command) throws Throwable {
         if (generateStatistics) putCount++;
         modifications.add(new Store(getStoredEntry(command.getKey(), ctx)));
         affectedKeys.add(command.getKey());
         return null;
      }
View Full Code Here

TOP

Related Classes of org.infinispan.loaders.modifications.Store

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.