Documentation ¶
Index ¶
Constants ¶
View Source
const ( // DIRECT login to the site DIRECT logintype = iota // FLOW or indirect login via login-flow FLOW )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Login ¶
type Login struct { ID int `db:"id"` User string `db:"user"` Created time.Time `db:"created"` Type logintype `db:"type"` }
Login stores user logins
type Repository ¶
type Repository interface { CreateAtomic() (per.Atomic, error) GetSitesByUser(user string) ([]UserSite, error) StoreSiteForUser(user string, sites []UserSite, a per.Atomic) (err error) StoreLogin(login Login, a per.Atomic) (err error) GetUsersForSite(site string) ([]string, error) }
Repository defines the methods interacting with the store
func NewRepository ¶
func NewRepository(c per.Connection) (Repository, error)
NewRepository creates a new instance using an existing connection
Click to show internal directories.
Click to hide internal directories.