go_micro_srv_account

package
v1.18.0 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2020 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterAccountHandler

func RegisterAccountHandler(s server.Server, hdlr AccountHandler, opts ...server.HandlerOption) error

Types

type AccountService

type AccountService interface {
	Login(ctx context.Context, in *LoginRequest, opts ...client.CallOption) (*LoginResponse, error)
	Logout(ctx context.Context, in *Request, opts ...client.CallOption) (*LogoutResponse, error)
	Info(ctx context.Context, in *Request, opts ...client.CallOption) (*InfoResponse, error)
}

func NewAccountService

func NewAccountService(name string, c client.Client) AccountService

type InfoResponse

type InfoResponse struct {
	Name                 string   `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Avatar               string   `protobuf:"bytes,2,opt,name=avatar,proto3" json:"avatar,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*InfoResponse) Descriptor

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

func (*InfoResponse) GetAvatar

func (m *InfoResponse) GetAvatar() string

func (*InfoResponse) GetName

func (m *InfoResponse) GetName() string

func (*InfoResponse) ProtoMessage

func (*InfoResponse) ProtoMessage()

func (*InfoResponse) Reset

func (m *InfoResponse) Reset()

func (*InfoResponse) String

func (m *InfoResponse) String() string

func (*InfoResponse) Validate

func (m *InfoResponse) Validate() error

Validate checks the field values on InfoResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

func (*InfoResponse) XXX_DiscardUnknown

func (m *InfoResponse) XXX_DiscardUnknown()

func (*InfoResponse) XXX_Marshal

func (m *InfoResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*InfoResponse) XXX_Merge

func (m *InfoResponse) XXX_Merge(src proto.Message)

func (*InfoResponse) XXX_Size

func (m *InfoResponse) XXX_Size() int

func (*InfoResponse) XXX_Unmarshal

func (m *InfoResponse) XXX_Unmarshal(b []byte) error

type InfoResponseValidationError

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

InfoResponseValidationError is the validation error returned by InfoResponse.Validate if the designated constraints aren't met.

func (InfoResponseValidationError) Cause

Cause function returns cause value.

func (InfoResponseValidationError) Error

Error satisfies the builtin error interface

func (InfoResponseValidationError) ErrorName

func (e InfoResponseValidationError) ErrorName() string

ErrorName returns error name.

func (InfoResponseValidationError) Field

Field function returns field value.

func (InfoResponseValidationError) Key

Key function returns key value.

func (InfoResponseValidationError) Reason

Reason function returns reason value.

type LoginRequest

type LoginRequest struct {
	Username             string   `protobuf:"bytes,1,opt,name=username,proto3" json:"username,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 (*LoginRequest) Descriptor

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

func (*LoginRequest) GetPassword

func (m *LoginRequest) GetPassword() string

func (*LoginRequest) GetUsername

func (m *LoginRequest) GetUsername() string

func (*LoginRequest) ProtoMessage

func (*LoginRequest) ProtoMessage()

func (*LoginRequest) Reset

func (m *LoginRequest) Reset()

func (*LoginRequest) String

func (m *LoginRequest) String() string

func (*LoginRequest) Validate

func (m *LoginRequest) Validate() error

Validate checks the field values on LoginRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

func (*LoginRequest) XXX_DiscardUnknown

func (m *LoginRequest) XXX_DiscardUnknown()

func (*LoginRequest) XXX_Marshal

func (m *LoginRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*LoginRequest) XXX_Merge

func (m *LoginRequest) XXX_Merge(src proto.Message)

func (*LoginRequest) XXX_Size

func (m *LoginRequest) XXX_Size() int

func (*LoginRequest) XXX_Unmarshal

func (m *LoginRequest) XXX_Unmarshal(b []byte) error

type LoginRequestValidationError

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

LoginRequestValidationError is the validation error returned by LoginRequest.Validate if the designated constraints aren't met.

func (LoginRequestValidationError) Cause

Cause function returns cause value.

func (LoginRequestValidationError) Error

Error satisfies the builtin error interface

func (LoginRequestValidationError) ErrorName

func (e LoginRequestValidationError) ErrorName() string

ErrorName returns error name.

func (LoginRequestValidationError) Field

Field function returns field value.

func (LoginRequestValidationError) Key

Key function returns key value.

func (LoginRequestValidationError) Reason

Reason function returns reason value.

type LoginResponse

type LoginResponse struct {
	Token                string   `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*LoginResponse) Descriptor

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

func (*LoginResponse) GetToken

func (m *LoginResponse) GetToken() string

func (*LoginResponse) ProtoMessage

func (*LoginResponse) ProtoMessage()

func (*LoginResponse) Reset

func (m *LoginResponse) Reset()

func (*LoginResponse) String

func (m *LoginResponse) String() string

func (*LoginResponse) Validate

func (m *LoginResponse) Validate() error

Validate checks the field values on LoginResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

func (*LoginResponse) XXX_DiscardUnknown

func (m *LoginResponse) XXX_DiscardUnknown()

func (*LoginResponse) XXX_Marshal

func (m *LoginResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*LoginResponse) XXX_Merge

func (m *LoginResponse) XXX_Merge(src proto.Message)

func (*LoginResponse) XXX_Size

func (m *LoginResponse) XXX_Size() int

func (*LoginResponse) XXX_Unmarshal

func (m *LoginResponse) XXX_Unmarshal(b []byte) error

type LoginResponseValidationError

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

LoginResponseValidationError is the validation error returned by LoginResponse.Validate if the designated constraints aren't met.

func (LoginResponseValidationError) Cause

Cause function returns cause value.

func (LoginResponseValidationError) Error

Error satisfies the builtin error interface

func (LoginResponseValidationError) ErrorName

func (e LoginResponseValidationError) ErrorName() string

ErrorName returns error name.

func (LoginResponseValidationError) Field

Field function returns field value.

func (LoginResponseValidationError) Key

Key function returns key value.

func (LoginResponseValidationError) Reason

Reason function returns reason value.

type LogoutResponse

type LogoutResponse struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*LogoutResponse) Descriptor

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

