proto

package
v0.0.0-...-ba4ce30 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 21, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AverageService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "proto.AverageService",
	HandlerType: (*AverageServiceServer)(nil),
	Methods:     []grpc.MethodDesc{},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "FindAverage",
			Handler:       _AverageService_FindAverage_Handler,
			ClientStreams: true,
		},
	},
	Metadata: "proto/average.proto",
}

AverageService_ServiceDesc is the grpc.ServiceDesc for AverageService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var FibonacciService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "proto.FibonacciService",
	HandlerType: (*FibonacciServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "SyncFibonacci",
			Handler:    _FibonacciService_SyncFibonacci_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "AsyncFibonacci",
			Handler:       _FibonacciService_AsyncFibonacci_Handler,
			ServerStreams: true,
		},
	},
	Metadata: "proto/fibonacci.proto",
}

FibonacciService_ServiceDesc is the grpc.ServiceDesc for FibonacciService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_proto_average_proto protoreflect.FileDescriptor
View Source
var File_proto_fibonacci_proto protoreflect.FileDescriptor
View Source
var File_proto_max_proto protoreflect.FileDescriptor
View Source
var MaxService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "proto.MaxService",
	HandlerType: (*MaxServiceServer)(nil),
	Methods:     []grpc.MethodDesc{},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "FindMax",
			Handler:       _MaxService_FindMax_Handler,
			ServerStreams: true,
			ClientStreams: true,
		},
	},
	Metadata: "proto/max.proto",
}

MaxService_ServiceDesc is the grpc.ServiceDesc for MaxService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterAverageServiceServer

func RegisterAverageServiceServer(s grpc.ServiceRegistrar, srv AverageServiceServer)

func RegisterFibonacciServiceServer

func RegisterFibonacciServiceServer(s grpc.ServiceRegistrar, srv FibonacciServiceServer)

func RegisterMaxServiceServer

func RegisterMaxServiceServer(s grpc.ServiceRegistrar, srv MaxServiceServer)

Types

type AsyncFibonacciResponse

type AsyncFibonacciResponse struct {
	Sequence        int32 `protobuf:"varint,1,opt,name=sequence,proto3" json:"sequence,omitempty"`
	FibonacciNumber int32 `protobuf:"varint,2,opt,name=fibonacciNumber,proto3" json:"fibonacciNumber,omitempty"`
	// contains filtered or unexported fields
}

func (*AsyncFibonacciResponse) Descriptor deprecated

func (*AsyncFibonacciResponse) Descriptor() ([]byte, []int)

Deprecated: Use AsyncFibonacciResponse.ProtoReflect.Descriptor instead.

func (*AsyncFibonacciResponse) GetFibonacciNumber

func (x *AsyncFibonacciResponse) GetFibonacciNumber() int32

func (*AsyncFibonacciResponse) GetSequence

func (x *AsyncFibonacciResponse) GetSequence() int32

func (*AsyncFibonacciResponse) ProtoMessage

func (*AsyncFibonacciResponse) ProtoMessage()

func (*AsyncFibonacciResponse) ProtoReflect

func (x *AsyncFibonacciResponse) ProtoReflect() protoreflect.Message

func (*AsyncFibonacciResponse) Reset

func (x *AsyncFibonacciResponse) Reset()

func (*AsyncFibonacciResponse) String

func (x *AsyncFibonacciResponse) String() string

type AverageRequest

type AverageRequest struct {
	Number int32 `protobuf:"varint,1,opt,name=number,proto3" json:"number,omitempty"`
	// contains filtered or unexported fields
}

func (*AverageRequest) Descriptor deprecated

func (*AverageRequest) Descriptor() ([]byte, []int)

Deprecated: Use AverageRequest.ProtoReflect.Descriptor instead.

func (*AverageRequest) GetNumber

func (x *AverageRequest) GetNumber() int32

func (*AverageRequest) ProtoMessage

func (*AverageRequest) ProtoMessage()

func (*AverageRequest) ProtoReflect

func (x *AverageRequest) ProtoReflect() protoreflect.Message

func (*AverageRequest) Reset

func (x *AverageRequest) Reset()

func (*AverageRequest) String

func (x *AverageRequest) String() string

type AverageResponse

type AverageResponse struct {
	Average int32 `protobuf:"varint,2,opt,name=average,proto3" json:"average,omitempty"`
	// contains filtered or unexported fields
}

func (*AverageResponse) Descriptor deprecated

