Package org.jsoup.parser

Examples of org.jsoup.parser.Token$Doctype


    }

    @Override
    protected Document createDocument(final Element root) {
        final Document doc = new Document(root);
        final DocType docType = new DocType(RSS091NetscapeParser.ELEMENT_NAME, RSS091NetscapeParser.PUBLIC_ID, RSS091NetscapeParser.SYSTEM_ID);
        doc.setDocType(docType);
        return doc;
    }
View Full Code Here


    public boolean isMyType(final Document document) {

        final Element rssRoot = document.getRootElement();
        final String name = rssRoot.getName();
        final Attribute version = rssRoot.getAttribute("version");
        final DocType docType = document.getDocType();

        return name.equals(ELEMENT_NAME) && version != null && version.getValue().equals(getRSSVersion()) && docType != null
                && ELEMENT_NAME.equals(docType.getElementName()) && PUBLIC_ID.equals(docType.getPublicID()) && SYSTEM_ID.equals(docType.getSystemID());

    }
View Full Code Here

TOP

Related Classes of org.jsoup.parser.Token$Doctype

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.