Package org.reficio.ws.client

Examples of org.reficio.ws.client.SoapClientException


                }
                post.addHeader(PROP_CONTENT_TYPE, contentType);
            }
            return post;
        } catch (UnsupportedEncodingException ex) {
            throw new SoapClientException(ex);
        }
    }
View Full Code Here


                factory = SSLUtils.getFactory(proxyProperties);
                port = proxyUri.getPort();
                registerTlsScheme(factory, port);
            }
        } catch (GeneralSecurityException ex) {
            throw new SoapClientException(ex);
        }
    }
View Full Code Here

            checkNotNull(value);
            try {
                URI uri = new URI(value);
                return endpointUri(uri);
            } catch (URISyntaxException ex) {
                throw new SoapClientException(String.format("URI [%s] is malformed", value), ex);
            }
        }
View Full Code Here

            checkNotNull(value);
            try {
                URI uri = new URI(value);
                return proxyUri(uri);
            } catch (URISyntaxException ex) {
                throw new SoapClientException(String.format("URI [%s] is malformed", value), ex);
            }
        }
View Full Code Here

            checkNotNull(value);
            try {
                keyStoreUrl = new URL(value);
                return this;
            } catch (MalformedURLException ex) {
                throw new SoapClientException(String.format("URL [%s] is malformed", value), ex);
            }
        }
View Full Code Here

            checkNotNull(value);
            try {
                trustStoreUrl = new URL(value);
                return this;
            } catch (MalformedURLException ex) {
                throw new SoapClientException(String.format("URL [%s] is malformed", value), ex);
            }
        }
View Full Code Here

        }

        private KeyStore initKeyStore(KeyStore keyStore, URL keyStoreUrl, String keyStoreType, char[] keyStorePassword) {
            boolean keyStorePropertiesDefined = keyStoreUrl != null || keyStoreType != null || keyStorePassword != null;
            if (keyStore != null && keyStorePropertiesDefined) {
                throw new SoapClientException("Specify either a keyStore | trustStore instance or properties required to load one " +
                        "(url, type, password)");
            }
            if (keyStoreUrl != null) {
                try {
                    InputStream in = keyStoreUrl.openStream();
                    KeyStore ks = KeyStore.getInstance(keyStoreType);
                    ks.load(in, keyStorePassword);
                    in.close();
                    return ks;
                } catch (GeneralSecurityException e) {
                    throw new SoapClientException("KeyStore setup failed", e);
                } catch (IOException e) {
                    throw new SoapClientException("KeyStore setup failed", e);
                }
            }
            return null;
        }
View Full Code Here

TOP

Related Classes of org.reficio.ws.client.SoapClientException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.