How to create an InputStream of files that have a certain extension in Java? -


i have lot of files in directory want read ones extension (say .txt). want these files added same bufferedinputstream can read them in 1 go. when call read() @ end of file, next 1 should begin.

it feels there should obvious answer had no luck finding it.

you might want take @ sequenceinputstream:

a sequenceinputstream represents logical concatenation of other input streams. starts out ordered collection of input streams , reads first 1 until end of file reached, whereupon reads second one, , on, until end of file reached on last of contained input streams.


Comments

Popular posts from this blog

c# - SelectList with Dictionary, add values to the Dictionary after it's assigned to SelectList -

how can i manage url using .htaccess in php? -

ios - I get the error Property '...' not found on object of type '...' -