github.com/endophage/docker@v1.4.2-0.20161027011718-242853499895/pkg/graphdb/conn_sqlite3.go (about) 1 // +build cgo 2 3 package graphdb 4 5 import "database/sql" 6 7 // NewSqliteConn opens a connection to a sqlite 8 // database. 9 func NewSqliteConn(root string) (*Database, error) { 10 conn, err := sql.Open("sqlite3", root) 11 if err != nil { 12 return nil, err 13 } 14 return NewDatabase(conn) 15 }