Documentation ¶
Index ¶
- Variables
- type RqliteUserRepository
- func (r *RqliteUserRepository) ChangeRoleAttr(userID int64, attr string, val int64) error
- func (r *RqliteUserRepository) ChangeRoleExp(userID int64, exp int64) error
- func (r *RqliteUserRepository) Create(user pb.User) (int64, error)
- func (r *RqliteUserRepository) GetByID(id int64) (pb.User, error)
- func (r *RqliteUserRepository) GetByName(name string) (pb.User, error)
- func (r *RqliteUserRepository) GetRole(userId int64) (pb.Role, error)
- func (r *RqliteUserRepository) List() ([]pb.User, error)
- func (r *RqliteUserRepository) Update(user pb.User) error
- type UserRepository
Constants ¶
This section is empty.
Variables ¶
View Source
var ProviderSet = wire.NewSet(NewRqliteUserRepository)
Functions ¶
This section is empty.
Types ¶
type RqliteUserRepository ¶ added in v0.0.25
type RqliteUserRepository struct {
// contains filtered or unexported fields
}
func (*RqliteUserRepository) ChangeRoleAttr ¶ added in v0.0.25
func (r *RqliteUserRepository) ChangeRoleAttr(userID int64, attr string, val int64) error
func (*RqliteUserRepository) ChangeRoleExp ¶ added in v0.0.25
func (r *RqliteUserRepository) ChangeRoleExp(userID int64, exp int64) error
func (*RqliteUserRepository) Create ¶ added in v0.0.25
func (r *RqliteUserRepository) Create(user pb.User) (int64, error)
func (*RqliteUserRepository) GetByID ¶ added in v0.0.25
func (r *RqliteUserRepository) GetByID(id int64) (pb.User, error)
func (*RqliteUserRepository) GetByName ¶ added in v0.0.25
func (r *RqliteUserRepository) GetByName(name string) (pb.User, error)
func (*RqliteUserRepository) GetRole ¶ added in v0.0.25
func (r *RqliteUserRepository) GetRole(userId int64) (pb.Role, error)
type UserRepository ¶
type UserRepository interface { GetRole(userID int64) (pb.Role, error) ChangeRoleExp(userID int64, exp int64) error ChangeRoleAttr(userID int64, attr string, val int64) error List() ([]pb.User, error) Create(user pb.User) (int64, error) GetByID(id int64) (pb.User, error) GetByName(name string) (pb.User, error) Update(user pb.User) error }
func CreateUserRepository ¶
func CreateUserRepository(id string) (UserRepository, error)
func NewRqliteUserRepository ¶ added in v0.0.25
func NewRqliteUserRepository(logger log.Logger, db *rqlite.Conn) UserRepository
Click to show internal directories.
Click to hide internal directories.