Examples of markForUpdate()


Examples of com.sun.sgs.app.DataManager.markForUpdate()

            Channel channel = cm.createChannel(channelName,
                                               null,
                                               Delivery.RELIABLE);

            // mark ourself for udate
            dm.markForUpdate(this);

            // add to the map
            HandlerRecord record = new HandlerRecord();
            record.ref = ref;
            record.channel  = dm.createReference(channel);
View Full Code Here

Examples of com.sun.sgs.app.DataManager.markForUpdate()

         * @param handler the handler to unregister
         */
        public void unregister(ClientConnectionHandler handler) {
            // mark ourself for udate
            DataManager dm = AppContext.getDataManager();
            dm.markForUpdate(this);

            HandlerRecord record = handlers.remove(handler.getConnectionType());
 
            // remove the channel and session store
            dm.removeObject(record.channel.get());
View Full Code Here

Examples of com.sun.sgs.app.DataManager.markForUpdate()

                                 ClientSession session)
    {
        ProtocolClientMap pcm = getProtocolClientMap();
       
        DataManager dm = AppContext.getDataManager();
        dm.markForUpdate(pcm);
       
        pcm.add(protocol, session);
    }
   
    /**
 
View Full Code Here

Examples of com.sun.sgs.app.DataManager.markForUpdate()

                                    ManagedReference<ClientSession> sessionRef)
    {
        ProtocolClientMap pcm = getProtocolClientMap();
       
        DataManager dm = AppContext.getDataManager();
        dm.markForUpdate(pcm);
       
        pcm.remove(protocol, sessionRef);
    }
     
    /**
 
View Full Code Here

Examples of com.sun.sgs.app.DataManager.markForUpdate()

  if (o == null) {
      throw new NullPointerException("null element");
  }
  Entry<E> entry = new Entry<E>(o);
  DataManager dataManager = AppContext.getDataManager();
  dataManager.markForUpdate(this);
  ManagedReference<Entry<E>> entryRef =
      dataManager.createReference(entry);
  if (tailRef == null) {
      headRef = entryRef;
            tailRef = entryRef;
View Full Code Here

Examples of com.sun.sgs.app.DataManager.markForUpdate()

    @Override
    public E poll() {
  E element = null;
  if (headRef != null) {
      DataManager dataManager = AppContext.getDataManager();
      dataManager.markForUpdate(this);
      Entry<E> head = getHeadForUpdate();
      element = head.getElement();
      headRef = head.nextEntryRef;
      if (headRef == null) {
    // last element removed
View Full Code Here

Examples of com.sun.sgs.app.DataManager.markForUpdate()

        void setNext(Element<E> next) {
            DataManager dm = AppContext.getDataManager();
            ManagedReference<Element<E>> ref =
                    (next == null) ? null : dm.createReference(next);

            dm.markForUpdate(this);
            nextElement = ref;
        }

        /**
         * Sets the link from this {@code Element} to the previous
View Full Code Here

Examples of com.sun.sgs.app.DataManager.markForUpdate()

        void setPrev(Element<E> prev) {
            DataManager dm = AppContext.getDataManager();
            ManagedReference<Element<E>> ref =
                    (prev == null) ? null : dm.createReference(prev);

            dm.markForUpdate(this);
            prevElement = ref;
        }

        /**
         * {@inheritDoc}
 
View Full Code Here

Examples of com.sun.sgs.app.DataManager.markForUpdate()

   * The entry point of the task to perform the clear.
   */
  public void run() {
      // Perform some work and check if we need to reschedule
      DataManager dm = AppContext.getDataManager();
      dm.markForUpdate(this);

      if (doWork()) {
    AppContext.getTaskManager().scheduleTask(this);
      } else {
    dm.removeObject(this);
View Full Code Here

Examples of com.sun.sgs.app.DataManager.markForUpdate()

        ScalableHashMap<K, V> leaf = getChildNode(index);

  DataManager dm = AppContext.getDataManager();

        // mark this node for update since we will be changing its directory
  dm.markForUpdate(this);
  // remove the old leaf node
  dm.removeObject(leaf);

  // update the new children nodes to point to this directory node as
  // their parent
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.