001package net.gdface.codegen.webclient; 002 003import org.slf4j.Logger; 004import org.slf4j.LoggerFactory; 005 006public class RPCClient<T> extends WebClient<T> implements WebClientConstants { 007 private static final Logger logger = LoggerFactory.getLogger(RPCClient.class); 008 private final String namespaceURI; 009 010 public RPCClient(Class<T> interfaceClass, Class<? extends T> refClass, Class<?> serviceClass) { 011 super(interfaceClass, refClass, serviceClass); 012 namespaceURI = NAMESPACEGENERATOR.namespaceFromPackageName(serviceClass.getPackage().getName()).toString(); 013 getImportedList().put("AxisFault", org.apache.axis2.AxisFault.class); 014 } 015 016 /** 017 * @return namespaceURI 018 */ 019 public String getNamespaceURI() { 020 return namespaceURI; 021 } 022 023 @Override 024 public boolean compile() { 025 boolean compileOk = false; 026 try { 027 if (super.compile()) { 028 method2PortMap = createMethod2PortMapMap(); 029 // addImportedClassFromMethods(method2PortMap.values()); 030 compileOk = true; 031 } 032 } catch (NoSuchMethodException e) { 033 logger.error(e.toString()); 034 } 035 return compileOk; 036 } 037 038}