init method

  1. @override
void init(
  1. CipherParameters params
)
override

Init the generator with its initialization params. The type of CipherParameters depends on the algorithm being used (see the documentation of each implementation to find out more).

Implementation

@override
void init(CipherParameters params) {
  ECKeyGeneratorParameters ecparams;

  if (params is ParametersWithRandom) {
    _random = params.random;
    ecparams = params.parameters as ECKeyGeneratorParameters;
  } else {
    _random = SecureRandom();
    ecparams = params as ECKeyGeneratorParameters;
  }

  _params = ecparams.domainParameters;
}