Refactor instance class back into server

@malcyL, @mmmmmrob - I had another look at this and decided I prefer it as you had it with one class, so I've tidied it back up into one. Thoughts?