MCPcopy Create free account
hub / github.com/SocketCluster/socketcluster / asciiToBytes

Function asciiToBytes

app/public/socketcluster-client.js:4344–4351  ·  view source on GitHub ↗
(str)

Source from the content-addressed store, hash-verified

4342}
4343
4344function asciiToBytes (str) {
4345 var byteArray = []
4346 for (var i = 0; i < str.length; ++i) {
4347 // Node's code seems to be doing this and not & 0x7F..
4348 byteArray.push(str.charCodeAt(i) & 0xFF)
4349 }
4350 return byteArray
4351}
4352
4353function utf16leToBytes (str, units) {
4354 var c, hi, lo

Callers 1

asciiWriteFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…