Method used to check equality with the last command return SW1SW2 ==
pEnum

@param pByte
response to the last command
@param pEnum
responses to check
@return true if the response of the last command is contained in pEnum
177435
public static boolean contains(final byte[] pByte, final SwEnum... pEnum) {
		SwEnum val = SwEnum.getSW(pByte);
		if (LOGGER.isDebugEnabled() && pByte != null) {
			LOGGER.debug("Response Status <"
					+ BytesUtils.bytesToStringNoSpace(Arrays.copyOfRange(pByte, Math.max(pByte.length - 2, 0), pByte.length)) + "> : "
					+ (val != null ? val.getDetail() : "Unknow"));
		}
		return val != null && ArrayUtils.contains(pEnum, val);
	}
778340
private static boolean compareByteValues(byte[] network,byte[] subnet,byte[] ipAddress)
    {    	
    	for(int i=0;i<network.length;i++)
    		if((network[i] & subnet[i]) != (ipAddress[i] & subnet[i]))
    			return false;
    	
    	return true;
    }
1030922
private int ssCompare(int pa, int pb, int p2, int depth) {
        int U1, U2, U1n, U2n;// pointers to T

        for (U1 = depth + pa, U2 = depth + SA[p2], U1n = pb + 2, U2n = SA[p2 + 1] + 2; (U1 < U1n)
            && (U2 < U2n) && (T[start + U1] == T[start + U2]); ++U1, ++U2) {
        }

        return U1 < U1n ? (U2 < U2n ? T[start + U1] - T[start + U2] : 1) : (U2 < U2n ? -1
            : 0);
    }
165588
private static boolean pointEqualsPoint_(Point2D pt_a, Point2D pt_b,
			double tolerance, ProgressTracker progress_tracker) {
		if (Point2D.sqrDistance(pt_a, pt_b) <= tolerance * tolerance)
			return true;

		return false;
	}
850193
public boolean isAffected(byte b) throws IllegalArgumentException {
        if (this.status.length < (b / 8)) {
            throw new IllegalArgumentException("Argument exceeds status!");
        }
        int index_l = (b / 8);

        int index = b % 8; // number of bit to lit... ech
        int n2Pattern = (int) Math.pow(2, index); // hmm no int pows... sucks
        return (this.status[index_l] & n2Pattern) > 0;
    }
1101551
def _buffer_list_equal(a, b):
    
    if len(a) != len(b):
        return False
    if a == b:
        return True
    for ia, ib in zip(a, b):
        # Check byte equality, since bytes are what is actually synced
        # NOTE: Simple ia != ib does not always work as intended, as
        # e.g. memoryview(np.frombuffer(ia, dtype='float32')) !=
        # memoryview(np.frombuffer(b)), since the format info differs.
        if PY3:
            # compare without copying
            if memoryview(ia).cast('B') != memoryview(ib).cast('B'):
                return False
        else:
            # python 2 doesn't have memoryview.cast, so we may have to copy
            if isinstance(ia, memoryview) and ia.format != 'B':
                ia = ia.tobytes()
            if isinstance(ib, memoryview) and ib.format != 'B':
                ib = ib.tobytes()
            if ia != ib:
                return False
    return True
97558
function arrayBufferEquals(ab1, ab2) {
    if (ab1.byteLength !== ab2.byteLength) {
        return false;
    }
    var arr1 = new Uint8Array(ab1);
    var arr2 = new Uint8Array(ab2);
    for (var i = 0, len = arr1.length; i < len; i++) {
        if (arr1[i] !== arr2[i]) {
            return false;
        }
    }
    return true;
}
26074
private boolean matchByte(final ByteBuffer bbuf) throws IOException {
		final byte b = bbuf.get(0);
		return b == getContent().charAt(0);
	}
1071406
private boolean isOnTheSameSideOut(final long pX0, final long pY0, final long pX1, final long pY1) {
        return (pX0 < mXMin && pX1 < mXMin)
                || (pX0 > mXMax && pX1 > mXMax)
                || (pY0 < mYMin && pY1 < mYMin)
                || (pY0 > mYMax && pY1 > mYMax);
    }
1281190
public boolean contentEquals(byte[] bytes, int offset, int len) {
    Preconditions.checkArgument(len >= 0 && offset >= 0 && offset + len <= bytes.length);
    return contentEqualsUnchecked(bytes, offset, len);
  }
309633
static boolean isO2JCached(String key, String protocol, String value) {
        Map<String, String> p2j = o2j.get(key);
        if (p2j == null) {
            return false;
        } else {
            return value.equals(p2j.get(protocol));
        }
    }
501273
private boolean contentEqualsUnchecked(byte[] bytes, int offset, int len) {
    if (length != len) {
      return false;
    }

    return compareToUnchecked(bytes, offset, len) == 0;
  }
207895
private boolean checkCombineValidity(Pail p, CopyArgs args) throws IOException {
        if(args.force) return true;
        PailSpec mine = getSpec();
        PailSpec other = p.getSpec();
        PailStructure structure = mine.getStructure();

        boolean typesSame = structure.getType().equals(other.getStructure().getType());
        //can always append into a "raw" pail
        if(!structure.getType().equals(new byte[0].getClass()) && !typesSame)
            throw new IllegalArgumentException("Cannot combine two pails of different types unless target pail is raw");

        //check that structure will be maintained
        for(String name: p.getUserFileNames()) {
            checkValidStructure(name);
        }


        return mine.getName().equals(other.getName()) && mine.getArgs().equals(other.getArgs());
    }
1180830
public /*@ pure @*/ int cmpPow52(int p5, int p2) {
        if (p5 == 0) {
            int wordcount = p2 >> 5;
            int bitcount = p2 & 0x1f;
            int size = this.nWords + this.offset;
            if (size > wordcount + 1) {
                return 1;
            } else if (size < wordcount + 1) {
                return -1;
            }
            int a = this.data[this.nWords -1];
            int b = 1 << bitcount;
            if (a != b) {
                return ( (a & LONG_MASK) < (b & LONG_MASK)) ? -1 : 1;
            }
            return checkZeroTail(this.data, this.nWords - 1);
        }
        return this.cmp(big5pow(p5).leftShift(p2));
    }
38095
@Pure
	protected int compareConnections(PT p1, PT p2) {
		assert p1 != null && p2 != null;
		return p1.hashCode() - p2.hashCode();
	}
1139281
boolean checkPaddingBytes(QrCode qr, int lengthBytes) {
		boolean a = true;

		for (int i = lengthBytes; i < qr.corrected.length; i++) {
			if (a) {
				if (0b00110111 != (qr.corrected[i] & 0xFF))
					return false;
			} else {
				if (0b10001000 != (qr.corrected[i] & 0xFF)) {
					// the pattern starts over at the beginning of a block. Strictly enforcing the standard
					// requires knowing size of a data chunk and where it starts. Possible but
					// probably not worth the effort the implement as a strict requirement.
					if (0b00110111 == (qr.corrected[i] & 0xFF)) {
						a = true;
					} else {
						return false;
					}
				}
			}
			a = !a;
		}

		return true;
	}
378722
def btc_is_p2pkh_address( address ):
    
    vb = keylib.b58check.b58check_version_byte( address )
    if vb == version_byte:
        return True
    else:
        return False