proto

package
v0.0.0-...-ef636f8 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLength        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflow          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroup = fmt.Errorf("proto: unexpected end of group")
)
View Source
var File_github_com_element_of_surprise_examples_testing_servwithclients_proto_greeter_proto_server_proto protoreflect.FileDescriptor
View Source
var Greeter_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "greeter.Greeter",
	HandlerType: (*GreeterServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "SayHello",
			Handler:    _Greeter_SayHello_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "github.com/element-of-surprise/examples/testing/servwithclients/proto/greeter/proto/server.proto",
}

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

Functions

func RegisterGreeterServer

func RegisterGreeterServer(s grpc.ServiceRegistrar, srv GreeterServer)

Types

type Address

type Address struct {
	Street  string `protobuf:"bytes,1,opt,name=street,proto3" json:"street,omitempty"`
	City    string `protobuf:"bytes,2,opt,name=city,proto3" json:"city,omitempty"`
	State   string `protobuf:"bytes,3,opt,name=state,proto3" json:"state,omitempty"`
	Zipcode int32  `protobuf:"varint,4,opt,name=zipcode,proto3" json:"zipcode,omitempty"`
	// contains filtered or unexported fields
}

func (*Address) CloneMessageVT

func (m *Address) CloneMessageVT() proto.Message

func (*Address) CloneVT

func (m *Address) CloneVT() *Address

func (*Address) Descriptor deprecated

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

Deprecated: Use Address.ProtoReflect.Descriptor instead.

func (*Address) EqualMessageVT

func (this *Address) EqualMessageVT(thatMsg proto.Message) bool

func (*Address) EqualVT

func (this *Address) EqualVT(that *Address) bool

func (*Address) GetCity

func (x *Address) GetCity() string

func (*Address) GetState

func (x *Address) GetState() string

func (*Address) GetStreet

func (x *Address) GetStreet() string

func (*Address) GetZipcode

func (x *Address) GetZipcode() int32

func (*Address) MarshalToSizedBufferVT

func (m *Address) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*Address) MarshalToSizedBufferVTStrict

func (m *Address) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error)

func (*Address) MarshalToVT

func (m *Address) MarshalToVT(dAtA []byte) (int, error)

func (*Address) MarshalToVTStrict

func (m *Address) MarshalToVTStrict(dAtA []byte) (int, error)

func (*Address) MarshalVT

func (m *Address) MarshalVT() (dAtA []byte, err error)

func (*Address) MarshalVTStrict

func (m *Address) MarshalVTStrict() (dAtA []byte, err error)

func (*Address) ProtoMessage

func (*Address) ProtoMessage()

func (*Address) ProtoReflect

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

func (*Address) Reset

func (x *Address) Reset()

func (*Address) SizeVT

func (m *Address) SizeVT() (n int)

func (*Address) String

func (x *Address) String() string

func (*Address) UnmarshalVT

func (m *Address) UnmarshalVT(dAtA []byte) error

type GreeterClient

type GreeterClient interface {
	// Sends a greeting
	SayHello(ctx context.Context, in *HelloRequest, opts ...grpc.CallOption) (*HelloReply, error)
}

GreeterClient is the client API for Greeter 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 NewGreeterClient

func NewGreeterClient(cc grpc.ClientConnInterface) GreeterClient

type GreeterServer

type GreeterServer interface {
	// Sends a greeting
	SayHello(context.Context, *HelloRequest) (*HelloReply, error)
	// contains filtered or unexported methods
}

GreeterServer is the server API for Greeter service. All implementations must embed UnimplementedGreeterServer for forward compatibility

type HelloReply

type HelloReply struct {
	Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
	// contains filtered or unexported fields
}

The response message containing the greetings

func (*HelloReply) CloneMessageVT

func (m *HelloReply) CloneMessageVT() proto.Message

func (*HelloReply) CloneVT

func (m *HelloReply) CloneVT() *HelloReply

func (*HelloReply) Descriptor deprecated

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

Deprecated: Use HelloReply.ProtoReflect.Descriptor instead.

func (*HelloReply) EqualMessageVT

