public interface ComparisonUtils
Modifier and Type | Method and Description |
---|---|
void |
compareCollections(Collection<? extends DbObject> leftCollection,
Collection<? extends DbObject> rightCollection,
DiffContext ctx)
Compare collections of
DbObject s using their DbObject.diff(DbObject, DiffContext) method. |
void |
compareSimple(DbProperty left,
DbProperty right,
DiffContext ctx)
Compare two 'simple' (i.e.
|
void |
compareSimpleCollections(DbProperty leftProperty,
DbProperty rightProperty,
DiffContext ctx)
Compare two collections.
|
void |
compareSimpleOrderedLists(DbProperty leftProperty,
DbProperty rightProperty,
DiffContext ctx)
Compare two
List s of 'simple' (i.e. |
List<DbObject> |
findEquivalentObjects(DbObject rootObject,
DbObject objToMatch) |
List<DbObject> findEquivalentObjects(DbObject rootObject, DbObject objToMatch)
void compareSimpleOrderedLists(DbProperty leftProperty, DbProperty rightProperty, DiffContext ctx)
List
s of 'simple' (i.e. non-DbObject
) objects. Ordering
is significant - if an element E appears in both collections but at different indexes
then it is not considered to be the same item.leftProperty
- DbPropertyrightProperty
- DbPropertyctx
- DiffContextvoid compareSimpleCollections(DbProperty leftProperty, DbProperty rightProperty, DiffContext ctx)
compareSimpleOrderedLists(DbProperty, DbProperty, DiffContext)
except that this method operates on Collection
s and order (and cardinality) is not important. If
an element E from the reference collection appears one or more times at any position in the target collection
then that element is said to be in both with no difference
.leftProperty
- DbPropertyrightProperty
- DbPropertyctx
- - contextvoid compareCollections(Collection<? extends DbObject> leftCollection, Collection<? extends DbObject> rightCollection, DiffContext ctx)
DbObject
s using their DbObject.diff(DbObject, DiffContext)
method.ctx
- - contextvoid compareSimple(DbProperty left, DbProperty right, DiffContext ctx)
DbObject
) objects using their Object.equals(Object)
method
to decide if there is a difference.left
- DbPropertyright
- DbPropertyctx
- - contextCopyright © 2005–2017 Alfresco Software. All rights reserved.