/** * Set the address of the provided endpoint reference. * @param ref - the endpoint reference * @param address - the address */ public static void setAddress(EndpointReferenceType ref, String address) { WSAEndpointReferenceUtils.setAddress(ref, address); } /**
/** * Create a duplicate endpoint reference sharing all atributes * @param ref the reference to duplicate * @return EndpointReferenceType - the duplicate endpoint reference */ public static EndpointReferenceType duplicate(EndpointReferenceType ref) { return WSAEndpointReferenceUtils.duplicate(ref); }
public void setAddress(String addr) { if (null == address) { address = WSAEndpointReferenceUtils.getEndpointReference(addr); } else { WSAEndpointReferenceUtils.setAddress(address, addr); } }
/** * Creates an endpoint reference by duplicating the endpoint reference of a given server. * @param server * @param address * @param props * @return */ private static EndpointReferenceType createEPR(Server server, String address, SLProperties props) { EndpointReferenceType sourceEPR = server.getEndpoint().getEndpointInfo().getTarget(); EndpointReferenceType targetEPR = WSAEndpointReferenceUtils.duplicate(sourceEPR); WSAEndpointReferenceUtils.setAddress(targetEPR, address); if (props != null) { addProperties(targetEPR, props); } return targetEPR; }
public static void setWSDLLocation(EndpointReferenceType ref, String... wsdlLocation) { MetadataType metadata = WSAEndpointReferenceUtils.getSetMetadata(ref); //wsdlLocation attribute is a list of anyURI. StringBuilder strBuf = new StringBuilder(); for (String str : wsdlLocation) { strBuf.append(str); strBuf.append(" "); } metadata.getOtherAttributes().put(WSDL_LOCATION, strBuf.toString().trim()); }
/** * Create an endpoint reference for the provided address. * @param address - address URI * @return EndpointReferenceType - the endpoint reference */ public static EndpointReferenceType getEndpointReference(String address) { return WSAEndpointReferenceUtils.getEndpointReference(address); }
/** * Create an anonymous endpoint reference. * @return EndpointReferenceType - the endpoint reference */ public static EndpointReferenceType getAnonymousEndpointReference() { return WSAEndpointReferenceUtils.getAnonymousEndpointReference(); }
/** * Get the address from the provided endpoint reference. * @param ref - the endpoint reference * @return String the address of the endpoint */ public static String getAddress(EndpointReferenceType ref) { return WSAEndpointReferenceUtils.getAddress(ref); }
/** * Create an endpoint reference for the provided wsdl, service and portname. * @param wsdlUrl - url of the wsdl that describes the service. * @param serviceName - the <code>QName</code> of the service. * @param portName - the name of the port. * @return EndpointReferenceType - the endpoint reference */ public static EndpointReferenceType getEndpointReference(URL wsdlUrl, QName serviceName, String portName) { EndpointReferenceType reference = WSAEndpointReferenceUtils.createEndpointReferenceWithMetadata(); setServiceAndPortName(reference, serviceName, portName); //TODO To Ensure it is a valid URI syntax. setWSDLLocation(reference, wsdlUrl.toString()); return reference; }
/** * Creates an endpoint reference by duplicating the endpoint reference of a given server. * @param server * @param address * @param props * @return */ private static EndpointReferenceType createEPR(Server server, String address, SLProperties props) { EndpointReferenceType sourceEPR = server.getEndpoint().getEndpointInfo().getTarget(); EndpointReferenceType targetEPR = WSAEndpointReferenceUtils.duplicate(sourceEPR); WSAEndpointReferenceUtils.setAddress(targetEPR, address); if (props != null) { addProperties(targetEPR, props); } return targetEPR; }
public static void setWSDLLocation(EndpointReferenceType ref, String... wsdlLocation) { MetadataType metadata = WSAEndpointReferenceUtils.getSetMetadata(ref); //wsdlLocation attribute is a list of anyURI. StringBuilder strBuf = new StringBuilder(); for (String str : wsdlLocation) { strBuf.append(str); strBuf.append(" "); } metadata.getOtherAttributes().put(WSDL_LOCATION, strBuf.toString().trim()); }
/** * Create an endpoint reference for the provided address. * @param address - address URI * @return EndpointReferenceType - the endpoint reference */ public static EndpointReferenceType getEndpointReference(String address) { return WSAEndpointReferenceUtils.getEndpointReference(address); }
/** * Create an anonymous endpoint reference. * @return EndpointReferenceType - the endpoint reference */ public static EndpointReferenceType getAnonymousEndpointReference() { return WSAEndpointReferenceUtils.getAnonymousEndpointReference(); }
/** * Get the address from the provided endpoint reference. * @param ref - the endpoint reference * @return String the address of the endpoint */ public static String getAddress(EndpointReferenceType ref) { return WSAEndpointReferenceUtils.getAddress(ref); }
/** * Create an endpoint reference for the provided wsdl, service and portname. * @param wsdlUrl - url of the wsdl that describes the service. * @param serviceName - the <code>QName</code> of the service. * @param portName - the name of the port. * @return EndpointReferenceType - the endpoint reference */ public static EndpointReferenceType getEndpointReference(URL wsdlUrl, QName serviceName, String portName) { EndpointReferenceType reference = WSAEndpointReferenceUtils.createEndpointReferenceWithMetadata(); setServiceAndPortName(reference, serviceName, portName); //TODO To Ensure it is a valid URI syntax. setWSDLLocation(reference, wsdlUrl.toString()); return reference; }
/** * Set the address of the provided endpoint reference. * @param ref - the endpoint reference * @param address - the address */ public static void setAddress(EndpointReferenceType ref, String address) { WSAEndpointReferenceUtils.setAddress(ref, address); } /**
public void setAddress(String addr) { if (null == address) { address = WSAEndpointReferenceUtils.getEndpointReference(addr); } else { WSAEndpointReferenceUtils.setAddress(address, addr); } }
/** * Sets the service and port name of the provided endpoint reference. * @param ref the endpoint reference. * @param serviceName the name of service. * @param portName the port name. */ public static void setServiceAndPortName(EndpointReferenceType ref, QName serviceName, String portName) { if (null != serviceName) { JAXBElement<ServiceNameType> jaxbElement = getServiceNameType(serviceName, portName); MetadataType mt = WSAEndpointReferenceUtils.getSetMetadata(ref); mt.getAny().add(jaxbElement); } }
public static EndpointReferenceType getEndpointReference(AttributedURIType address) { return WSAEndpointReferenceUtils.getEndpointReference(address); }
/** * Create a duplicate endpoint reference sharing all atributes * @param ref the reference to duplicate * @return EndpointReferenceType - the duplicate endpoint reference */ public static EndpointReferenceType duplicate(EndpointReferenceType ref) { return WSAEndpointReferenceUtils.duplicate(ref); }