Added in API level 1

ECParameterSpec

open class ECParameterSpec : AlgorithmParameterSpec
kotlin.Any
   ↳ java.security.spec.ECParameterSpec

This immutable class specifies the set of domain parameters used with elliptic curve cryptography (ECC).

Summary

Public constructors

Creates elliptic curve domain parameters based on the specified values.

Public methods
open Int

Returns the cofactor.

open EllipticCurve!

Returns the elliptic curve that this parameter defines.

open ECPoint!

Returns the generator which is also known as the base point.

open BigInteger!

Returns the order of the generator.

Public constructors

ECParameterSpec

Added in API level 1
ECParameterSpec(
    curve: EllipticCurve!,
    g: ECPoint!,
    n: BigInteger!,
    h: Int)

Creates elliptic curve domain parameters based on the specified values.

Parameters
curve EllipticCurve!: the elliptic curve which this parameter defines.
g ECPoint!: the generator which is also known as the base point.
n BigInteger!: the order of the generator g.
h Int: the cofactor.
Exceptions
java.lang.NullPointerException if curve, g, or n is null.
java.lang.IllegalArgumentException if n or h is not positive.

Public methods

getCofactor

Added in API level 1
open fun getCofactor(): Int

Returns the cofactor.

Return
Int the cofactor.

getCurve

Added in API level 1
open fun getCurve(): EllipticCurve!

Returns the elliptic curve that this parameter defines.

Return
EllipticCurve! the elliptic curve that this parameter defines.

getGenerator

Added in API level 1
open fun getGenerator(): ECPoint!

Returns the generator which is also known as the base point.

Return
ECPoint! the generator which is also known as the base point.

getOrder

Added in API level 1
open fun getOrder(): BigInteger!

Returns the order of the generator.

Return
BigInteger! the order of the generator.