added methods to saver class to encode and decode an image to string and back.