| 3 | import org.bouncycastle.math.ec.ECPoint; |
| 4 | |
| 5 | public class ECPair |
| 6 | { |
| 7 | private final ECPoint x; |
| 8 | private final ECPoint y; |
| 9 | |
| 10 | public ECPair(ECPoint x, ECPoint y) |
| 11 | { |
| 12 | this.x = x; |
| 13 | this.y = y; |
| 14 | } |
| 15 | |
| 16 | public ECPoint getX() |
| 17 | { |
| 18 | return x; |
| 19 | } |
| 20 | |
| 21 | public ECPoint getY() |
| 22 | { |
| 23 | return y; |
| 24 | } |
| 25 | |
| 26 | public boolean equals(ECPair other) |
| 27 | { |
| 28 | return other.getX().equals(getX()) && other.getY().equals(getY()); |
| 29 | } |
| 30 | |
| 31 | public boolean equals(Object other) |
| 32 | { |
| 33 | return other instanceof ECPair ? equals((ECPair)other) : false; |
| 34 | } |
| 35 | |
| 36 | public int hashCode() |
| 37 | { |
| 38 | return x.hashCode() + 37 * y.hashCode(); |
| 39 | } |
| 40 | } |
nothing calls this directly
no outgoing calls
no test coverage detected