Package org.apache.axis2.description

Examples of org.apache.axis2.description.AxisBinding


                        WSDLConstants.MESSAGE_LABEL_IN_VALUE));
                AxisEndpoint axisEndpoint =
                        (AxisEndpoint) msgctx.getProperty(WSDL2Constants.ENDPOINT_LOCAL_NAME);

                if (axisEndpoint != null) {
                    AxisBinding axisBinding = axisEndpoint.getBinding();
          AxisBindingOperation axisBindingOperation = (AxisBindingOperation) axisBinding
              .getChild(axisOperation.getName());
          if (axisBindingOperation == null) {
            String localName = axisOperation.getName()
                .getLocalPart();
            AxisBindingOperation bindingOp = null;
            for (Iterator<AxisBindingOperation> iterator = axisBinding.getChildren(); iterator
                .hasNext();) {
              bindingOp = (AxisBindingOperation) iterator.next();
              if (localName.equals(bindingOp.getName().getLocalPart())) {
                axisBindingOperation = bindingOp;
                break;
View Full Code Here


        }

        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

      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

        }

        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

        }

        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

   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

      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

    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

    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

          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

TOP

Related Classes of org.apache.axis2.description.AxisBinding

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.