PlacementConstraint.Visitablepublic static class PlacementConstraint.CardinalityConstraint extends PlacementConstraint.AbstractConstraint
PlacementConstraint.SingleConstraint, where the
target is a set of allocation tags.| Constructor | Description |
|---|---|
CardinalityConstraint(java.lang.String scope,
int minCardinality,
int maxCardinality,
java.util.Set<java.lang.String> allocationTags) |
| Modifier and Type | Method | Description |
|---|---|---|
<T> T |
accept(PlacementConstraint.Visitor<T> visitor) |
Visitor pattern.
|
boolean |
equals(java.lang.Object o) |
|
java.util.Set<java.lang.String> |
getAllocationTags() |
Get the allocation tags of the constraint.
|
int |
getMaxCardinality() |
Get the maximum cardinality of the constraint.
|
int |
getMinCardinality() |
Get the minimum cardinality of the constraint.
|
java.lang.String |
getScope() |
Get the scope of the constraint.
|
int |
hashCode() |
|
java.lang.String |
toString() |
buildpublic CardinalityConstraint(java.lang.String scope,
int minCardinality,
int maxCardinality,
java.util.Set<java.lang.String> allocationTags)
public java.lang.String getScope()
public int getMinCardinality()
public int getMaxCardinality()
public java.util.Set<java.lang.String> getAllocationTags()
public <T> T accept(PlacementConstraint.Visitor<T> visitor)
PlacementConstraint.VisitableT - defines the type that the visitor will use and the return type
of the accept.visitor - visitor to be usedpublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class PlacementConstraint.AbstractConstraintCopyright © 2008–2025 Apache Software Foundation. All rights reserved.