Documentation ¶
Index ¶
- Variables
- func CheckAccess(perm *data.Permission, pathRequest, method string) bool
- type Badger
- func (b *Badger) Backup(w io.Writer, since uint64) error
- func (b *Badger) Check(req data.CheckRequest) (*data.CheckResponse, error)
- func (b *Badger) Close() error
- func (b *Badger) CreateLMap(lmap data.LMap) error
- func (b *Badger) CreatePermission(permission data.Permission) (string, error)
- func (b *Badger) CreateRole(role data.Role) (string, error)
- func (b *Badger) CreateUser(user data.User) (string, error)
- func (b *Badger) DeleteLMap(name string) error
- func (b *Badger) DeletePermission(id string) error
- func (b *Badger) DeleteRole(id string) error
- func (b *Badger) DeleteUser(id string) error
- func (b *Badger) GetLMap(name string) (*data.LMap, error)
- func (b *Badger) GetLMaps(req data.GetLMapRequest) (*data.Response[[]data.LMap], error)
- func (b *Badger) GetPermission(name string) (*data.Permission, error)
- func (b *Badger) GetPermissions(req data.GetPermissionRequest) (*data.Response[[]data.Permission], error)
- func (b *Badger) GetRole(id string) (*data.Role, error)
- func (b *Badger) GetRoles(req data.GetRoleRequest) (*data.Response[[]data.Role], error)
- func (b *Badger) GetUser(req data.GetUserRequest) (*data.UserExtended, error)
- func (b *Badger) GetUsers(req data.GetUserRequest) (*data.Response[[]data.UserExtended], error)
- func (b *Badger) LMapRoleIDs() data.LMapRoleIDs
- func (b *Badger) PatchPermission(patch data.Permission) error
- func (b *Badger) PatchRole(role data.Role) error
- func (b *Badger) PatchUser(user data.User) error
- func (b *Badger) PutLMap(lmap data.LMap) error
- func (b *Badger) PutPermission(permission data.Permission) error
- func (b *Badger) PutRole(role data.Role) error
- func (b *Badger) PutUser(user data.User) error
- func (b *Badger) Restore(r io.Reader) error
- type LMapCacheRoleIDs
- type Logger
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultCacheSize = 100 << 20 // 100 MB
View Source
var ErrFuncExit = errors.New("function exit")
Functions ¶
func CheckAccess ¶
func CheckAccess(perm *data.Permission, pathRequest, method string) bool
Types ¶
type Badger ¶
type Badger struct {
// contains filtered or unexported fields
}
func (*Badger) Check ¶
func (b *Badger) Check(req data.CheckRequest) (*data.CheckResponse, error)
func (*Badger) CreatePermission ¶
func (b *Badger) CreatePermission(permission data.Permission) (string, error)
func (*Badger) DeleteLMap ¶
func (*Badger) DeletePermission ¶
func (*Badger) DeleteRole ¶
func (*Badger) DeleteUser ¶
func (*Badger) GetPermission ¶
func (b *Badger) GetPermission(name string) (*data.Permission, error)
func (*Badger) GetPermissions ¶
func (b *Badger) GetPermissions(req data.GetPermissionRequest) (*data.Response[[]data.Permission], error)
func (*Badger) GetUser ¶
func (b *Badger) GetUser(req data.GetUserRequest) (*data.UserExtended, error)
func (*Badger) GetUsers ¶
func (b *Badger) GetUsers(req data.GetUserRequest) (*data.Response[[]data.UserExtended], error)
func (*Badger) LMapRoleIDs ¶ added in v0.7.3
func (b *Badger) LMapRoleIDs() data.LMapRoleIDs
func (*Badger) PatchPermission ¶ added in v0.7.3
func (b *Badger) PatchPermission(patch data.Permission) error
func (*Badger) PutPermission ¶
func (b *Badger) PutPermission(permission data.Permission) error
type LMapCacheRoleIDs ¶ added in v0.7.3
type LMapCacheRoleIDs struct {
// contains filtered or unexported fields
}
func NewLMapCacheRoleIDs ¶ added in v0.7.3
func NewLMapCacheRoleIDs(b *Badger) *LMapCacheRoleIDs
Click to show internal directories.
Click to hide internal directories.