Sqlite3

Made Sqlite into a proper class and got rid of all those static functions.