Interface CSTNPSUEdge
- All Superinterfaces:
BasicCSTNUEdge, Comparable<Component>, Component, CSTNEdge, Edge, Serializable
- All Known Implementing Classes:
CSTNPSUEdgePluggable
Represents the behavior of a CSTNPSU edge.
A CSTNPSU edge is a CSTNU edge where it is also possible to have more lower-case values.
So, lower-case values are represented as a set of lower-case values.
LabeledLowerCaseValue is NOT used.
To promote greater efficiency, some methods return a view of the internal data structures (they are all methods that return a set of Entry).
Such a view could be dangerous because it could be modified directly (don't do that!) Such methods must be used only to read-only scan the labeled values or the labeled values' labels efficiently. Moreover, such views are not more valid if a value is added to or removed from the edge.
- Version:
- $Rev: 993 $
- Author:
- posenato
-
Nested Class Summary
Nested classes/interfaces inherited from interface Edge
Edge.ConstraintType -
Method Summary
Modifier and TypeMethodDescriptionvoidClears the labeled lowercase values.it.unimi.dsi.fastutil.objects.ObjectSet<it.unimi.dsi.fastutil.objects.Object2ObjectMap.Entry<ALabel, it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<Label>>> Don't use this set for scanning that requires modifying the internal map; otherwise, this set will become invalid after the first modification.it.unimi.dsi.fastutil.objects.ObjectSet<Label> it.unimi.dsi.fastutil.objects.ObjectSet<Label> getLabelsOfLowerCaseValues(ALabel aLabel) it.unimi.dsi.fastutil.objects.ObjectSet<ALabel> intgetLowerCaseValue(Label l, ALabel name) it.unimi.dsi.fastutil.objects.ObjectSet<it.unimi.dsi.fastutil.objects.Object2ObjectMap.Entry<ALabel, it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<Label>>> Don't use this set for scanning that requires modifying the internal map; otherwise, this set will become invalid after the first modification.it.unimi.dsi.fastutil.objects.ObjectSet<it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<Label>> getLowerCaseValues(ALabel lowerCaseLabel) it.unimi.dsi.fastutil.objects.Object2ObjectMap.Entry<Label, it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<ALabel>> booleanmergeLowerCaseValue(Label l, ALabel nodeName, int i) Merge a lower label constraint with valueifor the node namenwith labell.voidremoveLowerCaseValue(Label l, ALabel n) voidsetLowerCaseValues(LabeledALabelIntTreeMap lowerCaseValue) Methods inherited from interface BasicCSTNUEdge
clearLowerCaseValue, clearUpperCaseValues, getAllUpperCaseAndLabeledValues, getLabelsOfUpperCaseValues, getLabelsOfUpperCaseValues, getMinUpperCaseValue, getMinUpperCaseValue, getUpperCaseLabels, getUpperCaseValue, getUpperCaseValues, getUpperCaseValues, lowerCaseValueAsString, lowerCaseValueSize, mergeUpperCaseValue, putLowerCaseValue, putUpperCaseValue, removeUpperCaseValue, setUpperCaseValueMap, size, upperCaseValuesAsString, upperCaseValueSizeModifier and TypeMethodDescriptionvoidClears the labeled lowercase values.voidClears all uppercase labeled values.it.unimi.dsi.fastutil.objects.ObjectSet<it.unimi.dsi.fastutil.objects.Object2ObjectMap.Entry<ALabel, it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<Label>>> Don't use this set for scanning that requires modifying the internal map; otherwise, this set will become invalid after the first modification.it.unimi.dsi.fastutil.objects.ObjectSet<Label> it.unimi.dsi.fastutil.objects.ObjectSet<Label> getLabelsOfUpperCaseValues(ALabel aLabel) it.unimi.dsi.fastutil.objects.Object2ObjectMap.Entry<Label, it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<ALabel>> it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<Label> getMinUpperCaseValue(ALabel upperCaseLabel) it.unimi.dsi.fastutil.objects.ObjectSet<ALabel> intgetUpperCaseValue(Label l, ALabel name) it.unimi.dsi.fastutil.objects.ObjectSet<it.unimi.dsi.fastutil.objects.Object2ObjectMap.Entry<ALabel, it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<Label>>> Don't use this set for scanning that requires modifying the internal map; otherwise, this set will become invalid after the first modification.it.unimi.dsi.fastutil.objects.ObjectSet<it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<Label>> getUpperCaseValues(ALabel upperCaseLabel) Don't use this set for scanning that requires modifying the internal map; otherwise, this set will become invalid after the first modification.intbooleanmergeUpperCaseValue(Label l, ALabel nodeName, int i) Merge an upper label constraint with delayifor the node name n with propositional labell.voidputLowerCaseValue(Label l, ALabel nodeName, int i) Set or add a lower label constraint with delay i for the node n with label l.booleanputUpperCaseValue(Label l, ALabel nodeName, int i) Put an upper label constraint with delay i for the node name n with label l.intremoveUpperCaseValue(Label l, ALabel n) Remove the upper label for node name n with label l.voidsetUpperCaseValueMap(LabeledALabelIntTreeMap labeledValue) intsize()intMethods inherited from interface Comparable
compareToMethods inherited from interface Component
clear, equals, equalsByName, getName, hashCode, inNegativeCycle, setInNegativeCycle, setName, toStringModifier and TypeMethodDescriptionvoidclear()Clear all components but the name.booleanDeprecated.booleanA component is assumed to be equal to another if it has the same name.getName()inthashCode()booleanvoidsetInNegativeCycle(boolean inNegativeCycle) Sets true if the edge is in a negative cycleSet the name of the component.toString()Return a string representation of labeled values.Methods inherited from interface CSTNEdge
getLabeledIntMapImplClass, getLabeledValues, getLabelsOfLabeledValues, getMinLabeledValue, getMinValue, getMinValueSubsumedBy, getValue, labeledValuesAsString, mergeLabeledValue, mergeLabeledValue, mergeLabeledValues, putLabeledValue, removeLabeledValue, setLabeledValueMapModifier and TypeMethodDescriptionClass<? extends LabeledIntMap> it.unimi.dsi.fastutil.objects.ObjectSet<it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<Label>> it.unimi.dsi.fastutil.objects.ObjectSet<Label> it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<Label> intintintbooleanmergeLabeledValue(Label l, int i) Merges the labeled value i into the set of labeled values of this edge.booleanmergeLabeledValue(String ls, int i) Wrapper method forCSTNEdge.mergeLabeledValue(Label, int).voidbooleanputLabeledValue(Label l, int i) voidRemove the value labeled by l from the map.voidsetLabeledValueMap(LabeledIntMap inputLabeledValue) Uses inputLabeledValue as an internal labeled value map.Methods inherited from interface Edge
getConstraintType, getRoute, hasSameValues, isContingentEdge, isCSTNEdge, isCSTNPSUEdge, isCSTNUEdge, isEmpty, isOSTNUEdge, isRequirementEdge, isSTNEdge, isSTNUEdge, newInstance, newInstance, newInstance, setConstraintType, setRoute, takeInModifier and TypeMethodDescriptiondefault EdgeRoutegetRoute()booleandefault booleanbooleanThis method is inappropriate here, but it helps to speed up the code.booleanThis method is inappropriate here, but it helps to speed up the code.booleanThis method is inappropriate here, but it helps to speed up the code.booleanisEmpty()booleanThis method is inappropriate here, but it helps to speed up the code.default booleanbooleanThis method is inappropriate here, but it helps to speed up the code.booleanThis method is inappropriate here, but it helps to speed up the code.FactorynewInstance(Edge edge) Any super-interfaces/implementing classes should ensure that such a method has the edge as an argument!newInstance(String name) Factoryvoiddefault voidSets the explicit routing of this edge, ornullto return the edge to automatic.voidA copy by reference of the internal structure of edge e.
-
Method Details
-
clearLowerCaseValues
void clearLowerCaseValues()Clears the labeled lowercase values. -
getAllLowerCaseAndLabeledValues
it.unimi.dsi.fastutil.objects.ObjectSet<it.unimi.dsi.fastutil.objects.Object2ObjectMap.Entry<ALabel, it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<Label>>> getAllLowerCaseAndLabeledValues()Don't use this set for scanning that requires modifying the internal map; otherwise, this set will become invalid after the first modification.- Returns:
- the set of all labeled values and all labeled lower-case ones. The labeled values have an empty ALabel.
-
getLabelsOfLowerCaseValues
-
getLabelsOfLowerCaseValues
it.unimi.dsi.fastutil.objects.ObjectSet<Label> getLabelsOfLowerCaseValues()- Returns:
- the set of all labels associated with all lower-case labeled values;
-
getLowerCaseLabels
it.unimi.dsi.fastutil.objects.ObjectSet<ALabel> getLowerCaseLabels()- Returns:
- the set of all lower-case labels.
-
getLowerCaseValue
- Parameters:
l- aLabelobject.name- aALabelnode name.- Returns:
- the labeled lower-case value.
Constants.INT_NULLif the value does not exist.
-
getLowerCaseValues
it.unimi.dsi.fastutil.objects.ObjectSet<it.unimi.dsi.fastutil.objects.Object2ObjectMap.Entry<ALabel, it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<Label>>> getLowerCaseValues()Don't use this set for scanning that requires modifying the internal map; otherwise, this set will become invalid after the first modification.- Returns:
- the set of all labeled lower-case values.
-
setLowerCaseValues
- Parameters:
lowerCaseValue- the labeled lower case value to use for initializing the current one.
-
getLowerCaseValues
@Nonnull it.unimi.dsi.fastutil.objects.ObjectSet<it.unimi.dsi.fastutil.objects.Object2IntMap.Entry<Label>> getLowerCaseValues(@Nonnull ALabel lowerCaseLabel) - Parameters:
lowerCaseLabel- a non-null lower-case label.- Returns:
- a view of the lower-case values associated with lowerCaseLabel if there are some of them, an empty set otherwise.
-
getMinLowerCaseValue
-
mergeLowerCaseValue
Merge a lower label constraint with valueifor the node namenwith labell.- Parameters:
l- It cannot be null or empty.nodeName- the node name. It cannot be null. It must be the unmodified name of the node.i- It cannot be null.- Returns:
- true if the merge has been successful.
-
removeLowerCaseValue
-