mysql

package
v0.0.0-...-6623458 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 16, 2016 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DBID

type DBID uint64

func (DBID) String

func (id DBID) String() string

type Job

type Job struct {
	// contains filtered or unexported fields
}

func (*Job) Content

func (j *Job) Content() []byte

func (*Job) Delete

func (j *Job) Delete() error

func (*Job) ID

func (j *Job) ID() model.DBID

func (*Job) Next

func (j *Job) Next() time.Time

func (*Job) Schedule

func (j *Job) Schedule() schedule.MultiSchedule

func (*Job) SetContent

func (j *Job) SetContent(cont []byte) error

func (*Job) SetNext

func (j *Job) SetNext(next time.Time) error

func (*Job) SetSchedule

func (j *Job) SetSchedule(sched schedule.MultiSchedule) error

func (*Job) SetSubject

func (j *Job) SetSubject(sub string) error

func (*Job) Subject

func (j *Job) Subject() string

func (*Job) User

func (j *Job) User() model.User

type MySQLDBCon

type MySQLDBCon struct {
	// contains filtered or unexported fields
}

func (*MySQLDBCon) AddUser

func (con *MySQLDBCon) AddUser(email string, pwhash []byte, location *time.Location, active bool, acCode string) (model.User, error)

func (*MySQLDBCon) Close

func (con *MySQLDBCon) Close()

func (*MySQLDBCon) InactiveUsers

func (con *MySQLDBCon) InactiveUsers(olderthan time.Time) []model.DBID

func (*MySQLDBCon) JobsBefore

func (con *MySQLDBCon) JobsBefore(t time.Time) (jobs []model.Job)

func (*MySQLDBCon) UserByID

func (con *MySQLDBCon) UserByID(_id model.DBID) (model.User, error)

func (*MySQLDBCon) UserByMail

func (con *MySQLDBCon) UserByMail(email string) (model.User, error)

type User

type User struct {
	// contains filtered or unexported fields
}

func (*User) ActivationCode

func (u *User) ActivationCode() string

func (*User) Active

func (u *User) Active() bool

func (*User) AddJob

func (u *User) AddJob(subject string, content []byte, sched schedule.MultiSchedule, next time.Time) (model.Job, error)

func (*User) CountJobs

func (u *User) CountJobs() (c int)

func (*User) Delete

func (u *User) Delete() error

func (*User) Email

func (u *User) Email() string

func (*User) ID

func (u *User) ID() model.DBID

func (*User) JobByID

func (u *User) JobByID(_id model.DBID) (model.Job, error)

func (*User) Jobs

func (u *User) Jobs() []model.Job

func (*User) Location

func (u *User) Location() *time.Location

func (*User) PWHash

func (u *User) PWHash() []byte

func (*User) SetActivationCode

func (u *User) SetActivationCode(c string) error

func (*User) SetActive

func (u *User) SetActive(b bool) error

func (*User) SetLocation

func (u *User) SetLocation(loc *time.Location) error

func (*User) SetPWHash

func (u *User) SetPWHash(_pwhash []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL