Beispiel #1
0
func (eng *Engine) readBuffer() []byte {
	r := C.pn_connection_engine_read_buffer(&eng.engine)
	return byteSlice(unsafe.Pointer(r.start), r.size)
}
Beispiel #2
0
func (eng *Engine) buffers() ([]byte, []byte) {
	r := C.pn_connection_engine_read_buffer(&eng.engine)
	w := C.pn_connection_engine_write_buffer(&eng.engine)
	return byteSlice(unsafe.Pointer(r.data), r.size), byteSlice(unsafe.Pointer(w.data), w.size)
}