Home » sitemesh-2.4.1 » com.opensymphony.module » sitemesh » html » tokenizer » [javadoc | source]
com.opensymphony.module.sitemesh.html.tokenizer
public class: TagTokenizer [javadoc | source]
java.lang.Object
   com.opensymphony.module.sitemesh.html.tokenizer.TagTokenizer
Splits a chunk of HTML into 'text' and 'tag' tokens, for easy processing. Is VERY tolerant to badly formed HTML.

Usage

You need to supply a custom TokenHandler that will receive callbacks as text and tags are processed.

char[] input = ...;
HTMLTagTokenizer tokenizer = new HTMLTagTokenizer(input);
TokenHandler handler = new MyTokenHandler();
tokenizer.start(handler);
Constructor:
 public TagTokenizer(char[] input) 
 public TagTokenizer(String input) 
Method from com.opensymphony.module.sitemesh.html.tokenizer.TagTokenizer Summary:
start
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from com.opensymphony.module.sitemesh.html.tokenizer.TagTokenizer Detail:
 public  void start(TokenHandler handler)