News for hackers. Stuff that matters.
Re:Cap’n Proto by kentonv on Monday September 12, 2016 @02:26PM (#12482298)
You can certainly serialize to a byte array. The example uses a file descriptor but in fact the code defines an abstract stream type which you can implement any way you want, and you can also obtain pointers to the message's underlying storage in order to extract the bytes directly (avoiding a copy).
Re:Cap’n Proto by easytiger on Tuesday September 13, 2016 @03:38AM (#12486243)
Great thanks. I'll give it a go again for a current project I'm kicking off.
Re:Cap’n Proto by easytiger on Tuesday September 13, 2016 @06:11AM (#12486761)
i've had a look in kj/io.h

I see the classes: ArrayOutputStream/VectorOutputStream, i assumed these are the ones you are discussing.