Skip to content

Commit 0f4b055

Browse files
committed
Added base64 en-/decoding
1 parent b5f741d commit 0f4b055

File tree

10 files changed

+1152
-277
lines changed

10 files changed

+1152
-277
lines changed

ByteBuffer.js

Lines changed: 183 additions & 74 deletions
Large diffs are not rendered by default.

ByteBuffer.min.js

Lines changed: 49 additions & 45 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ByteBuffer.min.map

Lines changed: 3 additions & 3 deletions
Large diffs are not rendered by default.

ByteBuffer.noexpose.js

Lines changed: 179 additions & 74 deletions
Large diffs are not rendered by default.

README.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ ByteBuffer
3636
* `ByteBuffer#writeUTF8String(str[, offset])`, `ByteBuffer#readUTF8String(chars[, offset])` and
3737
`ByteBuffer#readUTF8StringBytes(length[, offset])` using the included UTF8 en-/decoder (full 6 bytes,
3838
[ref](http://en.wikipedia.org/wiki/UTF-8#Description))
39+
* `ByteBuffer.encode64(bb)`, `ByteBuffer.decode64(str)` and `ByteBuffer#toBase64()` using the included Base64
40+
en/-decoder.
3941
* `ByteBuffer#writeLString(str[, offset]))` and `ByteBuffer#readLString([offset])` to write respectively read a
4042
length-prepended (number of characters as UTF8 char) string
4143
* `ByteBuffer#writeVString(str[, offset]))` and `ByteBuffer#readVString([offset])` to write respectively read a
@@ -60,8 +62,9 @@ ByteBuffer
6062
var bb = new ByteBuffer(8).LE().writeInt(1).BE().writeInt(2).flip(); // toHex: <01 00 00 00 00 00 00 02>
6163
```
6264

63-
* `ByteBuffer#toString()`, `ByteBuffer#toHex([wrap])`, `ByteBuffer#toASCII([wrap])` and `ByteBuffer#printDebug()`
64-
(emits hex + ASCII + offsets to console, looks like your favourite hex editor) for pain-free debugging
65+
* `ByteBuffer#toString([enc])`, `ByteBuffer#toHex([wrap])`, `ByteBuffer#toASCII([wrap])`, `ByteBuffer#toUTF8()`,
66+
`ByteBuffer#toBase64()` and `ByteBuffer#printDebug()` (emits hex + ASCII + offsets to console, looks like your
67+
favourite hex editor) for pain-free debugging
6568

6669
Features
6770
--------

0 commit comments

Comments
 (0)