question: private ByteBuffer [ ] split ( ByteBuffer original , int pos ) { byte [ ] data = new byte [ pos ] ; original . get ( data ) ; ByteBuffer [ ] res = new ByteBuffer [ 2 ] ; res [ 0 ] = ByteBuffer . wrap ( data ) ; data = new byte [ original . remaining ( ) ] ; original . get ( data ) ; res [ 1 ] = ByteBuffer . wrap ( data ) ; return res ; }
target:  Splits given byte buffer into two byte buffers.