articles_fr.go 623 B

12345678910111213141516171819202122232425262728293031323334353637
  1. package fr
  2. import (
  3. "github.com/couchbaselabs/bleve/analysis"
  4. "github.com/couchbaselabs/bleve/registry"
  5. )
  6. const ArticlesName = "articles_fr"
  7. // this content was obtained from:
  8. // lucene-4.7.2/analysis/common/src/resources/org/apache/lucene/analysis
  9. var FrenchArticles = []byte(`
  10. l
  11. m
  12. t
  13. qu
  14. n
  15. s
  16. j
  17. d
  18. c
  19. jusqu
  20. quoiqu
  21. lorsqu
  22. puisqu
  23. `)
  24. func ArticlesTokenMapConstructor(config map[string]interface{}, cache *registry.Cache) (analysis.TokenMap, error) {
  25. rv := analysis.NewTokenMap()
  26. err := rv.LoadBytes(FrenchArticles)
  27. return rv, err
  28. }
  29. func init() {
  30. registry.RegisterTokenMap(ArticlesName, ArticlesTokenMapConstructor)
  31. }