// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.6
// 	protoc        v5.29.2
// source: p2p/host/peerstore/pstoreds/pb/pstore.proto

package pb

import (
	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
	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)
)

// AddrBookRecord represents a record for a peer in the address book.
type AddrBookRecord struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// The peer ID.
	Id []byte `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// The multiaddresses. This is a sorted list where element 0 expires the soonest.
	Addrs []*AddrBookRecord_AddrEntry `protobuf:"bytes,2,rep,name=addrs,proto3" json:"addrs,omitempty"`
	// The most recently received signed PeerRecord.
	CertifiedRecord *AddrBookRecord_CertifiedRecord `protobuf:"bytes,3,opt,name=certified_record,json=certifiedRecord,proto3" json:"certified_record,omitempty"`
	unknownFields   protoimpl.UnknownFields
	sizeCache       protoimpl.SizeCache
}

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

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

func (*AddrBookRecord) ProtoMessage() {}

func (x *AddrBookRecord) ProtoReflect() protoreflect.Message {
	mi := &file_p2p_host_peerstore_pstoreds_pb_pstore_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 AddrBookRecord.ProtoReflect.Descriptor instead.
func (*AddrBookRecord) Descriptor() ([]byte, []int) {
	return file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDescGZIP(), []int{0}
}

func (x *AddrBookRecord) GetId() []byte {
	if x != nil {
		return x.Id
	}
	return nil
}

func (x *AddrBookRecord) GetAddrs() []*AddrBookRecord_AddrEntry {
	if x != nil {
		return x.Addrs
	}
	return nil
}

func (x *AddrBookRecord) GetCertifiedRecord() *AddrBookRecord_CertifiedRecord {
	if x != nil {
		return x.CertifiedRecord
	}
	return nil
}

// AddrEntry represents a single multiaddress.
type AddrBookRecord_AddrEntry struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	Addr  []byte                 `protobuf:"bytes,1,opt,name=addr,proto3" json:"addr,omitempty"`
	// The point in time when this address expires.
	Expiry int64 `protobuf:"varint,2,opt,name=expiry,proto3" json:"expiry,omitempty"`
	// The original TTL of this address.
	Ttl           int64 `protobuf:"varint,3,opt,name=ttl,proto3" json:"ttl,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*AddrBookRecord_AddrEntry) ProtoMessage() {}

