Versions in this module Expand all Collapse all v0 v0.0.4 Nov 4, 2021 v0.0.3 Oct 21, 2021 Changes in this version + var File_messaging_kademlia_proto protoreflect.FileDescriptor + var KademliaMessenger_ServiceDesc = grpc.ServiceDesc + var Status_name = map[int32]string + var Status_value = map[string]int32 + func RegisterKademliaMessengerServer(s grpc.ServiceRegistrar, srv KademliaMessengerServer) + type FindNodesRequest struct + K int32 + Self string + TargetId []byte + func (*FindNodesRequest) Descriptor() ([]byte, []int) + func (*FindNodesRequest) ProtoMessage() + func (x *FindNodesRequest) GetK() int32 + func (x *FindNodesRequest) GetSelf() string + func (x *FindNodesRequest) GetTargetId() []byte + func (x *FindNodesRequest) ProtoReflect() protoreflect.Message + func (x *FindNodesRequest) Reset() + func (x *FindNodesRequest) String() string + type FindNodesResponse struct + Nodes []string + Status Status + func (*FindNodesResponse) Descriptor() ([]byte, []int) + func (*FindNodesResponse) ProtoMessage() + func (x *FindNodesResponse) GetNodes() []string + func (x *FindNodesResponse) GetStatus() Status + func (x *FindNodesResponse) ProtoReflect() protoreflect.Message + func (x *FindNodesResponse) Reset() + func (x *FindNodesResponse) String() string + type FindProvidersRequest struct + Key []byte + Self string + func (*FindProvidersRequest) Descriptor() ([]byte, []int) + func (*FindProvidersRequest) ProtoMessage() + func (x *FindProvidersRequest) GetKey() []byte + func (x *FindProvidersRequest) GetSelf() string + func (x *FindProvidersRequest) ProtoReflect() protoreflect.Message + func (x *FindProvidersRequest) Reset() + func (x *FindProvidersRequest) String() string + type FindProvidersResponse struct + ClosestToTarget []string + Nodes []string + Status Status + func (*FindProvidersResponse) Descriptor() ([]byte, []int) + func (*FindProvidersResponse) ProtoMessage() + func (x *FindProvidersResponse) GetClosestToTarget() []string + func (x *FindProvidersResponse) GetNodes() []string + func (x *FindProvidersResponse) GetStatus() Status + func (x *FindProvidersResponse) ProtoReflect() protoreflect.Message + func (x *FindProvidersResponse) Reset() + func (x *FindProvidersResponse) String() string + type GetRequest struct + Key []byte + Self string + func (*GetRequest) Descriptor() ([]byte, []int) + func (*GetRequest) ProtoMessage() + func (x *GetRequest) GetKey() []byte + func (x *GetRequest) GetSelf() string + func (x *GetRequest) ProtoReflect() protoreflect.Message + func (x *GetRequest) Reset() + func (x *GetRequest) String() string + type GetResponse struct + ClosestToTarget []string + Status Status + Value []byte + func (*GetResponse) Descriptor() ([]byte, []int) + func (*GetResponse) ProtoMessage() + func (x *GetResponse) GetClosestToTarget() []string + func (x *GetResponse) GetStatus() Status + func (x *GetResponse) GetValue() []byte + func (x *GetResponse) ProtoReflect() protoreflect.Message + func (x *GetResponse) Reset() + func (x *GetResponse) String() string + type KademliaMessengerClient interface + FindNodes func(ctx context.Context, in *FindNodesRequest, opts ...grpc.CallOption) (*FindNodesResponse, error) + FindProvider func(ctx context.Context, in *FindProvidersRequest, opts ...grpc.CallOption) (*FindProvidersResponse, error) + Get func(ctx context.Context, in *GetRequest, opts ...grpc.CallOption) (*GetResponse, error) + Ping func(ctx context.Context, in *PingRequest, opts ...grpc.CallOption) (*PingResponse, error) + Provide func(ctx context.Context, in *ProvideRequest, opts ...grpc.CallOption) (*ProvideResponse, error) + Put func(ctx context.Context, in *PutRequest, opts ...grpc.CallOption) (*PutResponse, error) + func NewKademliaMessengerClient(cc grpc.ClientConnInterface) KademliaMessengerClient + type KademliaMessengerServer interface + FindNodes func(context.Context, *FindNodesRequest) (*FindNodesResponse, error) + FindProvider func(context.Context, *FindProvidersRequest) (*FindProvidersResponse, error) + Get func(context.Context, *GetRequest) (*GetResponse, error) + Ping func(context.Context, *PingRequest) (*PingResponse, error) + Provide func(context.Context, *ProvideRequest) (*ProvideResponse, error) + Put func(context.Context, *PutRequest) (*PutResponse, error) + type PingRequest struct + Message string + Self string + func (*PingRequest) Descriptor() ([]byte, []int) + func (*PingRequest) ProtoMessage() + func (x *PingRequest) GetMessage() string + func (x *PingRequest) GetSelf() string + func (x *PingRequest) ProtoReflect() protoreflect.Message + func (x *PingRequest) Reset() + func (x *PingRequest) String() string + type PingResponse struct + Message string + Status Status + func (*PingResponse) Descriptor() ([]byte, []int) + func (*PingResponse) ProtoMessage() + func (x *PingResponse) GetMessage() string + func (x *PingResponse) GetStatus() Status + func (x *PingResponse) ProtoReflect() protoreflect.Message + func (x *PingResponse) Reset() + func (x *PingResponse) String() string + type ProvideRequest struct + Key []byte + Self string + func (*ProvideRequest) Descriptor() ([]byte, []int) + func (*ProvideRequest) ProtoMessage() + func (x *ProvideRequest) GetKey() []byte + func (x *ProvideRequest) GetSelf() string + func (x *ProvideRequest) ProtoReflect() protoreflect.Message + func (x *ProvideRequest) Reset() + func (x *ProvideRequest) String() string + type ProvideResponse struct + Status Status + func (*ProvideResponse) Descriptor() ([]byte, []int) + func (*ProvideResponse) ProtoMessage() + func (x *ProvideResponse) GetStatus() Status + func (x *ProvideResponse) ProtoReflect() protoreflect.Message + func (x *ProvideResponse) Reset() + func (x *ProvideResponse) String() string + type PutRequest struct + Key []byte + Self string + Value []byte + func (*PutRequest) Descriptor() ([]byte, []int) + func (*PutRequest) ProtoMessage() + func (x *PutRequest) GetKey() []byte + func (x *PutRequest) GetSelf() string + func (x *PutRequest) GetValue() []byte + func (x *PutRequest) ProtoReflect() protoreflect.Message + func (x *PutRequest) Reset() + func (x *PutRequest) String() string + type PutResponse struct + Status Status + func (*PutResponse) Descriptor() ([]byte, []int) + func (*PutResponse) ProtoMessage() + func (x *PutResponse) GetStatus() Status + func (x *PutResponse) ProtoReflect() protoreflect.Message + func (x *PutResponse) Reset() + func (x *PutResponse) String() string + type Status int32 + const Status_Failed + const Status_OK + const Status_Unknown + func (Status) Descriptor() protoreflect.EnumDescriptor + func (Status) EnumDescriptor() ([]byte, []int) + func (Status) Type() protoreflect.EnumType + func (x Status) Enum() *Status + func (x Status) Number() protoreflect.EnumNumber + func (x Status) String() string + type UnimplementedKademliaMessengerServer struct + func (UnimplementedKademliaMessengerServer) FindNodes(context.Context, *FindNodesRequest) (*FindNodesResponse, error) + func (UnimplementedKademliaMessengerServer) FindProvider(context.Context, *FindProvidersRequest) (*FindProvidersResponse, error) + func (UnimplementedKademliaMessengerServer) Get(context.Context, *GetRequest) (*GetResponse, error) + func (UnimplementedKademliaMessengerServer) Ping(context.Context, *PingRequest) (*PingResponse, error) + func (UnimplementedKademliaMessengerServer) Provide(context.Context, *ProvideRequest) (*ProvideResponse, error) + func (UnimplementedKademliaMessengerServer) Put(context.Context, *PutRequest) (*PutResponse, error) + type UnsafeKademliaMessengerServer interface