Package org.apache.tapestry5.internal.services

# Class XMLTokenStream

java.lang.Object
org.apache.tapestry5.internal.services.XMLTokenStream

public class XMLTokenStream extends Object
Parses a document as a stream of XML tokens. It includes a special hack (as of Tapestry 5.3) to support the HTML5 doctype (`<!DOCTYPE html>`) as if it were the XHTML transitional doctype (`<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">`).

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final String`
  `TRANSITIONAL_DOCTYPE`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `XMLTokenStream(Resource resource, Map<String,URL> publicIdToURL)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `getAttributeCount()`
  `QName`
  `getAttributeName(int i)`
  `String`
  `getAttributeValue(int i)`
  `DTDData`
  `getDTDInfo()`
  `XMLTokenType`
  `getEventType()`
  `String`
  `getLocalName()`
  `Location`
  `getLocation()`
  `int`
  `getNamespaceCount()`
  `String`
  `getNamespacePrefix(int i)`
  `String`
  `getNamespaceURI()`
  `String`
  `getNamespaceURI(int i)`
  `String`
  `getText()`
  `boolean`
  `hasNext()`
  `XMLTokenType`
  `next()`
  Returns the type of the next token.
  `void`
  `parse()`

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

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

- ## Field Details

  - ### TRANSITIONAL_DOCTYPE

    public static final String TRANSITIONAL_DOCTYPE
    See Also:
      - Constant Field Values

- ## Constructor Details

  - ### XMLTokenStream

    public XMLTokenStream(Resource resource, Map<String,URL> publicIdToURL)

- ## Method Details

  - ### parse

    public void parse() throws SAXException, IOException
    Throws:
      `SAXException`
      `IOException`

  - ### next

    public XMLTokenType next()
    Returns the type of the next token.

  - ### getAttributeCount

    public int getAttributeCount()

  - ### getAttributeName

    public QName getAttributeName(int i)

  - ### getDTDInfo

    public DTDData getDTDInfo()

  - ### getEventType

    public XMLTokenType getEventType()

  - ### getLocalName

    public String getLocalName()

  - ### getLocation

    public Location getLocation()

  - ### getNamespaceCount

    public int getNamespaceCount()

  - ### getNamespacePrefix

    public String getNamespacePrefix(int i)

  - ### getNamespaceURI

    public String getNamespaceURI()

  - ### getNamespaceURI

    public String getNamespaceURI(int i)

  - ### getText

    public String getText()

  - ### hasNext

    public boolean hasNext()

  - ### getAttributeValue

    public String getAttributeValue(int i)