|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.evolveum.midpoint.prism.delta.DeltaSetTriple<T>
public class DeltaSetTriple<T>
The triple of values (added, unchanged, deleted) that represents difference between two collections of values.
The DeltaSetTriple is used as a result of a "diff" operation or it is constructed to determine a ObjectDelta or PropertyDelta. It is a very useful structure in numerous situations when dealing with relative changes. DeltaSetTriple (similarly to other parts of this system) deal only with unordered values.
Field Summary | |
---|---|
protected Collection<T> |
minusSet
Collection of values that were deleted. |
protected Collection<T> |
plusSet
Collection of values that were added. |
protected Collection<T> |
zeroSet
Collection of values that were not changed. |
Fields inherited from interface com.evolveum.midpoint.util.DebugDumpable |
---|
INDENT_STRING |
Constructor Summary | |
---|---|
DeltaSetTriple()
|
|
DeltaSetTriple(Collection<T> zeroSet,
Collection<T> plusSet,
Collection<T> minusSet)
|
Method Summary | ||
---|---|---|
void |
accept(SimpleVisitor<T> visitor)
|
|
void |
addAllToMinusSet(Collection<T> items)
|
|
void |
addAllToPlusSet(Collection<T> items)
|
|
void |
addAllToZeroSet(Collection<T> items)
|
|
void |
addToMinusSet(T item)
|
|
void |
addToPlusSet(T item)
|
|
void |
addToZeroSet(T item)
|
|
void |
clearMinusSet()
|
|
void |
clearPlusSet()
|
|
void |
clearZeroSet()
|
|
DeltaSetTriple<T> |
clone(Cloner<T> cloner)
|
|
protected void |
copyValues(DeltaSetTriple<T> clone,
Cloner<T> cloner)
|
|
protected Collection<T> |
createSet()
|
|
String |
debugDump()
Show the content of the object intended for diagnostics by system administrator. |
|
String |
debugDump(int indent)
|
|
protected String |
debugName()
|
|
static
|
diff(Collection<T> valuesOld,
Collection<T> valuesNew)
Compares two (unordered) collections and creates a triple describing the differences. |
|
protected static
|
diff(Collection<T> valuesOld,
Collection<T> valuesNew,
DeltaSetTriple<T> triple)
|
|
String |
dump()
Show the content of the object intended for diagnostics by developer. |
|
Collection<T> |
getAllValues()
|
|
Collection<T> |
getMinusSet()
|
|
Collection<T> |
getNonNegativeValues()
|
|
Collection<T> |
getNonPositiveValues()
|
|
Collection<T> |
getPlusSet()
|
|
Collection<T> |
getZeroSet()
|
|
boolean |
hasMinusSet()
|
|
boolean |
hasPlusSet()
|
|
boolean |
hasZeroSet()
|
|
boolean |
isEmpty()
|
|
void |
merge(DeltaSetTriple<T> triple)
|
|
boolean |
presentInMinusSet(T item)
|
|
boolean |
presentInPlusSet(T item)
|
|
boolean |
presentInZeroSet(T item)
|
|
int |
size()
|
|
String |
toString()
|
|
Collection<T> |
union()
Returns all values, regardless of the internal sets. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected Collection<T> zeroSet
protected Collection<T> plusSet
protected Collection<T> minusSet
Constructor Detail |
---|
public DeltaSetTriple()
public DeltaSetTriple(Collection<T> zeroSet, Collection<T> plusSet, Collection<T> minusSet)
Method Detail |
---|
public static <T> DeltaSetTriple<T> diff(Collection<T> valuesOld, Collection<T> valuesNew)
protected static <T> void diff(Collection<T> valuesOld, Collection<T> valuesNew, DeltaSetTriple<T> triple)
protected Collection<T> createSet()
public Collection<T> getZeroSet()
public Collection<T> getPlusSet()
public Collection<T> getMinusSet()
public boolean hasPlusSet()
public boolean hasZeroSet()
public boolean hasMinusSet()
public void addToPlusSet(T item)
public void addToMinusSet(T item)
public void addToZeroSet(T item)
public void addAllToPlusSet(Collection<T> items)
public void addAllToMinusSet(Collection<T> items)
public void addAllToZeroSet(Collection<T> items)
public boolean presentInPlusSet(T item)
public boolean presentInMinusSet(T item)
public boolean presentInZeroSet(T item)
public void clearPlusSet()
public void clearMinusSet()
public void clearZeroSet()
public int size()
public Collection<T> union()
public Collection<T> getAllValues()
public Collection<T> getNonNegativeValues()
public Collection<T> getNonPositiveValues()
public void merge(DeltaSetTriple<T> triple)
public DeltaSetTriple<T> clone(Cloner<T> cloner)
protected void copyValues(DeltaSetTriple<T> clone, Cloner<T> cloner)
public boolean isEmpty()
public void accept(SimpleVisitor<T> visitor)
accept
in interface SimpleVisitable<T>
public String toString()
toString
in class Object
public String dump()
Dumpable
dump
in interface Dumpable
protected String debugName()
public String debugDump()
DebugDumpable
debugDump
in interface DebugDumpable
public String debugDump(int indent)
debugDump
in interface DebugDumpable
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |