@Override
  public boolean equalsKey(Key o) {
    if (!(o instanceof EciesPrivateKey)) {
      return false;
    }
    EciesPrivateKey other = (EciesPrivateKey) o;
    if (!publicKey.equalsKey(other.publicKey)) {
      return false;
    }
    if (x25519PrivateKeyBytes == null && other.x25519PrivateKeyBytes == null) {
      return nistPrivateKeyValue.equalsSecretBigInteger(other.nistPrivateKeyValue);
    }

    return x25519PrivateKeyBytes.equalsSecretBytes(other.x25519PrivateKeyBytes);
  }
Creates a new ECIES private key using NIST Curves.

@param publicKey Corresponding ECIES public key for this private key
@param nistPrivateKeyValue private big integer value in bigendian representation
java_src/src/main/java/com/google/crypto/tink/hybrid/EciesPrivateKey.java