package
0.0.0-20210127022441-ac8b7ceb0103
Repository: https://github.com/gavinxu520/go-ethereum-analysis.git
Documentation: pkg.go.dev

# Packages

Package abi implements the Ethereum ABI (Application Binary Interface).
Package keystore implements encrypted storage of secp256k1 private keys.
Package usbwallet implements support for USB hardware wallets.

# Functions

NewAuthNeededError creates a new authentication error with the extra details about the needed fields set.
NewManager creates a generic account manager to sign transaction via various supported backends.
ParseDerivationPath converts a user specified derivation path string to the internal binary representation.

# Constants

WalletArrived is fired when a new wallet is detected either via USB or via a filesystem event in the keystore.
WalletDropped.
WalletOpened is fired when a wallet is successfully opened with the purpose of starting any background processes such as automatic key derivation.

# Variables

DefaultBaseDerivationPath is the base path from which custom derivation endpoints are incremented.
DefaultLedgerBaseDerivationPath is the base path from which custom derivation endpoints are incremented.
DefaultRootDerivationPath is the root path to which custom derivation endpoints are appended.
ErrInvalidPassphrase is returned when a decryption operation receives a bad passphrase.
ErrNotSupported is returned when an operation is requested from an account backend that it does not support.
ErrUnknownAccount is returned for any requested operation for which no backend provides the specified account.
ErrUnknownWallet is returned for any requested operation for which no backend provides the specified wallet.
ErrWalletAlreadyOpen is returned if a wallet is attempted to be opened the second time.
ErrWalletClosed is returned if a wallet is attempted to be opened the secodn time.

# Structs

Account represents an Ethereum account located at a specific location defined by the optional URL field.
AuthNeededError is returned by backends for signing requests where the user is required to provide further authentication before signing can succeed.
是accounts模块对外导出的主要的结构和方法之一.
URL represents the canonical identification URL of a wallet or account.
WalletEvent is an event fired by an account backend when a wallet arrival or departure is detected.

# Interfaces

todo 其实对外面来说 Backend 才是一个大的钱包, 而 Wallet 则是代表 每个账户 (Manager 操作的是 Backend 而不是 Wallet) todo keystore 类型的钱包中 keystore 实例,和 usbwallet 类型钱包中 hub 实例, 其实就是两种类型钱包的 Backend 实现.
todo 注意: 一个Wallet对象(如keyStoreWallet)仅仅只代表了一个账户,而不是多个.

# Type aliases

DerivationPath represents the computer friendly version of a hierarchical deterministic wallet account derivaion path.
WalletEventType represents the different event types that can be fired by the wallet subscription subsystem.