All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.xmlpull.v1.builder.xpath.impl.XPathNamespace Maven / Gradle / Ivy

Go to download

MXP1 is a stable XmlPull parsing engine that is based on ideas from XPP and in particular XPP2 but completely revised and rewritten to take the best advantage of latest JIT JVMs such as Hotspot in JDK 1.4+.

The newest version!

package org.xmlpull.v1.builder.xpath.impl;

import org.xmlpull.v1.builder.XmlElement;
import org.xmlpull.v1.builder.XmlNamespace;

/**
 * Wrap namespace with parent so we can find parent as required by JAXEN ....
 *
 *  @author
 */
public class XPathNamespace
{
    private XmlElement element;

    private XmlNamespace namespace;

    public XPathNamespace( XmlNamespace namespace )
    {
        this.namespace = namespace;
    }

    public XPathNamespace( XmlElement element, XmlNamespace namespace )
    {
        this.element = element;
        this.namespace = namespace;
    }

    public XmlElement getElement()
    {
        return element;
    }

//    public void setElement( XmlElement element )
//    {
//        this.element = element;
//    }

    public XmlNamespace getNamespace()
    {
        return namespace;
    }

    public String toString()
    {
        return ( "[xmlns:" + namespace.getPrefix() + "=\"" +
                 namespace.getNamespaceName() + "\", element=" +
                 element.getName() + "]" );
    }
}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy