Lines Matching refs:op1
97 static boolean compareArrays(Object op1, Object op2) throws Exception { in compareArrays() argument
99 if (op1 instanceof PropertyValue[] && op2 instanceof PropertyValue[]) { in compareArrays()
100 return compareArrayOfPropertyValue((PropertyValue[])op1,(PropertyValue[])op2); in compareArrays()
103 if((op1.getClass().getComponentType() == op2.getClass().getComponentType()) in compareArrays()
104 && (Array.getLength(op1) == Array.getLength(op2))) in compareArrays()
106 Class zClass = op1.getClass().getComponentType(); in compareArrays()
108 for(int i = 0; i < Array.getLength(op1); ++ i) in compareArrays()
109 result = result & compareObjects(Array.get(op1, i), Array.get(op2, i)); in compareArrays()
117 static boolean compareInterfaces(XInterface op1, XInterface op2) { in compareInterfaces() argument
118 return op1 == op2; in compareInterfaces()
121 …static boolean compareUntil(Class zClass, Class untilClass, Object op1, Object op2) throws Excepti… in compareUntil() argument
127 result = result & compareUntil(superClass, untilClass, op1, op2); in compareUntil()
133 Object obj1 = fields[i].get(op1); in compareUntil()
164 static boolean compareStructs(Object op1, Object op2) throws Exception { in compareStructs() argument
167 if(op1.getClass() != op2.getClass()) in compareStructs()
170 result = compareUntil(op1.getClass(), Object.class, op1, op2); in compareStructs()
176 static boolean compareThrowable(Throwable op1, Throwable op2) throws Exception { in compareThrowable() argument
179 if(op1.getClass() != op2.getClass()) in compareThrowable()
182 result = compareUntil(op1.getClass(), Throwable.class, op1, op2); in compareThrowable()
184 result = result & op1.getMessage().equals(op2.getMessage()); in compareThrowable()
194 static boolean compareObjects(Object op1, Object op2) throws Exception { in compareObjects() argument
197 if(op1 == op2) in compareObjects()
200 if ( (op1==null) || (op2 == null) ) { in compareObjects()
201 result = (op1 == op2); in compareObjects()
204 else if(op1.getClass().isPrimitive() && op2.getClass().isPrimitive()) in compareObjects()
205 result = op1.equals(op2); in compareObjects()
207 else if(op1.getClass() == Byte.class && op2.getClass() == Byte.class) in compareObjects()
208 result = op1.equals(op2); in compareObjects()
210 else if(op1.getClass() == Type.class && op2.getClass() == Type.class) in compareObjects()
211 result = op1.equals(op2); in compareObjects()
213 else if(op1.getClass() == Boolean.class && op2.getClass() == Boolean.class) in compareObjects()
214 result = op1.equals(op2); in compareObjects()
216 else if(op1.getClass() == Short.class && op2.getClass() == Short.class) in compareObjects()
217 result = op1.equals(op2); in compareObjects()
219 …else if(Throwable.class.isAssignableFrom(op1.getClass()) && Throwable.class.isAssignableFrom(op2.g… in compareObjects()
220 result = compareThrowable((Throwable)op1, (Throwable)op2); in compareObjects()
222 else if(op1.getClass() == Integer.class && op2.getClass() == Integer.class) in compareObjects()
223 result = op1.equals(op2); in compareObjects()
225 else if(op1.getClass() == Character.class && op2.getClass() == Character.class) in compareObjects()
226 result = op1.equals(op2); in compareObjects()
228 else if(op1.getClass() == Long.class && op2.getClass() == Long.class) in compareObjects()
229 result = op1.equals(op2); in compareObjects()
231 else if(op1.getClass() == Void.class && op2.getClass() == Void.class) in compareObjects()
232 result = op1.equals(op2); in compareObjects()
234 else if(op1.getClass() == Float.class && op2.getClass() == Float.class) in compareObjects()
235 result = op1.equals(op2); in compareObjects()
237 else if(op1.getClass() == Double.class && op2.getClass() == Double.class) in compareObjects()
238 result = op1.equals(op2); in compareObjects()
240 else if(op1.getClass().isArray() && op2.getClass().isArray()) in compareObjects()
241 result = compareArrays(op1, op2); in compareObjects()
243 else if(op1.getClass() == Void.class || op2.getClass() == void.class) // write nothing ? in compareObjects()
246 …else if(XInterface.class.isAssignableFrom(op1.getClass()) && XInterface.class.isAssignableFrom(op2… in compareObjects()
247 compareInterfaces((XInterface)op1, (XInterface)op2); in compareObjects()
249 …else if(Enum.class.isAssignableFrom(op1.getClass()) && Enum.class.isAssignableFrom(op2.getClass())) in compareObjects()
250 compareEnums((Enum)op1, (Enum)op2); in compareObjects()
252 … else if(op1.getClass() == String.class && op2.getClass() == String.class) // is it a String ? in compareObjects()
253 result = ((String)op1).equals((String)op2); in compareObjects()
256 result = compareStructs(op1, op2); in compareObjects()