# Packages
Package sqlite defines a simple helper function to call functions with a temporary sqlite database.
# Functions
No description provided by the author
Begin calls Begin on the given DB handle and logs the beginning of a transaction.
CreateAllTables creates all tables in the right order.
CreateTableBooks the database table books if it does not already exist.
CreateTableJobs creates the jobs and jobs status database tables if they do not already exist.
CreateTableLines creates the two tables needed for the storing of text lines in the right order.
CreateTablePages creates the databases table pages if it does not already exist.
No description provided by the author
CreateTableProjects creates the project table if it does not already exist.
CreateTableSessions creates the sessions table.
CreateTableSuggestions creates the suggestion table.
CreateTableTypes creates the types table.
CreateTableUsers creates the users table if it does not already exist.
DeleteJobByID delete the given job from the database table.
No description provided by the author
No description provided by the author
Exec calls Exec on the given DB handle.
FindAllUsers returns all users in the database.
FindBookByID loads the book from the database that is identified by the given ID.
FindBookByProjectID loads the book from the database that is identified by the given project ID.
FindBookPages returns the page IDs for the given book.
FindJobByID returns the given job.
FindLineByID returns the line identified by the given book, page and line ID.
FindPageLines returns all line IDs for the page identified by the given book and page IDs.
No description provided by the author
No description provided by the author
FindProjectPages returns the page IDs for the given project.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
InsertLine inserts the given line into the database.
No description provided by the author
No description provided by the author
InsertSession creates a new unique session for the given user in the database and returns the new session.
InsertUser inserts a new user into the database.
No description provided by the author
NewJob inserts a new running job into the jobs table and returns the new job ID.
No description provided by the author
NewType inserts a new (string-) type into the types tables and returns its id.
NewTypeInserter constructs a new TypeInserter instance.
Query calls Query on the given DB handle.
SetJobStatus sets a new status for a job.
SetJobStatusWithText sets a new status and text (name) for a job.
No description provided by the author
UpdateLine updates the contents for the given line.
No description provided by the author
# Constants
No description provided by the author
ContentsTableName defines the name of the contents table.
Expires defines the time after a session expires.
HashLength defines the lenght of the password hash.
IDLength defines the length of auth tokens.
JobsTableName defines the name of the jobs table.
Max length of type strings.
No description provided by the author
No description provided by the author
ProjectsTableName of the the database table.
SaltLength defines the length of the salt.
Name defines the name of the sessions table.
Status names.
Status names.
Status names.
Status names.
Status IDs.
Status IDs.
Status IDs.
Status IDs.
Status IDs.
Status IDs.
Status IDs.
Status IDs.
Status names.
Status names.
Status names.
Status names.
StatusTableName defines the name of the jobs status table.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
TextLinesTableName defines the name of the textlines table.
ID field.
Name of the types table.
type field.
Name of the table.
# Structs
No description provided by the author
No description provided by the author
Char defines a character.
Line defines the line of a page in a book.
No description provided by the author
No description provided by the author
Project wraps a book with project-related information.
Transaction wraps a sql.Tx to abbort database transactions.
TypeInserter helps handle types with their according type IDs.
# Interfaces
DB defines a simple interface for database handling.
# Type aliases
Chars defines a slice of characters.