Added serializer class for reading/writing to files