Package org.jsoup.nodes

Examples of org.jsoup.nodes.Element.tagName()


        // handle empty unknown tags
        // when the spec expects an empty tag, will directly hit insertEmpty, so
        // won't generate fake end tag.
        if (startTag.isSelfClosing() && !Tag.isKnownTag(startTag.name())) {
            Element el = insertEmpty(startTag);
            process(new Token.EndTag(el.tagName())); // ensure we get out of
                                                     // whatever state we are in
            return el;
        }

        Element el = new Element(Tag.valueOf(startTag.name()), baseUri, startTag.attributes);
View Full Code Here


        String dataRef = ExtNodeConstants.ATTR_DATAREF_PREFIX_WITH_NS + key;
        Element elem = getCurrentRenderingElement();
        Object value = null;
        while (value == null && elem != null) {
            // for a faked snippet node, we will just jump over it
            if (elem.tagName().equals(ExtNodeConstants.SNIPPET_NODE_TAG)) {
                String type = elem.attr(ExtNodeConstants.SNIPPET_NODE_ATTR_TYPE);
                if (type.equals(ExtNodeConstants.SNIPPET_NODE_ATTR_TYPE_FAKE)) {
                    elem = elem.parent();
                    continue;
                }
View Full Code Here

        String blockingParentId;
        for (Element elem : elems) {
            searchElem = elem.parent();
            blockingParentId = "";
            while (searchElem != null) {
                if (searchElem.tagName().equals(ExtNodeConstants.SNIPPET_NODE_TAG)) {
                    blockingParentId = searchElem.attr(ExtNodeConstants.ATTR_SNIPPET_REF);
                    break;
                } else {
                    searchElem = searchElem.parent();
                }
View Full Code Here

       
        Elements spansb = element.child(1).getElementsByClass("c_ba2636");
        Iterator<Element> bIterator = spansb.iterator();
        while(bIterator.hasNext()){
          Element element2 = bIterator.next();
          if(!"span".equals(element2.tagName())){
            //spansb.remove(element2);
            bIterator.remove();
          }
        }
        if (spansb.size()==1) {
View Full Code Here

        String a = "";
        Elements spansa = element.child(1).getElementsByClass("c_1e50a2");
        Iterator<Element> aIterator = spansa.iterator();
        while(aIterator.hasNext()){
          Element element2 = aIterator.next();
          if(!"span".equals(element2.tagName())){
            //spansb.remove(element2);
            aIterator.remove();
          }
        }
        if (spansa.size()==1) {
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.