@Test public void testHashCodeWithOffset() { final int firstHash = CodecUtil.hashCode("zyxabc".toCharArray(), 0, 3); final int secondHash = CodecUtil.hashCode("abczyx".toCharArray(), 3, 3); assertEquals(firstHash, secondHash); }
public static int hashCode(final char[] value, final int offset, final int length) { int result = 1; for (int i = offset; i < offset + length; i++) { result = 31 * result + value[i]; } return result; }
CodecUtil { public static int hashCode(final char[] value, final int offset, final int length) { int result = 1; for (int i = offset; i < offset + length; i++) { result = 31 * result + value[i]; } return result; } }
CodecUtil { public static int hashCode(final char[] value, final int offset, final int length) { int result = 1; for (int i = offset; i < offset + length; i++) { result = 31 * result + value[i]; } return result; } private  CodecUtil(); }
CodecUtil { public static int hashCode(final char[] value, final int offset, final int length) { int result = 1; for (int i = offset; i < offset + length; i++) { result = 31 * result + value[i]; } return result; } private  CodecUtil(); @Deprecated // Will be removed in a future version static byte[] toBytes(final CharSequence value, final byte[] oldBuffer); @Deprecated // Will be removed in a future version static byte[] toBytes(final char[] value, final byte[] oldBuffer, final int length); @Deprecated // Will be removed in a future version static byte[] toBytes(final char[] value, final byte[] oldBuffer, final int offset, final int length); static byte[] toBytes(final char[] value, final int length); static char[] fromBytes(final byte[] value); static void toBytes(final CharSequence value, final MutableDirectBuffer buffer); static void toBytes(final char[] value, final MutableDirectBuffer oldBuffer, final int length); static void toBytes(
        final char[] value, final MutableDirectBuffer buffer, final int offset, final int length); static boolean equals(
        final char[] value,
        final char[] expected,
        final int offset,
        final int expectedOffset,
        final int length); static boolean equals(final char[] value, final char[] expected, final int length); static boolean equals(final char[] value, final String expected, final int length); static int hashCode(final char[] value, final int offset, final int length); static void indent(final StringBuilder builder, final int level); static void appendData(final StringBuilder builder, final byte[] dataField, final int length); static void appendBuffer(
        final StringBuilder builder, final MutableDirectBuffer buffer, final int offset, final int length); static void appendFloat(final StringBuilder builder, final DecimalFloat price); }
CodecUtil { public static int hashCode(final char[] value, final int offset, final int length) { int result = 1; for (int i = offset; i < offset + length; i++) { result = 31 * result + value[i]; } return result; } private  CodecUtil(); @Deprecated // Will be removed in a future version static byte[] toBytes(final CharSequence value, final byte[] oldBuffer); @Deprecated // Will be removed in a future version static byte[] toBytes(final char[] value, final byte[] oldBuffer, final int length); @Deprecated // Will be removed in a future version static byte[] toBytes(final char[] value, final byte[] oldBuffer, final int offset, final int length); static byte[] toBytes(final char[] value, final int length); static char[] fromBytes(final byte[] value); static void toBytes(final CharSequence value, final MutableDirectBuffer buffer); static void toBytes(final char[] value, final MutableDirectBuffer oldBuffer, final int length); static void toBytes(
        final char[] value, final MutableDirectBuffer buffer, final int offset, final int length); static boolean equals(
        final char[] value,
        final char[] expected,
        final int offset,
        final int expectedOffset,
        final int length); static boolean equals(final char[] value, final char[] expected, final int length); static boolean equals(final char[] value, final String expected, final int length); static int hashCode(final char[] value, final int offset, final int length); static void indent(final StringBuilder builder, final int level); static void appendData(final StringBuilder builder, final byte[] dataField, final int length); static void appendBuffer(
        final StringBuilder builder, final MutableDirectBuffer buffer, final int offset, final int length); static void appendFloat(final StringBuilder builder, final DecimalFloat price); static final byte[] BODY_LENGTH; static final int MISSING_INT; static final char MISSING_CHAR; static final long MISSING_LONG; static final char ENUM_MISSING_CHAR; static final int ENUM_MISSING_INT; static final String ENUM_MISSING_STRING; static final char ENUM_UNKNOWN_CHAR; static final int ENUM_UNKNOWN_INT; static final String ENUM_UNKNOWN_STRING; }