Documentation ¶
Index ¶
- func Get(c context.Context, key string) (interface{}, error)
- func GetPerms(c context.Context, user *model.User, owner, name string) *model.Perm
- func GetRepos(c context.Context, user *model.User) []*model.RepoLite
- func Set(c context.Context, key string, value interface{}) error
- func SetPerms(c context.Context, user *model.User, perm *model.Perm, owner, name string)
- func SetRepos(c context.Context, user *model.User, repos []*model.RepoLite)
- func ToContext(c Setter, cache Cache)
- type Cache
- type Setter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetPerms ¶
GetRepos returns the user permissions to the named repository from the cache associated with the current context.
func GetRepos ¶
GetRepos returns the list of user repositories from the cache associated with the current context.
func SetPerms ¶
SetRepos adds the listof user permissions to the named repsotiory to the cache assocaited with the current context.
Types ¶
Click to show internal directories.
Click to hide internal directories.