provider

package
v0.0.0-...-70c8363 Latest Latest
Warning

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

Go to latest
Published: Jul 27, 2015 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SELECT_PROVIDER      = `SELECT * from providers WHERE name=$1`
	SELECT_ALL_PROVIDERS = `SELECT * from providers WHERE name != 'SYSTEM'`
)
View Source
const (
	DELETE_PROVIDER = `DELETE from providers WHERE name='%s'`
)
View Source
const (
	INSERT_PROVIDER = `` /* 172-byte string literal not displayed */

)
View Source
const (
	UPDATE_PROVIDER = `` /* 167-byte string literal not displayed */

)

Variables

This section is empty.

Functions

func Delete

func Delete(conn *sqlx.DB, pname string) (err error)

Types

type Provider

type Provider struct {
	Id          int    `json:"id, omitempty" db:"id"`
	Name        string `json:"name" db:"name"`
	DisplayName string `json:"display_name" db:"display_name"`
	Description string `json:"description, omitempty" db:"description"`
	WebURL      string `json:"web_url, omitempty" db:"web_url"`
	IconURL     string `json:"icon_url, omitempty" db:"icon_url"`
	Active      bool   `json:"active, omitempty" db:"active"`
	Voice       string `json:"voice" db:"voice"`
}

func Get

func Get(conn *sqlx.DB, pname string) (p *Provider, err error)

func GetAll

func GetAll(conn *sqlx.DB) (p []*Provider, err error)

func (*Provider) Insert

func (self *Provider) Insert(conn *sqlx.DB) (err error)

func (*Provider) Update

func (self *Provider) Update(conn *sqlx.DB) (err error)

func (*Provider) ValidInsert

func (self *Provider) ValidInsert() error

func (*Provider) ValidUpdate

func (self *Provider) ValidUpdate() error

Jump to

Keyboard shortcuts

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