Documentation
¶
Index ¶
- func RegisterAuthHandlerServer(s *grpc.Server, srv AuthHandlerServer)
- type AuthHandlerClient
- type AuthHandlerServer
- type HttpError
- func (*HttpError) Descriptor() ([]byte, []int)
- func (m *HttpError) GetClientError() string
- func (m *HttpError) GetHttpCode() int32
- func (m *HttpError) GetLogError() string
- func (*HttpError) ProtoMessage()
- func (m *HttpError) Reset()
- func (m *HttpError) String() string
- func (m *HttpError) XXX_DiscardUnknown()
- func (m *HttpError) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *HttpError) XXX_Merge(src proto.Message)
- func (m *HttpError) XXX_Size() int
- func (m *HttpError) XXX_Unmarshal(b []byte) error
- type UnimplementedAuthHandlerServer
- type User
- func (*User) Descriptor() ([]byte, []int)
- func (m *User) GetAvatar() []byte
- func (m *User) GetCompanyId() int64
- func (m *User) GetEmail() string
- func (m *User) GetEncryptPassword() string
- func (m *User) GetErr() *HttpError
- func (m *User) GetFirstName() string
- func (m *User) GetFreelancerId() int64
- func (m *User) GetHireManagerId() int64
- func (m *User) GetID() int64
- func (m *User) GetPassword() string
- func (m *User) GetSecondName() string
- func (m *User) GetUserName() string
- func (m *User) GetUserType() string
- func (*User) ProtoMessage()
- func (m *User) Reset()
- func (m *User) String() string
- func (m *User) XXX_DiscardUnknown()
- func (m *User) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *User) XXX_Merge(src proto.Message)
- func (m *User) XXX_Size() int
- func (m *User) XXX_Unmarshal(b []byte) error
- type UserID
- func (*UserID) Descriptor() ([]byte, []int)
- func (m *UserID) GetErr() *HttpError
- func (m *UserID) GetID() int64
- func (*UserID) ProtoMessage()
- func (m *UserID) Reset()
- func (m *UserID) String() string
- func (m *UserID) XXX_DiscardUnknown()
- func (m *UserID) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *UserID) XXX_Merge(src proto.Message)
- func (m *UserID) XXX_Size() int
- func (m *UserID) XXX_Unmarshal(b []byte) error
- type UserRequest
- func (*UserRequest) Descriptor() ([]byte, []int)
- func (m *UserRequest) GetEmail() string
- func (m *UserRequest) GetPassword() string
- func (*UserRequest) ProtoMessage()
- func (m *UserRequest) Reset()
- func (m *UserRequest) String() string
- func (m *UserRequest) XXX_DiscardUnknown()
- func (m *UserRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *UserRequest) XXX_Merge(src proto.Message)
- func (m *UserRequest) XXX_Size() int
- func (m *UserRequest) XXX_Unmarshal(b []byte) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterAuthHandlerServer ¶
func RegisterAuthHandlerServer(s *grpc.Server, srv AuthHandlerServer)
Types ¶
type AuthHandlerClient ¶
type AuthHandlerClient interface { CreateUser(ctx context.Context, in *User, opts ...grpc.CallOption) (*User, error) VerifyUser(ctx context.Context, in *UserRequest, opts ...grpc.CallOption) (*UserID, error) }
AuthHandlerClient is the client API for AuthHandler service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewAuthHandlerClient ¶
func NewAuthHandlerClient(cc *grpc.ClientConn) AuthHandlerClient
type AuthHandlerServer ¶
type AuthHandlerServer interface { CreateUser(context.Context, *User) (*User, error) VerifyUser(context.Context, *UserRequest) (*UserID, error) }
AuthHandlerServer is the server API for AuthHandler service.
type HttpError ¶
type HttpError struct { HttpCode int32 `protobuf:"varint,1,opt,name=HttpCode,proto3" json:"HttpCode,omitempty"` LogError string `protobuf:"bytes,2,opt,name=LogError,proto3" json:"LogError,omitempty"` ClientError string `protobuf:"bytes,3,opt,name=ClientError,proto3" json:"ClientError,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*HttpError) Descriptor ¶
func (*HttpError) GetClientError ¶
func (*HttpError) GetHttpCode ¶
func (*HttpError) GetLogError ¶
func (*HttpError) ProtoMessage ¶
func (*HttpError) ProtoMessage()
func (*HttpError) XXX_DiscardUnknown ¶
func (m *HttpError) XXX_DiscardUnknown()
func (*HttpError) XXX_Marshal ¶
func (*HttpError) XXX_Unmarshal ¶
type UnimplementedAuthHandlerServer ¶
type UnimplementedAuthHandlerServer struct { }
UnimplementedAuthHandlerServer can be embedded to have forward compatible implementations.
func (*UnimplementedAuthHandlerServer) CreateUser ¶
func (*UnimplementedAuthHandlerServer) VerifyUser ¶
func (*UnimplementedAuthHandlerServer) VerifyUser(ctx context.Context, req *UserRequest) (*UserID, error)
type User ¶
type User struct { ID int64 `protobuf:"varint,1,opt,name=ID,proto3" json:"ID,omitempty"` FirstName string `protobuf:"bytes,2,opt,name=FirstName,proto3" json:"FirstName,omitempty"` SecondName string `protobuf:"bytes,3,opt,name=SecondName,proto3" json:"SecondName,omitempty"` UserName string `protobuf:"bytes,4,opt,name=UserName,proto3" json:"UserName,omitempty"` Email string `protobuf:"bytes,5,opt,name=Email,proto3" json:"Email,omitempty"` Password string `protobuf:"bytes,6,opt,name=Password,proto3" json:"Password,omitempty"` EncryptPassword string `protobuf:"bytes,7,opt,name=EncryptPassword,proto3" json:"EncryptPassword,omitempty"` UserType string `protobuf:"bytes,8,opt,name=UserType,proto3" json:"UserType,omitempty"` FreelancerId int64 `protobuf:"varint,9,opt,name=FreelancerId,proto3" json:"FreelancerId,omitempty"` HireManagerId int64 `protobuf:"varint,10,opt,name=HireManagerId,proto3" json:"HireManagerId,omitempty"` CompanyId int64 `protobuf:"varint,11,opt,name=CompanyId,proto3" json:"CompanyId,omitempty"` Avatar []byte `protobuf:"bytes,12,opt,name=Avatar,proto3" json:"Avatar,omitempty"` Err *HttpError `protobuf:"bytes,13,opt,name=Err,proto3" json:"Err,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*User) Descriptor ¶
func (*User) GetCompanyId ¶
func (*User) GetEncryptPassword ¶
func (*User) GetFirstName ¶
func (*User) GetFreelancerId ¶
func (*User) GetHireManagerId ¶
func (*User) GetPassword ¶
func (*User) GetSecondName ¶
func (*User) GetUserName ¶
func (*User) GetUserType ¶
func (*User) ProtoMessage ¶
func (*User) ProtoMessage()
func (*User) XXX_DiscardUnknown ¶
func (m *User) XXX_DiscardUnknown()
func (*User) XXX_Unmarshal ¶
type UserID ¶
type UserID struct { ID int64 `protobuf:"varint,1,opt,name=ID,proto3" json:"ID,omitempty"` Err *HttpError `protobuf:"bytes,2,opt,name=err,proto3" json:"err,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*UserID) Descriptor ¶
func (*UserID) ProtoMessage ¶
func (*UserID) ProtoMessage()
func (*UserID) XXX_DiscardUnknown ¶
func (m *UserID) XXX_DiscardUnknown()
func (*UserID) XXX_Marshal ¶
func (*UserID) XXX_Unmarshal ¶
type UserRequest ¶
type UserRequest struct { Email string `protobuf:"bytes,1,opt,name=email,proto3" json:"email,omitempty"` Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*UserRequest) Descriptor ¶
func (*UserRequest) Descriptor() ([]byte, []int)
func (*UserRequest) GetEmail ¶
func (m *UserRequest) GetEmail() string
func (*UserRequest) GetPassword ¶
func (m *UserRequest) GetPassword() string
func (*UserRequest) ProtoMessage ¶
func (*UserRequest) ProtoMessage()
func (*UserRequest) Reset ¶
func (m *UserRequest) Reset()
func (*UserRequest) String ¶
func (m *UserRequest) String() string
func (*UserRequest) XXX_DiscardUnknown ¶
func (m *UserRequest) XXX_DiscardUnknown()
func (*UserRequest) XXX_Marshal ¶
func (m *UserRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*UserRequest) XXX_Merge ¶
func (m *UserRequest) XXX_Merge(src proto.Message)
func (*UserRequest) XXX_Size ¶
func (m *UserRequest) XXX_Size() int
func (*UserRequest) XXX_Unmarshal ¶
func (m *UserRequest) XXX_Unmarshal(b []byte) error
Click to show internal directories.
Click to hide internal directories.