public class CMAConstraint
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
CMAConstraint.Equals
Create an equals deciding whether the path to a field constraints a given value.
|
static class |
CMAConstraint.FieldKeyPath
Define a path to a field.
|
Constructor and Description |
---|
CMAConstraint() |
Modifier and Type | Method and Description |
---|---|
CMAConstraint[] |
getAnd()
Which constraints have to be all satisfied?
|
CMAConstraint.Equals |
getEquals()
Which condition has to be satisfied to satisfy this constraint?
|
CMAConstraint.FieldKeyPath[] |
getFieldKeyPaths()
On which fieldKeyPaths does this constraint act?
|
CMAConstraint[] |
getNot()
Which constraints do need to be not satisfied?
|
CMAConstraint[] |
getOr()
Which array of constraints where only one needs to be satisfied?
|
CMAConstraint |
setAnd(CMAConstraint... and)
Set a new constraints which have all to be satisfied.
|
CMAConstraint |
setEquals(CMAConstraint.Equals equals)
Update the condition to be satisfied to satisfy this constraint.
|
CMAConstraint |
setFieldKeyPaths(CMAConstraint.FieldKeyPath... fieldKeyPaths)
Set the array of fieldKeyPaths to be used.
|
CMAConstraint |
setNot(CMAConstraint... not)
Set a new array of constraints which must not be satisfied.
|
CMAConstraint |
setOr(CMAConstraint... or)
Set a new list of constraints where only one be satisfied.
|
java.lang.String |
toString() |
public CMAConstraint[] getAnd()
public CMAConstraint setAnd(CMAConstraint... and)
and
- constraints to be satisfied.public CMAConstraint[] getOr()
public CMAConstraint setOr(CMAConstraint... or)
or
- constraints of which one needs to be satisfied.public CMAConstraint[] getNot()
This effectively negates all the constraints.
public CMAConstraint setNot(CMAConstraint... not)
not
- a constraint not to be true.public CMAConstraint.Equals getEquals()
public CMAConstraint setEquals(CMAConstraint.Equals equals)
equals
- the equals constraint.public CMAConstraint.FieldKeyPath[] getFieldKeyPaths()
public CMAConstraint setFieldKeyPaths(CMAConstraint.FieldKeyPath... fieldKeyPaths)
fieldKeyPaths
- the new fieldKeyPaths to be set.public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2019 Contentful, GmbH.. All Rights Reserved.