func (*AverageResponse) Descriptor() ([]byte, []int)

Deprecated: Use AverageResponse.ProtoReflect.Descriptor instead.

func (*AverageResponse) GetAverage

func (x *AverageResponse) GetAverage() int32

func (*AverageResponse) ProtoMessage

func (*AverageResponse) ProtoMessage()

func (*AverageResponse) ProtoReflect

func (x *AverageResponse) ProtoReflect() protoreflect.Message

func (*AverageResponse) Reset

func (x *AverageResponse) Reset()

func (*AverageResponse) String

func (x *AverageResponse) String() string

type AverageServiceClient

type AverageServiceClient interface {
	// Client Streaming
	FindAverage(ctx context.Context, opts ...grpc.CallOption) (AverageService_FindAverageClient, error)
}

AverageServiceClient is the client API for AverageService 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 AverageServiceServer

type AverageServiceServer interface {
	// Client Streaming
	FindAverage(AverageService_FindAverageServer) error
	// contains filtered or unexported methods
}

AverageServiceServer is the server API for AverageService service. All implementations must embed UnimplementedAverageServiceServer for forward compatibility

type AverageService_FindAverageClient

type AverageService_FindAverageClient interface {
	Send(*AverageRequest) error
	CloseAndRecv() (*AverageResponse, error)
	grpc.ClientStream
}

type AverageService_FindAverageServer

type AverageService_FindAverageServer interface {
	SendAndClose(*AverageResponse) error
	Recv() (*AverageRequest, error)
	grpc.ServerStream
}

type FibonacciRequest

type FibonacciRequest struct {
	Number int32 `protobuf:"varint,1,opt,name=number,proto3" json:"number,omitempty"`
	// contains filtered or unexported fields
}

func (*FibonacciRequest) Descriptor deprecated

func (*FibonacciRequest) Descriptor() ([]byte, []int)

Deprecated: Use FibonacciRequest.ProtoReflect.Descriptor instead.

func (*FibonacciRequest) GetNumber

func (x *FibonacciRequest) GetNumber() int32

func (*FibonacciRequest) ProtoMessage

func (*FibonacciRequest) ProtoMessage()

func (*FibonacciRequest) ProtoReflect

func (x *FibonacciRequest) ProtoReflect() protoreflect.Message

func (*FibonacciRequest) Reset

func (x *FibonacciRequest) Reset()

func (*FibonacciRequest) String

func (x *FibonacciRequest) String() string

type FibonacciServiceClient

type FibonacciServiceClient interface {
	// Unary
	SyncFibonacci(ctx context.Context, in *FibonacciRequest, opts ...grpc.CallOption) (*SyncFibonacciResponse, error)
	// Server Streaming
	AsyncFibonacci(ctx context.Context, in *FibonacciRequest, opts ...grpc.CallOption) (FibonacciService_AsyncFibonacciClient, error)
}

FibonacciServiceClient is the client API for FibonacciService 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 FibonacciServiceServer

type FibonacciServiceServer interface {
	// Unary
	SyncFibonacci(context.Context, *FibonacciRequest) (*SyncFibonacciResponse, error)
	// Server Streaming
	AsyncFibonacci(*FibonacciRequest, FibonacciService_AsyncFibonacciServer) error
	// contains filtered or unexported methods
}

FibonacciServiceServer is the server API for FibonacciService service. All implementations must embed UnimplementedFibonacciServiceServer for forward compatibility

type FibonacciService_AsyncFibonacciClient

type FibonacciService_AsyncFibonacciClient interface {
	Recv() (*AsyncFibonacciResponse, error)
	grpc.ClientStream
}

type FibonacciService_AsyncFibonacciServer

type FibonacciService_AsyncFibonacciServer interface {
	Send(*AsyncFibonacciResponse) error
	grpc.ServerStream
}

type MaxRequest

type MaxRequest struct {
	Number int32 `protobuf:"varint,1,opt,name=number,proto3" json:"number,omitempty"`
	// contains filtered or unexported fields
}

func (*MaxRequest) Descriptor deprecated

func (*MaxRequest) Descriptor() ([]byte, []int)

Deprecated: Use MaxRequest.ProtoReflect.Descriptor instead.

func (*MaxRequest) GetNumber

func (x *MaxRequest) GetNumber() int32

func (*MaxRequest) ProtoMessage

func (*MaxRequest) ProtoMessage()

func (*MaxRequest) ProtoReflect

func (x *MaxRequest) ProtoReflect() protoreflect.Message

