Client

package
v0.0.0-...-8c873f1 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CrawlClient

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

CrawlClient encapsulates a connection to the Crawler; the RPC methods may be called on it.

func New

func New(serverAddr string, opts ...grpc.DialOption) *CrawlClient

New takes the gRPC connection data, connects to the server, and returns a struct that the client methods can be called on.

func (*CrawlClient) Close

func (c *CrawlClient) Close()

Close exists to allow us to defer the close of the connection.

func (*CrawlClient) CrawlResult

func (c *CrawlClient) CrawlResult(ctx context.Context, in *pb.URLRequest, opts ...grpc.CallOption) (pb.Crawl_CrawlResultClient, error)

CrawlResult allows us to check on the results for a crawl.

func (*CrawlClient) CrawlSite

func (c *CrawlClient) CrawlSite(ctx context.Context, in *pb.URLRequest, opts ...grpc.CallOption) (*pb.URLState, error)

CrawlSite allows us to control the crawl on a specific site.

Jump to

Keyboard shortcuts

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