database

package
v0.0.0-...-799765a Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2020 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Add

func Add(db *sql.DB, entry token.Token) (bool, error)

Add checks if an entry is already in the database and if found updates the entry, else it adds the entry.

func Get

func Get(db *sql.DB, value string) (token.Token, error)

Get finds and returns an entry from the database.

func Insert

func Insert(db *sql.DB, entry token.Token) error

Insert adds a new entry into the database.

func Open

func Open(databaseName string) (db *sql.DB)

Open opens a database and creates one if not found.

func Remove

func Remove(db *sql.DB, entry token.Token) error

Remove deletes a token entry from the database.

Types

This section is empty.

Jump to

Keyboard shortcuts

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