< prev index next >

src/java.desktop/share/classes/javax/swing/text/html/parser/DocumentParser.java

Print this page

        

*** 56,67 **** * </ol> * The items in <i>italic</i> are implied, that is, although they were not * explicitly specified, to be correct html they should have been present * (head isn't necessary, but it is still generated). For tags that * are implied, the AttributeSet argument will have a value of ! * <code>Boolean.TRUE</code> for the key ! * <code>HTMLEditorKit.ParserCallback.IMPLIED</code>. * <p>HTML.Attributes defines a type safe enumeration of html attributes. * If an attribute key of a tag is defined in HTML.Attribute, the * HTML.Attribute will be used as the key, otherwise a String will be used. * For example &lt;p foo=bar class=neat&gt; has two attributes. foo is * not defined in HTML.Attribute, where as class is, therefore the --- 56,67 ---- * </ol> * The items in <i>italic</i> are implied, that is, although they were not * explicitly specified, to be correct html they should have been present * (head isn't necessary, but it is still generated). For tags that * are implied, the AttributeSet argument will have a value of ! * {@code Boolean.TRUE} for the key ! * {@code HTMLEditorKit.ParserCallback.IMPLIED}. * <p>HTML.Attributes defines a type safe enumeration of html attributes. * If an attribute key of a tag is defined in HTML.Attribute, the * HTML.Attribute will be used as the key, otherwise a String will be used. * For example &lt;p foo=bar class=neat&gt; has two attributes. foo is * not defined in HTML.Attribute, where as class is, therefore the
*** 79,97 **** * <p>As html skips whitespace the position for text will be the position * of the first valid character, eg in the string '\n\n\nblah' * the text 'blah' will have a position of 3, the newlines are skipped. * <p> * For attributes that do not have a value, eg in the html ! * string <code>&lt;foo blah&gt;</code> the attribute <code>blah</code> * does not have a value, there are two possible values that will be * placed in the AttributeSet's value: * <ul> * <li>If the DTD does not contain an definition for the element, or the * definition does not have an explicit value then the value in the ! * AttributeSet will be <code>HTML.NULL_ATTRIBUTE_VALUE</code>. * <li>If the DTD contains an explicit value, as in: ! * <code>&lt;!ATTLIST OPTION selected (selected) #IMPLIED&gt;</code> * this value from the dtd (in this case selected) will be used. * </ul> * <p> * Once the stream has been parsed, the callback is notified of the most * likely end of line string. The end of line string will be one of --- 79,97 ---- * <p>As html skips whitespace the position for text will be the position * of the first valid character, eg in the string '\n\n\nblah' * the text 'blah' will have a position of 3, the newlines are skipped. * <p> * For attributes that do not have a value, eg in the html ! * string {@code <foo blah>} the attribute {@code blah} * does not have a value, there are two possible values that will be * placed in the AttributeSet's value: * <ul> * <li>If the DTD does not contain an definition for the element, or the * definition does not have an explicit value then the value in the ! * AttributeSet will be {@code HTML.NULL_ATTRIBUTE_VALUE}. * <li>If the DTD contains an explicit value, as in: ! * {@code < !ATTLIST OPTION selected (selected) #IMPLIED>} * this value from the dtd (in this case selected) will be used. * </ul> * <p> * Once the stream has been parsed, the callback is notified of the most * likely end of line string. The end of line string will be one of
< prev index next >