model

package
v0.18.4 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2018 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bag

type Bag map[string]string

Bag is a simple abstraction on the top of a map. It can be stored in a SQL database as a gob BLOB.

func (*Bag) Get

func (b *Bag) Get(key string) string

Get returns a value for the given key.

func (*Bag) Has

func (b *Bag) Has(key string) bool

Has checks if the given key is set.

func (*Bag) Scan

func (b *Bag) Scan(src interface{}) (err error)

Scan satisfy sql.Scanner interface.

func (*Bag) Set

func (b *Bag) Set(key, value string)

Set assigns the value to a given key.

func (Bag) Value

func (b Bag) Value() (driver.Value, error)

Value satisfy driver.Valuer interface.

Jump to

Keyboard shortcuts

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