added helper for InputStreams