1 package org.jbpm.bpel.def.assign;2 3 import javax.xml.namespace.QName ;4 5 import org.jbpm.graph.exe.Token;6 7 import org.jbpm.bpel.data.def.VariableDefinition;8 import org.jbpm.bpel.data.exe.MessageVariableInstance;9 import org.jbpm.bpel.def.Assign;10 11 /**12 * <code><from></code> variant that explicitly manipulates message 13 * properties occurring in variables.14 * @see "WS-BPEL 2.0 §9.3"15 * @author Alejandro Guízar16 * @version $Revision: 1.4 $ $Date: 2005/05/31 00:49:53 $17 */18 public class FromProperty extends Assign.From {19 20 private static final long serialVersionUID = 1L;21 private VariableDefinition variable;22 private QName property;23 24 public Object extract(Token token) {25 MessageVariableInstance instance = (MessageVariableInstance) variable.getInstance(token);26 return instance.getProperty(property);27 }28 29 public VariableDefinition getVariable() {30 return variable;31 }32 33 public void setVariable(VariableDefinition variable) {34 this.variable = variable;35 }36 37 public QName getProperty() {38 return property;39 }40 41 public void setProperty(QName property) {42 this.property = property;43 }44 }45