Examples of AxisBinding


Examples of org.apache.axis2.description.AxisBinding

        }

        AxisBindingMessage bindingMessage =
          (AxisBindingMessage) getProperty(Constants.AXIS_BINDING_MESSAGE);

        AxisBinding binding;

        // If AxisBindingMessage is not set, try to find the binding message from the AxisService
        if (bindingMessage == null) {
          bindingMessage = findBindingMessage();
        }

        if (bindingMessage != null) {
            return bindingMessage.getEffectivePolicy();
            // If we can't find the AxisBindingMessage, then try the AxisBinding
        } else if ((binding = findBinding()) != null) {
            return binding.getEffectivePolicy();
            // If we can't find the AxisBindingMessage, then try the AxisMessage
        } else if (axisMessage != null) {
            return axisMessage.getEffectivePolicy();
        } else {
            if (axisService != null){
View Full Code Here

Examples of org.apache.axis2.description.AxisBinding

      if (axisService != null && axisOperation != null ) {
      if (axisService.getEndpointName() != null) {
        AxisEndpoint axisEndpoint = axisService
            .getEndpoint(axisService.getEndpointName());
        if (axisEndpoint != null) {
          AxisBinding axisBinding = axisEndpoint.getBinding();
                    AxisBindingOperation axisBindingOperation = (AxisBindingOperation) axisBinding
              .getChild(axisOperation.getName());

                    //If Binding Operation is not found, just return null
                    if (axisBindingOperation == null) {
                       return null;
View Full Code Here

Examples of org.apache.axis2.description.AxisBinding

        }

        AxisEndpoint axisEndpoint =
                (AxisEndpoint) messageContext.getProperty(WSDL2Constants.ENDPOINT_LOCAL_NAME);
        if (axisEndpoint != null) {
            AxisBinding axisBinding = axisEndpoint.getBinding();
            String soapVersion =
                    (String) axisBinding.getProperty(WSDL2Constants.ATTR_WSOAP_VERSION);
            soapFactory = getSOAPFactory(soapVersion);
        } else {
            soapFactory = getSOAPFactory(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
        }
        EndpointReference endpointReference = messageContext.getTo();
View Full Code Here

Examples of org.apache.axis2.description.AxisBinding

        }

        for (Object obj : axisService.getEndpoints().values()) {

            AxisEndpoint endpoint = (AxisEndpoint) obj;
            AxisBinding binding = endpoint.getBinding();
            if (Java2WSDLConstants.TRANSPORT_URI.equals(binding.getType())
                    || WSDL2Constants.URI_WSDL2_SOAP.equals(binding.getType())) {
                binding.getPolicySubject().attachPolicy(policy);
            }
        }

        axisService
                .addParameter("MTOM_ASSERTION_APPLIED", Constants.VALUE_TRUE);
View Full Code Here

Examples of org.apache.axis2.description.AxisBinding

   public boolean checkTypePublishing(){
     
       MessageContext msgctx= MessageContext.getCurrentMessageContext();
       AxisService axisServce= msgctx.getAxisService();
       AxisEndpoint axisEndpoint= axisServce.getEndpoint("AnnotationServiceHttpEndpoint");
       AxisBinding axisBinding=axisEndpoint.getBinding();
       AxisBindingOperation axisBindingOperation;
       Iterator<AxisBindingOperation> iterator=axisBinding.getChildren();


         while(iterator.hasNext()){
           axisBindingOperation=iterator.next();
             if(axisBindingOperation.getName().equals(new QName("addDataFromURLandBody"))){
View Full Code Here

Examples of org.apache.axis2.description.AxisBinding

      if (axisService != null && axisOperation != null ) {
      if (axisService.getEndpointName() != null) {
        AxisEndpoint axisEndpoint = axisService
            .getEndpoint(axisService.getEndpointName());
        if (axisEndpoint != null) {
          AxisBinding axisBinding = axisEndpoint.getBinding();
                    AxisBindingOperation axisBindingOperation = (AxisBindingOperation) axisBinding
              .getChild(axisOperation.getName());

                    //If Binding Operation is not found, just return null
                    if (axisBindingOperation == null) {
                       return null;
View Full Code Here

Examples of org.apache.axis2.description.AxisBinding

    String serviceName = axisService.getName();
    String name = serviceName + "HttpBinding";

    QName bindingName = new QName(name);

    AxisBinding axisBinding = (bindingCache != null) ? (AxisBinding) bindingCache
        .get(name)
        : null;

    if (axisBinding == null) {
      axisBinding = new AxisBinding();
      axisBinding.setName(bindingName);

      axisBinding.setType(WSDL2Constants.URI_WSDL2_HTTP);
      axisBinding.setProperty(WSDL2Constants.ATTR_WHTTP_METHOD, "POST");

      for (Iterator iterator = axisService.getChildren(); iterator
          .hasNext();) {
        AxisOperation operation = (AxisOperation) iterator.next();
        AxisBindingOperation axisBindingOperation = new AxisBindingOperation();

                QName operationQName = operation.getName();
                axisBindingOperation.setName(operationQName);
        axisBindingOperation.setAxisOperation(operation);
                String httpLocation = operationQName.getLocalPart();
                axisBindingOperation.setProperty(WSDL2Constants.ATTR_WHTTP_LOCATION, httpLocation);
        axisBinding.addChild(axisBindingOperation.getName(),
            axisBindingOperation);

        populateBindingOperation(axisService, axisBinding,
            axisBindingOperation);
      }
      if (bindingCache != null) {
        bindingCache.put(name, axisBinding);
      }
    }
    axisBinding.setParent(axisEndpoint);
    axisEndpoint.setBinding(axisBinding);
  }
View Full Code Here

Examples of org.apache.axis2.description.AxisBinding

    String soapVersion = (identifier.indexOf("soap12") > -1) ? SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI
        : SOAP11Constants.SOAP_ENVELOPE_NAMESPACE_URI;

    for (Iterator iterator = map.values().iterator(); iterator.hasNext();) {
      AxisEndpoint axisEndpoint = (AxisEndpoint) iterator.next();
      AxisBinding axisBinding = axisEndpoint.getBinding();
      String wsoap = (String) axisBinding
          .getProperty(WSDL2Constants.ATTR_WSOAP_VERSION);
      if (soapVersion.equals(wsoap)) {
        String[] identifiers = identifier.split("/");
        int key = identifiers.length;
        if (key == 1) {
          axisBinding.getPolicySubject().attachPolicyComponents(
              policyComponents);
        } else if (key == 2 || key == 3) {
          String opName = identifiers[1];
          opName = opName.substring(opName.indexOf(":") + 1, opName
              .length());
          AxisBindingOperation bindingOperation = null;
          boolean found = false;
          for (Iterator i = axisBinding.getChildren(); i.hasNext();) {
            bindingOperation = (AxisBindingOperation) i.next();
            if (opName.equals(bindingOperation.getName()
                .getLocalPart())) {
              found = true;
              break;
View Full Code Here

Examples of org.apache.axis2.description.AxisBinding

          String transportInDescription = endpoint
                  .getTransportInDescription();
          if (transportInDescription == null) {
              continue;
          }
          AxisBinding binding = endpoint.getBinding();
          if (binding != null) {
              if (isSoap11Binding(binding)) {
                  map.put(transportInDescription + ":soap11", endpoint);
              } else if (isSoap12Binding(binding)) {
                  map.put(transportInDescription + ":soap12", endpoint);
View Full Code Here

Examples of org.apache.axis2.description.AxisBinding

            ArrayList bindings = new ArrayList();
            Map endpointsMap = service.getEndpoints();
         
            for (Iterator iterator = endpointsMap.values().iterator(); iterator.hasNext();) {
                AxisEndpoint endpoint = (AxisEndpoint) iterator.next();
                AxisBinding binding = endpoint.getBinding();
          AxisBindingOperation bindingOperation = new AxisBindingOperation();
          bindingOperation.setName(operation.getName());
          bindingOperation.setAxisOperation(operation);
     
          if (!bindings.contains(binding.getName())) {
              if (isSoap11Binding(binding)) {
                  String soapAction = operation.getSoapAction();
                  if (soapAction != null) {
                          bindingOperation.setProperty(WSDL2Constants.ATTR_WSOAP_ACTION, soapAction);
                  }           
              } else if (isSoap12Binding(binding)) {
                  String soapAction = operation.getSoapAction();
                  if (soapAction != null) {
                      bindingOperation.setProperty(WSDL2Constants.ATTR_WSOAP_ACTION, soapAction);
                  }
         
              } else if (isHttpBinding(binding)) {
                  String serviceName = service.getName();
                  String name = serviceName + "HttpBinding";
                  String httpLocation = serviceName + "/" + operation.getName().getLocalPart();
                  bindingOperation.setProperty(WSDL2Constants.ATTR_WHTTP_LOCATION, httpLocation);
              }
          }
     
          binding.addChild(bindingOperation.getName(), bindingOperation);
          populateBindingOperation(service, binding, bindingOperation);
         
            }
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.