org.ajax4jsf.javascript
Class JSEncoder

java.lang.Object
  extended by org.ajax4jsf.javascript.JSEncoder

public class JSEncoder
extends java.lang.Object

Author:
shura Encode chars as JavaScript sequences

Constructor Summary
JSEncoder()
          Create a new instance of this XMLEncoder.
 
Method Summary
 boolean compile(char c)
          Return true or false wether this encoding can encode the specified character or not.
 char[] encode(char c)
          Return an array of characters representing the encoding for the specified character.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JSEncoder

public JSEncoder()
Create a new instance of this XMLEncoder.

Method Detail

compile

public boolean compile(char c)
Return true or false wether this encoding can encode the specified character or not.

This method will return true for the following character range:
#x9 | #xA | #xD | [#x20-#xD7FF] | [#xE000-#xFFFD]

See Also:
W3C XML 1.0

encode

public char[] encode(char c)
Return an array of characters representing the encoding for the specified character.



Copyright © 2010. All Rights Reserved.