// Code generated by protoc-gen-go-grpc. DO NOT EDIT.

package protocol

import (
	context "context"
	grpc "google.golang.org/grpc"
	codes "google.golang.org/grpc/codes"
	status "google.golang.org/grpc/status"
)

// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
// Requires gRPC-Go v1.32.0 or later.
const _ = grpc.SupportPackageIsVersion7

// RepoOwnersClient is the client API for RepoOwners 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.
type RepoOwnersClient interface {
	FindApproverOwnersForFile(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*Path, error)
	FindReviewersOwnersForFile(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*Path, error)
	LeafApprovers(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*Owners, error)
	LeafReviewers(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*Owners, error)
	Approvers(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*Owners, error)
	Reviewers(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*Owners, error)
	IsNoParentOwners(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*NoParentOwners, error)
	AllReviewers(ctx context.Context, in *Branch, opts ...grpc.CallOption) (*Owners, error)
	TopLevelApprovers(ctx context.Context, in *Branch, opts ...grpc.CallOption) (*Owners, error)
}

type repoOwnersClient struct {
	cc grpc.ClientConnInterface
}

func NewRepoOwnersClient(cc grpc.ClientConnInterface) RepoOwnersClient {
	return &repoOwnersClient{cc}
}

func (c *repoOwnersClient) FindApproverOwnersForFile(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*Path, error) {
	out := new(Path)
	err := c.cc.Invoke(ctx, "/repoOwners.RepoOwners/FindApproverOwnersForFile", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *repoOwnersClient) FindReviewersOwnersForFile(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*Path, error) {
	out := new(Path)
	err := c.cc.Invoke(ctx, "/repoOwners.RepoOwners/FindReviewersOwnersForFile", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *repoOwnersClient) LeafApprovers(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*Owners, error) {
	out := new(Owners)
	err := c.cc.Invoke(ctx, "/repoOwners.RepoOwners/LeafApprovers", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *repoOwnersClient) LeafReviewers(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*Owners, error) {
	out := new(Owners)
	err := c.cc.Invoke(ctx, "/repoOwners.RepoOwners/LeafReviewers", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *repoOwnersClient) Approvers(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*Owners, error) {
	out := new(Owners)
	err := c.cc.Invoke(ctx, "/repoOwners.RepoOwners/Approvers", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *repoOwnersClient) Reviewers(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*Owners, error) {
	out := new(Owners)
	err := c.cc.Invoke(ctx, "/repoOwners.RepoOwners/Reviewers", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *repoOwnersClient) IsNoParentOwners(ctx context.Context, in *RepoFilePath, opts ...grpc.CallOption) (*NoParentOwners, error) {
	out := new(NoParentOwners)
	err := c.cc.Invoke(ctx, "/repoOwners.RepoOwners/IsNoParentOwners", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *repoOwnersClient) AllReviewers(ctx context.Context, in *Branch, opts ...grpc.CallOption) (*Owners, error) {
	out := new(Owners)
	err := c.cc.Invoke(ctx, "/repoOwners.RepoOwners/AllReviewers", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *repoOwnersClient) TopLevelApprovers(ctx context.Context, in *Branch, opts ...grpc.CallOption) (*Owners, error) {
	out := new(Owners)
	err := c.cc.Invoke(ctx, "/repoOwners.RepoOwners/TopLevelApprovers", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// RepoOwnersServer is the server API for RepoOwners service.
// All implementations must embed UnimplementedRepoOwnersServer
// for forward compatibility
type RepoOwnersServer interface {
	FindApproverOwnersForFile(context.Context, *RepoFilePath) (*Path, error)
	FindReviewersOwnersForFile(context.Context, *RepoFilePath) (*Path, error)
	LeafApprovers(context.Context, *RepoFilePath) (*Owners, error)
	LeafReviewers(context.Context, *RepoFilePath) (*Owners, error)
	Approvers(context.Context, *RepoFilePath) (*Owners, error)
	Reviewers(context.Context, *RepoFilePath) (*Owners, error)
	IsNoParentOwners(context.Context, *RepoFilePath) (*NoParentOwners, error)
	AllReviewers(context.Context, *Branch) (*Owners, error)
	TopLevelApprovers(context.Context, *Branch) (*Owners, error)
	mustEmbedUnimplementedRepoOwnersServer()
}

// UnimplementedRepoOwnersServer must be embedded to have forward compatible implementations.
type UnimplementedRepoOwnersServer struct {
}

func (UnimplementedRepoOwnersServer) FindApproverOwnersForFile(context.Context, *RepoFilePath) (*Path, error) {
	return nil, status.Errorf(codes.Unimplemented, "method FindApproverOwnersForFile not implemented")
}
func (UnimplementedRepoOwnersServer) FindReviewersOwnersForFile(context.Context, *RepoFilePath) (*Path, error) {
	return nil, status.Errorf(codes.Unimplemented, "method FindReviewersOwnersForFile not implemented")
}
func (UnimplementedRepoOwnersServer) LeafApprovers(context.Context, *RepoFilePath) (*Owners, error) {
	return nil, status.Errorf(codes.Unimplemented, "method LeafApprovers not implemented")
}
func (UnimplementedRepoOwnersServer) LeafReviewers(context.Context, *RepoFilePath) (*Owners, error) {
	return nil, status.Errorf(codes.Unimplemented, "method LeafReviewers not implemented")
}
func (UnimplementedRepoOwnersServer) Approvers(context.Context, *RepoFilePath) (*Owners, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Approvers not implemented")
}
func (UnimplementedRepoOwnersServer) Reviewers(context.Context, *RepoFilePath) (*Owners, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Reviewers not implemented")
}
func (UnimplementedRepoOwnersServer) IsNoParentOwners(context.Context, *RepoFilePath) (*NoParentOwners, error) {
	return nil, status.Errorf(codes.Unimplemented, "method IsNoParentOwners not implemented")
}
func (UnimplementedRepoOwnersServer) AllReviewers(context.Context, *Branch) (*Owners, error) {
	return nil, status.Errorf(codes.Unimplemented, "method AllReviewers not implemented")
}
func (UnimplementedRepoOwnersServer) TopLevelApprovers(context.Context, *Branch) (*Owners, error) {
	return nil, status.Errorf(codes.Unimplemented, "method TopLevelApprovers not implemented")
}
func (UnimplementedRepoOwnersServer) mustEmbedUnimplementedRepoOwnersServer() {}

// UnsafeRepoOwnersServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to RepoOwnersServer will
// result in compilation errors.
type UnsafeRepoOwnersServer interface {
	mustEmbedUnimplementedRepoOwnersServer()
}

func RegisterRepoOwnersServer(s grpc.ServiceRegistrar, srv RepoOwnersServer) {
	s.RegisterService(&RepoOwners_ServiceDesc, srv)
}

func _RepoOwners_FindApproverOwnersForFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(RepoFilePath)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(RepoOwnersServer).FindApproverOwnersForFile(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/repoOwners.RepoOwners/FindApproverOwnersForFile",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(RepoOwnersServer).FindApproverOwnersForFile(ctx, req.(*RepoFilePath))
	}
	return interceptor(ctx, in, info, handler)
}

func _RepoOwners_FindReviewersOwnersForFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(RepoFilePath)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(RepoOwnersServer).FindReviewersOwnersForFile(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/repoOwners.RepoOwners/FindReviewersOwnersForFile",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(RepoOwnersServer).FindReviewersOwnersForFile(ctx, req.(*RepoFilePath))
	}
	return interceptor(ctx, in, info, handler)
}

func _RepoOwners_LeafApprovers_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(RepoFilePath)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(RepoOwnersServer).LeafApprovers(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/repoOwners.RepoOwners/LeafApprovers",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(RepoOwnersServer).LeafApprovers(ctx, req.(*RepoFilePath))
	}
	return interceptor(ctx, in, info, handler)
}

func _RepoOwners_LeafReviewers_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(RepoFilePath)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(RepoOwnersServer).LeafReviewers(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/repoOwners.RepoOwners/LeafReviewers",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(RepoOwnersServer).LeafReviewers(ctx, req.(*RepoFilePath))
	}
	return interceptor(ctx, in, info, handler)
}

func _RepoOwners_Approvers_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(RepoFilePath)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(RepoOwnersServer).Approvers(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/repoOwners.RepoOwners/Approvers",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(RepoOwnersServer).Approvers(ctx, req.(*RepoFilePath))
	}
	return interceptor(ctx, in, info, handler)
}

func _RepoOwners_Reviewers_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(RepoFilePath)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(RepoOwnersServer).Reviewers(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/repoOwners.RepoOwners/Reviewers",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(RepoOwnersServer).Reviewers(ctx, req.(*RepoFilePath))
	}
	return interceptor(ctx, in, info, handler)
}

func _RepoOwners_IsNoParentOwners_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(RepoFilePath)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(RepoOwnersServer).IsNoParentOwners(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/repoOwners.RepoOwners/IsNoParentOwners",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(RepoOwnersServer).IsNoParentOwners(ctx, req.(*RepoFilePath))
	}
	return interceptor(ctx, in, info, handler)
}

func _RepoOwners_AllReviewers_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(Branch)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(RepoOwnersServer).AllReviewers(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/repoOwners.RepoOwners/AllReviewers",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(RepoOwnersServer).AllReviewers(ctx, req.(*Branch))
	}
	return interceptor(ctx, in, info, handler)
}

func _RepoOwners_TopLevelApprovers_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(Branch)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(RepoOwnersServer).TopLevelApprovers(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/repoOwners.RepoOwners/TopLevelApprovers",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(RepoOwnersServer).TopLevelApprovers(ctx, req.(*Branch))
	}
	return interceptor(ctx, in, info, handler)
}

// RepoOwners_ServiceDesc is the grpc.ServiceDesc for RepoOwners service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var RepoOwners_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "repoOwners.RepoOwners",
	HandlerType: (*RepoOwnersServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "FindApproverOwnersForFile",
			Handler:    _RepoOwners_FindApproverOwnersForFile_Handler,
		},
		{
			MethodName: "FindReviewersOwnersForFile",
			Handler:    _RepoOwners_FindReviewersOwnersForFile_Handler,
		},
		{
			MethodName: "LeafApprovers",
			Handler:    _RepoOwners_LeafApprovers_Handler,
		},
		{
			MethodName: "LeafReviewers",
			Handler:    _RepoOwners_LeafReviewers_Handler,
		},
		{
			MethodName: "Approvers",
			Handler:    _RepoOwners_Approvers_Handler,
		},
		{
			MethodName: "Reviewers",
			Handler:    _RepoOwners_Reviewers_Handler,
		},
		{
			MethodName: "IsNoParentOwners",
			Handler:    _RepoOwners_IsNoParentOwners_Handler,
		},
		{
			MethodName: "AllReviewers",
			Handler:    _RepoOwners_AllReviewers_Handler,
		},
		{
			MethodName: "TopLevelApprovers",
			Handler:    _RepoOwners_TopLevelApprovers_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "repo_owners.proto",
}
