ECPair.fromPublicKey constructor

ECPair.fromPublicKey(
  1. Uint8List publicKey, {
  2. NetworkType network = mainnet,
  3. bool compressed = true,
})

Implementation

factory ECPair.fromPublicKey(Uint8List publicKey,
    {NetworkType network = mainnet, bool compressed = true}) {
  if (!ecc.isPoint(publicKey)) {
    throw new ArgumentError('Point is not on the curve');
  }
  return new ECPair(null, publicKey,
      network: network, compressed: compressed);
}