search

package
v0.0.0-...-f44d30b Latest Latest
Warning

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

Go to latest
Published: May 18, 2020 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrRead = errors.New("read error")

Functions

This section is empty.

Types

type CsvWriter

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

func NewCsvWriter

func NewCsvWriter(input chan *Repository, output io.WriteCloser) *CsvWriter

func (*CsvWriter) Handle

func (cw *CsvWriter) Handle() error

type Repository

type Repository struct {
	Description   string `json:"description"`
	Name          string `json:"name"`
	NameWithOwner string `json:"nameWithOwner"`
	URL           string `json:"url"`
	Owner         struct {
		Login string `json:"login"`
	} `json:"owner"`
	ForkCount  int64 `json:"forkCount"`
	Stargazers struct {
		TotalCount int64 `json:"totalCount"`
	} `json:"stargazers"`
	Watchers struct {
		TotalCount int64 `json:"totalCount"`
	} `json:"watchers"`
	HomepageURL string `json:"homepageUrl"`
	LicenseInfo struct {
		Name string `json:"name"`
	} `json:"licenseInfo"`
	MentionableUsers struct {
		TotalCount int64 `json:"totalCount"`
	} `json:"mentionableUsers"`
	MirrorURL       string `json:"mirrorUrl"`
	IsMirror        bool   `json:"isMirror"`
	PrimaryLanguage struct {
		Name string `json:"name"`
	} `json:"primaryLanguage"`
	Parent struct {
		Name string `json:"name"`
	} `json:"parent"`
	CreatedAt time.Time `json:"createdAt"`
	UpdatedAt time.Time `json:"updatedAt"`
}

type RepositoryReader

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

func NewRepositoryReader

func NewRepositoryReader(query string, total int, output chan *Repository, client finderhttp.Client) *RepositoryReader

func (*RepositoryReader) Close

func (sr *RepositoryReader) Close() error

func (*RepositoryReader) Handle

func (sr *RepositoryReader) Handle() error

type Response

type Response struct {
	Data struct {
		Search struct {
			RepositoryCount int `json:"repositoryCount"`
			Edges           []struct {
				Cursor string     `json:"cursor"`
				Node   Repository `json:"node"`
			} `json:"edges"`
		} `json:"search"`
	} `json:"data,omitempty"`
	Message string `json:"message,omitempty"`
	Errors  []struct {
		Type    string `json:"type"`
		Message string `json:"message"`
	} `json:"errors,omitempty"`
}

Jump to

Keyboard shortcuts

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