1
2
3
4
5
6
7
8
9
10
11 package org.mule.impl.model.resolvers;
12
13 import org.mule.impl.NoSatisfiableMethodsException;
14 import org.mule.umo.UMOEventContext;
15 import org.mule.umo.lifecycle.Callable;
16 import org.mule.umo.model.UMOEntryPoint;
17
18
19
20
21 public class CallableEntryPoint implements UMOEntryPoint
22 {
23
24 public Object invoke(Object component, UMOEventContext context) throws Exception
25 {
26 if (component instanceof Callable)
27 {
28 return ((Callable) component).onCall(context);
29 }
30 else
31 {
32 throw new NoSatisfiableMethodsException(component, UMOEventContext.class);
33 }
34 }
35
36 }