to top
Android APIs
public class

DHGenParameterSpec

extends Object
implements AlgorithmParameterSpec
java.lang.Object
   ↳ javax.crypto.spec.DHGenParameterSpec

Class Overview

The algorithm parameter specification for generating Diffie-Hellman parameters used in Diffie-Hellman key agreement.

Summary

Public Constructors
DHGenParameterSpec(int primeSize, int exponentSize)
Creates a new DHGenParameterSpec instance with the specified parameters.
Public Methods
int getExponentSize()
Returns the size of the random exponent in bits.
int getPrimeSize()
Returns the size of the prime modulus in bits.
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public DHGenParameterSpec (int primeSize, int exponentSize)

Since: API Level 1

Creates a new DHGenParameterSpec instance with the specified parameters.

Parameters
primeSize the size of the prime modulus in bits.
exponentSize the size of the random exponent in bits.

Public Methods

public int getExponentSize ()

Since: API Level 1

Returns the size of the random exponent in bits.

Returns
  • the size of the random exponent in bits.

public int getPrimeSize ()

Since: API Level 1

Returns the size of the prime modulus in bits.

Returns
  • the size of the prime modulus in bits.