|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.qtunes.auth.control.JSONParser
public class JSONParser
A ParamParser that parses it's input as JSON. {object:db, calls:[{method:"getPlaylist", args:{name:"MyList"}}, {method:"addTrack", args:{track: 24}}]}
Field Summary | |
---|---|
protected Auth |
auth
|
protected java.util.List<Call> |
calls
|
protected ServiceContext |
context
|
protected JSONSerializer |
json
|
protected java.lang.String |
object
|
protected Session |
session
|
Constructor Summary | |
---|---|
JSONParser(ServiceContext context)
|
Method Summary | |
---|---|
java.util.List<Call> |
getMethodCalls()
Get the name of the ControlMethod we want to invoke |
java.lang.String |
getObjectName()
Get the name of the Object we want to invoke the method on |
Session |
getSession()
Get the Session that was specified in the Parameters |
void |
parse(java.lang.String in)
|
java.lang.String |
toString(java.lang.Object o)
Convert the specified Object to a String in a form that would be usable by this ParamParser |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final ServiceContext context
protected final Auth auth
protected final JSONSerializer json
protected java.util.List<Call> calls
protected Session session
protected java.lang.String object
Constructor Detail |
---|
public JSONParser(ServiceContext context)
Method Detail |
---|
public void parse(java.lang.String in) throws java.lang.Exception
parse
in interface ParamParser
java.lang.Exception
public java.lang.String getObjectName()
ParamParser
getObjectName
in interface ParamParser
public java.util.List<Call> getMethodCalls()
ParamParser
getMethodCalls
in interface ParamParser
public Session getSession()
ParamParser
getSession
in interface ParamParser
public java.lang.String toString(java.lang.Object o)
ParamParser
toString
in interface ParamParser
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |