Moved IO stuff to the particular class