Documentation ¶
Index ¶
- Variables
- type AdminUser
- type CustomClaim
- type MongoAdmin
- func (ma *MongoAdmin) DeleteUser(u *user.User) error
- func (ma *MongoAdmin) GetProjects(user ...*user.User) []*project.Project
- func (ma *MongoAdmin) GetUsers() []*user.User
- func (ma *MongoAdmin) IsAdmin(u *user.User) bool
- func (ma *MongoAdmin) RemoveAdmin(u *user.User) error
- func (ma *MongoAdmin) SetAdmin(u *user.User) error
- func (ma *MongoAdmin) SetLevel(u *user.User, level int) error
- type MongoAnnotationStore
- type MongoAuth
- func (ma *MongoAuth) Allowed(req *http.Request) error
- func (ma *MongoAuth) Get(id string) (*user.User, error)
- func (ma *MongoAuth) GetCurrentUser(req *http.Request) *user.User
- func (ma *MongoAuth) GetCurrentUsername(req *http.Request) (string, error)
- func (ma *MongoAuth) Login(u *user.User) error
- func (ma *MongoAuth) Logout(u *user.User) error
- func (ma *MongoAuth) Signup(u *user.User) error
- func (ma *MongoAuth) Update(u *user.User) error
- type MongoProjectACL
- type MongoProjectProvider
- func (mpp *MongoProjectProvider) AddContributor(u *user.User, p *project.Project) error
- func (mpp *MongoProjectProvider) AddImage(prj *project.Project, name string, reader io.Reader) error
- func (mpp *MongoProjectProvider) CanAnnotate(u *user.User, p *project.Project) bool
- func (mpp *MongoProjectProvider) CanEdit(u *user.User, p *project.Project) bool
- func (mpp *MongoProjectProvider) Delete(p *project.Project) error
- func (mpp *MongoProjectProvider) Export(p *project.Project, exp exporter.Exporter) io.Reader
- func (mpp *MongoProjectProvider) Get(name string) *project.Project
- func (mpp *MongoProjectProvider) GetAll(u *user.User) []*project.Project
- func (mpp *MongoProjectProvider) GetContributors(p *project.Project) []*user.User
- func (mpp *MongoProjectProvider) New(p *project.Project) error
- func (mpp *MongoProjectProvider) NextImage(prj *project.Project) (string, string, error)
- func (mpp *MongoProjectProvider) RemoveContributor(u *user.User, p *project.Project) error
- func (mpp *MongoProjectProvider) Update(p *project.Project) error
- type MongoProjectStats
- type MongoUserStats
- type ProjectAnnotation
- type UserSearch
Constants ¶
This section is empty.
Variables ¶
View Source
var SigningKey = []byte("AllYourBase")
Functions ¶
This section is empty.
Types ¶
type CustomClaim ¶
type CustomClaim struct { ID string Username string jwt.StandardClaims }
type MongoAdmin ¶
type MongoAdmin struct{}
func (*MongoAdmin) DeleteUser ¶
func (ma *MongoAdmin) DeleteUser(u *user.User) error
func (*MongoAdmin) GetProjects ¶
func (ma *MongoAdmin) GetProjects(user ...*user.User) []*project.Project
func (*MongoAdmin) GetUsers ¶
func (ma *MongoAdmin) GetUsers() []*user.User
func (*MongoAdmin) RemoveAdmin ¶
func (ma *MongoAdmin) RemoveAdmin(u *user.User) error
type MongoAnnotationStore ¶
type MongoAnnotationStore struct{}
func (*MongoAnnotationStore) Get ¶
func (ma *MongoAnnotationStore) Get(p *project.Project) []*annotation.Annotation
func (*MongoAnnotationStore) GetImage ¶
func (ma *MongoAnnotationStore) GetImage(p *project.Project, name string) (*annotation.Annotation, error)
func (*MongoAnnotationStore) Save ¶
func (ma *MongoAnnotationStore) Save(p *project.Project, ann *annotation.Annotation) error
type MongoAuth ¶
type MongoAuth struct{}
func (*MongoAuth) GetCurrentUser ¶
func (*MongoAuth) GetCurrentUsername ¶
type MongoProjectACL ¶
type MongoProjectProvider ¶
type MongoProjectProvider struct{}
func (*MongoProjectProvider) AddContributor ¶
func (*MongoProjectProvider) CanAnnotate ¶
func (*MongoProjectProvider) Delete ¶
func (mpp *MongoProjectProvider) Delete(p *project.Project) error
func (*MongoProjectProvider) Get ¶
func (mpp *MongoProjectProvider) Get(name string) *project.Project
func (*MongoProjectProvider) GetAll ¶
func (mpp *MongoProjectProvider) GetAll(u *user.User) []*project.Project
func (*MongoProjectProvider) GetContributors ¶
func (mpp *MongoProjectProvider) GetContributors(p *project.Project) []*user.User
func (*MongoProjectProvider) RemoveContributor ¶
type MongoProjectStats ¶
type MongoProjectStats struct { }
func (*MongoProjectStats) CountAnnotations ¶
func (s *MongoProjectStats) CountAnnotations(prj *project.Project) int
func (*MongoProjectStats) CountProjects ¶
func (s *MongoProjectStats) CountProjects() int
type MongoUserStats ¶
type MongoUserStats struct{}
func (*MongoUserStats) CountUsers ¶
func (mu *MongoUserStats) CountUsers() int
type ProjectAnnotation ¶
type ProjectAnnotation struct { Pid bson.ObjectId `bson:"pid"` Annotation *annotation.Annotation `bson:"annotation"` }
type UserSearch ¶
type UserSearch struct{}
Click to show internal directories.
Click to hide internal directories.