Пример #1
0
 protected void setSodaTestOn(STClass[] classes) {
   for (int i = 0; i < classes.length; i++) {
     try {
       Field field = classes[i].getClass().getDeclaredField("st");
       try {
         Platform4.setAccessible(field);
       } catch (Throwable t) {
         // JDK 1.x has no setAccessible
       }
       field.set(classes[i], this);
     } catch (Exception e) {
       System.err.println("Add the following line to Class " + classes[i].getClass().getName());
       System.err.println("public static transient SodaTest st;");
     }
   }
 }
Пример #2
0
 protected static boolean jdkOK(Object obj) {
   return Platform4.jdk().ver() >= 2 || STClass1.class.isAssignableFrom(obj.getClass());
 }