1
2
3
4
5
6
7
8
9
10
11 package org.mule.tck.testmodels.fruit;
12
13 import org.mule.api.MuleEventContext;
14
15
16
17
18
19 public class Kiwi implements Fruit
20 {
21
22
23
24 private static final long serialVersionUID = -1468423665948468954L;
25
26 private boolean bitten;
27
28 public void handle(MuleEventContext eventContext) throws Exception
29 {
30 final Object payload = eventContext.transformMessage();
31 if (payload instanceof FruitLover)
32 {
33 this.bite();
34 }
35 }
36
37 public void bite()
38 {
39 this.bitten = true;
40 }
41
42 public boolean isBitten()
43 {
44 return this.bitten;
45 }
46 }