What are the differences between BufferedReader
, BufferedInputStream
and Scanner
in java? BufferedReader
reads the text and BufferedInputStream
reads byte
. Is there any difference other than this?
相关问题
- Delete Messages from a Topic in Apache Kafka
- Jackson Deserialization not calling deserialize on
- How to maintain order of key-value in DataFrame sa
- StackExchange API - Deserialize Date in JSON Respo
- Difference between Types.INTEGER and Types.NULL in
I guess, the difference is the same as between reader and inputstream: one is character-based, another is byte-based. For example, reader normally supports encoding...
Edit: Check this question: The difference between InputStream and InputStreamReader when reading multi-byte characters
BufferedInputStream
reads the data in the buffer as bytes by usingInputStream
.BufferedReader
reads the text but not as bytes andBufferedReader
is efficient reading of characters,arrays and lines.