Package com.sun.java.help.impl

# Class Parser

java.lang.Object
com.sun.java.help.impl.DocumentParser
com.sun.java.help.impl.Parser

public class Parser extends DocumentParser

## Nested Class Summary

Nested Classes
Modifier and Type
Class
Description
`protected static class`
`Parser.ParserMulticaster`

## Field Summary

Fields
Modifier and Type
Field
Description
`protected ParserListener`
`listenerList`

### Fields inherited from class com.sun.java.help.impl.DocumentParser

`source`

## Constructor Summary

Constructors
Constructor
Description
`Parser(InputStream in)`
`Parser(Reader src)`

## Method Summary

Modifier and Type
Method
Description
`void`
`addParserListener(ParserListener l)`
`protected void`
`comment(String s)`
This method inserts a comment It should be overridden by the subclass
`protected void`
`doctype(String root, String publicId, String systemId)`
This method emits a doctype.
`protected String`
`documentAttribute(String name)`
This method looks up a &xxx; sequence in the document properties (this is used for templates).
`protected void`
`errorString(String s)`
This method inserts a parse error string into the document It should be overridden by the subclass
`protected void`
`flush(char[] buf, int offset, int length)`
This method creates a block of text for a document.
`protected void`
`pi(String target, String data)`
This method emits a pi It should be overridden by the subclass
`void`
`removeParserListener(ParserListener l)`
`protected void`
`tag(String name, TagProperties atts, boolean endTag, boolean emptyTag)`
This method emits a tag It should be overridden by the subclass

### Methods inherited from class com.sun.java.help.impl.DocumentParser

`callFlush, commentEOFError, eofError, findCloseAngleForComment, generateError, getDocumentSource, handleCommentOrDoctype, initEntities, parse, parseEscape, parseTag, parseText, readChar, scanIdentifier, scanQuotedString, setInput, setInput, setShouldCacheSource, setXmlEntities, skipToCloseAngle, skipWhite`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### listenerList

protected ParserListener listenerList

## Constructor Details

### Parser

public Parser(Reader src)

### Parser

public Parser(InputStream in)

## Method Details

### tag

protected void tag(String name, TagProperties atts, boolean endTag, boolean emptyTag)
Description copied from class: `DocumentParser`
This method emits a tag It should be overridden by the subclass

Specified by:
  `tag` in class `DocumentParser`

### pi

protected void pi(String target, String data)
Description copied from class: `DocumentParser`
This method emits a pi It should be overridden by the subclass

Specified by:
  `pi` in class `DocumentParser`

### doctype

protected void doctype(String root, String publicId, String systemId)
Description copied from class: `DocumentParser`
This method emits a doctype. Internal subset information is discarded It should be overridden by the subclass

Specified by:
  `doctype` in class `DocumentParser`

### flush

protected void flush(char[] buf, int offset, int length)
Description copied from class: `DocumentParser`
This method creates a block of text for a document. It should be overridden by the subclass

Specified by:
  `flush` in class `DocumentParser`

### comment

protected void comment(String s)
Description copied from class: `DocumentParser`
This method inserts a comment It should be overridden by the subclass

Specified by:
  `comment` in class `DocumentParser`

### errorString

protected void errorString(String s)
Description copied from class: `DocumentParser`
This method inserts a parse error string into the document It should be overridden by the subclass

Specified by:
  `errorString` in class `DocumentParser`

### documentAttribute

protected String documentAttribute(String name)
Description copied from class: `DocumentParser`
This method looks up a &xxx; sequence in the document properties (this is used for templates). A return of null means the proerty is undefined. It should be overridden by the subclass

Specified by:
  `documentAttribute` in class `DocumentParser`

### addParserListener

public void addParserListener(ParserListener l)

### removeParserListener

public void removeParserListener(ParserListener l)