Package org.xcsp.parser.entries
Class XConstraints.XSeqbin
- java.lang.Object
-
- org.xcsp.parser.entries.ParsingEntry
-
- org.xcsp.parser.entries.ParsingEntry.CEntry
-
- org.xcsp.parser.entries.XConstraints.CEntryReifiable
-
- org.xcsp.parser.entries.XConstraints.XSeqbin
-
- Enclosing class:
- XConstraints
public static final class XConstraints.XSeqbin extends XConstraints.CEntryReifiable
The class for representing the meta-constraint.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.xcsp.parser.entries.ParsingEntry
ParsingEntry.CEntry, ParsingEntry.OEntry, ParsingEntry.VEntry
-
-
Field Summary
Fields Modifier and Type Field Description XConstraints.CChild
list
The child element- of the meta-constraint.
XConstraints.CChild
number
The child element used for counting the number of violations.XVariables.XVar[][]
scopes
XConstraints.XCtr
template1
The two constraint templates for the meta-constraint.XConstraints.XCtr
template2
The two constraint templates for the meta-constraint.-
Fields inherited from class org.xcsp.parser.entries.XConstraints.CEntryReifiable
reification, softening
-
Fields inherited from class org.xcsp.parser.entries.ParsingEntry
attributes, classes, flags, id, note
-
-
Constructor Summary
Constructors Constructor Description XSeqbin(XConstraints.CChild list, XConstraints.XCtr template1, XConstraints.XCtr template2, XConstraints.CChild number, XVariables.XVar[][] scopes)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LinkedHashSet<XVariables.XVar>
collectVars(LinkedHashSet<XVariables.XVar> set)
Collect the set of variables involved in this element, and add them to the specified set.boolean
subjectToAbstraction()
Returns true iff this element is subject to abstraction, i.e., contains parameters (tokens of the form %i or %...).String
toString()
-
Methods inherited from class org.xcsp.parser.entries.ParsingEntry.CEntry
vars
-
Methods inherited from class org.xcsp.parser.entries.ParsingEntry
copyAttributesOf, getAttributeValue, getAttributeValue, getAttributeValue
-
-
-
-
Field Detail
-
list
public final XConstraints.CChild list
The child element- of the meta-constraint.
-
template1
public final XConstraints.XCtr template1
The two constraint templates for the meta-constraint. The first one is hard, and the second one can be violated.
-
template2
public final XConstraints.XCtr template2
The two constraint templates for the meta-constraint. The first one is hard, and the second one can be violated.
-
number
public final XConstraints.CChild number
The child element used for counting the number of violations. Its value is either an object Long or Var.
-
scopes
public final XVariables.XVar[][] scopes
-
-
Constructor Detail
-
XSeqbin
public XSeqbin(XConstraints.CChild list, XConstraints.XCtr template1, XConstraints.XCtr template2, XConstraints.CChild number, XVariables.XVar[][] scopes)
-
-
Method Detail
-
collectVars
public LinkedHashSet<XVariables.XVar> collectVars(LinkedHashSet<XVariables.XVar> set)
Description copied from class:ParsingEntry.CEntry
Collect the set of variables involved in this element, and add them to the specified set.- Overrides:
collectVars
in classXConstraints.CEntryReifiable
-
subjectToAbstraction
public boolean subjectToAbstraction()
Description copied from class:ParsingEntry.CEntry
Returns true iff this element is subject to abstraction, i.e., contains parameters (tokens of the form %i or %...).- Specified by:
subjectToAbstraction
in classParsingEntry.CEntry
-
toString
public String toString()
- Overrides:
toString
in classXConstraints.CEntryReifiable
-
-