Package org.jboss.cache.aop.test.propagation

Examples of org.jboss.cache.aop.test.propagation.Node


      registMap(rootNode_);
   }

   public void addNode(String parentFdn, String rdn) {
      Node parent = findNode(parentFdn);
      if (parent != null) {
         Node node = new NodeImpl();
         node.setNodeFDN(parentFdn + "." + rdn);
         node.setNodeRDN(rdn);
         node.setPropagationRule(orRule_);

         node.setParentNode(parent);
         parent.addChildNode(node);

         StateItem summary = new StateItemImpl(0);
         summary.setState(PropagationRule.STATE_CLEAR);
         node.setSummaryStateItem(summary);

         registMap(node);

         PropagationRule rule = node.getPropagationRule();
         rule.summaryUpperPropagate(node);
      }
   }
View Full Code Here


         rule.summaryUpperPropagate(node);
      }
   }

   public void addStateItem(String parentFdn, long itemId, long defaultState) {
      Node node = findNode(parentFdn);
      if (node != null) {
         StateItem item = new StateItemImpl(itemId);
         item.setState(defaultState);

         node.addStateItem(item);

         PropagationRule rule = node.getPropagationRule();
         rule.summaryUpperPropagate(node);
      }
   }
View Full Code Here

         rule.summaryUpperPropagate(node);
      }
   }

   public void stateChange(String parentFdn, long itemId, long newState) {
      Node node = findNode(parentFdn);
      if (node != null) {
         PropagationRule rule = node.getPropagationRule();
         rule.changeState(node, itemId, newState);
      }
   }
View Full Code Here

      String childPrefix = prefix + " + ";
      List children = node.getChildren();
      size = children.size();
      for (int idx = 0; idx < size; idx++) {
         Node child = (Node) children.get(idx);
         printNode(child, childPrefix);
      }
   }
View Full Code Here

      String childPrefix = prefix + " + ";
      List children = node.getChildren();
      size = children.size();
      for (int idx = 0; idx < size; idx++) {
         Node child = (Node) children.get(idx);
         buf.append(toNodeString(child, childPrefix));
      }

      return buf.toString();
   }
View Full Code Here

      }

      List childNodes = node.getChildren();
      size = childNodes.size();
      for (int idx = 0; idx < size; idx++) {
         Node child = (Node) childNodes.get(idx);
         StateItem childSummary = child.getSummaryStateItem();

         maxSeverity = updateMaxSeverity(maxSeverity, childSummary);
      }

      long summaryState = STATE_CLEAR + maxSeverity;
View Full Code Here

         summaryUpperPropagate(node);
      }
   }

   protected void upperPropagate(Node node) {
      Node parentNode = (Node) node.getParentNode();
      if (parentNode != null) {
         PropagationRule parentRule = parentNode.getPropagationRule();
         parentRule.summaryUpperPropagate(parentNode);
      }
   }
View Full Code Here

TOP

Related Classes of org.jboss.cache.aop.test.propagation.Node

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.