| java.lang.Object com.mysql.jdbc.Util
Util | public class Util (Code) | | Various utility methods for the driver.
author: Mark Matthews |
Inner Class :class RandStructcture | |
Method Summary | |
public static Map | calculateDifferences(Map map1, Map map2) | public static Object | cast(Object invokeOn, Object toCast) Reflexive access on JDK-1.5's Class.cast() method so we don't have to
move that out into separate classes built for JDBC-4.0. | public static long | getCurrentTimeNanosOrMillis() | final static TimeZone | getDefaultTimeZone() | public static Object | getInstance(String className, Class[] argTypes, Object[] args) | final public static Object | handleNewInstance(Constructor ctor, Object[] args) | public static boolean | interfaceExists(String hostname) | public static boolean | isColdFusion() | public static boolean | isJdbc4() | protected static boolean | nanoTimeAvailable() | static String | newCrypt(String password, String seed) | static long[] | newHash(String password) | static String | oldCrypt(String password, String seed) | static long | oldHash(String password) | public static Object | readObject(java.sql.ResultSet resultSet, int index) Given a ResultSet and an index into the columns of that ResultSet, read
binary data from the column which represents a serialized object, and
re-create the object.
Parameters: resultSet - the ResultSet to use. Parameters: index - an index into the ResultSet. | public static void | resultSetToMap(Map mappedValues, java.sql.ResultSet rs) | public static String | scramble(String message, String password) | public static String | stackTraceToString(Throwable ex) Converts a nested exception into a nicer message
Parameters: ex - the exception to expand into a message. |
systemNanoTimeMethod | protected static Method systemNanoTimeMethod(Code) | | |
calculateDifferences | public static Map calculateDifferences(Map map1, Map map2)(Code) | | |
cast | public static Object cast(Object invokeOn, Object toCast)(Code) | | Reflexive access on JDK-1.5's Class.cast() method so we don't have to
move that out into separate classes built for JDBC-4.0.
Parameters: invokeOn - Parameters: toCast - |
getCurrentTimeNanosOrMillis | public static long getCurrentTimeNanosOrMillis()(Code) | | |
handleNewInstance | final public static Object handleNewInstance(Constructor ctor, Object[] args) throws SQLException(Code) | | Handles constructing new instance with the given constructor and wrapping
(or not, as required) the exceptions that could possibly be generated
|
interfaceExists | public static boolean interfaceExists(String hostname)(Code) | | Does a network interface exist locally with the given hostname?
Parameters: hostname - the hostname (or IP address in string form) to check true if it exists, false if no, or unable to determine due to VMversion support of java.net.NetworkInterface |
isColdFusion | public static boolean isColdFusion()(Code) | | |
isJdbc4 | public static boolean isJdbc4()(Code) | | |
nanoTimeAvailable | protected static boolean nanoTimeAvailable()(Code) | | |
readObject | public static Object readObject(java.sql.ResultSet resultSet, int index) throws Exception(Code) | | Given a ResultSet and an index into the columns of that ResultSet, read
binary data from the column which represents a serialized object, and
re-create the object.
Parameters: resultSet - the ResultSet to use. Parameters: index - an index into the ResultSet. the object if it can be de-serialized throws: Exception - if an error occurs |
scramble | public static String scramble(String message, String password)(Code) | | DOCUMENT ME!
Parameters: message - DOCUMENT ME! Parameters: password - DOCUMENT ME! DOCUMENT ME! |
stackTraceToString | public static String stackTraceToString(Throwable ex)(Code) | | Converts a nested exception into a nicer message
Parameters: ex - the exception to expand into a message. a message containing the exception, the message (if any), and astacktrace. |
|
|