Examples of AbstractContext


Examples of org.deuce.transaction.AbstractContext

  private List<String> reservations = new LinkedList<String>();
 
  public Customer(String id){
    this.id = id;
   
    AbstractContext context = ContextDelegator.getInstance();
    if(context.getContextId()==null)
      new GlobalObject(this, ((AbstractDistinguishable)this).getId())// publish it now 
    else
      context.newObject(this)// add it to context publish-set
  }
View Full Code Here

Examples of org.deuce.transaction.AbstractContext

    this.id = id;
    this.resourceid = resourceid;
    this.price = price;
    this.type = type;
   
    AbstractContext context = ContextDelegator.getInstance();
    if(context.getContextId()==null)
      new GlobalObject(this, ((AbstractDistinguishable)this).getId())// publish it now 
    else
      context.newObject(this)// add it to context publish-set
  }
View Full Code Here

Examples of org.deuce.transaction.AbstractContext

 
  public Node(String id, Integer value) {
    this.id = id;
    this.value = value;

    AbstractContext context = ContextDelegator.getInstance();
    if(context.getContextId()==null)
      new GlobalObject(this, ((AbstractDistinguishable)this).getId())// publish it now 
    else
      context.newObject(this)// add it to context publish-set
  }
View Full Code Here

Examples of org.deuce.transaction.AbstractContext

    private String id;
   
  public LoanAccount(String id) {
    this.id = id;
   
    AbstractContext context = ContextDelegator.getInstance();
    if(context.getContextId()==null)
      new GlobalObject(this, ((AbstractDistinguishable)this).getId())// publish it now 
    else
      context.newObject(this)// add it to context publish-set
  }
View Full Code Here

Examples of org.deuce.transaction.AbstractContext

        LockTable.setRemote(object);
      else
        Logger.debug("Refuse.. " + object);
      result.put(hashcode, new Object[]{object, senderClock});
     
      AbstractContext context = pendingContexts.remove(hashcode);
      if(context!=null)
        synchronized(context){
          Logger.debug("signal.");
          context.notifyAll()
        }
      else
        System.err.println("How? " + Arrays.toString(pendingContexts.values().toArray()));
    }
View Full Code Here

Examples of org.deuce.transaction.AbstractContext

        LockTable.setRemote(object);
      else
        Logger.debug("Refuse.. " + object);
      result.put(hashcode, new Object[]{object, senderClock, ResSec, ResnSec, EarlierTxPresent});
     
      AbstractContext context = pendingContexts.remove(hashcode);
      if(context!=null) {
        synchronized(context){
          Logger.debug("signal.");
          context.notifyAll();
        }
      }
      else
        System.err.println("How? " + Arrays.toString(pendingContexts.values().toArray()));
    }
View Full Code Here

Examples of org.deuce.transaction.AbstractContext

      Logger.debug("Refuse.. " + object);
    TrackerDirectory.repliesQueue.put(contextHashcode, new Object[]{
        object,
        senderClock
    });
    AbstractContext context = TrackerDirectory.pendingContexts.remove(contextHashcode);
    if(context!=null)
      synchronized(context){
        Logger.debug("signal.");
        context.notifyAll()
      }
    else
      System.err.println("How? " + Arrays.toString(TrackerDirectory.pendingContexts.values().toArray()));
  }
View Full Code Here

Examples of org.deuce.transaction.AbstractContext

    if(hashCode==0){
      Logger.debug("No call backs");
      return;
    }
    Logger.debug("Hashcode is " + hashCode);
    AbstractContext context = LockTable.pendingLocks.get(hashCode);
    if(context==null){
      System.out.println("Null context: " + hashCode);
      return;
    }
    Logger.debug(context + " will notified");
    synchronized (context) {
      ((Context)context).pendingLock = success;
      context.notifyAll();
      Logger.debug(context + " notified");
    }
  }
View Full Code Here

Examples of org.deuce.transaction.AbstractContext

    Network.linkDelay(false, from);
    if(owner!=null)
      TrackerDirectory.repliesQueue.put(contextHashcode, owner);
    else
      Logger.debug("Null owner");
    AbstractContext context = TrackerDirectory.pendingContexts.get(contextHashcode);
    if(context!=null)
      synchronized(context){
        Logger.debug("signal.");
        context.notifyAll()
      }
    else
      System.err.println("How? " + Arrays.toString(TrackerDirectory.pendingContexts.values().toArray()));
  }
View Full Code Here

Examples of org.deuce.transaction.AbstractContext

    this.id = id;
    this.price = price;
    this.total = INITIAL;
    this.used = 0;
   
    AbstractContext context = ContextDelegator.getInstance();
    if(context.getContextId()==null)
      HyFlow.getLocator().register(this); // publish it now 
    else
      context.newObject(this)// add it to context publish-set
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.