func (*MaxRequest) Reset

func (x *MaxRequest) Reset()

func (*MaxRequest) String

func (x *MaxRequest) String() string

type MaxResponse

type MaxResponse struct {
	Max int32 `protobuf:"varint,1,opt,name=max,proto3" json:"max,omitempty"`
	// contains filtered or unexported fields
}

func (*MaxResponse) Descriptor deprecated

func (*MaxResponse) Descriptor() ([]byte, []int)

Deprecated: Use MaxResponse.ProtoReflect.Descriptor instead.

func (*MaxResponse) GetMax

func (x *MaxResponse) GetMax() int32

func (*MaxResponse) ProtoMessage

func (*MaxResponse) ProtoMessage()

func (*MaxResponse) ProtoReflect

func (x *MaxResponse) ProtoReflect() protoreflect.Message

func (*MaxResponse) Reset

func (x *MaxResponse) Reset()

func (*MaxResponse) String

func (x *MaxResponse) String() string

type MaxServiceClient

type MaxServiceClient interface {
	// Bi-Directional Streaming
	FindMax(ctx context.Context, opts ...grpc.CallOption) (MaxService_FindMaxClient, error)
}

MaxServiceClient is the client API for MaxService 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.

func NewMaxServiceClient

func NewMaxServiceClient(cc grpc.ClientConnInterface) MaxServiceClient

type MaxServiceServer

type MaxServiceServer interface {
	// Bi-Directional Streaming
	FindMax(MaxService_FindMaxServer) error
	// contains filtered or unexported methods
}

MaxServiceServer is the server API for MaxService service. All implementations must embed UnimplementedMaxServiceServer for forward compatibility

type MaxService_FindMaxClient

type MaxService_FindMaxClient interface {
	Send(*MaxRequest) error
	Recv() (*MaxResponse, error)
	grpc.ClientStream
}

type MaxService_FindMaxServer

type MaxService_FindMaxServer interface {
	Send(*MaxResponse) error
	Recv() (*MaxRequest, error)
	grpc.ServerStream
}

type SyncFibonacciResponse

type SyncFibonacciResponse struct {
	TimeTaken        string  `protobuf:"bytes,1,opt,name=timeTaken,proto3" json:"timeTaken,omitempty"`
	FibonacciNumbers []int32 `protobuf:"varint,2,rep,packed,name=fibonacciNumbers,proto3" json:"fibonacciNumbers,omitempty"`
	// contains filtered or unexported fields
}

func (*SyncFibonacciResponse) Descriptor deprecated

func (*SyncFibonacciResponse) Descriptor() ([]byte, []int)

Deprecated: Use SyncFibonacciResponse.ProtoReflect.Descriptor instead.

func (*SyncFibonacciResponse) GetFibonacciNumbers

func (x *SyncFibonacciResponse) GetFibonacciNumbers() []int32

func (*SyncFibonacciResponse) GetTimeTaken

func (x *SyncFibonacciResponse) GetTimeTaken() string

func (*SyncFibonacciResponse) ProtoMessage

func (*SyncFibonacciResponse) ProtoMessage()

func (*SyncFibonacciResponse) ProtoReflect

func (x *SyncFibonacciResponse) ProtoReflect() protoreflect.Message

func (*SyncFibonacciResponse) Reset

func (x *SyncFibonacciResponse) Reset()

func (*SyncFibonacciResponse) String

func (x *SyncFibonacciResponse) String() string

type UnimplementedAverageServiceServer

type UnimplementedAverageServiceServer struct {
}

UnimplementedAverageServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedAverageServiceServer) FindAverage

type UnimplementedFibonacciServiceServer

type UnimplementedFibonacciServiceServer struct {
}

UnimplementedFibonacciServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedFibonacciServiceServer) AsyncFibonacci

func (UnimplementedFibonacciServiceServer) SyncFibonacci

type UnimplementedMaxServiceServer

type UnimplementedMaxServiceServer struct {
}

UnimplementedMaxServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedMaxServiceServer) FindMax

type UnsafeAverageServiceServer

type UnsafeAverageServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeAverageServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AverageServiceServer will result in compilation errors.

type UnsafeFibonacciServiceServer

type UnsafeFibonacciServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeFibonacciServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to FibonacciServiceServer will result in compilation errors.

type UnsafeMaxServiceServer

type UnsafeMaxServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeMaxServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to MaxServiceServer will result in compilation errors.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL