Package org.apache.axis2.om

Examples of org.apache.axis2.om.OMAttribute


        while (trs_senders.hasNext()) {
            TransportOutDescription transportout;
            OMElement transport = (OMElement) trs_senders.next();

            // getting transport Name
            OMAttribute trsName = transport.getAttribute(new QName(ATTRIBUTE_NAME));

            if (trsName != null) {
                String name = trsName.getAttributeValue();

                transportout = new TransportOutDescription(new QName(name));

                // transport impl class
                OMAttribute trsClas = transport.getAttribute(new QName(TAG_CLASS_NAME));

                if (trsClas == null) {
                    throw new DeploymentException(
                            Messages.getMessage(DeploymentErrorMsgs.TRANSPORT_SENDER_ERROR, name));
                }

                String clasName = trsClas.getAttributeValue();
                Class sender;

                try {
                    sender = Class.forName(clasName, true,
                            Thread.currentThread().getContextClassLoader());
View Full Code Here


            OMElement proxyParamElement = proxyParam.getParameterElement();
            Iterator ite = proxyParamElement.getAllAttributes();

            while (ite.hasNext()) {
                OMAttribute att = (OMAttribute) ite.next();

                if (att.getLocalName().equalsIgnoreCase(PROXY_HOST_NAME)) {
                    proxyHostName = att.getAttributeValue();
                }

                if (att.getLocalName().equalsIgnoreCase(PROXY_PORT)) {
                    proxyPort = Integer.parseInt(att.getAttributeValue());
                }
            }

            if (domain.equals("") || domain.equals(ANONYMOUS)) {
                if (usrName.equals(ANONYMOUS) && passwd.equals(ANONYMOUS)) {
View Full Code Here

        if (hostElement != null) {
            Iterator ite = hostElement.getAllAttributes();

            while (ite.hasNext()) {
                OMAttribute attribute = (OMAttribute) ite.next();

                if (attribute.getLocalName().equalsIgnoreCase(PROXY_HOST_NAME))
                {
                    returnValue = true;
                }
            }
        }
View Full Code Here

  public Object fromOMElement(OMElement ackRangePart) throws OMException {

    if (ackRangePart == null)
      throw new OMException("The passed element is null");

    OMAttribute lowerAttrib = ackRangePart.getAttribute(new QName(
        Sandesha2Constants.WSRM.LOWER));
    OMAttribute upperAttrib = ackRangePart.getAttribute(new QName(
        Sandesha2Constants.WSRM.UPPER));

    if (lowerAttrib == null || upperAttrib == null)
      throw new OMException(
          "Passed element does not contain upper or lower attributes");

    try {
      long lower = Long.parseLong(lowerAttrib.getAttributeValue());
      long upper = Long.parseLong(upperAttrib.getAttributeValue());
      upperValue = upper;
      lowerValue = lower;
    } catch (Exception ex) {
      throw new OMException(
          "The ack range does not have proper long values for Upper and Lower attributes");
View Full Code Here

    if (upperValue <= 0 || lowerValue <= 0 || lowerValue > upperValue)
      throw new OMException(
          "Cant set Ack Range part since Upper or Lower is not set to the correct value");

    OMAttribute lowerAttrib = factory.createOMAttribute(
        Sandesha2Constants.WSRM.LOWER, null, Long.toString(lowerValue));
    OMAttribute upperAttrib = factory.createOMAttribute(
        Sandesha2Constants.WSRM.UPPER, null, Long.toString(upperValue));

    acknowledgementRangeElement.addAttribute(lowerAttrib);
    acknowledgementRangeElement.addAttribute(upperAttrib);
View Full Code Here

    public void processRest(OMElement rpcElement) throws Exception {
        // The siblings of this should be SOAP 1.1 independent elements
        OMNode nextElement = rpcElement.getNextOMSibling();
        while (nextElement != null) {
            if (nextElement instanceof OMElement) {
                OMAttribute idAttr =
                        ((OMElement)nextElement).getAttribute(new QName("id"));
                if (idAttr != null) {
                    idFound(idAttr.getAttributeValue(), (OMElement)nextElement);
                }
            }
            nextElement = nextElement.getNextOMSibling();
        }
    }
View Full Code Here

    public OMElement processElementforRefs(OMElement elemnts) throws AxisFault {
        Iterator itr = elemnts.getChildElements();
        while (itr.hasNext()) {
            OMElement omElement = (OMElement) itr.next();
            OMAttribute attri = processRefAtt(omElement);
            if(attri != null){
                String ref = getAttvalue(attri);
                OMElement tempele = getOMElement(ref);
                if(tempele == null){
                    tempele = processOMElementRef(ref);
View Full Code Here

    private void readallChildElements(){
        Iterator childs =  parent.getChildElements();
        while (childs.hasNext()) {
            OMElement omElement = (OMElement) childs.next();
            OMAttribute id =  omElement.getAttribute(new QName("id"));
            if(id !=null){
                omElement.build();
                elementMap.put(id.getAttributeValue(),omElement);
            }
        }
        filledTable =true;
    }
View Full Code Here

        }
        return ref;
    }

    public static OMAttribute processRefAtt(OMElement omElement) {
        OMAttribute omatribute =  omElement.getAttribute(new QName(SOAP11_REF_ATTR));
        if(omatribute == null){
            omatribute =  omElement.getAttribute(new QName(SOAP12_REF_ATTR));
        }
        return omatribute;
    }
View Full Code Here

                if (prty != null) {
                    Class parameters = prty.getPropertyType();
                    if (prty.equals("class"))
                        continue;
                    Object partObj;
                    OMAttribute attr = MultirefHelper.processRefAtt(parts);
                    if (attr != null) {
                        String refId = MultirefHelper.getAttvalue(attr);
                        partObj = helper.getObject(refId);
                        if (partObj == null) {
                            partObj = helper.processRef(parameters, refId);
View Full Code Here

TOP

Related Classes of org.apache.axis2.om.OMAttribute

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.