database

package
v0.0.0-...-e98148d Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2018 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Database

type Database struct {
	Tables map[string]*table.Table
}

Database is a collection of the tables in a database

func FromString

func FromString(input string) (*Database, error)

FromString creates a logical representation of a sqlite database from a series of sql statements in a string.

func (*Database) Directory

func (d *Database) Directory(dir string) error

Directory output the Database as a directory of .sql text files.

func (*Database) File

func (d *Database) File(file string) error

File outputs the Database as a binary sqlite file.

func (Database) SortedTables

func (d Database) SortedTables() ([]string, error)

SortedTables returns the table names of the database, sorted alphabetically first, but also sorting tables with references to other tables after those tables they refer to.

func (Database) String

func (d Database) String() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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