com.novell.sentinel.json.java
Class JSONParserFactory

java.lang.Object
  extended by com.novell.sentinel.json.java.JSONParserFactory

public class JSONParserFactory
extends Object

Factory class for getting implementations of the JSONParser interface.


Constructor Summary
protected JSONParserFactory()
           
 
Method Summary
static JSONParserFactory newInstance()
          Get an instance of a factory.
 JSONParser newParser(InputStream inputStream, String charEncoding)
          Get a new JSONParser instance for the passed input.
 JSONParser newParser(Reader reader)
          Get a new JSONParser instance for the passed input.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JSONParserFactory

protected JSONParserFactory()
Method Detail

newInstance

public static JSONParserFactory newInstance()
Get an instance of a factory.

Returns:
A factory instance.

newParser

public JSONParser newParser(Reader reader)
Get a new JSONParser instance for the passed input.

Parameters:
reader - The source from which the JSON input will be read.
Returns:
A JSONParser instance.

newParser

public JSONParser newParser(InputStream inputStream,
                            String charEncoding)
                     throws UnsupportedEncodingException
Get a new JSONParser instance for the passed input.

Parameters:
inputStream - The source from which the JSON input will be read.
charEncoding - The encoding of the input source.
Returns:
A JSONParser instance.
Throws:
UnsupportedEncodingException