user

package
v0.0.0-...-cc10780 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_proto_user_user_proto protoreflect.FileDescriptor

Functions

func NewUserEndpoints

func NewUserEndpoints() []*api.Endpoint

func RegisterUserHandler

func RegisterUserHandler(s server.Server, hdlr UserHandler, opts ...server.HandlerOption) error

Types

type AllUser

type AllUser struct {
	UserInfo []*UserInfo `protobuf:"bytes,1,rep,name=user_info,json=userInfo,proto3" json:"user_info,omitempty"`
	// contains filtered or unexported fields
}

func (*AllUser) Descriptor deprecated

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

Deprecated: Use AllUser.ProtoReflect.Descriptor instead.

func (*AllUser) GetUserInfo

func (x *AllUser) GetUserInfo() []*UserInfo

func (*AllUser) ProtoMessage

func (*AllUser) ProtoMessage()

func (*AllUser) ProtoReflect

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

func (*AllUser) Reset

func (x *AllUser) Reset()

func (*AllUser) String

func (x *AllUser) String() string

type FindAll

type FindAll struct {
	// contains filtered or unexported fields
}

func (*FindAll) Descriptor deprecated

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

Deprecated: Use FindAll.ProtoReflect.Descriptor instead.

func (*FindAll) ProtoMessage

func (*FindAll) ProtoMessage()

func (*FindAll) ProtoReflect

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

func (*FindAll) Reset

func (x *FindAll) Reset()

func (*FindAll) String

func (x *FindAll) String() string

type Response

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

func (*Response) Descriptor deprecated

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

Deprecated: Use Response.ProtoReflect.Descriptor instead.

func (*Response) GetMsg

func (x *Response) GetMsg() string

func (*Response) ProtoMessage

func (*Response) ProtoMessage()

func (*Response) ProtoReflect

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

func (*Response) Reset

func (x *Response) Reset()

func (*Response) String

func (x *Response) String() string

type UserHandler

type UserHandler interface {
	//对外提供添加服务
	AddUser(context.Context, *UserInfo, *Response) error
	DeleteUser(context.Context, *UserId, *Response) error
	UpdateUser(context.Context, *UserInfo, *Response) error
	FindUserByID(context.Context, *UserId, *UserInfo) error
	FindAllUser(context.Context, *FindAll, *AllUser) error
}

type UserId

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

func (*UserId) Descriptor deprecated

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

Deprecated: Use UserId.ProtoReflect.Descriptor instead.

func (*UserId) GetId

func (x *UserId) GetId() int64

func (*UserId) ProtoMessage

func (*UserId) ProtoMessage()

func (*UserId) ProtoReflect

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

func (*UserId) Reset

func (x *UserId) Reset()

func (*UserId) String

func (x *UserId) String() string

type UserInfo

type UserInfo struct {
	Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*UserInfo) Descriptor deprecated

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

Deprecated: Use UserInfo.ProtoReflect.Descriptor instead.

func (*UserInfo) GetId

func (x *UserInfo) GetId() int64

func (*UserInfo) ProtoMessage

func (*UserInfo) ProtoMessage()

func (*UserInfo) ProtoReflect

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

func (*UserInfo) Reset

func (x *UserInfo) Reset()

func (*UserInfo) String

func (x *UserInfo) String() string

type UserService

type UserService interface {
	//对外提供添加服务
	AddUser(ctx context.Context, in *UserInfo, opts ...client.CallOption) (*Response, error)
	DeleteUser(ctx context.Context, in *UserId, opts ...client.CallOption) (*Response, error)
	UpdateUser(ctx context.Context, in *UserInfo, opts ...client.CallOption) (*Response, error)
	FindUserByID(ctx context.Context, in *UserId, opts ...client.CallOption) (*UserInfo, error)
	FindAllUser(ctx context.Context, in *FindAll, opts ...client.CallOption) (*AllUser, error)
}

func NewUserService

func NewUserService(name string, c client.Client) UserService

Jump to

Keyboard shortcuts

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