func (*LogoutResponse) ProtoMessage

func (*LogoutResponse) ProtoMessage()

func (*LogoutResponse) Reset

func (m *LogoutResponse) Reset()

func (*LogoutResponse) String

func (m *LogoutResponse) String() string

func (*LogoutResponse) Validate

func (m *LogoutResponse) Validate() error

Validate checks the field values on LogoutResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

func (*LogoutResponse) XXX_DiscardUnknown

func (m *LogoutResponse) XXX_DiscardUnknown()

func (*LogoutResponse) XXX_Marshal

func (m *LogoutResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*LogoutResponse) XXX_Merge

func (m *LogoutResponse) XXX_Merge(src proto.Message)

func (*LogoutResponse) XXX_Size

func (m *LogoutResponse) XXX_Size() int

func (*LogoutResponse) XXX_Unmarshal

func (m *LogoutResponse) XXX_Unmarshal(b []byte) error

type LogoutResponseValidationError

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

LogoutResponseValidationError is the validation error returned by LogoutResponse.Validate if the designated constraints aren't met.

func (LogoutResponseValidationError) Cause

Cause function returns cause value.

func (LogoutResponseValidationError) Error

Error satisfies the builtin error interface

func (LogoutResponseValidationError) ErrorName

func (e LogoutResponseValidationError) ErrorName() string

ErrorName returns error name.

func (LogoutResponseValidationError) Field

Field function returns field value.

func (LogoutResponseValidationError) Key

Key function returns key value.

func (LogoutResponseValidationError) Reason

Reason function returns reason value.

type Request

type Request struct {
	Id                   int64    `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Request) Descriptor

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

func (*Request) GetId

func (m *Request) GetId() int64

func (*Request) ProtoMessage

func (*Request) ProtoMessage()

func (*Request) Reset

func (m *Request) Reset()

func (*Request) String

func (m *Request) String() string

func (*Request) Validate

func (m *Request) Validate() error

Validate checks the field values on Request with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

func (*Request) XXX_DiscardUnknown

func (m *Request) XXX_DiscardUnknown()

func (*Request) XXX_Marshal

func (m *Request) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Request) XXX_Merge

func (m *Request) XXX_Merge(src proto.Message)

func (*Request) XXX_Size

func (m *Request) XXX_Size() int

func (*Request) XXX_Unmarshal

func (m *Request) XXX_Unmarshal(b []byte) error

type RequestValidationError

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

RequestValidationError is the validation error returned by Request.Validate if the designated constraints aren't met.

func (RequestValidationError) Cause

func (e RequestValidationError) Cause() error

Cause function returns cause value.

func (RequestValidationError) Error

func (e RequestValidationError) Error() string

Error satisfies the builtin error interface

func (RequestValidationError) ErrorName

func (e RequestValidationError) ErrorName() string

ErrorName returns error name.

func (RequestValidationError) Field

func (e RequestValidationError) Field() string

Field function returns field value.

func (RequestValidationError) Key

func (e RequestValidationError) Key() bool

Key function returns key value.

func (RequestValidationError) Reason

func (e RequestValidationError) Reason() string

Reason function returns reason value.

Jump to

Keyboard shortcuts

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