Package org.switchyard.common.io.pull

Examples of org.switchyard.common.io.pull.StringPuller


    private static final String HELP = "help";

    private static final String MAVEN_USAGE = String.format("Maven Usage: mvn exec:java -Dexec.args=\"%s %s %s\"", CONFIDENTIALITY, CLIENT_AUTHENTICATION, HELP);

    private static void invokeWorkService(String scheme, int port, String context, String[] userPass) throws Exception {
        String soapRequest = new StringPuller().pull("/xml/soap-request.xml").replaceAll("WORK_CMD", "CMD-" + System.currentTimeMillis());
        HTTPMixIn http = new HTTPMixIn();
        if (userPass != null && userPass.length == 2) {
            http.setRequestHeader("Authorization", "Basic " + Base64.encodeFromString(userPass[0] + ":" + userPass[1]));
        }
        http.initialize();
View Full Code Here


    private static final String HELP = "help";

    private static final String MAVEN_USAGE = String.format("Maven Usage: mvn exec:java -Dexec.args=\"%s %s %s\"", CONFIDENTIALITY, CLIENT_AUTHENTICATION, HELP);

    private static void invokeWorkService(String scheme, int port, String context, String binarySecurityToken) throws Exception {
        String soapRequest = new StringPuller().pull("/xml/soap-request.xml").replaceAll("WORK_CMD", "CMD-" + System.currentTimeMillis());
        if (binarySecurityToken != null) {
            soapRequest = soapRequest.replaceFirst("<!-- BinarySecurityToken -->", binarySecurityToken);
        }
        HTTPMixIn http = new HTTPMixIn();
        http.initialize();
View Full Code Here

                sr.register(https);
            } else {
                scheme = "http";
                port = getPort(8080);
            }
            String binarySecurityToken = policies.contains(CLIENT_AUTHENTICATION) ? new StringPuller().pull("/xml/BinarySecurityToken.xml") : null;
            invokeWorkService(scheme, port, getContext(), binarySecurityToken);
        }
    }
View Full Code Here

    private static final String MAVEN_USAGE = String.format("Maven Usage: mvn exec:java -Dexec.args=\"%s %s %s\"", CONFIDENTIALITY, SIGNENCRYPT, HELP);

    private static void invokeWorkService(String scheme, int port, String context, boolean signencrypt) throws Exception {
        String soapRequest;
        if (signencrypt) {
            soapRequest = new StringPuller().pull("/xml/secure-request.xml");
        } else {
            soapRequest = new StringPuller().pull("/xml/insecure-request.xml").replaceAll("WORK_CMD", "CMD-" + System.currentTimeMillis());
        }
        HTTPMixIn http = new HTTPMixIn();
        http.initialize();
        try {
            String endpoint = String.format("%s://localhost:%s/%s/WorkService", scheme, port, context);
View Full Code Here

    private static final String HELP = "help";

    private static final String MAVEN_USAGE = String.format("Maven Usage: mvn exec:java -Dexec.args=\"%s %s %s\"", CONFIDENTIALITY, CLIENT_AUTHENTICATION, HELP);

    private static void invokeWorkService(String scheme, int port, String context, String[] userPass) throws Exception {
        String soapRequest = new StringPuller().pull("/xml/soap-request.xml").replaceAll("WORK_CMD", "CMD-" + System.currentTimeMillis());
        HTTPMixIn http = new HTTPMixIn();
        if (userPass != null && userPass.length == 2) {
            http.setRequestHeader("Authorization", "Basic " + Base64.encodeFromString(userPass[0] + ":" + userPass[1]));
        }
        http.initialize();
View Full Code Here

    private static final String HELP = "help";

    private static final String MAVEN_USAGE = String.format("Maven Usage: mvn exec:java -Dexec.args=\"%s %s %s\"", CONFIDENTIALITY, CLIENT_AUTHENTICATION, HELP);

    private static void invokeWorkService(String scheme, int port, String context, String username) throws Exception {
        String soapRequest = new StringPuller().pull("/xml/soap-request.xml").replaceAll("WORK_CMD", "CMD-" + System.currentTimeMillis());
        HTTPMixIn http = new HTTPMixIn();
        soapRequest = soapRequest.replaceFirst("<!-- Username -->", username);
        http.initialize();
        try {
            String endpoint = String.format("%s://localhost:%s/%s/WorkService", scheme, port, context);
View Full Code Here

TOP

Related Classes of org.switchyard.common.io.pull.StringPuller

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.