backends

package
v0.0.0-...-1014ae9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 16, 2019 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Backend

type Backend interface {
	Search(string, string) []*Result
}

Backend specifies which backend should handle the request Currently only rest is supported

type ByStars

type ByStars []*Result

ByStars a type to sort results by stars

func (ByStars) Len

func (s ByStars) Len() int

func (ByStars) Less

func (s ByStars) Less(i, j int) bool

func (ByStars) Swap

func (s ByStars) Swap(i, j int)

type Result

type Result struct {
	RepoID    int64
	RepoName  string
	RepoURL   string
	Stars     int
	FilePaths []string
}

Result hold the result to amount of stars mapping

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL