1 | |
|
2 | |
|
3 | |
|
4 | |
|
5 | |
|
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | |
|
11 | |
|
12 | |
|
13 | |
|
14 | |
|
15 | |
|
16 | |
|
17 | |
package org.kuali.rice.ksb.messaging.serviceexporters; |
18 | |
|
19 | |
import org.kuali.rice.ksb.messaging.KSBHttpInvokerServiceExporter; |
20 | |
import org.kuali.rice.ksb.messaging.ServerSideRemotedServiceHolder; |
21 | |
import org.kuali.rice.ksb.messaging.ServiceInfo; |
22 | |
|
23 | |
|
24 | |
|
25 | |
|
26 | |
|
27 | |
public class HttpInvokerServiceExporter implements ServiceExporter { |
28 | |
|
29 | |
private ServiceInfo serviceInfo; |
30 | |
|
31 | 0 | public HttpInvokerServiceExporter(ServiceInfo serviceInfo) { |
32 | 0 | this.serviceInfo = serviceInfo; |
33 | 0 | } |
34 | |
|
35 | |
public ServerSideRemotedServiceHolder getServiceExporter(Object serviceImpl) { |
36 | 0 | KSBHttpInvokerServiceExporter service = new KSBHttpInvokerServiceExporter(); |
37 | 0 | service.setServiceInfo(getServiceInfo()); |
38 | 0 | service.setService(serviceImpl); |
39 | 0 | service.afterPropertiesSet(); |
40 | 0 | return new ServerSideRemotedServiceHolder(service, getServiceInfo().getServiceDefinition().getService(), getServiceInfo()); |
41 | |
} |
42 | |
|
43 | |
public ServiceInfo getServiceInfo() { |
44 | 0 | return this.serviceInfo; |
45 | |
} |
46 | |
} |