I'm missing something here -- I have a ByteArray and I want to convert it to a ArrayBuffer or an ArrayBufferView. The ByteArray is coming back from protobufjs and the ArrayBuffer/View is what a websocket.send(...) method requires. hmmmm
ehubbard
11/23/2018, 5:03 PM
Why do I figure out solutions once I ask for help? 😞
Copy code
val bytes:ByteArray = v.protoMarshal()
val uint8Array = Uint8Array(bytes.toTypedArray())
ws.send(uint8Array)