Package org.apache.abdera.model

Examples of org.apache.abdera.model.ElementWrapper


    return (T) ((t != null) ? factory.getElementWrapper(t) : null);
  }
 
  public void addExtension(Element extension) {
    if (extension instanceof ElementWrapper) {
      ElementWrapper wrapper = (ElementWrapper) extension;
      extension = wrapper.getInternal();
    }
    QName qname = extension.getQName();
    String prefix = qname.getPrefix();
    if (prefix != null) {
      declareNS(prefix, qname.getNamespaceURI());
View Full Code Here


    return (T) ((t != null) ? factory.getElementWrapper(t) : null);
  }
 
  public void addExtension(Element extension) {
    if (extension instanceof ElementWrapper) {
      ElementWrapper wrapper = (ElementWrapper) extension;
      extension = wrapper.getInternal();
    }
    QName qname = extension.getQName();
    String prefix = qname.getPrefix();
    if (prefix != null) {
      declareNS(prefix, qname.getNamespaceURI());
View Full Code Here

    }

    public <T extends ExtensibleElement> T addExtension(Element extension) {
        complete();
        if (extension instanceof ElementWrapper) {
            ElementWrapper wrapper = (ElementWrapper)extension;
            extension = wrapper.getInternal();
        }
        QName qname = extension.getQName();
        String prefix = qname.getPrefix();
        declareIfNecessary(qname.getNamespaceURI(), prefix);
        addChild((OMElement)extension);
View Full Code Here

        return t;
    }

    private Element getInternal(Element element) {
        if (element instanceof ElementWrapper) {
            ElementWrapper wrapper = (ElementWrapper)element;
            element = wrapper.getInternal();
        }
        return element;
    }
View Full Code Here

    public <T extends ExtensibleElement> T addExtension(Element extension, Element before) {
        complete();
        extension = getInternal(extension);
        before = getInternal(before);
        if (before instanceof ElementWrapper) {
            ElementWrapper wrapper = (ElementWrapper)before;
            before = wrapper.getInternal();
        }
        if (before == null) {
            addExtension(extension);
        } else {
            extension.setParentElement(this);
View Full Code Here

    }

    public <T extends ExtensibleElement> T addExtension(Element extension) {
        complete();
        if (extension instanceof ElementWrapper) {
            ElementWrapper wrapper = (ElementWrapper)extension;
            extension = wrapper.getInternal();
        }
        QName qname = extension.getQName();
        String prefix = qname.getPrefix();
        declareIfNecessary(qname.getNamespaceURI(), prefix);
        addChild((OMElement)extension);
View Full Code Here

        return t;
    }

    private Element getInternal(Element element) {
        if (element instanceof ElementWrapper) {
            ElementWrapper wrapper = (ElementWrapper)element;
            element = wrapper.getInternal();
        }
        return element;
    }
View Full Code Here

    public <T extends ExtensibleElement> T addExtension(Element extension, Element before) {
        complete();
        extension = getInternal(extension);
        before = getInternal(before);
        if (before instanceof ElementWrapper) {
            ElementWrapper wrapper = (ElementWrapper)before;
            before = wrapper.getInternal();
        }
        if (before == null) {
            addExtension(extension);
        } else {
            extension.setParentElement(this);
View Full Code Here

  }
 
  public <T extends ExtensibleElement>T addExtension(Element extension) {
    complete();
    if (extension instanceof ElementWrapper) {
      ElementWrapper wrapper = (ElementWrapper) extension;
      extension = wrapper.getInternal();
    }
    QName qname = extension.getQName();
    String prefix = qname.getPrefix();
    declareIfNecessary(qname.getNamespaceURI(), prefix);
    addChild((OMElement)extension);
View Full Code Here

    return t;
  }

  private Element getInternal(Element element) {
    if (element instanceof ElementWrapper) {
      ElementWrapper wrapper = (ElementWrapper) element;
      element = wrapper.getInternal();
    }
    return element;
  }
View Full Code Here

TOP

Related Classes of org.apache.abdera.model.ElementWrapper

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.