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

package devrpc

import (
	context "context"
	lnrpc "github.com/lightningnetwork/lnd/lnrpc"
	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

// DevClient is the client API for Dev 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 DevClient interface {
	// ImportGraph imports a ChannelGraph into the graph database. Should only be
	// used for development.
	ImportGraph(ctx context.Context, in *lnrpc.ChannelGraph, opts ...grpc.CallOption) (*ImportGraphResponse, error)
}

type devClient struct {
	cc grpc.ClientConnInterface
}

func NewDevClient(cc grpc.ClientConnInterface) DevClient {
	return &devClient{cc}
}

func (c *devClient) ImportGraph(ctx context.Context, in *lnrpc.ChannelGraph, opts ...grpc.CallOption) (*ImportGraphResponse, error) {
	out := new(ImportGraphResponse)
	err := c.cc.Invoke(ctx, "/devrpc.Dev/ImportGraph", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// DevServer is the server API for Dev service.
// All implementations must embed UnimplementedDevServer
// for forward compatibility
type DevServer interface {
	// ImportGraph imports a ChannelGraph into the graph database. Should only be
	// used for development.
	ImportGraph(context.Context, *lnrpc.ChannelGraph) (*ImportGraphResponse, error)
	mustEmbedUnimplementedDevServer()
}

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

func (UnimplementedDevServer) ImportGraph(context.Context, *lnrpc.ChannelGraph) (*ImportGraphResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method ImportGraph not implemented")
}
func (UnimplementedDevServer) mustEmbedUnimplementedDevServer() {}

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

func RegisterDevServer(s grpc.ServiceRegistrar, srv DevServer) {
	s.RegisterService(&Dev_ServiceDesc, srv)
}

func _Dev_ImportGraph_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(lnrpc.ChannelGraph)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(DevServer).ImportGraph(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/devrpc.Dev/ImportGraph",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(DevServer).ImportGraph(ctx, req.(*lnrpc.ChannelGraph))
	}
	return interceptor(ctx, in, info, handler)
}

// Dev_ServiceDesc is the grpc.ServiceDesc for Dev service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var Dev_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "devrpc.Dev",
	HandlerType: (*DevServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "ImportGraph",
			Handler:    _Dev_ImportGraph_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "devrpc/dev.proto",
}