summaryrefslogtreecommitdiffstats
path: root/vendor/github.com/blevesearch/bleve/document/indexing_options.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/blevesearch/bleve/document/indexing_options.go')
-rw-r--r--vendor/github.com/blevesearch/bleve/document/indexing_options.go11
1 files changed, 11 insertions, 0 deletions
diff --git a/vendor/github.com/blevesearch/bleve/document/indexing_options.go b/vendor/github.com/blevesearch/bleve/document/indexing_options.go
index 5d562c1de9..44498a8e90 100644
--- a/vendor/github.com/blevesearch/bleve/document/indexing_options.go
+++ b/vendor/github.com/blevesearch/bleve/document/indexing_options.go
@@ -20,6 +20,7 @@ const (
IndexField IndexingOptions = 1 << iota
StoreField
IncludeTermVectors
+ DocValues
)
func (o IndexingOptions) IsIndexed() bool {
@@ -34,6 +35,10 @@ func (o IndexingOptions) IncludeTermVectors() bool {
return o&IncludeTermVectors != 0
}
+func (o IndexingOptions) IncludeDocValues() bool {
+ return o&DocValues != 0
+}
+
func (o IndexingOptions) String() string {
rv := ""
if o.IsIndexed() {
@@ -51,5 +56,11 @@ func (o IndexingOptions) String() string {
}
rv += "TV"
}
+ if o.IncludeDocValues() {
+ if rv != "" {
+ rv += ", "
+ }
+ rv += "DV"
+ }
return rv
}