Documentation ¶
Index ¶
- Variables
- func RegisterFetchServer(s grpc.ServiceRegistrar, srv FetchServer)
- type FetchClient
- type FetchServer
- type UnimplementedFetchServer
- func (UnimplementedFetchServer) GetArticle(context.Context, *v1.GetArticleRequest) (*v1.Article, error)
- func (UnimplementedFetchServer) ListArticles(context.Context, *v1.ListArticlesRequest) (*v1.ListArticlesResponse, error)
- func (UnimplementedFetchServer) SearchArticles(context.Context, *v1.SearchArticlesRequest) (*v1.SearchArticlesResponse, error)
- type UnsafeFetchServer
Constants ¶
This section is empty.
Variables ¶
var Fetch_ServiceDesc = grpc.ServiceDesc{ ServiceName: "fetchnews.bbc.v1.Fetch", HandlerType: (*FetchServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "ListArticles", Handler: _Fetch_ListArticles_Handler, }, { MethodName: "GetArticle", Handler: _Fetch_GetArticle_Handler, }, { MethodName: "SearchArticles", Handler: _Fetch_SearchArticles_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "api/fetchnews/bbc/v1/fetchnews.proto", }
Fetch_ServiceDesc is the grpc.ServiceDesc for Fetch service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_api_fetchnews_bbc_v1_fetchnews_proto protoreflect.FileDescriptor
Functions ¶
func RegisterFetchServer ¶ added in v0.0.3
func RegisterFetchServer(s grpc.ServiceRegistrar, srv FetchServer)
Types ¶
type FetchClient ¶ added in v0.0.3
type FetchClient interface { ListArticles(ctx context.Context, in *v1.ListArticlesRequest, opts ...grpc.CallOption) (*v1.ListArticlesResponse, error) GetArticle(ctx context.Context, in *v1.GetArticleRequest, opts ...grpc.CallOption) (*v1.Article, error) SearchArticles(ctx context.Context, in *v1.SearchArticlesRequest, opts ...grpc.CallOption) (*v1.SearchArticlesResponse, error) }
FetchClient is the client API for Fetch service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewFetchClient ¶ added in v0.0.3
func NewFetchClient(cc grpc.ClientConnInterface) FetchClient
type FetchServer ¶ added in v0.0.3
type FetchServer interface { ListArticles(context.Context, *v1.ListArticlesRequest) (*v1.ListArticlesResponse, error) GetArticle(context.Context, *v1.GetArticleRequest) (*v1.Article, error) SearchArticles(context.Context, *v1.SearchArticlesRequest) (*v1.SearchArticlesResponse, error) // contains filtered or unexported methods }
FetchServer is the server API for Fetch service. All implementations must embed UnimplementedFetchServer for forward compatibility
type UnimplementedFetchServer ¶ added in v0.0.3
type UnimplementedFetchServer struct { }
UnimplementedFetchServer must be embedded to have forward compatible implementations.
func (UnimplementedFetchServer) GetArticle ¶ added in v0.0.3
func (UnimplementedFetchServer) GetArticle(context.Context, *v1.GetArticleRequest) (*v1.Article, error)
func (UnimplementedFetchServer) ListArticles ¶ added in v0.0.3
func (UnimplementedFetchServer) ListArticles(context.Context, *v1.ListArticlesRequest) (*v1.ListArticlesResponse, error)
func (UnimplementedFetchServer) SearchArticles ¶ added in v0.0.3
func (UnimplementedFetchServer) SearchArticles(context.Context, *v1.SearchArticlesRequest) (*v1.SearchArticlesResponse, error)
type UnsafeFetchServer ¶ added in v0.0.3
type UnsafeFetchServer interface {
// contains filtered or unexported methods
}
UnsafeFetchServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to FetchServer will result in compilation errors.