func (this *HelloReply) EqualMessageVT(thatMsg proto.Message) bool

func (*HelloReply) EqualVT

func (this *HelloReply) EqualVT(that *HelloReply) bool

func (*HelloReply) GetMessage

func (x *HelloReply) GetMessage() string

func (*HelloReply) MarshalToSizedBufferVT

func (m *HelloReply) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*HelloReply) MarshalToSizedBufferVTStrict

func (m *HelloReply) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error)

func (*HelloReply) MarshalToVT

func (m *HelloReply) MarshalToVT(dAtA []byte) (int, error)

func (*HelloReply) MarshalToVTStrict

func (m *HelloReply) MarshalToVTStrict(dAtA []byte) (int, error)

func (*HelloReply) MarshalVT

func (m *HelloReply) MarshalVT() (dAtA []byte, err error)

func (*HelloReply) MarshalVTStrict

func (m *HelloReply) MarshalVTStrict() (dAtA []byte, err error)

func (*HelloReply) ProtoMessage

func (*HelloReply) ProtoMessage()

func (*HelloReply) ProtoReflect

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

func (*HelloReply) Reset

func (x *HelloReply) Reset()

func (*HelloReply) SizeVT

func (m *HelloReply) SizeVT() (n int)

func (*HelloReply) String

func (x *HelloReply) String() string

func (*HelloReply) UnmarshalVT

func (m *HelloReply) UnmarshalVT(dAtA []byte) error

type HelloRequest

type HelloRequest struct {
	Name    string   `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Age     int32    `protobuf:"varint,2,opt,name=age,proto3" json:"age,omitempty"`
	Address *Address `protobuf:"bytes,3,opt,name=address,proto3" json:"address,omitempty"`
	// contains filtered or unexported fields
}

The request message containing the user's name.

func (*HelloRequest) CloneMessageVT

func (m *HelloRequest) CloneMessageVT() proto.Message

func (*HelloRequest) CloneVT

func (m *HelloRequest) CloneVT() *HelloRequest

func (*HelloRequest) Descriptor deprecated

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

Deprecated: Use HelloRequest.ProtoReflect.Descriptor instead.

func (*HelloRequest) EqualMessageVT

func (this *HelloRequest) EqualMessageVT(thatMsg proto.Message) bool

func (*HelloRequest) EqualVT

func (this *HelloRequest) EqualVT(that *HelloRequest) bool

func (*HelloRequest) GetAddress

func (x *HelloRequest) GetAddress() *Address

func (*HelloRequest) GetAge

func (x *HelloRequest) GetAge() int32

func (*HelloRequest) GetName

func (x *HelloRequest) GetName() string

func (*HelloRequest) MarshalToSizedBufferVT

func (m *HelloRequest) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*HelloRequest) MarshalToSizedBufferVTStrict

func (m *HelloRequest) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error)

func (*HelloRequest) MarshalToVT

func (m *HelloRequest) MarshalToVT(dAtA []byte) (int, error)

func (*HelloRequest) MarshalToVTStrict

func (m *HelloRequest) MarshalToVTStrict(dAtA []byte) (int, error)

func (*HelloRequest) MarshalVT

func (m *HelloRequest) MarshalVT() (dAtA []byte, err error)

func (*HelloRequest) MarshalVTStrict

func (m *HelloRequest) MarshalVTStrict() (dAtA []byte, err error)

func (*HelloRequest) ProtoMessage

func (*HelloRequest) ProtoMessage()

func (*HelloRequest) ProtoReflect

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

func (*HelloRequest) Reset

func (x *HelloRequest) Reset()

func (*HelloRequest) SizeVT

func (m *HelloRequest) SizeVT() (n int)

func (*HelloRequest) String

func (x *HelloRequest) String() string

func (*HelloRequest) UnmarshalVT

func (m *HelloRequest) UnmarshalVT(dAtA []byte) error

type UnimplementedGreeterServer

type UnimplementedGreeterServer struct {
}

UnimplementedGreeterServer must be embedded to have forward compatible implementations.

func (UnimplementedGreeterServer) SayHello

type UnsafeGreeterServer

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

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

Jump to

Keyboard shortcuts

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