Documentation ¶
Index ¶
- Variables
- type State
- func (s *State) AddUser(i id.ID, username, bcryptPassword string) error
- func (s *State) Exec(query string, args ...any) (sql.Result, error)
- func (s *State) GetAuthClient(clientId string) (*m.AuthClient, error)
- func (s *State) GetUserInfo(id id.ID) (u m.UserInfo, err error)
- func (s *State) GetUserPassword(username string) (u m.UserPassword, err error)
- func (s *State) Open(url string) error
- func (s *State) Query(query string, args ...any) (*sql.Rows, error)
- func (s *State) QueryCode(clientid, codestr string) (code *m.AuthCode, err error)
- func (s *State) QueryRefreshToken(clientId, refreshToken string) (ref []m.RefreshToken, err error)
- func (s *State) QueryRow(query string, args ...any) *sql.Row
- func (s *State) SaveRefreshToken(ref *m.RefreshToken) error
- func (s *State) StoreCode(code *m.AuthCode) error
Constants ¶
This section is empty.
Variables ¶
View Source
var Ctx = State{}
Functions ¶
This section is empty.
Types ¶
type State ¶
type State struct {
// contains filtered or unexported fields
}
func (*State) GetAuthClient ¶
func (s *State) GetAuthClient(clientId string) (*m.AuthClient, error)
query m.AuthClient by client_id
func (*State) GetUserPassword ¶
func (s *State) GetUserPassword(username string) (u m.UserPassword, err error)
func (*State) QueryRefreshToken ¶
func (s *State) QueryRefreshToken(clientId, refreshToken string) (ref []m.RefreshToken, err error)
func (*State) SaveRefreshToken ¶
func (s *State) SaveRefreshToken(ref *m.RefreshToken) error
Click to show internal directories.
Click to hide internal directories.