A DataInputStream lets an application read primitive Java data types from an underlying input stream in a machine-independent way.