Class AccountLedgerFactory

A factory class that generates instances of AccountLedger based on provided transport.

Hierarchy (view full)

Constructors

Properties

transport: Transport

Connection to Ledger to use

Methods

  • Discovers accounts in set that already have been used (has any on-chain transactions). It returns an empty array if none of accounts been used. If a used account is preceded by an unused account then it would be ignored.

    Parameters

    • node: Node

      Instance of Node to get account information from

    Returns Promise<AccountBase[]>

  • It throws an exception if Aeternity app on Ledger has an incompatible version, not opened or not installed.

    Returns Promise<void>

  • Get ak_-prefixed address for a given account index.

    Parameters

    • accountIndex: number

      Index of account

    • verify: boolean = false

      Ask user to confirm address by showing it on the device screen

    Returns Promise<`ak_${string}`>