asip

package module
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: May 12, 2019 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Overview

Package asip is a Alexa Website Info page parser.

Index

Constants

This section is empty.

Variables

View Source
var ErrNoEnoughData = errors.New("asip: no enough data")

ErrNoEnoughData is returned when a domain is not in top 1M.

Functions

This section is empty.

Types

type Conf

type Conf struct {
	// contains filtered or unexported fields
}

Conf is a asip configuration.

func NewWithClient

func NewWithClient(c *http.Client) *Conf

NewWithClient bootstraps configuration with a customized client.

func (*Conf) SiteInfo

func (c *Conf) SiteInfo(domain string) (*Site, error)

SiteInfo parses webpage of Alexa Website Info with customised parameters.

type Keyword

type Keyword struct {
	Word    string
	Percent string
}

Keyword is a one of the top keywords from search engines.

type Link struct {
	Site string
	Page string
}

Link is a site and page that links to the website.

type Site

type Site struct {
	Title        string
	Description  string
	MainCountry  string
	GlobalRank   uint
	LocalRank    uint
	LinkingTotal uint
	Visitors     []Visitor
	Keywords     []Keyword
	Upstreams    []Upstream
	Related      []string
	Subdomains   []Subdomain
	Categories   []string
	LinksFrom    []Link
}

Site is Website Traffic Statistics from alexa.com.

func SiteInfo

func SiteInfo(domain string) (*Site, error)

SiteInfo parses webpage of Alexa Website Info.

type Subdomain

type Subdomain struct {
	Domain  string
	Percent string
}

Subdomain represent subdomains where visitors go from the site.

type Upstream

type Upstream struct {
	Site    string
	Percent string
}

Upstream sites people visited immediately before this site.

type Visitor

type Visitor struct {
	Country   string
	Percent   string
	LocalRank uint
}

Visitor represents a variety of visitors from a single country.

Jump to

Keyboard shortcuts

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