test

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_blachris_arpcnet_test_test_service_proto protoreflect.FileDescriptor
View Source
var Test_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "blachris.arpcnet.test.Test",
	HandlerType: (*TestServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "UnaryCall",
			Handler:    _Test_UnaryCall_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "ServerStream",
			Handler:       _Test_ServerStream_Handler,
			ServerStreams: true,
		},
		{
			StreamName:    "BidiStream",
			Handler:       _Test_BidiStream_Handler,
			ServerStreams: true,
			ClientStreams: true,
		},
	},
	Metadata: "blachris/arpcnet/test/test_service.proto",
}

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

Functions

func RegisterTestServer

func RegisterTestServer(s grpc.ServiceRegistrar, srv TestServer)

Types

type TestClient

type TestClient interface {
	UnaryCall(ctx context.Context, in *TestMessage, opts ...grpc.CallOption) (*TestMessage, error)
	ServerStream(ctx context.Context, in *TestMessage, opts ...grpc.CallOption) (Test_ServerStreamClient, error)
	BidiStream(ctx context.Context, opts ...grpc.CallOption) (Test_BidiStreamClient, error)
}

TestClient is the client API for Test 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 NewTestClient

func NewTestClient(cc grpc.ClientConnInterface) TestClient

type TestMessage

type TestMessage struct {
	Text string `protobuf:"bytes,1,opt,name=text,proto3" json:"text,omitempty"`
	Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
	// contains filtered or unexported fields
}

func (*TestMessage) Descriptor deprecated

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

Deprecated: Use TestMessage.ProtoReflect.Descriptor instead.

func (*TestMessage) GetData

func (x *TestMessage) GetData() []byte

func (*TestMessage) GetText

func (x *TestMessage) GetText() string

func (*TestMessage) ProtoMessage

func (*TestMessage) ProtoMessage()

func (*TestMessage) ProtoReflect

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

func (*TestMessage) Reset

func (x *TestMessage) Reset()

func (*TestMessage) String

func (x *TestMessage) String() string

type TestServer

type TestServer interface {
	UnaryCall(context.Context, *TestMessage) (*TestMessage, error)
	ServerStream(*TestMessage, Test_ServerStreamServer) error
	BidiStream(Test_BidiStreamServer) error
	// contains filtered or unexported methods
}

TestServer is the server API for Test service. All implementations must embed UnimplementedTestServer for forward compatibility

type Test_BidiStreamClient

type Test_BidiStreamClient interface {
	Send(*TestMessage) error
	Recv() (*TestMessage, error)
	grpc.ClientStream
}

type Test_BidiStreamServer

type Test_BidiStreamServer interface {
	Send(*TestMessage) error
	Recv() (*TestMessage, error)
	grpc.ServerStream
}

type Test_ServerStreamClient

type Test_ServerStreamClient interface {
	Recv() (*TestMessage, error)
	grpc.ClientStream
}

type Test_ServerStreamServer

type Test_ServerStreamServer interface {
	Send(*TestMessage) error
	grpc.ServerStream
}

type UnimplementedTestServer

type UnimplementedTestServer struct {
}

UnimplementedTestServer must be embedded to have forward compatible implementations.

func (UnimplementedTestServer) BidiStream

func (UnimplementedTestServer) ServerStream

func (UnimplementedTestServer) UnaryCall

type UnsafeTestServer

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

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

Jump to

Keyboard shortcuts

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