| Package | Description |
|---|---|
| org.unitils.reflectionassert | |
| org.unitils.reflectionassert.comparator | |
| org.unitils.reflectionassert.comparator.impl |
| Modifier and Type | Method and Description |
|---|---|
static ReflectionComparator |
ReflectionComparatorFactory.createRefectionComparator(ReflectionComparatorMode... modes)
Creates a reflection comparator for the given modes.
|
| Modifier and Type | Method and Description |
|---|---|
Difference |
Comparator.compare(Object left,
Object right,
boolean onlyFirstDifference,
ReflectionComparator reflectionComparator)
Compares the given objects and returns the difference (if any).
|
| Modifier and Type | Method and Description |
|---|---|
Difference |
SimpleCasesComparator.compare(Object left,
Object right,
boolean onlyFirstDifference,
ReflectionComparator reflectionComparator)
Compares the given values.
|
Difference |
ObjectComparator.compare(Object left,
Object right,
boolean onlyFirstDifference,
ReflectionComparator reflectionComparator)
Compares the given objects by iterating over the fields and comparing the corresponding values.
|
Difference |
MapComparator.compare(Object left,
Object right,
boolean onlyFirstDifference,
ReflectionComparator reflectionComparator)
Compares the given maps by looping over the keys and comparing their values.
|
Difference |
LenientOrderCollectionComparator.compare(Object left,
Object right,
boolean onlyFirstDifference,
ReflectionComparator reflectionComparator)
Compares the given collections/arrays but ignoring the actual order of the elements.
|
Difference |
LenientNumberComparator.compare(Object left,
Object right,
boolean onlyFirstDifference,
ReflectionComparator reflectionComparator)
Compares the two values by converting them to a double and comparing these double values.
|
Difference |
LenientDatesComparator.compare(Object left,
Object right,
boolean onlyFirstDifference,
ReflectionComparator reflectionComparator)
Compares the given dates.
|
Difference |
IgnoreDefaultsComparator.compare(Object left,
Object right,
boolean onlyFirstDifference,
ReflectionComparator reflectionComparator)
Always returns null: both objects are equal.
|
Difference |
HibernateProxyComparator.compare(Object left,
Object right,
boolean onlyFirstDifference,
ReflectionComparator reflectionComparator)
Compares the given objects.
|
Difference |
CollectionComparator.compare(Object left,
Object right,
boolean onlyFirstDifference,
ReflectionComparator reflectionComparator)
Compared the given collections/arrays.
|
protected void |
ObjectComparator.compareFields(Object left,
Object right,
Class<?> clazz,
ObjectDifference difference,
boolean onlyFirstDifference,
ReflectionComparator reflectionComparator)
Compares the values of all fields in the given objects by use of reflection.
|
protected void |
LenientOrderCollectionComparator.fillAllDifferences(ArrayList<Object> leftList,
ArrayList<Object> rightList,
ReflectionComparator reflectionComparator,
UnorderedCollectionDifference difference)
Calculates the difference of all elements in the left list with all elements of the right list.
|
protected boolean |
LenientOrderCollectionComparator.isEqual(ArrayList<Object> leftList,
ArrayList<Object> rightList,
int leftIndex,
ReflectionComparator reflectionComparator)
Recursively checks whether there is a sequence so that both collections have matching elements.
|
Copyright © 2016. All Rights Reserved.