README

protoc ./search-only.proto --go_out=plugins=grpc:.

Expand ▾ Collapse ▴

Documentation

Overview

    Package search_only is a generated protocol buffer package.

    It is generated from these files:

    search-only.proto
    

    It has these top-level messages:

    Request
    Result
    

    Index

    Constants

    This section is empty.

    Variables

    This section is empty.

    Functions

    func RegisterGoogleServer

    func RegisterGoogleServer(s *grpc.Server, srv GoogleServer)

    Types

    type GoogleClient

    type GoogleClient interface {
    	// Search returns a Google search result for the query.
    	Search(ctx context.Context, in *Request, opts ...grpc.CallOption) (*Result, error)
    }

    func NewGoogleClient

    func NewGoogleClient(cc *grpc.ClientConn) GoogleClient

    type GoogleServer

    type GoogleServer interface {
    	// Search returns a Google search result for the query.
    	Search(context.Context, *Request) (*Result, error)
    }

    type Request

    type Request struct {
    	Query string `protobuf:"bytes,1,opt,name=query" json:"query,omitempty"`
    }

    func (*Request) ProtoMessage

    func (*Request) ProtoMessage()

    func (*Request) Reset

    func (m *Request) Reset()

    func (*Request) String

    func (m *Request) String() string

    type Result

    type Result struct {
    	Title   string `protobuf:"bytes,1,opt,name=title" json:"title,omitempty"`
    	Url     string `protobuf:"bytes,2,opt,name=url" json:"url,omitempty"`
    	Snippet string `protobuf:"bytes,3,opt,name=snippet" json:"snippet,omitempty"`
    }

    func (*Result) ProtoMessage

    func (*Result) ProtoMessage()

    func (*Result) Reset

    func (m *Result) Reset()

    func (*Result) String

    func (m *Result) String() string