Substrate.fromPrivateKey constructor
Substrate.fromPrivateKey(
- List<
int> privateKeyBytes, - SubstrateCoins coinType
Create a Substrate context from a private key and coin type.
Implementation
factory Substrate.fromPrivateKey(
List<int> privateKeyBytes,
SubstrateCoins coinType,
) {
final privateKey = SubstratePrvKey.fromBytes(
privateKeyBytes,
coinType.conf,
);
return Substrate._(
privateKey,
privateKey.publicKey,
SubstratePath(),
coinType.conf,
);
}