@Override
    public String toString() {
        return toStringHelper(getClass())
                .add("sourcePort", Integer.toString(sourcePort))
                .add("destinationPort", Integer.toString(destinationPort))
                .add("sequence", Integer.toString(sequence))
                .add("acknowledge", Integer.toString(acknowledge))
                .add("dataOffset", Byte.toString(dataOffset))
                .add("flags", Short.toString(flags))
                .add("windowSize", Short.toString(windowSize))
                .add("checksum", Short.toString(checksum))
                .add("urgentPointer", Short.toString(urgentPointer))
                .add("options", Arrays.toString(options))
                .toString();
    }
@Test
    public void testToStringTcp() throws Exception {
        TCP tcp = deserializer.deserialize(bytePacketTCP4, 0, bytePacketTCP4.length);
        String str = tcp.toString();

        assertTrue(StringUtils.contains(str, "sourcePort=" + 0x50));
        assertTrue(StringUtils.contains(str, "destinationPort=" + 0x60));
        assertTrue(StringUtils.contains(str, "sequence=" + 0x10));
        assertTrue(StringUtils.contains(str, "acknowledge=" + 0x20));
        assertTrue(StringUtils.contains(str, "dataOffset=" + (byte) 0x5));
        assertTrue(StringUtils.contains(str, "flags=" + (short) 0x2));
        assertTrue(StringUtils.contains(str, "windowSize=" + (short) 0x1000));
        assertTrue(StringUtils.contains(str, "checksum=" + (short) 0x1bae));
        assertTrue(StringUtils.contains(str, "urgentPointer=" + (short) 0x1));
    }