|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.endeca.portal.mdex.MDEXUtil
public class MDEXUtil
Helper class containing useful methods to execute on an ENEQuery
Constructor Summary | |
---|---|
MDEXUtil()
|
Method Summary | |
---|---|
static com.endeca.navigation.ENEQuery |
addQueryTracking(com.endeca.navigation.ENEQuery query,
RequestTracker requestTracker)
instruments a MDEX 6 query by setting an ENEQueryInfo object on the query |
static boolean |
checkAPICompatibility(MDEXState state)
|
static com.endeca.navigation.ENEQuery |
copyQuery(com.endeca.navigation.ENEQuery previousQuery)
This method takes an ENEQuery object and makes a copy of it. |
static com.endeca.navigation.ENEQueryResults |
execute(MDEXState mdexState,
com.endeca.navigation.ENEQuery query,
RequestTracker requestTracker)
|
static com.endeca.navigation.ENEQuery |
fromJSONObject(org.json.JSONObject j)
Creates a new ENEQuery object based on the contents of this JSON object. |
static com.endeca.navigation.ENEQuery |
fromJSONString(java.lang.String s)
Creates a new ENEQuery object based on the contents of this JSON packet. |
static int |
hashCode(com.endeca.navigation.ENEQuery query)
Returns a hashcode of the query, used to tersely identify the contents of the query. |
static int |
hashCode(java.lang.String jsonString)
Currently this is just a wrapper of String.hashCode() - this method exists solely so we can override the hashcode implementation if we want to, and to allow calling ENEQueryUtils.hashCode() on a pre-existing jsonString. |
static void |
main(java.lang.String[] args)
|
static java.net.URLConnection |
ping(java.lang.String server,
java.lang.String port,
SSLConfig sslConfig)
|
static java.net.URLConnection |
stats(java.lang.String server,
java.lang.String port,
SSLConfig sslConfig)
|
static com.endeca.navigation.ENEQuery |
tidyNavQuery(com.endeca.navigation.ENEQuery query)
Cleans up and sanitizes a nav query; right now all it does is rewrite the query to include the root if there are otherwise no nav descriptors |
static org.json.JSONObject |
toJSONObject(com.endeca.navigation.ENEQuery query)
Returns a JSONObject containing all pertinent query info |
static java.lang.String |
toJSONString(com.endeca.navigation.ENEQuery query)
Returns a JSON string containing all pertinent query info |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MDEXUtil()
Method Detail |
---|
public static int hashCode(com.endeca.navigation.ENEQuery query) throws org.json.JSONException
query
- the query to hash
org.json.JSONException
public static int hashCode(java.lang.String jsonString)
jsonString
- the (json) string to hash
public static java.lang.String toJSONString(com.endeca.navigation.ENEQuery query) throws org.json.JSONException
query
- the query to turn into a JSON string
org.json.JSONException
public static org.json.JSONObject toJSONObject(com.endeca.navigation.ENEQuery query) throws org.json.JSONException
query
- the query to turn into a JSON object
org.json.JSONException
public static com.endeca.navigation.ENEQuery fromJSONString(java.lang.String s)
s
- the JSON packet to parse
public static com.endeca.navigation.ENEQuery fromJSONObject(org.json.JSONObject j)
j
- the JSON object to parse
public static com.endeca.navigation.ENEQuery tidyNavQuery(com.endeca.navigation.ENEQuery query)
query
- the query to tidy up
public static com.endeca.navigation.ENEQuery copyQuery(com.endeca.navigation.ENEQuery previousQuery)
previousQuery
-
public static void main(java.lang.String[] args) throws org.json.JSONException
org.json.JSONException
public static com.endeca.navigation.ENEQueryResults execute(MDEXState mdexState, com.endeca.navigation.ENEQuery query, RequestTracker requestTracker) throws com.endeca.navigation.ENEQueryException
com.endeca.navigation.ENEQueryException
public static com.endeca.navigation.ENEQuery addQueryTracking(com.endeca.navigation.ENEQuery query, RequestTracker requestTracker)
query
- the ENEQueryrequestTracker
- the tracker containing the session, request, etc. tokens
public static java.net.URLConnection ping(java.lang.String server, java.lang.String port, SSLConfig sslConfig) throws java.lang.Exception
java.lang.Exception
public static java.net.URLConnection stats(java.lang.String server, java.lang.String port, SSLConfig sslConfig) throws java.lang.Exception
java.lang.Exception
public static boolean checkAPICompatibility(MDEXState state)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |