proto

package
v0.0.0-...-3659004 Latest Latest
Warning

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

Go to latest
Published: Aug 28, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_hello_grpc_proto protoreflect.FileDescriptor

Functions

func RegisterUserProviderServer

func RegisterUserProviderServer(s *grpc.Server, srv UserProviderServer)

Types

type GetUserRequest

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

func (*GetUserRequest) Descriptor deprecated

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

Deprecated: Use GetUserRequest.ProtoReflect.Descriptor instead.

func (*GetUserRequest) GetUserId

func (x *GetUserRequest) GetUserId() int32

func (*GetUserRequest) ProtoMessage

func (*GetUserRequest) ProtoMessage()

func (*GetUserRequest) ProtoReflect

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

func (*GetUserRequest) Reset

func (x *GetUserRequest) Reset()

func (*GetUserRequest) String

func (x *GetUserRequest) String() string

type GetUserResponse

type GetUserResponse struct {
	Message string  `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
	Users   []*User `protobuf:"bytes,2,rep,name=users,proto3" json:"users,omitempty"`
	// contains filtered or unexported fields
}

func (*GetUserResponse) Descriptor deprecated

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

Deprecated: Use GetUserResponse.ProtoReflect.Descriptor instead.

func (*GetUserResponse) GetMessage

func (x *GetUserResponse) GetMessage() string

func (*GetUserResponse) GetUsers

func (x *GetUserResponse) GetUsers() []*User

func (*GetUserResponse) ProtoMessage

func (*GetUserResponse) ProtoMessage()

func (*GetUserResponse) ProtoReflect

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

func (*GetUserResponse) Reset

func (x *GetUserResponse) Reset()

func (*GetUserResponse) String

func (x *GetUserResponse) String() string

type UnimplementedUserProviderServer

type UnimplementedUserProviderServer struct {
}

UnimplementedUserProviderServer must be embedded to have forward compatible implementations.

func (UnimplementedUserProviderServer) GetUser

type UnsafeUserProviderServer

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

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

type User

type User struct {
	UserId int32  `protobuf:"varint,1,opt,name=userId,proto3" json:"userId,omitempty"`
	Name   string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*User) Descriptor deprecated

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

Deprecated: Use User.ProtoReflect.Descriptor instead.

func (*User) GetName

func (x *User) GetName() string

func (*User) GetUserId

func (x *User) GetUserId() int32

func (*User) ProtoMessage

func (*User) ProtoMessage()

func (*User) ProtoReflect

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

func (*User) Reset

func (x *User) Reset()

func (*User) String

func (x *User) String() string

type UserProviderClient

type UserProviderClient interface {
	GetUser(ctx context.Context, in *GetUserRequest, opts ...grpc.CallOption) (*GetUserResponse, error)
}

UserProviderClient is the client API for UserProvider 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 UserProviderServer

type UserProviderServer interface {
	GetUser(context.Context, *GetUserRequest) (*GetUserResponse, error)
	// contains filtered or unexported methods
}

UserProviderServer is the server API for UserProvider service. All implementations must embed UnimplementedUserProviderServer for forward compatibility

Jump to

Keyboard shortcuts

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