Documentation ¶
Index ¶
- type ConcurrentMap
- type General
- func (r *General) AppendEngineRanks(rank Rank)
- func (r General) ConvertToOutput(salt string) ResultOutput
- func (r General) Description() string
- func (r General) EngineRanks() []Rank
- func (r General) Rank() int
- func (r General) Score() float64
- func (r *General) SetDescription(desc string)
- func (r *General) SetRank(rank int)
- func (r *General) SetScore(score float64)
- func (r General) Shorten(maxTitleLength int, maxDescriptionLength int) Result
- func (r *General) ShrinkEngineRanks()
- func (r General) Title() string
- func (r General) URL() string
- type GeneralScraped
- type ImageFormat
- type Images
- func (r Images) ConvertToOutput(salt string) ResultOutput
- func (r Images) OriginalSize() ImageFormat
- func (r Images) Shorten(maxTitleLength int, maxDescriptionLength int) Result
- func (r Images) SourceName() string
- func (r Images) SourceURL() string
- func (r Images) ThumbnailSize() ImageFormat
- func (r Images) ThumbnailURL() string
- type ImagesOutput
- type ImagesScraped
- type Rank
- type RankScraped
- type Result
- type ResultOutput
- type ResultScraped
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConcurrentMap ¶
func Map ¶
func Map() ConcurrentMap
func (*ConcurrentMap) ExtractResultsAndResponders ¶
func (r *ConcurrentMap) ExtractResultsAndResponders(enabledEnginesLen, titleLen, descLen int) ([]Result, []engines.Name)
type General ¶
type General struct {
// contains filtered or unexported fields
}
func (*General) AppendEngineRanks ¶
func (General) ConvertToOutput ¶
func (r General) ConvertToOutput(salt string) ResultOutput
func (General) Description ¶
func (General) EngineRanks ¶
func (*General) SetDescription ¶
func (General) Shorten ¶
Changes the title and description of the result to be at most N and M characters long respectively.
func (*General) ShrinkEngineRanks ¶
func (r *General) ShrinkEngineRanks()
type GeneralScraped ¶
type GeneralScraped struct {
// contains filtered or unexported fields
}
func ConstructResult ¶
func (GeneralScraped) Convert ¶
func (r GeneralScraped) Convert(erCap int) Result
func (GeneralScraped) Description ¶
func (r GeneralScraped) Description() string
func (GeneralScraped) Rank ¶
func (r GeneralScraped) Rank() RankScraped
func (GeneralScraped) Title ¶
func (r GeneralScraped) Title() string
func (GeneralScraped) URL ¶
func (r GeneralScraped) URL() string
type ImageFormat ¶
type Images ¶
type Images struct {
// contains filtered or unexported fields
}
func (Images) ConvertToOutput ¶
func (r Images) ConvertToOutput(salt string) ResultOutput
func (Images) OriginalSize ¶
func (r Images) OriginalSize() ImageFormat
func (Images) SourceName ¶
func (Images) ThumbnailSize ¶
func (r Images) ThumbnailSize() ImageFormat
func (Images) ThumbnailURL ¶
type ImagesOutput ¶
type ImagesOutput struct {
// contains filtered or unexported fields
}
type ImagesScraped ¶
type ImagesScraped struct { GeneralScraped // contains filtered or unexported fields }
func ConstructImagesResult ¶
func (ImagesScraped) Convert ¶
func (r ImagesScraped) Convert(erCap int) Result
func (ImagesScraped) OriginalSize ¶
func (r ImagesScraped) OriginalSize() scrapedImageFormat
func (ImagesScraped) SourceName ¶
func (r ImagesScraped) SourceName() string
func (ImagesScraped) SourceURL ¶
func (r ImagesScraped) SourceURL() string
func (ImagesScraped) ThumbnailSize ¶
func (r ImagesScraped) ThumbnailSize() scrapedImageFormat
func (ImagesScraped) ThumbnailURL ¶
func (r ImagesScraped) ThumbnailURL() string
type Rank ¶
type Rank struct {
// contains filtered or unexported fields
}
func (Rank) OnPageRank ¶
func (Rank) SearchEngine ¶
func (*Rank) SetOnPageRank ¶
type RankScraped ¶
type RankScraped struct {
// contains filtered or unexported fields
}
func NewRankScraped ¶
func NewRankScraped(searchEngine engines.Name, rank, page, onPageRank int) RankScraped
func (RankScraped) Convert ¶
func (r RankScraped) Convert() Rank
func (RankScraped) OnPageRank ¶
func (r RankScraped) OnPageRank() int
func (RankScraped) Page ¶
func (r RankScraped) Page() int
func (RankScraped) Rank ¶
func (r RankScraped) Rank() int
func (RankScraped) SearchEngine ¶
func (r RankScraped) SearchEngine() engines.Name
type ResultOutput ¶
type ResultOutput interface{}
func ConvertToOutput ¶
func ConvertToOutput(results []Result, salt string) []ResultOutput
type ResultScraped ¶
Source Files ¶
Click to show internal directories.
Click to hide internal directories.