|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.konakart.json.KKJSONEngBase
public class KKJSONEngBase
KonaKart JSON Client-side Engine Base for the Application Engine
| Field Summary | |
|---|---|
protected static org.codehaus.jackson.map.ObjectMapper |
mapper
JSON Data Mapping Object |
| Constructor Summary | |
|---|---|
KKJSONEngBase(EngineConfigIf engConf)
Constructor with an EngineConfig object. |
|
| Method Summary | |
|---|---|
protected void |
checkForException(KKJSON_ResponseIf response)
|
EngineConfigIf |
getEngConf()
|
java.net.URL |
getJsonURL()
|
static org.codehaus.jackson.map.ObjectMapper |
getMapper()
|
protected java.lang.String |
getNextId()
Return the next number in a sequence for matching requests and responses |
java.lang.String |
getStoreId()
|
java.lang.String |
getStoreIdForRequest()
Only return the storeId if we're in a multi-store environment |
protected static KKException |
handleThrowable(java.lang.Throwable e,
java.lang.String methodName)
Handles the exception for all methods. |
void |
init()
|
boolean |
isGenerateMatchIds()
|
boolean |
isSuccessfullyInitialised()
|
java.lang.String |
postRequest(java.lang.String request)
|
static java.lang.String |
prettyJson(java.lang.String uglyJsonString)
To pretty-print a JSON String |
void |
setEngConf(EngineConfigIf engConf)
|
void |
setGenerateMatchIds(boolean generateMatchIds)
|
void |
setJsonURL(java.net.URL jsonURL)
|
void |
setStoreId(java.lang.String storeId)
|
void |
setSuccessfullyInitialised(boolean successfullyInitialised)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static org.codehaus.jackson.map.ObjectMapper mapper
| Constructor Detail |
|---|
public KKJSONEngBase(EngineConfigIf engConf)
throws KKException
engConf -
KKException| Method Detail |
|---|
public void init()
throws KKException
KKException
protected static KKException handleThrowable(java.lang.Throwable e,
java.lang.String methodName)
We do this so that the receiver can detect the cause exception and act on it. Otherwise it gets lost.
e - methodName -
protected void checkForException(KKJSON_ResponseIf response)
throws KKException
KKExceptionprotected java.lang.String getNextId()
public java.lang.String postRequest(java.lang.String request)
throws java.lang.Exception
request -
java.lang.Exceptionpublic static java.lang.String prettyJson(java.lang.String uglyJsonString)
uglyJsonString - the raw JSON String
public boolean isSuccessfullyInitialised()
public void setSuccessfullyInitialised(boolean successfullyInitialised)
successfullyInitialised - the successfullyInitialised to setpublic java.lang.String getStoreIdForRequest()
public java.lang.String getStoreId()
public void setStoreId(java.lang.String storeId)
storeId - the storeId to setpublic EngineConfigIf getEngConf()
public void setEngConf(EngineConfigIf engConf)
engConf - the engConf to setpublic java.net.URL getJsonURL()
public void setJsonURL(java.net.URL jsonURL)
jsonURL - the jsonURL to setpublic boolean isGenerateMatchIds()
public void setGenerateMatchIds(boolean generateMatchIds)
generateMatchIds - the generateMatchIds to setpublic static org.codehaus.jackson.map.ObjectMapper getMapper()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||