org.apache.myfaces.trinidadinternal.util
Class FormattedTextParser

java.lang.Object
  extended by org.apache.myfaces.trinidadinternal.util.FormattedTextParser

public class FormattedTextParser
extends java.lang.Object

Class responsible for performing a very lightweight parse of a primitive HTML subset. FormattedTextParsers are threadsafe and will generally be created once and reused, though the addElement() method should be called only before the parser has been used.

Version:
$Name: $ ($Revision: adfrt/faces/adf-faces-impl/src/main/java/oracle/adfinternal/view/faces/util/FormattedTextParser.java#0 $) $Date: 10-nov-2005.18:49:08 $
Author:
The Oracle ADF Faces Team

Nested Class Summary
static class FormattedTextParser.DefaultElementInfo
          Default implementation of ElementInfo.
static class FormattedTextParser.ElementInfo
          Abstract representation of an element type.
 
Constructor Summary
FormattedTextParser()
          Create a FormattedTextParser.
 
Method Summary
 void addElement(FormattedTextParser.ElementInfo element)
          Adds a type of element to the parser.
 void writeFormattedText(javax.faces.context.FacesContext context, java.lang.String text)
          Outputs a String, using the set of registered ElementInfos to handle contained elements.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FormattedTextParser

public FormattedTextParser()
Create a FormattedTextParser.

Method Detail

addElement

public void addElement(FormattedTextParser.ElementInfo element)
Adds a type of element to the parser. The element name will be supported in both lower and upper case.


writeFormattedText

public void writeFormattedText(javax.faces.context.FacesContext context,
                               java.lang.String text)
                        throws java.io.IOException
Outputs a String, using the set of registered ElementInfos to handle contained elements.

Throws:
java.io.IOException


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved.