// Analyzer is the name of the analyzer to use.
326938
func (s *IndicesAnalyzeService) Analyzer(analyzer string) *IndicesAnalyzeService {
	s.request.Analyzer = analyzer
	return s
}
667531
func (q *SimpleQueryStringQuery) AnalyzeWildcard(analyzeWildcard bool) *SimpleQueryStringQuery {
	q.analyzeWildcard = &analyzeWildcard
	return q
}
205852
func (reporterOptions) Logger(logger Logger) ReporterOption {
	return func(r *reporterOptions) {
		r.logger = logger
	}
}
315138
func (q *MoreLikeThisQuery) Analyzer(analyzer string) *MoreLikeThisQuery {
	q.analyzer = analyzer
	return q
}
296825
func (d *diagnosticsCollector) logErr(err error) bool {
	if err != nil {
		d.Logger.Printf("%v", err)
		return true
	}
	return false
}
571055
func (e eval) AnalysisPrinter(input []byte, printAll interface{}) (results []string, err error) {
	var result Result
	if err := json.Unmarshal(input, &result); err != nil {
		return nil, fmt.Errorf("awsCertlint Worker: failed to parse results: err=%v", err)
	}

	// Build results for webview
	for i := range result.FatalErrors {
		results = append(results, fmt.Sprintf(" - Fatal Error: %s", result.FatalErrors[i]))
	}
	for i := range result.Errors {
		results = append(results, fmt.Sprintf(" - Error: %s", result.Errors[i]))
	}
	for i := range result.Warnings {
		results = append(results, fmt.Sprintf(" - Warning: %s", result.Warnings[i]))
	}
	for i := range result.Informational {
		results = append(results, fmt.Sprintf(" - Information: %s", result.Informational[i]))
	}
	for i := range result.Notices {
		results = append(results, fmt.Sprintf(" - Notice: %s", result.Notices[i]))
	}
	for i := range result.Bugs {
		results = append(results, fmt.Sprintf(" - Bug: %s", result.Bugs[i]))
	}

	// Add header and summary as first two lines
	headers := []string{
		"* awslabs/certlint",
	}

	// We only want one summary line, so match in order of severity
	switch true {
	case len(result.FatalErrors) > 0 || len(result.Errors) > 0:
		headers = append(headers, fmt.Sprintf(" - %d errors, %d fatal", len(result.Errors), len(result.FatalErrors)))
	case len(result.Warnings) > 0:
		headers = append(headers, fmt.Sprintf(" - %d warnings found", len(result.Warnings)))
	}

	// Add header(s) as first line, print notice if nothing was found
	results = append(headers, results...)
	if len(results) == 1 {
		results = append(results, " - No messages")
	}
	return results, nil
}
478741
func (s *SearchSource) Rescorer(rescore *Rescore) *SearchSource {
	s.rescores = append(s.rescores, rescore)
	return s
}
857832
func tracer(name string) (string, bool) {
	if tracer, ok := all[name]; ok {
		return tracer, true
	}
	return "", false
}
1266419
func Sampler(sampler jaeger.Sampler) Option {
	return func(c *Options) {
		c.sampler = sampler
	}
}
857612
func (s *CountService) Analyzer(analyzer string) *CountService {
	s.analyzer = analyzer
	return s
}
1326826
func QuerySelector(o *js.Object, sel string) *js.Object {
	return o.Call("querySelector", sel)
}
1073647
func (s *ExplainService) Analyzer(analyzer string) *ExplainService {
	s.analyzer = analyzer
	return s
}
1116226
func (s *MultiTermvectorItem) PerFieldAnalyzer(perFieldAnalyzer map[string]string) *MultiTermvectorItem {
	s.perFieldAnalyzer = perFieldAnalyzer
	return s
}
1267625
func Logger(logger StdLogger) Option {
	return func(c *Client) error {
		c.logger = logger
		return nil
	}
}
556423
func (q *QueryStringQuery) Analyzer(analyzer string) *QueryStringQuery {
	q.analyzer = analyzer
	return q
}
654609
func (s *Static) Wrapper(r echo.RouteRegister) {
	r.Get(s.Path+`/*`, s)
}
428937
func (t Tokenizer) Analyze(input string, mode TokenizeMode) (tokens []Token) {
	la := lattice.New(t.dic, t.udic)
	defer la.Free()
	la.Build(input)
	m := lattice.Normal
	switch mode {
	case Normal:
		m = lattice.Normal
	case Search:
		m = lattice.Search
	case Extended:
		m = lattice.Extended
	}
	la.Forward(m)
	la.Backward(m)
	size := len(la.Output)
	tokens = make([]Token, 0, size)
	for i := range la.Output {
		n := la.Output[size-1-i]
		tok := Token{
			ID:      n.ID,
			Class:   TokenClass(n.Class),
			Start:   n.Start,
			End:     n.Start + utf8.RuneCountInString(n.Surface),
			Surface: n.Surface,
			dic:     t.dic,
			udic:    t.udic,
		}
		if tok.ID == lattice.BosEosID {
			if i == 0 {
				tok.Surface = "BOS"
			} else {
				tok.Surface = "EOS"
			}
		}
		tokens = append(tokens, tok)
	}
	return
}