Stay organized with collections
Save and categorize content based on your preferences.
EdECPoint
class EdECPoint
An elliptic curve point used to specify keys as defined by RFC 8032: Edwards-Curve Digital Signature Algorithm (EdDSA). These points are distinct from the points represented by ECPoint
, and they are intended for use with algorithms based on RFC 8032 such as the EdDSA Signature
algorithm.
An EdEC point is specified by its y-coordinate value and a boolean that indicates whether the x-coordinate is odd. The y-coordinate is an element of the field of integers modulo some value p that is determined by the algorithm parameters. This field element is represented by a BigInteger
, and implementations that consume objects of this class may reject integer values which are not in the range [0, p).
Summary
Public constructors |
Construct an EdECPoint.
|
Public methods |
BigInteger |
Get the y-coordinate of the point.
|
Boolean |
Get whether the x-coordinate of the point is odd.
|
Public constructors
EdECPoint
EdECPoint(
xOdd: Boolean,
y: BigInteger)
Construct an EdECPoint.
Parameters |
xOdd |
Boolean: whether the x-coordinate is odd. |
y |
BigInteger: the y-coordinate, represented using a BigInteger . |
Exceptions |
java.lang.NullPointerException |
if y is null. |
Public methods
getY
fun getY(): BigInteger
Get the y-coordinate of the point.
Return |
BigInteger |
the y-coordinate, represented using a BigInteger . |
isXOdd
fun isXOdd(): Boolean
Get whether the x-coordinate of the point is odd.
Return |
Boolean |
a boolean indicating whether the x-coordinate is odd. |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-02-10 UTC."],[],[],null,["# EdECPoint\n\nAdded in [API level 33](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)\n\nEdECPoint\n=========\n\n```\nclass EdECPoint\n```\n\n|---|-----------------------------------|\n| [kotlin.Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html) ||\n| ↳ | [java.security.spec.EdECPoint](#) |\n\nAn elliptic curve point used to specify keys as defined by [RFC 8032: Edwards-Curve Digital Signature Algorithm (EdDSA)](https://tools.ietf.org/html/rfc8032). These points are distinct from the points represented by `ECPoint`, and they are intended for use with algorithms based on RFC 8032 such as the EdDSA `Signature` algorithm.\n\nAn EdEC point is specified by its y-coordinate value and a boolean that indicates whether the x-coordinate is odd. The y-coordinate is an element of the field of integers modulo some value p that is determined by the algorithm parameters. This field element is represented by a `BigInteger`, and implementations that consume objects of this class may reject integer values which are not in the range \\[0, p).\n\nSummary\n-------\n\n| Public constructors ||\n|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---|\n| [EdECPoint](#EdECPoint(kotlin.Boolean,%20java.math.BigInteger))`(`xOdd:` `[Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)`, `y:` `[BigInteger](../../math/BigInteger.html#)`)` Construct an EdECPoint. |\n\n| Public methods ||\n|------------------------------------------------------------------------------------|---------------------------------------------------------------------------|\n| [BigInteger](../../math/BigInteger.html#) | [getY](#getY())`()` Get the y-coordinate of the point. |\n| [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) | [isXOdd](#isXOdd())`()` Get whether the x-coordinate of the point is odd. |\n\nPublic constructors\n-------------------\n\n### EdECPoint\n\nAdded in [API level 33](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nEdECPoint(\n xOdd: Boolean, \n y: BigInteger)\n```\n\nConstruct an EdECPoint.\n\n| Parameters ||\n|--------|----------------------------------------------------------------------------------------------------------------------|\n| `xOdd` | [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html): whether the x-coordinate is odd. |\n| `y` | [BigInteger](../../math/BigInteger.html#): the y-coordinate, represented using a `BigInteger`. |\n\n| Exceptions ||\n|----------------------------------|-----------------|\n| `java.lang.NullPointerException` | if `y` is null. |\n\nPublic methods\n--------------\n\n### getY\n\nAdded in [API level 33](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nfun getY(): BigInteger\n```\n\nGet the y-coordinate of the point.\n\n| Return ||\n|-------------------------------------------|-----------------------------------------------------|\n| [BigInteger](../../math/BigInteger.html#) | the y-coordinate, represented using a `BigInteger`. |\n\n### isXOdd\n\nAdded in [API level 33](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nfun isXOdd(): Boolean\n```\n\nGet whether the x-coordinate of the point is odd.\n\n| Return ||\n|------------------------------------------------------------------------------------|-------------------------------------------------------|\n| [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) | a boolean indicating whether the x-coordinate is odd. |"]]