public void writeStringSmallLength ( byte [ ] value ) { int length = value . length ; while ( remaining ( ) < length + 1 ) { grow ( ) ; } buf [ position ++ ] = ( byte ) length ; System . arraycopy ( value , 0 , buf , position , length ) ; position += length ; }
Write value with length encoded prefix . value length MUST be less than 251 char