data_base
❭ utils
❭ split_file_to_buffers
split_file_to_buffers¶
-
data_base.utils.split_file_to_buffers(f, split_str=
'#'
)¶ Reads a file f and splits it wherever
split_str
is found.- Parameters:¶
f (file) – file to be split
split_str (str) – string to split the file. Default is ‘#’
- Returns:¶
list of
StringIO
Buffers.- Return type:¶
list
See also
adapted from http://stackoverflow.com/a/33346758/5082048