当前页面:
在线文档首页 >
JDK 5 Documentation v1.2.2, Java 2 SDK 英文文档
Java(TM) 2 Platform, Standard Edition, v1.2.2 API Specification: Class DocumentParser - JDK 5 Documentation v1.2.2, Java 2 SDK 英文文档
javax.swing.text.html.parser
Class DocumentParser
java.lang.Object
|
+--javax.swing.text.html.parser.Parser
|
+--javax.swing.text.html.parser.DocumentParser
- public class DocumentParser
- extends Parser
A Parser for HTML Documents. Read an InputStream of HTML and
invoke the appropriate methods in the ParserCallback class.
Fields inherited from class javax.swing.text.html.parser.Parser |
dtd,
strict |
Methods inherited from class javax.swing.text.html.parser.Parser |
endTag,
error,
error,
error,
error,
flushAttributes,
getAttributes,
getCurrentLine,
getCurrentPos,
handleEOFInComment,
handleTitle,
makeTag,
makeTag,
markFirstTime,
parse,
parseDTDMarkup,
parseMarkupDeclarations,
startTag |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
DocumentParser
public DocumentParser(DTD dtd)
parse
public void parse(Reader in,
HTMLEditorKit.ParserCallback callback,
boolean ignoreCharSet)
throws IOException
handleStartTag
protected void handleStartTag(TagElement tag)
- Handle Start Tag.
- Overrides:
- handleStartTag in class Parser
handleComment
protected void handleComment(char[] text)
- Description copied from class: Parser
- Called when an HTML comment is encountered.
- Overrides:
- handleComment in class Parser
handleEmptyTag
protected void handleEmptyTag(TagElement tag)
throws ChangedCharSetException
- Handle Empty Tag.
- Overrides:
- handleEmptyTag in class Parser
handleEndTag
protected void handleEndTag(TagElement tag)
- Handle End Tag.
- Overrides:
- handleEndTag in class Parser
handleText
protected void handleText(char[] data)
- Handle Text.
- Overrides:
- handleText in class Parser
handleError
protected void handleError(int ln,
String errorMsg)
- Description copied from class: Parser
- An error has occurred.
- Overrides:
- handleError in class Parser
Submit a bug or feature
Java, Java 2D, and JDBC are a trademarks or registered trademarks of Sun Microsystems, Inc. in the US and other countries.
Copyright 1993-1999 Sun Microsystems, Inc. 901 San Antonio Road,
Palo Alto, California, 94303, U.S.A. All Rights Reserved.