public class HitPropertyDocumentStoredField extends HitProperty
contexts, hits, logger, reverse
Constructor and Description |
---|
HitPropertyDocumentStoredField(BlackLabIndex index,
String fieldName) |
HitPropertyDocumentStoredField(BlackLabIndex index,
String fieldName,
String friendlyName) |
Modifier and Type | Method and Description |
---|---|
int |
compare(Hit a,
Hit b)
Compares two hits on this property.
|
HitProperty |
copyWith(Results<Hit> newHits,
Contexts contexts,
boolean invert)
Produce a copy of this HitProperty object with a different Hits and Contexts
object.
|
DocProperty |
docPropsOnly()
Return only the DocProperty portion (if any) of this HitProperty, if any.
|
PropertyValue |
docPropValues(PropertyValue value)
Return only the values corresponding to DocProperty's of the given PropertyValue, if any.
|
boolean |
equals(Object obj) |
PropertyValueString |
get(Hit result)
Get the property value for a specific result.
|
int |
hashCode() |
String |
name()
Get the name of the property
|
String |
serialize()
Serialize this HitProperty so we can deserialize it later (to pass it via
URL, for example)
|
copyWith, deserialize, deserialize, isReverse, needsContext, needsContextSize, reverse, serializeReverse, setContextIndices, setContexts, sortDescendingByDefault, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
ignoreSensitivity, isCompound, propNames, props
comparing, comparing, comparingDouble, comparingInt, comparingLong, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
public HitPropertyDocumentStoredField(BlackLabIndex index, String fieldName, String friendlyName)
public HitPropertyDocumentStoredField(BlackLabIndex index, String fieldName)
public HitProperty copyWith(Results<Hit> newHits, Contexts contexts, boolean invert)
HitProperty
copyWith
in class HitProperty
newHits
- new Hits to use, or null to inheritcontexts
- new Contexts to use, or null to inheritinvert
- true if we should invert the previous sort order; false to keep it the samepublic PropertyValueString get(Hit result)
ResultProperty
get
in interface ResultProperty<Hit>
get
in class HitProperty
result
- result to get property value forpublic int compare(Hit a, Hit b)
ResultProperty
compare
in interface Comparator<Hit>
compare
in interface ResultProperty<Hit>
compare
in class HitProperty
a
- first hitb
- second hitpublic String name()
ResultProperty
name
in interface ResultProperty<Hit>
name
in class HitProperty
public String serialize()
ResultProperty
serialize
in interface ResultProperty<Hit>
serialize
in class HitProperty
public int hashCode()
hashCode
in interface ResultProperty<Hit>
hashCode
in class HitProperty
public boolean equals(Object obj)
equals
in interface Comparator<Hit>
equals
in interface ResultProperty<Hit>
equals
in class HitProperty
public DocProperty docPropsOnly()
HitProperty
docPropsOnly
in class HitProperty
public PropertyValue docPropValues(PropertyValue value)
HitProperty
docPropValues
in class HitProperty
value
- value to extract the values corresponding to DocProperty's fromCopyright © 2020 Instituut voor Nederlandse Taal (INT). All rights reserved.