public Msg putShortString(String data)
    {
        if (data == null) {
            return this;
        }
        ByteBuffer dup = buf.duplicate();
        dup.position(writeIndex);
        writeIndex += Wire.putShortString(dup, data);
        return this;
    }
@Test(expected = IllegalArgumentException.class)
    public void testPutStringLongerThan255InBuilder()
    {
        final Msg.Builder msg = new Msg.Builder();

        char[] charArray = new char[256];
        Arrays.fill(charArray, ' ');
        String str = new String(charArray);

        msg.putShortString(str);
    }