summaryrefslogtreecommitdiff
path: root/qadevOOo/runner/util/ValueComparer.java
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2012-06-27 16:08:28 +0200
committerMichael Stahl <mstahl@redhat.com>2012-06-29 22:03:01 +0200
commit453d7edc424d6652e209ace4915d96193a79be71 (patch)
tree0a6af928cf7d1fd90ec995ae7d114f08eaf617fd /qadevOOo/runner/util/ValueComparer.java
parentb65017a2a7af290f6681da7b197a52efe83d5185 (diff)
Java5 update - convert more code to use generics:wq
Change-Id: I7ea32cad40a6657e4e5886d04af008cb6d67ac6e
Diffstat (limited to 'qadevOOo/runner/util/ValueComparer.java')
-rw-r--r--qadevOOo/runner/util/ValueComparer.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/qadevOOo/runner/util/ValueComparer.java b/qadevOOo/runner/util/ValueComparer.java
index 3ce1719156d5..d4535bc6fde7 100644
--- a/qadevOOo/runner/util/ValueComparer.java
+++ b/qadevOOo/runner/util/ValueComparer.java
@@ -98,7 +98,7 @@ public class ValueComparer {
if((op1.getClass().getComponentType() == op2.getClass().getComponentType())
&& (Array.getLength(op1) == Array.getLength(op2)))
{
- Class zClass = op1.getClass().getComponentType();
+ Class<?> zClass = op1.getClass().getComponentType();
for(int i = 0; i < Array.getLength(op1); ++ i)
result = result & compareObjects(Array.get(op1, i), Array.get(op2, i));
@@ -113,11 +113,11 @@ public class ValueComparer {
return op1 == op2;
}
- static boolean compareUntil(Class zClass, Class untilClass, Object op1, Object op2) throws Exception {
+ static boolean compareUntil(Class<?> zClass, Class<?> untilClass, Object op1, Object op2) throws Exception {
boolean result = true;
// write inherited members first
- Class superClass = zClass.getSuperclass();
+ Class<?> superClass = zClass.getSuperclass();
if(superClass != null && superClass != untilClass)
result = result & compareUntil(superClass, untilClass, op1, op2);
@@ -245,7 +245,7 @@ public class ValueComparer {
compareEnums((Enum)op1, (Enum)op2);
else if(op1.getClass() == String.class && op2.getClass() == String.class) // is it a String ?
- result = ((String)op1).equals((String)op2);
+ result = ((String)op1).equals(op2);
else // otherwise it must be a struct
result = compareStructs(op1, op2);