Incredibly basic class for managing simple input/output streams
Project description
Incredibly Easy and Instantly Accessible Input Output
Class IOUtils
with intuitive function names for basic petty I/O streams.
Many times there's no need to have fine-grained control over some I/O. Hence the idea to pack boilerplate code (e.g. the one in os
,glob
) in functions with intuitive names.
glob.os
The first aim is to pack in single functions otherwise long code snippets for operations done via the os
or glob
module. For instance, instead of having in the script something like this:
if not glob.os.path.exists(path):
glob.os.makedirs(path)
Simply write IOUtils.mkdir(path)
. This also allows to have basic glob
and os
functions in a single place. For instance, get all the files in a folder recursively by extension with : IOUtils.ioglob(path,ext='txt',recursive=True)
.
JSON and pickle
It is often the case that for several reasons one need to (1) create simple configuration files or (2) load samll python object (e.g. dictionaries) across scripts. For this use case there's no need to have the fine-grained control provided by json
and pickle
modules. Hence IOUtils
has load_json
/save_json
and load_pickle
/save_pickle
for these cases.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for ie_a_ia_io-0.1.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9d60f62ba6d45f10036da0dbd60702e9f6c83557c402d95684ccfb42395bb050 |
|
MD5 | 1f5406ebe993892a65391066d6c60cd5 |
|
BLAKE2b-256 | b72c165f044e18d7fcbb5807d97e66d61856e1e8a13d0f0cca09afc02548433f |