Documentation ¶
Index ¶
- type Service
- func (s *Service) AddInfo(ctx context.Context, name, password string) (mid int64, err error)
- func (s *Service) CheckPassword(ctx context.Context, mid int64, password string) (pass bool, err error)
- func (s *Service) Close()
- func (s *Service) FilterName(ctx context.Context, name string) (pass bool)
- func (s *Service) GeneratePassword(ctx context.Context, password string) (hash_password string, err error)
- func (s *Service) GenerateToken(ctx context.Context) (token string, err error)
- func (s *Service) GetInfo(ctx context.Context, mid int64) (info *api.Info, err error)
- func (s *Service) GetMidByName(ctx context.Context, name string) (mid int64, err error)
- func (s *Service) GetProfile(ctx context.Context, mid int64) (profile *api.Profile, err error)
- func (s *Service) GetToken(ctx context.Context, mid int64) (token string, err error)
- func (s *Service) NextID(ctx context.Context) (id int64, err error)
- func (s *Service) Ping(ctx context.Context) (err error)
- func (s *Service) SetEmail(ctx context.Context, mid int64, email string) (err error)
- func (s *Service) SetFace(ctx context.Context, mid int64, face string) (err error)
- func (s *Service) SetName(ctx context.Context, name string, mid int64) (err error)
- func (s *Service) SetPassword(ctx context.Context, mid int64, password string) (err error)
- func (s *Service) SetPhone(ctx context.Context, mid int64, phone string) (err error)
- func (s *Service) SetSex(ctx context.Context, mid int64, sex string) (err error)
- func (s *Service) SetToken(ctx context.Context, token string, mid int64) (err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service service.
func (*Service) CheckPassword ¶
func (s *Service) CheckPassword(ctx context.Context, mid int64, password string) (pass bool, err error)
Check password
func (*Service) FilterName ¶
func (*Service) GeneratePassword ¶
func (s *Service) GeneratePassword(ctx context.Context, password string) (hash_password string, err error)
Hash password
func (*Service) GenerateToken ¶
Generate unique token
func (*Service) GetMidByName ¶
func (*Service) GetProfile ¶
func (*Service) SetPassword ¶
Click to show internal directories.
Click to hide internal directories.