1 5 6 package org.exoplatform.services.wsrp.mocks; 7 8 9 import javax.xml.rpc.ServiceException ; 10 import javax.xml.rpc.Call ; 11 import javax.xml.rpc.handler.HandlerRegistry ; 12 import javax.xml.rpc.encoding.TypeMappingRegistry ; 13 import javax.xml.namespace.QName ; 14 import org.exoplatform.services.wsrp.bind.WSRP_v1_Markup_Binding_SOAPImpl; 15 import org.exoplatform.services.wsrp.bind.WSRP_v1_PortletManagement_Binding_SOAPImpl; 16 import org.exoplatform.services.wsrp.bind.WSRP_v1_Registration_Binding_SOAPImpl; 17 import org.exoplatform.services.wsrp.bind.WSRP_v1_ServiceDescription_Binding_SOAPImpl; 18 import org.exoplatform.services.wsrp.intf.WSRP_v1_Markup_PortType; 19 import org.exoplatform.services.wsrp.intf.WSRP_v1_PortletManagement_PortType; 20 import org.exoplatform.services.wsrp.intf.WSRP_v1_Registration_PortType; 21 import org.exoplatform.services.wsrp.intf.WSRP_v1_ServiceDescription_PortType; 22 import org.exoplatform.services.wsrp.wsdl.WSRPService; 23 import org.exoplatform.services.wsrp.wsdl.WSRPServiceLocator; 24 import java.net.URL ; 25 import java.rmi.Remote ; 26 import java.util.Iterator ; 27 28 34 35 public class MockWSRPService extends WSRPServiceLocator implements WSRPService { 36 private WSRP_v1_ServiceDescription_Binding_SOAPImpl serviceDescriptionInterface; 37 private WSRP_v1_Registration_Binding_SOAPImpl registrationOperationsInterface; 38 private WSRP_v1_Markup_Binding_SOAPImpl markupOperationsInterface; 39 private WSRP_v1_PortletManagement_Binding_SOAPImpl portletManagementOperationsInterface; 40 41 public MockWSRPService() { 42 serviceDescriptionInterface = new WSRP_v1_ServiceDescription_Binding_SOAPImpl(); 43 registrationOperationsInterface = new WSRP_v1_Registration_Binding_SOAPImpl(); 44 markupOperationsInterface = new WSRP_v1_Markup_Binding_SOAPImpl(); 45 portletManagementOperationsInterface = new WSRP_v1_PortletManagement_Binding_SOAPImpl(); 46 } 47 48 public String getWSRPPortletManagementServiceAddress() { 49 return "Mock"; 50 } 51 52 public WSRP_v1_PortletManagement_PortType getWSRPPortletManagementService() throws ServiceException { 53 return portletManagementOperationsInterface; 54 } 55 56 public WSRP_v1_PortletManagement_PortType getWSRPPortletManagementService(URL portAddress) throws ServiceException { 57 return portletManagementOperationsInterface; 58 } 59 60 public String getWSRPRegistrationServiceAddress() { 61 return "Mock"; 62 } 63 64 public WSRP_v1_Registration_PortType getWSRPRegistrationService() throws ServiceException { 65 return registrationOperationsInterface; 66 } 67 68 public WSRP_v1_Registration_PortType getWSRPRegistrationService(URL portAddress) throws ServiceException { 69 return registrationOperationsInterface; 70 } 71 72 public String getWSRPBaseServiceAddress() { 73 return "Mock"; 74 } 75 76 public WSRP_v1_Markup_PortType getWSRPBaseService() throws ServiceException { 77 return markupOperationsInterface; 78 } 79 80 public WSRP_v1_Markup_PortType getWSRPBaseService(URL portAddress) throws ServiceException { 81 return markupOperationsInterface; 82 } 83 84 public String getWSRPServiceDescriptionServiceAddress() { 85 return "Mock"; 86 } 87 88 public WSRP_v1_ServiceDescription_PortType getWSRPServiceDescriptionService() throws ServiceException { 89 return serviceDescriptionInterface; 90 } 91 92 public WSRP_v1_ServiceDescription_PortType getWSRPServiceDescriptionService(URL portAddress) throws ServiceException { 93 return serviceDescriptionInterface; 94 } 95 96 97 98 100 101 public Remote getPort(QName qName, Class aClass) throws ServiceException { 102 return null; } 104 105 public Remote getPort(Class aClass) throws ServiceException { 106 return null; } 108 109 public Call [] getCalls(QName qName) throws ServiceException { 110 return new Call [0]; } 112 113 public Call createCall(QName qName) throws ServiceException { 114 return null; } 116 117 public Call createCall(QName qName, QName qName1) throws ServiceException { 118 return null; } 120 121 public Call createCall(QName qName, String string) throws ServiceException { 122 return null; } 124 125 public Call createCall() throws ServiceException { 126 return null; } 128 129 public QName getServiceName() { 130 return null; } 132 133 136 137 public URL getWSDLDocumentLocation() { 138 return null; } 140 141 public TypeMappingRegistry getTypeMappingRegistry() { 142 return null; } 144 145 public HandlerRegistry getHandlerRegistry() { 146 return null; } 148 } 149 | Popular Tags |