public static class QueryOptions.QueryConstraint extends Object implements Annotatable<QueryOptions.QueryConstraint>
| Constructor and Description |
|---|
QueryConstraint()
Zero-argument constructor.
|
QueryConstraint(String name)
Construct with the name of the constraint.
|
| Modifier and Type | Method and Description |
|---|---|
QueryOptions.QueryConstraint |
annotate(String xmlAnnotation)
Adds an annotation and returns the constraint.
|
List<QueryOptions.QueryAnnotation> |
getAnnotations()
Returns the list of annotations on the constraint.
|
String |
getName()
Returns the name of the constraint.
|
<T extends QueryOptions.BaseConstraintItem> |
getSource()
Returns the constrained index.
|
void |
setName(String name)
Specifies the name of the constraint.
|
void |
setSource(ConstraintSource constraintDefinition)
Specifies the constrained index.
|
public QueryConstraint()
public QueryConstraint(String name)
name - the name of the constraintpublic List<QueryOptions.QueryAnnotation> getAnnotations()
getAnnotations in interface Annotatable<QueryOptions.QueryConstraint>public String getName()
public <T extends QueryOptions.BaseConstraintItem> T getSource()
T - the type of sourcepublic void setName(String name)
name - the constraint namepublic void setSource(ConstraintSource constraintDefinition)
constraintDefinition - the index specificationpublic QueryOptions.QueryConstraint annotate(String xmlAnnotation)
annotate in interface Annotatable<QueryOptions.QueryConstraint>Copyright © 2013-2016 MarkLogic Corporation.