|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jdbwc.util.Util
public final class Util
General utility class to assist the JDBWC Driver.
Field Summary | |
---|---|
static int |
CASE_LOWER
|
static int |
CASE_MIXED
|
static int |
CASE_UPPER
|
static java.lang.String |
DT_IMPL_VER
DataHandler implementation used by this driver |
static int |
ID_DEFAULT
|
static int |
ID_MYSQL
|
static int |
ID_POSTGRESQL
|
static java.lang.String |
OUR_ACTION
|
static java.lang.String |
OUR_AUTH
|
static java.lang.String |
OUR_DBTYPE
|
static boolean |
OUR_DEBUG_MODE
users debug trigger for JDBC and server-side (WC) |
static java.lang.String |
OUR_DEBUG_TAG
|
static java.lang.String |
OUR_SEC_PASS
|
static java.lang.String |
OUR_SEC_USER
|
static java.lang.String |
OUR_SQL
|
static boolean |
OUR_UA_FIX
Workaround to enable the use of a dummy User-Agent if you think the HttpClient agent is being blocked by your host. |
static java.lang.String |
OUR_USER_AGENT
Dummy User-Agent This is only used if OUR_UA_FIX = true |
static java.lang.String |
WC_ERROR_TAG
Indetifier for errors being sent from the server API |
static java.lang.String |
WC_NL
systems line break property |
Method Summary | |
---|---|
static boolean |
checkForExceptions(java.lang.String response)
Look for errors from the server. Chuck a wobbly (alias: throw exception) back to the requesting method with a few details about the problem if one [or more] are found. NOTE: This release will only throw one exception for the first found (instead of java's usual exception trail) but will include details for all in the message. |
static java.lang.String |
csvFormat(java.lang.String input)
|
static java.lang.String |
csvUnFormat(java.lang.String input)
|
static com.ozdevworx.dtype.DataHandler |
getCaseSafeHandler(int caseType)
DataHandler Factory method. Get a DataHandler object with keys matching the required caseType to satisfy various database engine requirements. All DataHandler objects used by this driver come from this method, making the use of different DataHandler implementations very simple. |
static java.lang.String |
parseResponse(java.io.InputStream ins)
|
static org.apache.commons.httpclient.NameValuePair[] |
prepareForWeb(com.ozdevworx.dtype.DataHandler input)
|
static java.lang.String |
stripTags(java.lang.String input)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String WC_NL
public static final java.lang.String OUR_SQL
public static final java.lang.String OUR_ACTION
public static final java.lang.String OUR_AUTH
public static final java.lang.String OUR_SEC_USER
public static final java.lang.String OUR_SEC_PASS
public static final java.lang.String OUR_DBTYPE
public static final java.lang.String OUR_DEBUG_TAG
public static boolean OUR_DEBUG_MODE
public static final java.lang.String DT_IMPL_VER
public static boolean OUR_UA_FIX
public static final java.lang.String OUR_USER_AGENT
public static final int ID_DEFAULT
public static final int ID_MYSQL
public static final int ID_POSTGRESQL
public static final int CASE_LOWER
public static final int CASE_UPPER
public static final int CASE_MIXED
public static final java.lang.String WC_ERROR_TAG
Method Detail |
---|
public static java.lang.String stripTags(java.lang.String input)
public static java.lang.String parseResponse(java.io.InputStream ins) throws java.sql.SQLException, java.io.IOException
java.sql.SQLException
java.io.IOException
public static boolean checkForExceptions(java.lang.String response) throws java.sql.SQLException
response
- The Server response String.
java.sql.SQLException
- if any errors are detected.public static org.apache.commons.httpclient.NameValuePair[] prepareForWeb(com.ozdevworx.dtype.DataHandler input)
input
- LabeledArray
public static com.ozdevworx.dtype.DataHandler getCaseSafeHandler(int caseType)
caseType
- One of Util.CASE_LOWER, Util.CASE_UPPER, Util.CASE_MIXED
public static java.lang.String csvFormat(java.lang.String input)
public static java.lang.String csvUnFormat(java.lang.String input)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |