1
2
3
4
5
6 package net.kwfgrid.gworkflowdl.protocol.calls;
7
8 import net.kwfgrid.gworkflowdl.protocol.structure.*;
9
10 import java.io.IOException;
11
12 import org.xmlpull.v1.XmlSerializer;
13
14 /***
15 Modification that sets the OperationClass of an Operation.
16 */
17 public class OperationSetOperationClass extends AbstractMethodCall {
18 protected ProtocolOperationClass _oc;
19 protected ProtocolOperation _operation;
20
21 public OperationSetOperationClass(ProtocolOperation operation, ProtocolOperationClass co) {
22 super(operation.getRoot());
23 _operation = operation;
24 _oc = co;
25 }
26
27 public void marshal(IMethodCallMarshaller encoder, XmlSerializer serializer) throws IOException {
28 encoder.marshalOperationSetOperationClass(serializer, _operation, _oc);
29 }
30
31 public Object execute() {
32 _operation.__set(_oc);
33 setExecuted();
34 return null;
35 }
36 }