@Test public void success_DecodePoint_18() throws DecodeException { EncodedPoint encodedPoint = new EncodedPointEd25519(HexEncoder.getBytes("a13f3a02cc97ec252b785702ce5f1a201a0fc7dd177c636c5f97482af7294f5f")); Point point = encodedPoint.decode(); assertThat(point.getX().getInteger(), is(new BigInteger("28991574176798270631055516789513246251336837817295903512076991779188778127680"))); assertThat(point.getY().getInteger(), is(new BigInteger("43109591168687823035564402387271177577811433066020507559569157621096510013345"))); }
@Override public Point decode() throws DecodeException { byte readTarget = value[value.length - 1]; int x0 = ByteUtils.readBit(readTarget, 7); Coordinate y = recoverY(this.value); Coordinate x = recoverX(y, x0); return PointEd25519.fromAffine(x, y); }
EncodedPointEd25519 extends EncodedPoint { @Override public Point decode() throws DecodeException { byte readTarget = value[value.length - 1]; int x0 = ByteUtils.readBit(readTarget, 7); Coordinate y = recoverY(this.value); Coordinate x = recoverX(y, x0); return PointEd25519.fromAffine(x, y); } }
EncodedPointEd25519 extends EncodedPoint { @Override public Point decode() throws DecodeException { byte readTarget = value[value.length - 1]; int x0 = ByteUtils.readBit(readTarget, 7); Coordinate y = recoverY(this.value); Coordinate x = recoverX(y, x0); return PointEd25519.fromAffine(x, y); } EncodedPointEd25519(byte[] value); }
EncodedPointEd25519 extends EncodedPoint { @Override public Point decode() throws DecodeException { byte readTarget = value[value.length - 1]; int x0 = ByteUtils.readBit(readTarget, 7); Coordinate y = recoverY(this.value); Coordinate x = recoverX(y, x0); return PointEd25519.fromAffine(x, y); } EncodedPointEd25519(byte[] value); @Override Point decode(); }
EncodedPointEd25519 extends EncodedPoint { @Override public Point decode() throws DecodeException { byte readTarget = value[value.length - 1]; int x0 = ByteUtils.readBit(readTarget, 7); Coordinate y = recoverY(this.value); Coordinate x = recoverX(y, x0); return PointEd25519.fromAffine(x, y); } EncodedPointEd25519(byte[] value); @Override Point decode();  }