All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.sksamuel.elastic4s.api.AnalyzerApi.scala Maven / Gradle / Ivy

The newest version!
package com.sksamuel.elastic4s.api

import com.sksamuel.elastic4s.requests.analyzers.{CustomAnalyzerDefinition, PatternAnalyzerDefinition, SnowballAnalyzerDefinition, StandardAnalyzerDefinition, StopAnalyzerDefinition, TokenFilter, Tokenizer}

@deprecated("use new analysis package", "7.7.0")
trait AnalyzerApi {

  @deprecated("use new analysis package", "7.0.1")
  def stopAnalyzer(name: String): StopAnalyzerDefinition = StopAnalyzerDefinition(name)

  @deprecated("use new analysis package", "7.0.1")
  def standardAnalyzer(name: String): StandardAnalyzerDefinition = StandardAnalyzerDefinition(name)

  @deprecated("use new analysis package", "7.0.1")
  def patternAnalyzer(name: String, regex: String): PatternAnalyzerDefinition = PatternAnalyzerDefinition(name, regex)

  @deprecated("use new analysis package", "7.0.1")
  def snowballAnalyzer(name: String): SnowballAnalyzerDefinition = SnowballAnalyzerDefinition(name)

  @deprecated("use new analysis package", "7.0.1")
  def customAnalyzer(name: String, tokenizer: Tokenizer): CustomAnalyzerDefinition =
    CustomAnalyzerDefinition(name, tokenizer)

  @deprecated("use new analysis package", "7.0.1")
  def customAnalyzer(name: String,
                     tokenizer: Tokenizer,
                     filter: TokenFilter,
                     rest: TokenFilter*): CustomAnalyzerDefinition =
    CustomAnalyzerDefinition(name, tokenizer, filter +: rest)
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy