extend the example tool to allow reading/writing data from/to the filesystem

instead of having to use i/o redirection to achieve the same result
(especially useful for get_multi commands that can now save all retrieved
 keys in an output directory)