Skip to content

Commit

Permalink
Add support for more span queries (#553)
Browse files Browse the repository at this point in the history
Add support for the `span_containing`, `field_masking_span`, and
`span_within` span queries.

Signed-off-by: mattjmcnaughton <mattjmcnaughton@gmail.com>
  • Loading branch information
mattjmcnaughton authored and honzakral committed Jan 7, 2017
1 parent 917eda2 commit 8b5ef1f
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions elasticsearch_dsl/query.py
Expand Up @@ -233,6 +233,17 @@ class SpanOr(Query):
name = 'span_or'
_params_def = {'clauses': {'type': 'query', 'multi': True}}

class FieldMaskingSpan(Query):
name = 'field_masking_span'
_params_def = {'query': {'type': 'query'}}

class SpanContainining(Query):
name = 'span_containing'
_params_def = {'little': {'type': 'query'}, 'big': {'type': 'query'}}

class SpanWithin(Query):
name = 'span_within'
_params_def = {'little': {'type': 'query'}, 'big': {'type': 'query'}}

# core queries
class Common(Query):
Expand Down

0 comments on commit 8b5ef1f

Please sign in to comment.