signMessage method

Future<String> signMessage(
  1. String message
)

Signs message with this wallet, through the signer bound to it when it was built (WaaS today). Fails when no WalletSigner was installed on the client this wallet came from — see signer.

Implementation

Future<String> signMessage(String message) async {
  final signer = this.signer;
  if (signer == null) {
    throw DynamicStateException("no WalletSigner installed to sign with (e.g. useWaas) — add one first");
  }
  final signature = await signer.signMessage(this.chain, this.address, message);
  return signature;
}