Java Array Equal arraysEquals(byte[] a, int ofsA, byte[] b, int ofsB, int len)

Here you can find the source of arraysEquals(byte[] a, int ofsA, byte[] b, int ofsB, int len)

Description

arrays Equals

License

Apache License

Declaration

public static boolean arraysEquals(byte[] a, int ofsA, byte[] b, int ofsB, int len) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {
    public static boolean arraysEquals(byte[] a, int ofsA, byte[] b, int ofsB, int len) {
        int end = ofsA + len;
        while (ofsA < end) {
            if (b[ofsB++] != a[ofsA++]) {
                return false;
            }/*from   www. ja  v a 2 s.  co m*/
        }
        return true;
    }
}

Related

  1. arraysEqual(final Object[] a1, final Object[] a2)
  2. arraysEqual(Object[] array1, Object[] array2)
  3. arraysEqual(String[] arr1, String[] arr2)
  4. arraysEqual(String[] one, String[] other)
  5. arraysEquals(byte[] a, byte[] b)
  6. arraysEquals(byte[] arr1, int offset1, byte[] arr2, int offset2)
  7. arraysEquals(Object[] mThis, Object[] mThat)
  8. blobsAreEqual(byte[] blob1, byte[] blob2)
  9. bytesAreEqual(byte[] b1, byte[] b2)