1 package org.jbpm.bpel.xml; 2 3 import org.w3c.dom.Element ; 4 5 import org.jbpm.bpel.def.Activity; 6 import org.jbpm.bpel.def.While; 7 import org.jbpm.bpel.xml.util.NodeUtil; 8 9 15 public class WhileReader extends ActivityReader { 16 17 protected Activity createActivity() { 18 return new While(); 19 } 20 21 protected void readActivity(Activity activity, Element element) { 22 While whileBlock = (While) activity; 23 Element conditionElement = NodeUtil.getElement(element, BpelConstants.NS_BPWS, BpelConstants.ELEM_CONDITION); 25 whileBlock.setCondition(bpelReader.readExpression(conditionElement, whileBlock.getCompositeActivity())); 26 27 Element childElement = bpelReader.getActivityElement(element); 29 bpelReader.readActivity(childElement, whileBlock); 30 } 31 } 32 | Popular Tags |