@AccessesPartialKey
  public static PublicKeyVerify create(Ed25519PublicKey key) throws GeneralSecurityException {
    if (!FIPS.isCompatible()) {
      throw new GeneralSecurityException("Can not use Ed25519 in FIPS-mode.");
    }
    return new Ed25519Verify(
        key.getPublicKeyBytes().toByteArray(),
        key.getOutputPrefix().toByteArray(),
        key.getParameters().getVariant().equals(Ed25519Parameters.Variant.LEGACY)
            ? new byte[] {0}
            : new byte[0]);
  }
Ed25519 verifying.

<p>The first call to this function may take longer, because Ed25519Constants needs to be
initialized.

<h3>Usage</h3>

<pre>{@code
// get the publicKey from the other party.
Ed25519Verify verifier = new Ed25519Verify(publicKey);
try {
  verifier.verify(signature, message);
} catch (GeneralSecurityException e) {
  // all the rest of security exceptions.
}
}</pre>

@since 1.1.0
java_src/src/main/java/com/google/crypto/tink/subtle/Ed25519Verify.java