ledger-core
|
#include <BitcoinLikeInput.hpp>
Public Member Functions | |
virtual std::experimental::optional< std::string > | getAddress ()=0 |
virtual std::vector< std::vector< uint8_t > > | getPublicKeys ()=0 |
virtual std::vector< std::shared_ptr< DerivationPath > > | getDerivationPath ()=0 |
virtual std::shared_ptr< Amount > | getValue ()=0 |
virtual std::experimental::optional< std::string > | getPreviousTxHash ()=0 |
virtual bool | isCoinbase ()=0 |
virtual std::experimental::optional< std::string > | getCoinbase ()=0 |
virtual std::experimental::optional< int32_t > | getPreviousOutputIndex ()=0 |
virtual std::shared_ptr< BitcoinLikeOutput > | getPreviousOuput ()=0 |
virtual std::vector< uint8_t > | getScriptSig ()=0 |
virtual std::shared_ptr< BitcoinLikeScript > | parseScriptSig ()=0 |
virtual void | setScriptSig (const std::vector< uint8_t > &scriptSig)=0 |
virtual void | pushToScriptSig (const std::vector< uint8_t > &data)=0 |
virtual void | setSequence (int32_t sequence)=0 |
virtual int64_t | getSequence ()=0 |
virtual void | getPreviousTransaction (const std::shared_ptr< BinaryCallback > &callback)=0 |
virtual void | setP2PKHSigScript (const std::vector< uint8_t > &signature)=0 |
Class representing Bitcoin inputs.
|
pure virtual |
Returns the address of the input (if an address can be computed).
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Stored data cointained in coinbase.
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Returns the derivation path of this input if the address is owned by the wallet.
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Retrieve the output spent by this input. Depending on the implementation this method may use a lock to fetch data from a database. Therefore it may have poor performance, use with caution.
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Get output index, it identifies which UTXO from tht transaction to spend.
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Get the previous transaction associated with the input.
|
pure virtual |
Get the transaction hash of the output spent by this input. The result can be NULL if the output is not owned by the wallet.
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Returns the public associated with the address. This value can be NULL if you are building a transaction with an address which does not belong to your wallet.
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Get ScriptSig of this input. The scriptsig is the first half of a script necessary to spend a previous output.
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Get the sequence number of this input.
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Returns the value of the amount. Depending on the backend this value may not exist if the input is not owned by the wallet.
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Check whether input is for a coinbase.
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Parse the script sig to a [[BitcoinLikeScript]].
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Push data to the end of the current ScriptSig.
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Easy way to set the P2PKH script signature. Shorthand for input.pushToScriptSig(input.getPublicKeys()[0], signature).
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Set the ScriptS to the given value.
scriptSig | The ScriptSig to use for this input |
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.
|
pure virtual |
Set the sequence number of this input.
Implemented in ledger::core::BitcoinLikeWritableInputApi, and ledger::core::BitcoinLikeInputApi.