More type safety goodness. It all compiles with no warnings now. Yay!
git-svn-id: https://samskivert.googlecode.com/svn/trunk@1845 6335cc39-0255-0410-8fd6-9bcaacd3b74c
This commit is contained in:
@@ -20,6 +20,7 @@
|
|||||||
|
|
||||||
package com.samskivert.jdbc.jora;
|
package com.samskivert.jdbc.jora;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
import java.sql.*;
|
import java.sql.*;
|
||||||
import java.lang.reflect.*;
|
import java.lang.reflect.*;
|
||||||
@@ -505,7 +506,7 @@ public class Table<T>
|
|||||||
if ((f[i].getModifiers()&(Modifier.TRANSIENT|Modifier.STATIC))==0)
|
if ((f[i].getModifiers()&(Modifier.TRANSIENT|Modifier.STATIC))==0)
|
||||||
{
|
{
|
||||||
String name = f[i].getName();
|
String name = f[i].getName();
|
||||||
Class fieldClass = f[i].getType();
|
Class<?> fieldClass = f[i].getType();
|
||||||
String fullName = prefix + convertName(name);
|
String fullName = prefix + convertName(name);
|
||||||
FieldDescriptor fd = new FieldDescriptor(f[i], fullName);
|
FieldDescriptor fd = new FieldDescriptor(f[i], fullName);
|
||||||
int type;
|
int type;
|
||||||
@@ -891,7 +892,7 @@ public class Table<T>
|
|||||||
protected Constructor<T> constructor;
|
protected Constructor<T> constructor;
|
||||||
protected static Method setBypass;
|
protected static Method setBypass;
|
||||||
|
|
||||||
protected static Class serializableClass;
|
protected static Class<Serializable> serializableClass;
|
||||||
protected static final Object[] bypassFlag = { new Boolean(true) };
|
protected static final Object[] bypassFlag = { new Boolean(true) };
|
||||||
protected static final Object[] constructorArgs = {};
|
protected static final Object[] constructorArgs = {};
|
||||||
|
|
||||||
@@ -900,7 +901,7 @@ public class Table<T>
|
|||||||
|
|
||||||
static {
|
static {
|
||||||
try {
|
try {
|
||||||
serializableClass = Class.forName("java.io.Serializable");
|
serializableClass = Serializable.class;
|
||||||
Class c = Class.forName("java.lang.reflect.AccessibleObject");
|
Class c = Class.forName("java.lang.reflect.AccessibleObject");
|
||||||
Class[] param = { Boolean.TYPE };
|
Class[] param = { Boolean.TYPE };
|
||||||
setBypass = c.getMethod("setAccessible", param);
|
setBypass = c.getMethod("setAccessible", param);
|
||||||
|
|||||||
@@ -54,6 +54,7 @@ public class SortableArrayList<T> extends BaseArrayList<T>
|
|||||||
*
|
*
|
||||||
* @return the index at which the element was inserted.
|
* @return the index at which the element was inserted.
|
||||||
*/
|
*/
|
||||||
|
@SuppressWarnings("unchecked")
|
||||||
public int insertSorted (T value, Comparator<T> comp)
|
public int insertSorted (T value, Comparator<T> comp)
|
||||||
{
|
{
|
||||||
int ipos = binarySearch(value, comp);
|
int ipos = binarySearch(value, comp);
|
||||||
|
|||||||
Reference in New Issue
Block a user