An InputStream generates values of type c in the IO monad.
Two primitive operations are defined on InputStream:
read :: InputStream c -> IO (Maybe c)reads a value from the stream, where "end of stream" is signaled by read returning Nothing.unRead :: c -> InputStream c -> IO ()"pushes back" a value to the stream.
It is intended that InputStreams obey the following law:
unRead c stream >> read stream === return (Just c)Instances6BufferedIO, RawIO, IODevice
BufferedIO (InputStream ByteString)Defined in io-streams-1.5.2.2 · System.IO.Streams.InternalBufferedIO (StreamPair ByteString)Defined in io-streams-1.5.2.2 · System.IO.Streams.InternalRawIO (InputStream ByteString)Defined in io-streams-1.5.2.2 · System.IO.Streams.InternalThe offset argument is ignored if present.
RawIO (StreamPair ByteString)Defined in io-streams-1.5.2.2 · System.IO.Streams.InternalThe offset argument is ignored if present.
IODevice (InputStream ByteString)Defined in io-streams-1.5.2.2 · System.IO.Streams.InternalIODevice (StreamPair ByteString)Defined in io-streams-1.5.2.2 · System.IO.Streams.Internal