public interface IDocumentQueryCustomization
Modifier and Type | Method and Description |
---|---|
IDocumentQueryCustomization |
beforeQueryExecution(Action1<IndexQuery> action)
Allow you to modify the index query before it is executed
|
IDocumentQueryCustomization |
highlight(java.lang.String fieldName,
int fragmentLength,
int fragmentCount,
Reference<FieldHighlightings> highlightings)
Adds matches highlighting for the specified field.
|
IDocumentQueryCustomization |
highlight(java.lang.String fieldName,
int fragmentLength,
int fragmentCount,
java.lang.String fragmentsField)
Adds matches highlighting for the specified field.
|
IDocumentQueryCustomization |
include(java.lang.Class<?> targetClass,
com.mysema.query.types.Path<?> path)
Includes the specified path in the query, loading the document specified in that path
|
IDocumentQueryCustomization |
include(com.mysema.query.types.Path<?> path)
Includes the specified path in the query, loading the document specified in that path
|
IDocumentQueryCustomization |
include(java.lang.String path)
Includes the specified path in the query, loading the document specified in that path
|
IDocumentQueryCustomization |
noCaching()
Disables caching for query results.
|
IDocumentQueryCustomization |
noTracking()
Disables tracking for queried entities by Raven's Unit of Work.
|
IDocumentQueryCustomization |
randomOrdering()
Order the search results randomly
|
IDocumentQueryCustomization |
randomOrdering(java.lang.String seed)
Order the search results randomly using the specified seed
this is useful if you want to have repeatable random queries
|
IDocumentQueryCustomization |
relatesToShape(java.lang.String fieldName,
java.lang.String shapeWKT,
SpatialOptions.SpatialRelation rel)
Filter matches based on a given shape - only documents with the shape defined in fieldName that
have a relation rel with the given shapeWKT will be returned
|
IDocumentQueryCustomization |
setAllowMultipleIndexEntriesForSameDocumentToResultTransformer(boolean val)
If set to true, this property will send multiple index entries from the same document (assuming the index project them)
to the result transformer function.
|
IDocumentQueryCustomization |
setHighlighterTags(java.lang.String[] preTags,
java.lang.String[] postTags)
Sets the tags to highlight matches with.
|
IDocumentQueryCustomization |
setHighlighterTags(java.lang.String preTag,
java.lang.String postTag)
Sets the tags to highlight matches with.
|
IDocumentQueryCustomization |
showTimings()
Enables calculation of timings for various parts of a query (Lucene search, loading documents, transforming results).
|
IDocumentQueryCustomization |
sortByDistance()
When using spatial queries, instruct the query to sort by the distance from the origin point
|
IDocumentQueryCustomization |
spatial(java.lang.String fieldName,
SpatialCriteria criteria) |
IDocumentQueryCustomization |
waitForNonStaleResults()
EXPERT ONLY: Instructs the query to wait for non stale results.
|
IDocumentQueryCustomization |
waitForNonStaleResults(long waitTimeout)
EXPERT ONLY: Instructs the query to wait for non stale results for the specified wait timeout.
|
IDocumentQueryCustomization |
waitForNonStaleResultsAsOf(java.util.Date cutOff)
Instructs the query to wait for non stale results as of the cutoff date.
|
IDocumentQueryCustomization |
waitForNonStaleResultsAsOf(java.util.Date cutOff,
long waitTimeout)
Instructs the query to wait for non stale results as of the cutoff date for the specified timeout
|
IDocumentQueryCustomization |
waitForNonStaleResultsAsOf(Etag cutOffEtag)
Instructs the query to wait for non stale results as of the cutoff etag.
|
IDocumentQueryCustomization |
waitForNonStaleResultsAsOf(Etag cutOffEtag,
long waitTimeout)
Instructs the query to wait for non stale results as of the cutoff etag for the specified timeout.
|
IDocumentQueryCustomization |
waitForNonStaleResultsAsOfLastWrite()
Instructs the query to wait for non stale results as of the last write made by any session belonging to the
current document store.
|
IDocumentQueryCustomization |
waitForNonStaleResultsAsOfLastWrite(long waitTimeout)
Instructs the query to wait for non stale results as of the last write made by any session belonging to the
current document store.
|
IDocumentQueryCustomization |
waitForNonStaleResultsAsOfNow()
Instructs the query to wait for non stale results as of now.
|
IDocumentQueryCustomization |
waitForNonStaleResultsAsOfNow(long waitTimeout)
Instructs the query to wait for non stale results as of now for the specified timeout.
|
IDocumentQueryCustomization |
withinRadiusOf(double radius,
double latitude,
double longitude)
Filter matches to be inside the specified radius
|
IDocumentQueryCustomization |
withinRadiusOf(double radius,
double latitude,
double longitude,
SpatialOptions.SpatialUnits radiusUnits)
Filter matches to be inside the specified radius
|
IDocumentQueryCustomization |
withinRadiusOf(java.lang.String fieldName,
double radius,
double latitude,
double longitude)
Filter matches to be inside the specified radius
|
IDocumentQueryCustomization |
withinRadiusOf(java.lang.String fieldName,
double radius,
double latitude,
double longitude,
SpatialOptions.SpatialUnits radiusUnits)
Filter matches to be inside the specified radius
|
IDocumentQueryCustomization waitForNonStaleResultsAsOfLastWrite()
IDocumentQueryCustomization waitForNonStaleResultsAsOfLastWrite(long waitTimeout)
waitTimeout
- IDocumentQueryCustomization waitForNonStaleResultsAsOfNow()
IDocumentQueryCustomization waitForNonStaleResultsAsOfNow(long waitTimeout)
waitTimeout
- timeout in milisIDocumentQueryCustomization waitForNonStaleResultsAsOf(java.util.Date cutOff)
cutOff
- IDocumentQueryCustomization waitForNonStaleResultsAsOf(java.util.Date cutOff, long waitTimeout)
cutOff
- waitTimeout
- timeout in milisIDocumentQueryCustomization waitForNonStaleResultsAsOf(Etag cutOffEtag)
cutOffEtag
- IDocumentQueryCustomization waitForNonStaleResultsAsOf(Etag cutOffEtag, long waitTimeout)
cutOffEtag
- waitTimeout
- IDocumentQueryCustomization waitForNonStaleResults()
IDocumentQueryCustomization include(com.mysema.query.types.Path<?> path)
path
- IDocumentQueryCustomization include(java.lang.String path)
path
- IDocumentQueryCustomization include(java.lang.Class<?> targetClass, com.mysema.query.types.Path<?> path)
path
- IDocumentQueryCustomization waitForNonStaleResults(long waitTimeout)
waitTimeout
- IDocumentQueryCustomization withinRadiusOf(double radius, double latitude, double longitude)
radius
- latitude
- longitude
- IDocumentQueryCustomization withinRadiusOf(java.lang.String fieldName, double radius, double latitude, double longitude)
fieldName
- radius
- latitude
- longitude
- IDocumentQueryCustomization withinRadiusOf(double radius, double latitude, double longitude, SpatialOptions.SpatialUnits radiusUnits)
radius
- latitude
- longitude
- radiusUnits
- IDocumentQueryCustomization withinRadiusOf(java.lang.String fieldName, double radius, double latitude, double longitude, SpatialOptions.SpatialUnits radiusUnits)
fieldName
- radius
- latitude
- longitude
- radiusUnits
- IDocumentQueryCustomization relatesToShape(java.lang.String fieldName, java.lang.String shapeWKT, SpatialOptions.SpatialRelation rel)
fieldName
- The name of the field containing the shape to use for filteringshapeWKT
- The query shaperel
- Spatial relation to checkIDocumentQueryCustomization spatial(java.lang.String fieldName, SpatialCriteria criteria)
IDocumentQueryCustomization sortByDistance()
IDocumentQueryCustomization randomOrdering()
IDocumentQueryCustomization randomOrdering(java.lang.String seed)
seed
- IDocumentQueryCustomization beforeQueryExecution(Action1<IndexQuery> action)
action
- IDocumentQueryCustomization highlight(java.lang.String fieldName, int fragmentLength, int fragmentCount, java.lang.String fragmentsField)
fieldName
- The field name to highlight.fragmentLength
- The fragment length.fragmentCount
- The maximum number of fragments for the field.fragmentsField
- The field in query results item to put highlightings into.IDocumentQueryCustomization highlight(java.lang.String fieldName, int fragmentLength, int fragmentCount, Reference<FieldHighlightings> highlightings)
fieldName
- The field name to highlight.fragmentLength
- The fragment length.fragmentCount
- The maximum number of fragments for the field.highlightings
- Field highlightings for all results.IDocumentQueryCustomization setAllowMultipleIndexEntriesForSameDocumentToResultTransformer(boolean val)
val
- IDocumentQueryCustomization setHighlighterTags(java.lang.String preTag, java.lang.String postTag)
preTag
- Prefix tag.postTag
- Postfix tag.IDocumentQueryCustomization setHighlighterTags(java.lang.String[] preTags, java.lang.String[] postTags)
preTags
- Prefix tags.postTags
- Postfix tags.IDocumentQueryCustomization noTracking()
IDocumentQueryCustomization noCaching()
IDocumentQueryCustomization showTimings()
Copyright © 2014. All Rights Reserved.