Functions for reading/writing little-endian data using InputStream/OutputStream.
NOTE: This namespace is intended to be used only from within cljam, and should not be used outside cljam.
Functions for reading/writing little-endian data using InputStream/OutputStream. NOTE: This namespace is intended to be used only from within cljam, and should not be used outside cljam.
(read-byte stream)
Reads 1 byte. Returns a byte value.
Reads 1 byte. Returns a byte value.
(read-bytes stream length)
(read-bytes stream buffer offset length)
Reads 'length' bytes to buffer starting from offset bytes. Returns a new byte-array if called without buffer.
Reads 'length' bytes to buffer starting from offset bytes. Returns a new byte-array if called without buffer.
(read-double stream)
Reads 8 bytes. Returns a double value.
Reads 8 bytes. Returns a double value.
(read-float stream)
Reads 4 bytes. Returns a float value.
Reads 4 bytes. Returns a float value.
(read-int stream)
Reads 4 bytes. Returns an int value.
Reads 4 bytes. Returns an int value.
(read-long stream)
Reads 8 bytes. Returns a long value.
Reads 8 bytes. Returns a long value.
(read-null-terminated-string stream)
Reads until next null character. Returns a String without the null.
Reads until next null character. Returns a String without the null.
(read-short stream)
Reads 2 bytes. Returns a short value.
Reads 2 bytes. Returns a short value.
(read-string stream length)
Reads 'length' bytes. Returns a String.
Reads 'length' bytes. Returns a String.
(read-ubyte stream)
Reads 1 byte. Returns an unsigned byte value as long.
Reads 1 byte. Returns an unsigned byte value as long.
(read-uint stream)
Reads 4 bytes. Returns an unsigned int value as long.
Reads 4 bytes. Returns an unsigned int value as long.
(read-ushort stream)
Reads 2 bytes. Returns an unsigned short value as long.
Reads 2 bytes. Returns an unsigned short value as long.
(skip stream length)
Skips over 'length' bytes of data, discarding the skipped bytes.
Skips over 'length' bytes of data, discarding the skipped bytes.
(write-char stream b)
Writes a 1-byte ascii character.
Writes a 1-byte ascii character.
(write-double stream n)
Writes a 8-byte double value.
Writes a 8-byte double value.
(write-float stream n)
Writes a 4-byte float value.
Writes a 4-byte float value.
(write-int stream n)
Writes a 4-byte integer value.
Writes a 4-byte integer value.
(write-long stream n)
Writes an 8-byte long value.
Writes an 8-byte long value.
(write-short stream n)
Writes a 2-byte short value.
Writes a 2-byte short value.
(write-string stream s)
Writes a string as a sequence of ascii characters.
Writes a string as a sequence of ascii characters.
(write-uint stream n)
Writes a 4-byte unsigned integer value.
Writes a 4-byte unsigned integer value.
(write-ushort stream n)
Writes a 2-byte unsigned short value.
Writes a 2-byte unsigned short value.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close