func (x *AddrBookRecord_AddrEntry) ProtoReflect() protoreflect.Message {
	mi := &file_p2p_host_peerstore_pstoreds_pb_pstore_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 AddrBookRecord_AddrEntry.ProtoReflect.Descriptor instead.
func (*AddrBookRecord_AddrEntry) Descriptor() ([]byte, []int) {
	return file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDescGZIP(), []int{0, 0}
}

func (x *AddrBookRecord_AddrEntry) GetAddr() []byte {
	if x != nil {
		return x.Addr
	}
	return nil
}

func (x *AddrBookRecord_AddrEntry) GetExpiry() int64 {
	if x != nil {
		return x.Expiry
	}
	return 0
}

func (x *AddrBookRecord_AddrEntry) GetTtl() int64 {
	if x != nil {
		return x.Ttl
	}
	return 0
}

// CertifiedRecord contains a serialized signed PeerRecord used to
// populate the signedAddrs list.
type AddrBookRecord_CertifiedRecord struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// The Seq counter from the signed PeerRecord envelope
	Seq uint64 `protobuf:"varint,1,opt,name=seq,proto3" json:"seq,omitempty"`
	// The serialized bytes of the SignedEnvelope containing the PeerRecord.
	Raw           []byte `protobuf:"bytes,2,opt,name=raw,proto3" json:"raw,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*AddrBookRecord_CertifiedRecord) ProtoMessage() {}

func (x *AddrBookRecord_CertifiedRecord) ProtoReflect() protoreflect.Message {
	mi := &file_p2p_host_peerstore_pstoreds_pb_pstore_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 AddrBookRecord_CertifiedRecord.ProtoReflect.Descriptor instead.
func (*AddrBookRecord_CertifiedRecord) Descriptor() ([]byte, []int) {
	return file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDescGZIP(), []int{0, 1}
}

func (x *AddrBookRecord_CertifiedRecord) GetSeq() uint64 {
	if x != nil {
		return x.Seq
	}
	return 0
}

func (x *AddrBookRecord_CertifiedRecord) GetRaw() []byte {
	if x != nil {
		return x.Raw
	}
	return nil
}

var File_p2p_host_peerstore_pstoreds_pb_pstore_proto protoreflect.FileDescriptor

const file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDesc = "" +
	"\n" +
	"+p2p/host/peerstore/pstoreds/pb/pstore.proto\x12\tpstore.pb\"\xb3\x02\n" +
	"\x0eAddrBookRecord\x12\x0e\n" +
	"\x02id\x18\x01 \x01(\fR\x02id\x129\n" +
	"\x05addrs\x18\x02 \x03(\v2#.pstore.pb.AddrBookRecord.AddrEntryR\x05addrs\x12T\n" +
	"\x10certified_record\x18\x03 \x01(\v2).pstore.pb.AddrBookRecord.CertifiedRecordR\x0fcertifiedRecord\x1aI\n" +
	"\tAddrEntry\x12\x12\n" +
	"\x04addr\x18\x01 \x01(\fR\x04addr\x12\x16\n" +
	"\x06expiry\x18\x02 \x01(\x03R\x06expiry\x12\x10\n" +
	"\x03ttl\x18\x03 \x01(\x03R\x03ttl\x1a5\n" +
	"\x0fCertifiedRecord\x12\x10\n" +
	"\x03seq\x18\x01 \x01(\x04R\x03seq\x12\x10\n" +
	"\x03raw\x18\x02 \x01(\fR\x03rawB<Z:github.com/libp2p/go-libp2p/p2p/host/peerstore/pstoreds/pbb\x06proto3"

var (
	file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDescOnce sync.Once
	file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDescData []byte
)

func file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDescGZIP() []byte {
	file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDescOnce.Do(func() {
		file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDesc), len(file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDesc)))
	})
	return file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDescData
}

var file_p2p_host_peerstore_pstoreds_pb_pstore_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
var file_p2p_host_peerstore_pstoreds_pb_pstore_proto_goTypes = []any{
	(*AddrBookRecord)(nil),                 // 0: pstore.pb.AddrBookRecord
	(*AddrBookRecord_AddrEntry)(nil),       // 1: pstore.pb.AddrBookRecord.AddrEntry
	(*AddrBookRecord_CertifiedRecord)(nil), // 2: pstore.pb.AddrBookRecord.CertifiedRecord
}
var file_p2p_host_peerstore_pstoreds_pb_pstore_proto_depIdxs = []int32{
	1, // 0: pstore.pb.AddrBookRecord.addrs:type_name -> pstore.pb.AddrBookRecord.AddrEntry
	2, // 1: pstore.pb.AddrBookRecord.certified_record:type_name -> pstore.pb.AddrBookRecord.CertifiedRecord
	2, // [2:2] is the sub-list for method output_type
	2, // [2:2] 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_p2p_host_peerstore_pstoreds_pb_pstore_proto_init() }
func file_p2p_host_peerstore_pstoreds_pb_pstore_proto_init() {
	if File_p2p_host_peerstore_pstoreds_pb_pstore_proto != nil {
		return
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDesc), len(file_p2p_host_peerstore_pstoreds_pb_pstore_proto_rawDesc)),
			NumEnums:      0,
			NumMessages:   3,
			NumExtensions: 0,
			NumServices:   0,
		},
		GoTypes:           file_p2p_host_peerstore_pstoreds_pb_pstore_proto_goTypes,
		DependencyIndexes: file_p2p_host_peerstore_pstoreds_pb_pstore_proto_depIdxs,
		MessageInfos:      file_p2p_host_peerstore_pstoreds_pb_pstore_proto_msgTypes,
	}.Build()
	File_p2p_host_peerstore_pstoreds_pb_pstore_proto = out.File
	file_p2p_host_peerstore_pstoreds_pb_pstore_proto_goTypes = nil
	file_p2p_host_peerstore_pstoreds_pb_pstore_proto_depIdxs = nil
}
