I can find tons of examples but they seem to either rely mostly on Java libraries or just read characters/lines/etc.
I just want to read in some file and get a byte
This should work (Scala 2.8):
val bis = new BufferedInputStream(new FileInputStream(fileName)) val bArray = Stream.continually(bis.read).takeWhile(-1 !=).map(_.toByte).toArray