Class PipelineAggregationBuilder.ValidationContext
java.lang.Object
org.elasticsearch.search.aggregations.PipelineAggregationBuilder.ValidationContext
- Enclosing class:
- PipelineAggregationBuilder
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Add a validation error about thebuckets_path
.void
addValidationError(String error)
Add a validation error to this context.forInsideTree(AggregationBuilder parent, ActionRequestValidationException validationFailuresSoFar)
Build the context for a node inside the aggregation tree.forTreeRoot(Collection<AggregationBuilder> siblingAggregations, Collection<PipelineAggregationBuilder> siblingPipelineAggregations, ActionRequestValidationException validationFailuresSoFar)
Build the context for the root of the aggregation tree.abstract Collection<AggregationBuilder>
Aggregations that are siblings to the aggregation being validated.abstract Collection<PipelineAggregationBuilder>
Pipeline aggregations that are siblings to the aggregation being validated.The validation exception, if there is one.abstract void
validateHasParent(String type, String name)
Validates that there is a parent aggregation.abstract void
validateParentAggSequentiallyOrdered(String type, String name)
Validates that the parent is sequentially ordered.
-
Method Details
-
forTreeRoot
public static PipelineAggregationBuilder.ValidationContext forTreeRoot(Collection<AggregationBuilder> siblingAggregations, Collection<PipelineAggregationBuilder> siblingPipelineAggregations, ActionRequestValidationException validationFailuresSoFar)Build the context for the root of the aggregation tree. -
forInsideTree
public static PipelineAggregationBuilder.ValidationContext forInsideTree(AggregationBuilder parent, ActionRequestValidationException validationFailuresSoFar)Build the context for a node inside the aggregation tree. -
getSiblingAggregations
Aggregations that are siblings to the aggregation being validated. -
getSiblingPipelineAggregations
Pipeline aggregations that are siblings to the aggregation being validated. -
addValidationError
Add a validation error to this context. All validation errors are accumulated in a list and, if there are any, the request is not executed and the entire list is returned as the error response. -
addBucketPathValidationError
Add a validation error about thebuckets_path
. -
validateHasParent
Validates that there is a parent aggregation. -
validateParentAggSequentiallyOrdered
Validates that the parent is sequentially ordered. -
getValidationException
The validation exception, if there is one. It'll benull
if the context wasn't provided with any exception on creation and none were added.
-