ledger-core
Public Member Functions | List of all members
ledger::core::OperationApi Class Reference
+ Inheritance diagram for ledger::core::OperationApi:
+ Collaboration diagram for ledger::core::OperationApi:

Public Member Functions

 OperationApi (const std::shared_ptr< AbstractAccount > &account)
 
std::string getUid () override
 
int32_t getAccountIndex () override
 
api::OperationType getOperationType () override
 
std::chrono::system_clock::time_point getDate () override
 
std::vector< std::string > getSenders () override
 
std::vector< std::string > getRecipients () override
 
std::shared_ptr< api::AmountgetAmount () override
 
std::shared_ptr< api::AmountgetFees () override
 
std::shared_ptr< api::PreferencesgetPreferences () override
 
std::shared_ptr< api::TrustIndicatorgetTrust () override
 
std::shared_ptr< api::BitcoinLikeOperationasBitcoinLikeOperation () override
 
std::shared_ptr< api::EthereumLikeOperationasEthereumLikeOperation () override
 
std::shared_ptr< api::RippleLikeOperationasRippleLikeOperation () override
 
std::shared_ptr< api::TezosLikeOperationasTezosLikeOperation () override
 
optional< int64_t > getBlockHeight () override
 
bool isInstanceOfBitcoinLikeOperation () override
 
bool isInstanceOfEthereumLikeOperation () override
 
bool isInstanceOfRippleLikeOperation () override
 
bool isInstanceOfTezosLikeOperation () override
 
bool isComplete () override
 
api::WalletType getWalletType () override
 
ledger::core::OperationgetBackend ()
 
const std::shared_ptr< AbstractAccount > & getAccount () const
 
api::Currency getCurrency () override
 

Member Function Documentation

◆ asBitcoinLikeOperation()

std::shared_ptr< api::BitcoinLikeOperation > ledger::core::OperationApi::asBitcoinLikeOperation ( )
overridevirtual

Convert operation as Bitcoin operation.

Returns
BitcoinLikeOperation object

Implements ledger::core::api::Operation.

◆ asEthereumLikeOperation()

std::shared_ptr< api::EthereumLikeOperation > ledger::core::OperationApi::asEthereumLikeOperation ( )
overridevirtual

Convert operation as Ethereum operation.

Returns
EthereumLikeOperation object

Implements ledger::core::api::Operation.

◆ asRippleLikeOperation()

std::shared_ptr< api::RippleLikeOperation > ledger::core::OperationApi::asRippleLikeOperation ( )
overridevirtual

Convert operation as Ripple operation

Returns
RippleLikeOperation object

Implements ledger::core::api::Operation.

◆ asTezosLikeOperation()

std::shared_ptr< api::TezosLikeOperation > ledger::core::OperationApi::asTezosLikeOperation ( )
overridevirtual

Convert operation as Tezos operation

Returns
TezosLikeOperation object

Implements ledger::core::api::Operation.

◆ getAccountIndex()

int32_t ledger::core::OperationApi::getAccountIndex ( )
overridevirtual

Get account's index in user's wallet.

Returns
32-bit integer

Implements ledger::core::api::Operation.

◆ getAmount()

std::shared_ptr< api::Amount > ledger::core::OperationApi::getAmount ( )
overridevirtual

Get amount of operation.

Returns
Amount object

Implements ledger::core::api::Operation.

◆ getBlockHeight()

optional< int64_t > ledger::core::OperationApi::getBlockHeight ( )
overridevirtual

Get block height on which operation was included.

Returns
Optional 64-bit integer, height of block in which operation was validated

Implements ledger::core::api::Operation.

◆ getCurrency()

api::Currency ledger::core::OperationApi::getCurrency ( )
overridevirtual

Get the currency this operation is about.

Implements ledger::core::api::Operation.

◆ getDate()

std::chrono::system_clock::time_point ledger::core::OperationApi::getDate ( )
overridevirtual

Return date on which operation was issued.

Returns
date object

Implements ledger::core::api::Operation.

◆ getFees()

std::shared_ptr< api::Amount > ledger::core::OperationApi::getFees ( )
overridevirtual

Get fees of operation.

Returns
Optional Amount object

Implements ledger::core::api::Operation.

◆ getOperationType()

api::OperationType ledger::core::OperationApi::getOperationType ( )
overridevirtual

Get type of operation.

Returns
OperationType object (for more details refer to OperationType)

Implements ledger::core::api::Operation.

◆ getPreferences()

std::shared_ptr< api::Preferences > ledger::core::OperationApi::getPreferences ( )
overridevirtual

Get preferences of operation.

Returns
Prefences object

Implements ledger::core::api::Operation.

◆ getRecipients()

std::vector< std::string > ledger::core::OperationApi::getRecipients ( )
overridevirtual

Get recipients of operation.

Returns
List of string, list of all recipients

Implements ledger::core::api::Operation.

◆ getSenders()

std::vector< std::string > ledger::core::OperationApi::getSenders ( )
overridevirtual

Get senders of operation.

Returns
List of string, list of all senders

Implements ledger::core::api::Operation.

◆ getTrust()

std::shared_ptr< api::TrustIndicator > ledger::core::OperationApi::getTrust ( )
overridevirtual

Get trust indicator of operation.

Returns
TrustIndicator object

Implements ledger::core::api::Operation.

◆ getUid()

std::string ledger::core::OperationApi::getUid ( )
overridevirtual

Get id's operation.

Returns
string

Implements ledger::core::api::Operation.

◆ getWalletType()

api::WalletType ledger::core::OperationApi::getWalletType ( )
overridevirtual

Get type of wallet from which operation was issued.

Returns
WalletType object

Implements ledger::core::api::Operation.

◆ isComplete()

bool ledger::core::OperationApi::isComplete ( )
overridevirtual

Tells if the operation is complete.

Returns
boolean

Implements ledger::core::api::Operation.

◆ isInstanceOfBitcoinLikeOperation()

bool ledger::core::OperationApi::isInstanceOfBitcoinLikeOperation ( )
overridevirtual

Same as isInstanceOfBitcoinLikeOperation for bitcoin.

Implements ledger::core::api::Operation.

◆ isInstanceOfEthereumLikeOperation()

bool ledger::core::OperationApi::isInstanceOfEthereumLikeOperation ( )
overridevirtual

Same as isInstanceOfEthereumLikeOperation for ethereum.

Implements ledger::core::api::Operation.

◆ isInstanceOfRippleLikeOperation()

bool ledger::core::OperationApi::isInstanceOfRippleLikeOperation ( )
overridevirtual

Same as isInstanceOfRippleLikeOperation for ripple.

Implements ledger::core::api::Operation.

◆ isInstanceOfTezosLikeOperation()

bool ledger::core::OperationApi::isInstanceOfTezosLikeOperation ( )
overridevirtual

Same as isInstanceOfTezosLikeOperation for tezos.

Implements ledger::core::api::Operation.


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