// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.11
// 	protoc        v6.33.1
// source: downloader/downloader.proto

package downloaderproto

import (
	typesproto "github.com/erigontech/erigon/node/gointerfaces/typesproto"
	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
	emptypb "google.golang.org/protobuf/types/known/emptypb"
	reflect "reflect"
	sync "sync"
	unsafe "unsafe"
)

const (
	// Verify that this generated code is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
	// Verify that runtime/protoimpl is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)

type SeedItem struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Path          string                 `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *SeedItem) Reset() {
	*x = SeedItem{}
	mi := &file_downloader_downloader_proto_msgTypes[0]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *SeedItem) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*SeedItem) ProtoMessage() {}

func (x *SeedItem) ProtoReflect() protoreflect.Message {
	mi := &file_downloader_downloader_proto_msgTypes[0]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use SeedItem.ProtoReflect.Descriptor instead.
func (*SeedItem) Descriptor() ([]byte, []int) {
	return file_downloader_downloader_proto_rawDescGZIP(), []int{0}
}

func (x *SeedItem) GetPath() string {
	if x != nil {
		return x.Path
	}
	return ""
}

type SeedRequest struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Paths         []string               `protobuf:"bytes,1,rep,name=paths,proto3" json:"paths,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *SeedRequest) Reset() {
	*x = SeedRequest{}
	mi := &file_downloader_downloader_proto_msgTypes[1]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *SeedRequest) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*SeedRequest) ProtoMessage() {}

func (x *SeedRequest) ProtoReflect() protoreflect.Message {
	mi := &file_downloader_downloader_proto_msgTypes[1]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use SeedRequest.ProtoReflect.Descriptor instead.
func (*SeedRequest) Descriptor() ([]byte, []int) {
	return file_downloader_downloader_proto_rawDescGZIP(), []int{1}
}

func (x *SeedRequest) GetPaths() []string {
	if x != nil {
		return x.Paths
	}
	return nil
}

// DownloadItem:
// - if Erigon created new snapshot and want seed it
// - if Erigon wnat download files - it fills only "torrent_hash" field
type DownloadItem struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Path          string                 `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
	TorrentHash   *typesproto.H160       `protobuf:"bytes,2,opt,name=torrent_hash,json=torrentHash,proto3" json:"torrent_hash,omitempty"` // will be resolved as magnet link
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *DownloadItem) Reset() {
	*x = DownloadItem{}
	mi := &file_downloader_downloader_proto_msgTypes[2]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *DownloadItem) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*DownloadItem) ProtoMessage() {}

func (x *DownloadItem) ProtoReflect() protoreflect.Message {
	mi := &file_downloader_downloader_proto_msgTypes[2]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use DownloadItem.ProtoReflect.Descriptor instead.
func (*DownloadItem) Descriptor() ([]byte, []int) {
	return file_downloader_downloader_proto_rawDescGZIP(), []int{2}
}

func (x *DownloadItem) GetPath() string {
	if x != nil {
		return x.Path
	}
	return ""
}

func (x *DownloadItem) GetTorrentHash() *typesproto.H160 {
	if x != nil {
		return x.TorrentHash
	}
	return nil
}

type DownloadRequest struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Items         []*DownloadItem        `protobuf:"bytes,1,rep,name=items,proto3" json:"items,omitempty"`
	LogTarget     string                 `protobuf:"bytes,2,opt,name=log_target,json=logTarget,proto3" json:"log_target,omitempty"` // Why we requested this.
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *DownloadRequest) Reset() {
	*x = DownloadRequest{}
	mi := &file_downloader_downloader_proto_msgTypes[3]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *DownloadRequest) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*DownloadRequest) ProtoMessage() {}

func (x *DownloadRequest) ProtoReflect() protoreflect.Message {
	mi := &file_downloader_downloader_proto_msgTypes[3]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use DownloadRequest.ProtoReflect.Descriptor instead.
func (*DownloadRequest) Descriptor() ([]byte, []int) {
	return file_downloader_downloader_proto_rawDescGZIP(), []int{3}
}

func (x *DownloadRequest) GetItems() []*DownloadItem {
	if x != nil {
		return x.Items
	}
	return nil
}

func (x *DownloadRequest) GetLogTarget() string {
	if x != nil {
		return x.LogTarget
	}
	return ""
}

// DeleteRequest: stop seeding, delete file, delete .torrent
type DeleteRequest struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Paths         []string               `protobuf:"bytes,1,rep,name=paths,proto3" json:"paths,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *DeleteRequest) Reset() {
	*x = DeleteRequest{}
	mi := &file_downloader_downloader_proto_msgTypes[4]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *DeleteRequest) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*DeleteRequest) ProtoMessage() {}

