org.cyberneko.html

Class HTMLScanner.SpecialScanner

Enclosing Class:
HTMLScanner
Implemented Interfaces:
HTMLScanner.Scanner

public class HTMLScanner.SpecialScanner
extends Object
implements HTMLScanner.Scanner

Special scanner used for elements whose content needs to be scanned as plain text, ignoring markup such as elements and entity references. For example: <SCRIPT> and <COMMENT>.
Author:
Andy Clark

Field Summary

protected String
fElementName
Name of element whose content needs to be scanned as text.
protected boolean
fScript
True if <script> element.
protected boolean
fStyle
True if <style> element.
protected boolean
fTextarea
True if <textarea> element.

Method Summary

boolean
scan(boolean complete)
Scan.
protected void
scanCharacters(XMLStringBuffer buffer, int delimiter)
Scan characters.
HTMLScanner.Scanner
setElementName(String ename)
Sets the element name.

Field Details

fElementName

protected String fElementName
Name of element whose content needs to be scanned as text.

fScript

protected boolean fScript
True if <script> element.

fStyle

protected boolean fStyle
True if <style> element.

fTextarea

protected boolean fTextarea
True if <textarea> element.

Method Details

scan

public boolean scan(boolean complete)
            throws IOException
Scan.
Specified by:
scan in interface HTMLScanner.Scanner

scanCharacters

protected void scanCharacters(XMLStringBuffer buffer,
                              int delimiter)
            throws IOException
Scan characters.

setElementName

public HTMLScanner.Scanner setElementName(String ename)
Sets the element name.

(C) Copyright 2002-2005, Andy Clark. All rights reserved.