|
|||||||||||||||||||
| 30 day Evaluation Version distributed via the Maven Jar Repository. Clover is not free. You have 30 days to evaluate it. Please visit http://www.thecortex.net/clover to obtain a licensed version of Clover | |||||||||||||||||||
| Source file | Conditionals | Statements | Methods | TOTAL | |||||||||||||||
| InvokeImpl.java | - | 68.8% | 61.5% | 65.5% |
|
||||||||||||||
| 1 |
/*
|
|
| 2 |
* $Id: InvokeImpl.java,v 1.1 2004/12/15 14:18:13 patforna Exp $
|
|
| 3 |
*
|
|
| 4 |
* Copyright (c) 2004 Patric Fornasier, Pawel Kowalski
|
|
| 5 |
* Berne University of Applied Sciences
|
|
| 6 |
* School of Engineering and Information Technology
|
|
| 7 |
* All rights reserved.
|
|
| 8 |
*/
|
|
| 9 |
package bexee.model.activity.impl;
|
|
| 10 |
|
|
| 11 |
import java.util.ArrayList;
|
|
| 12 |
import java.util.List;
|
|
| 13 |
|
|
| 14 |
import javax.xml.namespace.QName;
|
|
| 15 |
|
|
| 16 |
import bexee.core.ProcessController;
|
|
| 17 |
import bexee.core.ProcessInstance;
|
|
| 18 |
import bexee.model.BPELElementVisitor;
|
|
| 19 |
import bexee.model.StandardAttributes;
|
|
| 20 |
import bexee.model.activity.CatchAll;
|
|
| 21 |
import bexee.model.activity.CompensationHandler;
|
|
| 22 |
import bexee.model.activity.Invoke;
|
|
| 23 |
import bexee.model.elements.CatchFault;
|
|
| 24 |
import bexee.model.elements.Correlations;
|
|
| 25 |
import bexee.model.elements.PartnerLink;
|
|
| 26 |
import bexee.model.elements.Variable;
|
|
| 27 |
|
|
| 28 |
/**
|
|
| 29 |
* Default implementation of the <code>Invoke</code> activity.
|
|
| 30 |
*
|
|
| 31 |
* @version $Revision: 1.1 $, $Date: 2004/12/15 14:18:13 $
|
|
| 32 |
* @author Patric Fornasier
|
|
| 33 |
* @author Pawel Kowalski
|
|
| 34 |
*/
|
|
| 35 |
public class InvokeImpl extends AbstractActivity implements Invoke { |
|
| 36 |
|
|
| 37 |
private PartnerLink partnerLink;
|
|
| 38 |
|
|
| 39 |
private QName portType;
|
|
| 40 |
|
|
| 41 |
private String operation;
|
|
| 42 |
|
|
| 43 |
private Variable inVariable;
|
|
| 44 |
|
|
| 45 |
private Variable outVariable;
|
|
| 46 |
|
|
| 47 |
private Correlations correlations;
|
|
| 48 |
|
|
| 49 |
private List catchFaults;
|
|
| 50 |
|
|
| 51 |
private CatchAll catchAll;
|
|
| 52 |
|
|
| 53 |
private CompensationHandler compensationHandler;
|
|
| 54 |
|
|
| 55 |
//**************************************************/
|
|
| 56 |
// c'tors
|
|
| 57 |
//**************************************************/
|
|
| 58 |
|
|
| 59 | 8 |
public InvokeImpl() {
|
| 60 | 8 |
this(null); |
| 61 |
} |
|
| 62 |
|
|
| 63 |
/**
|
|
| 64 |
* @param standardAttributes
|
|
| 65 |
*/
|
|
| 66 | 8 |
public InvokeImpl(StandardAttributes standardAttributes) {
|
| 67 | 8 |
this(standardAttributes, null, null, null, null, null); |
| 68 |
} |
|
| 69 |
|
|
| 70 |
/**
|
|
| 71 |
* @param standardAttributes
|
|
| 72 |
* @param partnerLink2
|
|
| 73 |
* @param portType2
|
|
| 74 |
* @param operation2
|
|
| 75 |
* @param inVariable
|
|
| 76 |
* @param outVariable
|
|
| 77 |
*/
|
|
| 78 | 70 |
public InvokeImpl(StandardAttributes standardAttributes,
|
| 79 |
PartnerLink partnerLink, QName portType, String operation, |
|
| 80 |
Variable inVariable, Variable outVariable) {
|
|
| 81 |
|
|
| 82 | 70 |
super(standardAttributes);
|
| 83 |
|
|
| 84 | 70 |
init(); |
| 85 |
|
|
| 86 | 70 |
this.partnerLink = partnerLink;
|
| 87 | 70 |
this.portType = portType;
|
| 88 | 70 |
this.operation = operation;
|
| 89 | 70 |
this.inVariable = inVariable;
|
| 90 | 70 |
this.outVariable = outVariable;
|
| 91 |
} |
|
| 92 |
|
|
| 93 | 70 |
private void init() { |
| 94 | 70 |
catchFaults = new ArrayList();
|
| 95 |
} |
|
| 96 |
|
|
| 97 |
//**************************************************/
|
|
| 98 |
// bexee.model.activity.Invoke
|
|
| 99 |
//**************************************************/
|
|
| 100 |
|
|
| 101 | 4 |
public void setPartnerLink(PartnerLink partnerLink) { |
| 102 | 4 |
this.partnerLink = partnerLink;
|
| 103 |
} |
|
| 104 |
|
|
| 105 | 4 |
public PartnerLink getPartnerLink() {
|
| 106 | 4 |
return partnerLink;
|
| 107 |
} |
|
| 108 |
|
|
| 109 | 4 |
public void setPortType(QName portType) { |
| 110 | 4 |
this.portType = portType;
|
| 111 |
} |
|
| 112 |
|
|
| 113 | 20 |
public QName getPortType() {
|
| 114 | 20 |
return portType;
|
| 115 |
} |
|
| 116 |
|
|
| 117 | 4 |
public void setOperation(String operation) { |
| 118 | 4 |
this.operation = operation;
|
| 119 |
} |
|
| 120 |
|
|
| 121 | 18 |
public String getOperation() {
|
| 122 | 18 |
return operation;
|
| 123 |
} |
|
| 124 |
|
|
| 125 | 4 |
public void setInputVariable(Variable inputVariable) { |
| 126 | 4 |
this.inVariable = inputVariable;
|
| 127 |
} |
|
| 128 |
|
|
| 129 | 12 |
public Variable getInputVariable() {
|
| 130 | 12 |
return inVariable;
|
| 131 |
} |
|
| 132 |
|
|
| 133 | 0 |
public void setOutputVariable(Variable outputVariable) { |
| 134 | 0 |
this.outVariable = outputVariable;
|
| 135 |
} |
|
| 136 |
|
|
| 137 | 8 |
public Variable getOutputVariable() {
|
| 138 | 8 |
return outVariable;
|
| 139 |
} |
|
| 140 |
|
|
| 141 | 0 |
public void setCorrelations(Correlations correlations) { |
| 142 | 0 |
this.correlations = correlations;
|
| 143 |
} |
|
| 144 |
|
|
| 145 | 0 |
public Correlations getCorrelations() {
|
| 146 | 0 |
return correlations;
|
| 147 |
} |
|
| 148 |
|
|
| 149 | 0 |
public void addCatchFault(CatchFault catchFault) { |
| 150 | 0 |
catchFaults.add(catchFault); |
| 151 |
} |
|
| 152 |
|
|
| 153 | 0 |
public void setCatchFaults(List catchFaults) { |
| 154 | 0 |
this.catchFaults = catchFaults;
|
| 155 |
} |
|
| 156 |
|
|
| 157 | 0 |
public List getCatchFaults() {
|
| 158 | 0 |
return catchFaults;
|
| 159 |
} |
|
| 160 |
|
|
| 161 | 0 |
public void setCatchAll(CatchAll catchAll) { |
| 162 | 0 |
this.catchAll = catchAll;
|
| 163 |
} |
|
| 164 |
|
|
| 165 | 0 |
public CatchAll getCatchAll() {
|
| 166 | 0 |
return catchAll;
|
| 167 |
} |
|
| 168 |
|
|
| 169 | 0 |
public void setCompensationHandler(CompensationHandler compensationHandler) { |
| 170 | 0 |
this.compensationHandler = compensationHandler;
|
| 171 |
} |
|
| 172 |
|
|
| 173 | 0 |
public CompensationHandler getCompensationHandler() {
|
| 174 | 0 |
return compensationHandler;
|
| 175 |
} |
|
| 176 |
|
|
| 177 | 8 |
public boolean isSynchronous() { |
| 178 | 8 |
return (outVariable != null); |
| 179 |
} |
|
| 180 |
|
|
| 181 |
//**************************************************/
|
|
| 182 |
// bexee.core.BPELElement
|
|
| 183 |
//**************************************************/
|
|
| 184 |
|
|
| 185 | 12 |
public void accept(ProcessController controller, ProcessInstance instance) |
| 186 |
throws Exception {
|
|
| 187 | 12 |
controller.process(this, instance);
|
| 188 |
} |
|
| 189 |
|
|
| 190 | 66 |
public void accept(BPELElementVisitor elementVisitor) { |
| 191 | 66 |
elementVisitor.visit(this);
|
| 192 |
} |
|
| 193 |
} |
|
||||||||||