Package org.jboss.cache.marshall

Examples of org.jboss.cache.marshall.NodeData


   {
      Map<Object, Object> attrs;
      Set<?> childrenNames;
      String childName;
      Fqn tmpFqn;
      NodeData nd;

      // first handle the current node
      attrs = get(fqn);
      if (attrs == null || attrs.size() == 0)
      {
         nd = new NodeData(fqn);
      }
      else
      {
         nd = new NodeData(fqn, attrs);
      }
      //out.writeObject(nd);
      list.add(nd);

      // then visit the children
View Full Code Here


         return buildNodeDataLegacy(list, node, mapSafe);
      }
   }

   private List<NodeData> buildNodeData(List<NodeData> list, InternalNode<?, ?> node, Map dataInNode, boolean mapSafe) {
      NodeData data = new NodeData(buddyFqnTransformer.getActualFqn(node.getFqn()), dataInNode, mapSafe);
      list.add(data);
      for (InternalNode childNode : node.getChildrenMap().values()) {
         buildNodeData(list, childNode, childNode.getData(), true);
      }
      return list;
View Full Code Here

      return list;
   }

   @Deprecated
   private List<NodeData> buildNodeDataLegacy(List<NodeData> list, NodeSPI node, boolean mapSafe) {
      NodeData data = new NodeData(buddyFqnTransformer.getActualFqn(node.getFqn()), node.getDataDirect(), mapSafe);
      list.add(data);
      for (Object childNode : node.getChildrenDirect()) {
         buildNodeData(list, (NodeSPI) childNode, true);
      }
      return list;
View Full Code Here

      }

      List nodeData = (List) objectFromStream;
      for (Object aNodeData : nodeData)
      {
         NodeData nd = (NodeData) aNodeData;
         if (nd.isExceptionMarker())
         {
            NodeDataExceptionMarker ndem = (NodeDataExceptionMarker) nd;
            throw new CacheException("State provider cacheloader at node " + ndem.getCacheNodeIdentity()
                  + " threw exception during loadState (see Caused by)", ndem.getCause());
         }
View Full Code Here

   protected void storeStateHelper(Fqn subtree, List nodeData, boolean moveToBuddy) throws Exception
   {
      List<Modification> mod = new ArrayList<Modification>(nodeData.size());
      for (Object aNodeData : nodeData)
      {
         NodeData nd = (NodeData) aNodeData;
         if (nd.isMarker())
         {
            if (trace) log.trace("Reached delimiter; exiting loop");
            break;
         }
         Fqn fqn;
         if (moveToBuddy)
         {
            fqn = buddyFqnTransformer.getBackupFqn(subtree, nd.getFqn());
         }
         else
         {
            fqn = nd.getFqn();
         }
         if (trace) log.trace("Storing state in Fqn " + fqn);
         mod.add(new Modification(ModificationType.PUT_DATA_ERASE, fqn, nd.getAttributes()));
      }
      prepare(null, mod, true);
   }
View Full Code Here

   {
      Map<Object, Object> attrs;
      Set<?> childrenNames;
      Object childName;
      Fqn tmpFqn;
      NodeData nd;

      // first handle the current node
      attrs = get(fqn);
      if (attrs == null || attrs.size() == 0)
      {
         nd = new NodeData(fqn);
      }
      else
      {
         nd = new NodeData(fqn, attrs, true);
      }
      //out.writeObject(nd);
      list.add(nd);

      // then visit the children
View Full Code Here

TOP

Related Classes of org.jboss.cache.marshall.NodeData

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.