4 Star 12 Fork 3

yasenagat / gokit-inaction

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
user.pb.go 7.30 KB
一键复制 编辑 原始数据 按行查看 历史
yasenagat 提交于 2020-04-09 10:31 . U-更新readme
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: user.proto
package pro
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import (
context "golang.org/x/net/context"
grpc "google.golang.org/grpc"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type LoginReq struct {
Header *RequestHeader `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"`
Username string `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"`
Pwd string `protobuf:"bytes,3,opt,name=pwd,proto3" json:"pwd,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *LoginReq) Reset() { *m = LoginReq{} }
func (m *LoginReq) String() string { return proto.CompactTextString(m) }
func (*LoginReq) ProtoMessage() {}
func (*LoginReq) Descriptor() ([]byte, []int) {
return fileDescriptor_user_41fc5ec05d837255, []int{0}
}
func (m *LoginReq) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_LoginReq.Unmarshal(m, b)
}
func (m *LoginReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_LoginReq.Marshal(b, m, deterministic)
}
func (dst *LoginReq) XXX_Merge(src proto.Message) {
xxx_messageInfo_LoginReq.Merge(dst, src)
}
func (m *LoginReq) XXX_Size() int {
return xxx_messageInfo_LoginReq.Size(m)
}
func (m *LoginReq) XXX_DiscardUnknown() {
xxx_messageInfo_LoginReq.DiscardUnknown(m)
}
var xxx_messageInfo_LoginReq proto.InternalMessageInfo
func (m *LoginReq) GetHeader() *RequestHeader {
if m != nil {
return m.Header
}
return nil
}
func (m *LoginReq) GetUsername() string {
if m != nil {
return m.Username
}
return ""
}
func (m *LoginReq) GetPwd() string {
if m != nil {
return m.Pwd
}
return ""
}
type LoginRes struct {
Header *ResponseHeader `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"`
Userid string `protobuf:"bytes,2,opt,name=userid,proto3" json:"userid,omitempty"`
Sid string `protobuf:"bytes,3,opt,name=sid,proto3" json:"sid,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *LoginRes) Reset() { *m = LoginRes{} }
func (m *LoginRes) String() string { return proto.CompactTextString(m) }
func (*LoginRes) ProtoMessage() {}
func (*LoginRes) Descriptor() ([]byte, []int) {
return fileDescriptor_user_41fc5ec05d837255, []int{1}
}
func (m *LoginRes) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_LoginRes.Unmarshal(m, b)
}
func (m *LoginRes) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_LoginRes.Marshal(b, m, deterministic)
}
func (dst *LoginRes) XXX_Merge(src proto.Message) {
xxx_messageInfo_LoginRes.Merge(dst, src)
}
func (m *LoginRes) XXX_Size() int {
return xxx_messageInfo_LoginRes.Size(m)
}
func (m *LoginRes) XXX_DiscardUnknown() {
xxx_messageInfo_LoginRes.DiscardUnknown(m)
}
var xxx_messageInfo_LoginRes proto.InternalMessageInfo
func (m *LoginRes) GetHeader() *ResponseHeader {
if m != nil {
return m.Header
}
return nil
}
func (m *LoginRes) GetUserid() string {
if m != nil {
return m.Userid
}
return ""
}
func (m *LoginRes) GetSid() string {
if m != nil {
return m.Sid
}
return ""
}
func init() {
proto.RegisterType((*LoginReq)(nil), "pro.LoginReq")
proto.RegisterType((*LoginRes)(nil), "pro.LoginRes")
}
// Reference imports to suppress errors if they are not otherwise used.
var _ context.Context
var _ grpc.ClientConn
// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion4
// UserClient is the client API for User service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type UserClient interface {
Login(ctx context.Context, in *LoginReq, opts ...grpc.CallOption) (*LoginRes, error)
}
type userClient struct {
cc *grpc.ClientConn
}
func NewUserClient(cc *grpc.ClientConn) UserClient {
return &userClient{cc}
}
func (c *userClient) Login(ctx context.Context, in *LoginReq, opts ...grpc.CallOption) (*LoginRes, error) {
out := new(LoginRes)
err := c.cc.Invoke(ctx, "/pro.User/Login", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// UserServer is the server API for User service.
type UserServer interface {
Login(context.Context, *LoginReq) (*LoginRes, error)
}
func RegisterUserServer(s *grpc.Server, srv UserServer) {
s.RegisterService(&_User_serviceDesc, srv)
}
func _User_Login_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(LoginReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(UserServer).Login(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/pro.User/Login",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(UserServer).Login(ctx, req.(*LoginReq))
}
return interceptor(ctx, in, info, handler)
}
var _User_serviceDesc = grpc.ServiceDesc{
ServiceName: "pro.User",
HandlerType: (*UserServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "Login",
Handler: _User_Login_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "user.proto",
}
func init() { proto.RegisterFile("user.proto", fileDescriptor_user_41fc5ec05d837255) }
var fileDescriptor_user_41fc5ec05d837255 = []byte{
// 199 bytes of a gzipped FileDescriptorProto
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, 0x00, 0x00, 0xff, 0xff, 0xd1,
0x46, 0xc7, 0x66, 0x1f, 0x01, 0x00, 0x00,
}
Go
1
https://gitee.com/godY/gokit-inaction.git
git@gitee.com:godY/gokit-inaction.git
godY
gokit-inaction
gokit-inaction
201036b8f164

搜索帮助