|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.mockrunner.jdbc.ParameterUtil
Util class for PreparedStatement and ResultSet
parameters.
| Constructor Summary | |
ParameterUtil()
|
|
| Method Summary | |
static boolean |
compareParameter(java.lang.Object source,
java.lang.Object target)
Compares two parameters of a PreparedStatement or
CallableStatement. |
static java.lang.Object |
copyParameter(java.lang.Object source)
Copies a parameter of a PreparedStatement,
CallableStatement or ResultSet. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public ParameterUtil()
| Method Detail |
public static java.lang.Object copyParameter(java.lang.Object source)
PreparedStatement,
CallableStatement or ResultSet.
InputStream objects, Reader objects
and arrays are copied into new allocated streams resp. arrays.
All other objects are cloned by calling the clone method.
If the object is not cloneable, it is returned unchanged.
source - the parameter to copy
public static boolean compareParameter(java.lang.Object source,
java.lang.Object target)
PreparedStatement or
CallableStatement. You can use it to compare
parameters of a ResultSet. It is used by
PreparedStatementResultSetHandler
for comparing parameters specified in the prepare
methods.
Since the parameters can be of the type byte[],
InputStream, Reader, Ref,
Array, Blob, Clob or
Struct this method can handle these types of objects.
All other objects are compared using the equals method.
source - the first parametertarget - the second parameter
true if source is equal to target,
false otherwise
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||