data

package
v0.0.0-...-2484db1 Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2016 License: MIT Imports: 7 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Connect

func Connect(connectionString string) *sql.DB

func DeleteNote

func DeleteNote(db *sql.DB, id string) error

Types

type Note

type Note struct {
	Id      string
	Title   string
	Body    string
	Updated int64
}

func CreateNote

func CreateNote(db *sql.DB, title string, body string) (Note, error)

func GetAllNotes

func GetAllNotes(db *sql.DB) ([]Note, error)

func GetNote

func GetNote(db *sql.DB, id string) (Note, error)

func MustGetAllNotes

func MustGetAllNotes(db *sql.DB) []Note

func UpdateNote

func UpdateNote(db *sql.DB, note Note) (Note, error)

type UUID

type UUID [16]byte

func NewUUID

func NewUUID() *UUID

Create a new uuid v4

func (*UUID) String

func (u *UUID) String() string

Jump to

Keyboard shortcuts

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