ECPair.fromPublicKey constructor

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

Implementation

factory ECPair.fromPublicKey(Uint8List publicKey, {NetworkType? network, bool? compressed}) {
  if (!ecc.isPoint(publicKey)) throw ArgumentError('Point is not on the curve');

  return ECPair(null, publicKey, network: network, compressed: compressed);
}