ledger-core
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
ledger::core::BitcoinLikeKeychain Class Referenceabstract
+ Inheritance diagram for ledger::core::BitcoinLikeKeychain:

Public Types

enum  KeyPurpose { RECEIVE, CHANGE }
 
using Address = std::shared_ptr< BitcoinLikeAddress >
 

Public Member Functions

 BitcoinLikeKeychain (const std::shared_ptr< api::DynamicObject > &configuration, const api::Currency &params, int account, const std::shared_ptr< Preferences > &preferences)
 
virtual bool markAsUsed (const std::vector< std::string > &addresses)
 
virtual bool markAsUsed (const std::string &address)
 
virtual bool markPathAsUsed (const DerivationPath &path)=0
 
virtual std::vector< Address > getAllObservableAddresses (uint32_t from, uint32_t to)=0
 
virtual std::vector< Address > getAllObservableAddresses (KeyPurpose purpose, uint32_t from, uint32_t to)=0
 
virtual Address getFreshAddress (KeyPurpose purpose)=0
 
virtual std::vector< Address > getFreshAddresses (KeyPurpose purpose, size_t n)=0
 
virtual Option< KeyPurpose > getAddressPurpose (const std::string &address) const =0
 
virtual Option< std::string > getAddressDerivationPath (const std::string &address) const =0
 
virtual bool isEmpty () const =0
 
int getAccountIndex () const
 
const api::BitcoinLikeNetworkParametersgetNetworkParameters () const
 
const api::CurrencygetCurrency () const
 
virtual Option< std::vector< uint8_t > > getPublicKey (const std::string &address) const =0
 
std::shared_ptr< api::DynamicObjectgetConfiguration () const
 
const DerivationSchemegetDerivationScheme () const
 
const DerivationSchemegetFullDerivationScheme () const
 
std::string getKeychainEngine () const
 
bool isSegwit () const
 
bool isNativeSegwit () const
 
virtual std::string getRestoreKey () const =0
 
virtual int32_t getObservableRangeSize () const =0
 
virtual bool contains (const std::string &address) const =0
 
virtual int32_t getOutputSizeAsSignedTxInput () const =0
 

Static Public Member Functions

static bool isSegwit (const std::string &keychainEngine)
 
static bool isNativeSegwit (const std::string &keychainEngine)
 

Protected Member Functions

std::shared_ptr< PreferencesgetPreferences () const
 
DerivationSchemegetDerivationScheme ()
 

The documentation for this class was generated from the following files: