Added Record class, also a bunch of other stuff