privateKey property

String? get privateKey

Implementation

String? get privateKey{
  if(_coinType == null) return HEX.encode(_bip32.privateKey!);
  //Bitcoin
  if(_coinType == "0"){
    return  _bip32.toWIF();
  }else if(_coinType=="60"){ //Ethereum
    if(_ethPrivateKey==null) return null;
    return HEX.encode(_ethPrivateKey!.privateKey);
  }
  return null;
}