com.werxltd.jsonrpc
Class Request

java.lang.Object
  extended by com.werxltd.jsonrpc.Request

public class Request
extends java.lang.Object


Nested Class Summary
static class Request.ParamType
           
 
Constructor Summary
Request()
           
Request(java.lang.String request)
           
 
Method Summary
 java.lang.String getId()
           
 org.json.JSONObject getJSON()
           
 java.lang.String getMethod()
           
 java.lang.String getParam(java.lang.String param)
           
 java.lang.String getParamAt(int pos)
           
 int getParamCount()
           
 org.json.JSONObject getParamObj()
           
 Request.ParamType getParamtype()
           
 boolean hasParam(java.lang.String param)
           
 boolean parseJSON(java.lang.String requestStr)
           
 boolean parseParams(java.lang.String paramsStr)
           
 void setId(java.lang.String id)
           
 void setMethod(java.lang.String method)
           
 void setParamCount(int param_count)
           
 void setParamtype(Request.ParamType paramtype)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Request

public Request()

Request

public Request(java.lang.String request)
        throws org.json.JSONException
Throws:
org.json.JSONException
Method Detail

parseJSON

public boolean parseJSON(java.lang.String requestStr)
                  throws org.json.JSONException
Throws:
org.json.JSONException

parseParams

public boolean parseParams(java.lang.String paramsStr)

getId

public java.lang.String getId()

setId

public void setId(java.lang.String id)

getMethod

public java.lang.String getMethod()

setMethod

public void setMethod(java.lang.String method)

hasParam

public boolean hasParam(java.lang.String param)

getParam

public java.lang.String getParam(java.lang.String param)
                          throws org.json.JSONException
Throws:
org.json.JSONException

getParamAt

public java.lang.String getParamAt(int pos)
                            throws org.json.JSONException
Throws:
org.json.JSONException

getParamObj

public org.json.JSONObject getParamObj()

getJSON

public org.json.JSONObject getJSON()

setParamCount

public void setParamCount(int param_count)

getParamCount

public int getParamCount()

setParamtype

public void setParamtype(Request.ParamType paramtype)

getParamtype

public Request.ParamType getParamtype()


Copyright © 2010. All Rights Reserved.