func (x *DeleteRequest) ProtoReflect() protoreflect.Message {
	mi := &file_downloader_downloader_proto_msgTypes[4]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use DeleteRequest.ProtoReflect.Descriptor instead.
func (*DeleteRequest) Descriptor() ([]byte, []int) {
	return file_downloader_downloader_proto_rawDescGZIP(), []int{4}
}

func (x *DeleteRequest) GetPaths() []string {
	if x != nil {
		return x.Paths
	}
	return nil
}

var File_downloader_downloader_proto protoreflect.FileDescriptor

const file_downloader_downloader_proto_rawDesc = "" +
	"\n" +
	"\x1bdownloader/downloader.proto\x12\n" +
	"downloader\x1a\x1bgoogle/protobuf/empty.proto\x1a\x11types/types.proto\"\x1e\n" +
	"\bSeedItem\x12\x12\n" +
	"\x04path\x18\x01 \x01(\tR\x04path\"#\n" +
	"\vSeedRequest\x12\x14\n" +
	"\x05paths\x18\x01 \x03(\tR\x05paths\"R\n" +
	"\fDownloadItem\x12\x12\n" +
	"\x04path\x18\x01 \x01(\tR\x04path\x12.\n" +
	"\ftorrent_hash\x18\x02 \x01(\v2\v.types.H160R\vtorrentHash\"`\n" +
	"\x0fDownloadRequest\x12.\n" +
	"\x05items\x18\x01 \x03(\v2\x18.downloader.DownloadItemR\x05items\x12\x1d\n" +
	"\n" +
	"log_target\x18\x02 \x01(\tR\tlogTarget\"%\n" +
	"\rDeleteRequest\x12\x14\n" +
	"\x05paths\x18\x01 \x03(\tR\x05paths2\xc9\x01\n" +
	"\n" +
	"Downloader\x129\n" +
	"\x04Seed\x12\x17.downloader.SeedRequest\x1a\x16.google.protobuf.Empty\"\x00\x12A\n" +
	"\bDownload\x12\x1b.downloader.DownloadRequest\x1a\x16.google.protobuf.Empty\"\x00\x12=\n" +
	"\x06Delete\x12\x19.downloader.DeleteRequest\x1a\x16.google.protobuf.Empty\"\x00B\x1eZ\x1c./downloader;downloaderprotob\x06proto3"

var (
	file_downloader_downloader_proto_rawDescOnce sync.Once
	file_downloader_downloader_proto_rawDescData []byte
)

func file_downloader_downloader_proto_rawDescGZIP() []byte {
	file_downloader_downloader_proto_rawDescOnce.Do(func() {
		file_downloader_downloader_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_downloader_downloader_proto_rawDesc), len(file_downloader_downloader_proto_rawDesc)))
	})
	return file_downloader_downloader_proto_rawDescData
}

var file_downloader_downloader_proto_msgTypes = make([]protoimpl.MessageInfo, 5)
var file_downloader_downloader_proto_goTypes = []any{
	(*SeedItem)(nil),        // 0: downloader.SeedItem
	(*SeedRequest)(nil),     // 1: downloader.SeedRequest
	(*DownloadItem)(nil),    // 2: downloader.DownloadItem
	(*DownloadRequest)(nil), // 3: downloader.DownloadRequest
	(*DeleteRequest)(nil),   // 4: downloader.DeleteRequest
	(*typesproto.H160)(nil), // 5: types.H160
	(*emptypb.Empty)(nil),   // 6: google.protobuf.Empty
}
var file_downloader_downloader_proto_depIdxs = []int32{
	5, // 0: downloader.DownloadItem.torrent_hash:type_name -> types.H160
	2, // 1: downloader.DownloadRequest.items:type_name -> downloader.DownloadItem
	1, // 2: downloader.Downloader.Seed:input_type -> downloader.SeedRequest
	3, // 3: downloader.Downloader.Download:input_type -> downloader.DownloadRequest
	4, // 4: downloader.Downloader.Delete:input_type -> downloader.DeleteRequest
	6, // 5: downloader.Downloader.Seed:output_type -> google.protobuf.Empty
	6, // 6: downloader.Downloader.Download:output_type -> google.protobuf.Empty
	6, // 7: downloader.Downloader.Delete:output_type -> google.protobuf.Empty
	5, // [5:8] is the sub-list for method output_type
	2, // [2:5] is the sub-list for method input_type
	2, // [2:2] is the sub-list for extension type_name
	2, // [2:2] is the sub-list for extension extendee
	0, // [0:2] is the sub-list for field type_name
}

func init() { file_downloader_downloader_proto_init() }
func file_downloader_downloader_proto_init() {
	if File_downloader_downloader_proto != nil {
		return
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_downloader_downloader_proto_rawDesc), len(file_downloader_downloader_proto_rawDesc)),
			NumEnums:      0,
			NumMessages:   5,
			NumExtensions: 0,
			NumServices:   1,
		},
		GoTypes:           file_downloader_downloader_proto_goTypes,
		DependencyIndexes: file_downloader_downloader_proto_depIdxs,
		MessageInfos:      file_downloader_downloader_proto_msgTypes,
	}.Build()
	File_downloader_downloader_proto = out.File
	file_downloader_downloader_proto_goTypes = nil
	file_downloader_downloader_proto_depIdxs = nil
}
