samedi 18 mars 2017

Soap http methods Java

I would like to map all http's methods from within a wsdl file.

I currently have:

    String url = "http://ift.tt/USArCx";

    String wsdl = url + "?wsdl";
    WSDLParser parser = new WSDLParser();

    Definitions defs = parser.parse(wsdl);

    String targetNamespace = defs.getTargetNamespace();
    String prefix = defs.getTargetNamespacePrefix();

    defs.getServices().forEach(service -> {
        System.out.println("Service -> " + service.getName());
        service.getPorts().forEach(port -> {
            String bindingName = port.getBinding().getName();
            System.out.println("\tBinding -> " + bindingName);
            System.out.println("\tAddress -> " + port.getAddress().getLocation());

            Binding binding = defs.getBinding(bindingName);
        });
    });

But I would like to get the HTTPBinding tried in all ways but have not yet found a solution

Aucun commentaire:

Enregistrer un commentaire