Class AbstractDelegatedPrismValueDeltaSetTriple<V extends PrismValue>
- java.lang.Object
-
- com.evolveum.midpoint.prism.extensions.AbstractDelegatedPrismValueDeltaSetTriple<V>
-
- All Implemented Interfaces:
DeltaSetTriple<V>,PrismValueDeltaSetTriple<V>,SimpleVisitable<V>,Visitable,DebugDumpable,Foreachable<V>,ShortDumpable,Serializable
public class AbstractDelegatedPrismValueDeltaSetTriple<V extends PrismValue> extends Object implements PrismValueDeltaSetTriple<V>
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected PrismValueDeltaSetTriple<V>inner-
Fields inherited from interface com.evolveum.midpoint.util.DebugDumpable
INDENT_STRING
-
-
Constructor Summary
Constructors Constructor Description AbstractDelegatedPrismValueDeltaSetTriple(PrismValueDeltaSetTriple<V> inner)AbstractDelegatedPrismValueDeltaSetTriple(PrismContext prismContext)AbstractDelegatedPrismValueDeltaSetTriple(Collection<V> zeroSet, Collection<V> plusSet, Collection<V> minusSet, PrismContext prismContext)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(Visitor visitor)voidaddAllToMinusSet(Collection<V> items)voidaddAllToPlusSet(Collection<V> items)voidaddAllToSet(PlusMinusZero destination, Collection<V> items)voidaddAllToZeroSet(Collection<V> items)voidaddToMinusSet(V item)voidaddToPlusSet(V item)voidaddToSet(PlusMinusZero destination, V item)voidaddToZeroSet(V item)voidapplyDefinition(ItemDefinition itemDefinition)voidcheckConsistence()voidcheckNoParent()voidclearMinusSet()voidclearPlusSet()voidclearZeroSet()PrismValueDeltaSetTriple<V>clone()DeltaSetTriple<V>clone(Cloner<V> cloner)StringdebugDump(int indent)voiddebugDumpSets(StringBuilder sb, Consumer<V> dumper, int indent)static <T> DeltaSetTriple<T>diff(Collection<T> valuesOld, Collection<T> valuesNew, PrismContext prismContext)Compares two (unordered) collections and creates a triple describing the differences.<O extends PrismValue>
voiddistributeAs(V myMember, PrismValueDeltaSetTriple<O> otherTriple, O otherMember)Distributes a value in this triple similar to the placement of other value in the other triple.voidforeach(Processor<V> processor)Process each element of every set.Collection<V>getAllValues()VgetAnyValue()@NotNull Collection<V>getMinusSet()@NotNull Collection<V>getNonNegativeValues()@NotNull Collection<V>getNonPositiveValues()@NotNull Collection<V>getPlusSet()Class<?>getRealValueClass()Collection<V>getSet(PlusMinusZero whichSet)Class<V>getValueClass()@NotNull Collection<V>getZeroSet()booleanhasMinusSet()booleanhasPlusSet()booleanhasZeroSet()booleanisEmpty()booleanisRaw()booleanisZeroOnly()voidmerge(DeltaSetTriple<V> triple)booleanpresentInMinusSet(V item)booleanpresentInPlusSet(V item)booleanpresentInZeroSet(V item)voidremoveEmptyValues(boolean allowEmptyValues)voidsetOriginObject(Objectable originObject)Sets specified origin object for all values in all setsvoidsetOriginType(OriginType sourceType)Sets specified source type for all values in all setsvoidshortDump(StringBuilder sb)Show the content of the object intended for diagnostics.voidsimpleAccept(SimpleVisitor<V> visitor)intsize()Stream<V>stream()StringtoHumanReadableString()<X> voidtransform(DeltaSetTriple<X> transformTarget, Transformer<V,X> transformer)Collection<V>union()Returns all values, regardless of the internal sets.-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.evolveum.midpoint.util.DebugDumpable
debugDump, debugDumpLazily, debugDumpLazily
-
Methods inherited from interface com.evolveum.midpoint.prism.delta.DeltaSetTriple
clear
-
Methods inherited from interface com.evolveum.midpoint.util.ShortDumpable
shortDump, shortDumpLazily
-
-
-
-
Field Detail
-
inner
protected PrismValueDeltaSetTriple<V extends PrismValue> inner
-
-
Constructor Detail
-
AbstractDelegatedPrismValueDeltaSetTriple
public AbstractDelegatedPrismValueDeltaSetTriple(PrismValueDeltaSetTriple<V> inner)
-
AbstractDelegatedPrismValueDeltaSetTriple
public AbstractDelegatedPrismValueDeltaSetTriple(PrismContext prismContext)
-
AbstractDelegatedPrismValueDeltaSetTriple
public AbstractDelegatedPrismValueDeltaSetTriple(Collection<V> zeroSet, Collection<V> plusSet, Collection<V> minusSet, PrismContext prismContext)
-
-
Method Detail
-
distributeAs
public <O extends PrismValue> void distributeAs(V myMember, PrismValueDeltaSetTriple<O> otherTriple, O otherMember)
Description copied from interface:PrismValueDeltaSetTripleDistributes a value in this triple similar to the placement of other value in the other triple. E.g. if the value "otherMember" is in the zero set in "otherTriple" then "myMember" will be placed in zero set in this triple.- Specified by:
distributeAsin interfacePrismValueDeltaSetTriple<V extends PrismValue>
-
getValueClass
public Class<V> getValueClass()
- Specified by:
getValueClassin interfacePrismValueDeltaSetTriple<V extends PrismValue>
-
getRealValueClass
public Class<?> getRealValueClass()
- Specified by:
getRealValueClassin interfacePrismValueDeltaSetTriple<V extends PrismValue>
-
isRaw
public boolean isRaw()
- Specified by:
isRawin interfacePrismValueDeltaSetTriple<V extends PrismValue>
-
applyDefinition
public void applyDefinition(ItemDefinition itemDefinition) throws SchemaException
- Specified by:
applyDefinitionin interfacePrismValueDeltaSetTriple<V extends PrismValue>- Throws:
SchemaException
-
setOriginType
public void setOriginType(OriginType sourceType)
Description copied from interface:PrismValueDeltaSetTripleSets specified source type for all values in all sets- Specified by:
setOriginTypein interfacePrismValueDeltaSetTriple<V extends PrismValue>
-
setOriginObject
public void setOriginObject(Objectable originObject)
Description copied from interface:PrismValueDeltaSetTripleSets specified origin object for all values in all sets- Specified by:
setOriginObjectin interfacePrismValueDeltaSetTriple<V extends PrismValue>
-
removeEmptyValues
public void removeEmptyValues(boolean allowEmptyValues)
- Specified by:
removeEmptyValuesin interfacePrismValueDeltaSetTriple<V extends PrismValue>
-
clone
public PrismValueDeltaSetTriple<V> clone()
- Specified by:
clonein interfacePrismValueDeltaSetTriple<V extends PrismValue>- Overrides:
clonein classObject
-
checkConsistence
public void checkConsistence()
- Specified by:
checkConsistencein interfacePrismValueDeltaSetTriple<V extends PrismValue>
-
accept
public void accept(Visitor visitor)
- Specified by:
acceptin interfacePrismValueDeltaSetTriple<V extends PrismValue>- Specified by:
acceptin interfaceVisitable<V extends PrismValue>
-
checkNoParent
public void checkNoParent()
- Specified by:
checkNoParentin interfacePrismValueDeltaSetTriple<V extends PrismValue>
-
diff
public static <T> DeltaSetTriple<T> diff(Collection<T> valuesOld, Collection<T> valuesNew, PrismContext prismContext)
Description copied from interface:DeltaSetTripleCompares two (unordered) collections and creates a triple describing the differences.
-
getZeroSet
@NotNull public @NotNull Collection<V> getZeroSet()
- Specified by:
getZeroSetin interfaceDeltaSetTriple<V extends PrismValue>
-
getPlusSet
@NotNull public @NotNull Collection<V> getPlusSet()
- Specified by:
getPlusSetin interfaceDeltaSetTriple<V extends PrismValue>
-
getMinusSet
@NotNull public @NotNull Collection<V> getMinusSet()
- Specified by:
getMinusSetin interfaceDeltaSetTriple<V extends PrismValue>
-
hasPlusSet
public boolean hasPlusSet()
- Specified by:
hasPlusSetin interfaceDeltaSetTriple<V extends PrismValue>
-
hasZeroSet
public boolean hasZeroSet()
- Specified by:
hasZeroSetin interfaceDeltaSetTriple<V extends PrismValue>
-
hasMinusSet
public boolean hasMinusSet()
- Specified by:
hasMinusSetin interfaceDeltaSetTriple<V extends PrismValue>
-
isZeroOnly
public boolean isZeroOnly()
- Specified by:
isZeroOnlyin interfaceDeltaSetTriple<V extends PrismValue>
-
addToPlusSet
public void addToPlusSet(V item)
- Specified by:
addToPlusSetin interfaceDeltaSetTriple<V extends PrismValue>
-
addToMinusSet
public void addToMinusSet(V item)
- Specified by:
addToMinusSetin interfaceDeltaSetTriple<V extends PrismValue>
-
addToZeroSet
public void addToZeroSet(V item)
- Specified by:
addToZeroSetin interfaceDeltaSetTriple<V extends PrismValue>
-
addAllToPlusSet
public void addAllToPlusSet(Collection<V> items)
- Specified by:
addAllToPlusSetin interfaceDeltaSetTriple<V extends PrismValue>
-
addAllToMinusSet
public void addAllToMinusSet(Collection<V> items)
- Specified by:
addAllToMinusSetin interfaceDeltaSetTriple<V extends PrismValue>
-
addAllToZeroSet
public void addAllToZeroSet(Collection<V> items)
- Specified by:
addAllToZeroSetin interfaceDeltaSetTriple<V extends PrismValue>
-
getSet
public Collection<V> getSet(PlusMinusZero whichSet)
- Specified by:
getSetin interfaceDeltaSetTriple<V extends PrismValue>
-
addAllToSet
public void addAllToSet(PlusMinusZero destination, Collection<V> items)
- Specified by:
addAllToSetin interfaceDeltaSetTriple<V extends PrismValue>
-
addToSet
public void addToSet(PlusMinusZero destination, V item)
- Specified by:
addToSetin interfaceDeltaSetTriple<V extends PrismValue>
-
presentInPlusSet
public boolean presentInPlusSet(V item)
- Specified by:
presentInPlusSetin interfaceDeltaSetTriple<V extends PrismValue>
-
presentInMinusSet
public boolean presentInMinusSet(V item)
- Specified by:
presentInMinusSetin interfaceDeltaSetTriple<V extends PrismValue>
-
presentInZeroSet
public boolean presentInZeroSet(V item)
- Specified by:
presentInZeroSetin interfaceDeltaSetTriple<V extends PrismValue>
-
clearPlusSet
public void clearPlusSet()
- Specified by:
clearPlusSetin interfaceDeltaSetTriple<V extends PrismValue>
-
clearMinusSet
public void clearMinusSet()
- Specified by:
clearMinusSetin interfaceDeltaSetTriple<V extends PrismValue>
-
clearZeroSet
public void clearZeroSet()
- Specified by:
clearZeroSetin interfaceDeltaSetTriple<V extends PrismValue>
-
size
public int size()
- Specified by:
sizein interfaceDeltaSetTriple<V extends PrismValue>
-
union
public Collection<V> union()
Description copied from interface:DeltaSetTripleReturns all values, regardless of the internal sets.- Specified by:
unionin interfaceDeltaSetTriple<V extends PrismValue>
-
getAnyValue
public V getAnyValue()
- Specified by:
getAnyValuein interfaceDeltaSetTriple<V extends PrismValue>
-
getAllValues
public Collection<V> getAllValues()
- Specified by:
getAllValuesin interfaceDeltaSetTriple<V extends PrismValue>
-
stream
public Stream<V> stream()
- Specified by:
streamin interfaceDeltaSetTriple<V extends PrismValue>
-
getNonNegativeValues
@NotNull public @NotNull Collection<V> getNonNegativeValues()
- Specified by:
getNonNegativeValuesin interfaceDeltaSetTriple<V extends PrismValue>
-
getNonPositiveValues
@NotNull public @NotNull Collection<V> getNonPositiveValues()
- Specified by:
getNonPositiveValuesin interfaceDeltaSetTriple<V extends PrismValue>
-
merge
public void merge(DeltaSetTriple<V> triple)
- Specified by:
mergein interfaceDeltaSetTriple<V extends PrismValue>
-
clone
public DeltaSetTriple<V> clone(Cloner<V> cloner)
- Specified by:
clonein interfaceDeltaSetTriple<V extends PrismValue>
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmptyin interfaceDeltaSetTriple<V extends PrismValue>
-
foreach
public void foreach(Processor<V> processor)
Description copied from interface:DeltaSetTripleProcess each element of every set. This is different from the visitor. Visitor will go deep inside, foreach will remain on the surface.- Specified by:
foreachin interfaceDeltaSetTriple<V extends PrismValue>- Specified by:
foreachin interfaceForeachable<V extends PrismValue>
-
simpleAccept
public void simpleAccept(SimpleVisitor<V> visitor)
- Specified by:
simpleAcceptin interfaceDeltaSetTriple<V extends PrismValue>- Specified by:
simpleAcceptin interfaceSimpleVisitable<V extends PrismValue>
-
transform
public <X> void transform(DeltaSetTriple<X> transformTarget, Transformer<V,X> transformer)
- Specified by:
transformin interfaceDeltaSetTriple<V extends PrismValue>
-
debugDumpSets
public void debugDumpSets(StringBuilder sb, Consumer<V> dumper, int indent)
- Specified by:
debugDumpSetsin interfaceDeltaSetTriple<V extends PrismValue>
-
toHumanReadableString
public String toHumanReadableString()
- Specified by:
toHumanReadableStringin interfaceDeltaSetTriple<V extends PrismValue>
-
debugDump
public String debugDump(int indent)
- Specified by:
debugDumpin interfaceDebugDumpable
-
shortDump
public void shortDump(StringBuilder sb)
Description copied from interface:ShortDumpableShow the content of the object intended for diagnostics. This method is supposed to append a compact, human-readable output in a single line. Unlike toString() method, there is no requirement to identify the actual class or type of the object. It is assumed that the class/type will be obvious from the context in which the output is used.- Specified by:
shortDumpin interfaceShortDumpable- Parameters:
sb- StringBuilder to which to a compact one-line content of the object intended for diagnostics by system administrator should be appended.
-
-