Search in sources :

Example 1 with ContentModel

use of javax.swing.text.html.parser.ContentModel in project jdk8u_jdk by JetBrains.

the class bug8074956 method main.

public static void main(String[] args) throws Exception {
    final DTD html32 = DTD.getDTD("html32");
    ContentModel contentModel = new ContentModel('&', new ContentModel());
    Element elem1 = html32.getElement("html-element");
    contentModel.first(elem1);
    Element elem2 = html32.getElement("test-element");
    // Shouldn't throw ArrayIndexOutOfBoundsException
    contentModel.first(elem2);
}
Also used : ContentModel(javax.swing.text.html.parser.ContentModel) DTD(javax.swing.text.html.parser.DTD) Element(javax.swing.text.html.parser.Element)

Aggregations

ContentModel (javax.swing.text.html.parser.ContentModel)1 DTD (javax.swing.text.html.parser.DTD)1 Element (javax.swing.text.html.parser.Element)1