Class ByteArrayComparator
java.lang.Object
eu.europa.esig.dss.spi.validation.evidencerecord.ByteArrayComparator
- All Implemented Interfaces:
Serializable
,Comparator<byte[]>
Used to compare two byte arrays.
Inspired by
<a href="https://github.com/bcgit/bc-java/blob/main/pkix/src/main/java/org/bouncycastle/tsp/ers/ByteArrayComparator.java">BC ByteArrayComparator implementation</a>
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionint
compare
(byte[] o1, byte[] o2) static ByteArrayComparator
Returns singleton instance ofByteArrayComparator
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Method Details
-
getInstance
Returns singleton instance ofByteArrayComparator
- Returns:
ByteArrayComparator
-
compare
public int compare(byte[] o1, byte[] o2) - Specified by:
compare
in interfaceComparator<byte[]>
-