rough implementation of most of the persistance layer
ah, spelling