Documentation ¶
Index ¶
- Variables
- type BindRepo
- type IamCase
- func (uc *IamCase) CanDo(ctx context.Context, username string, resource string, action string) bool
- func (uc *IamCase) CreateToken(ctx context.Context, username, password string) (*Token, error)
- func (u *IamCase) CreateUser(ctx context.Context, user *User) (*User, error)
- func (u *IamCase) GetRolesByUsername(ctx context.Context, username string) ([]*Role, error)
- type IamRepo
- type PolicyRepo
- type Role
- type RoleRepo
- type TenantRepo
- type Token
- type User
- type UserRepo
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrExistUsername = errors.New("已存在的用户名") ErrNotFound = errors.New("记录不存在") ErrNotFoundUser = errors.New("用户名不存在") )
View Source
var ProviderSet = wire.NewSet(NewIamCase)
Functions ¶
This section is empty.
Types ¶
type IamCase ¶
type IamCase struct {
// contains filtered or unexported fields
}
func NewIamCase ¶
func (*IamCase) CreateToken ¶
func (*IamCase) CreateUser ¶
CreateUser hashed password and create a new user.
type PolicyRepo ¶
type PolicyRepo interface{}
type TenantRepo ¶
type TenantRepo interface{}
Click to show internal directories.
Click to hide internal directories.