|
Monero
|
#include <rpc_payment.h>

Classes | |
| struct | client_info |
Public Member Functions | |
| rpc_payment (const cryptonote::account_public_address &address, uint64_t diff, uint64_t credits_per_hash_found) | |
| uint64_t | balance (const crypto::public_key &client, int64_t delta=0) |
| bool | pay (const crypto::public_key &client, uint64_t ts, uint64_t payment, const std::string &rpc, bool same_ts, uint64_t &credits) |
| bool | get_info (const crypto::public_key &client, const std::function< bool(const cryptonote::blobdata &, cryptonote::block &, uint64_t &seed_height, crypto::hash &seed_hash)> &get_block_template, cryptonote::blobdata &hashing_blob, uint64_t &seed_height, crypto::hash &seed_hash, const crypto::hash &top, uint64_t &diff, uint64_t &credits_per_hash_found, uint64_t &credits, uint32_t &cookie) |
| bool | submit_nonce (const crypto::public_key &client, uint32_t nonce, const crypto::hash &top, int64_t &error_code, std::string &error_message, uint64_t &credits, crypto::hash &hash, cryptonote::block &block, uint32_t cookie, bool &stale) |
| const cryptonote::account_public_address & | get_payment_address () const |
| bool | foreach (const std::function< bool(const crypto::public_key &client, const client_info &info)> &f) const |
| unsigned int | flush_by_age (time_t seconds=0) |
| uint64_t | get_hashes (unsigned int seconds) const |
| void | prune_hashrate (unsigned int seconds) |
| bool | on_idle () |
| template<class t_archive > | |
| void | serialize (t_archive &a, const unsigned int ver) |
| bool | load (std::string directory) |
| bool | store (const std::string &directory=std::string()) const |
Private Attributes | |
| cryptonote::account_public_address | m_address |
| uint64_t | m_diff |
| uint64_t | m_credits_per_hash_found |
| serializable_unordered_map< crypto::public_key, client_info > | m_client_info |
| std::string | m_directory |
| serializable_map< uint64_t, uint64_t > | m_hashrate |
| uint64_t | m_credits_total |
| uint64_t | m_credits_used |
| uint64_t | m_nonces_good |
| uint64_t | m_nonces_stale |
| uint64_t | m_nonces_bad |
| uint64_t | m_nonces_dupe |
| boost::mutex | mutex |
| cryptonote::rpc_payment::rpc_payment | ( | const cryptonote::account_public_address & | address, |
| uint64_t | diff, | ||
| uint64_t | credits_per_hash_found | ||
| ) |
| uint64_t cryptonote::rpc_payment::balance | ( | const crypto::public_key & | client, |
| int64_t | delta = 0 |
||
| ) |
| unsigned int cryptonote::rpc_payment::flush_by_age | ( | time_t | seconds = 0 | ) |
| bool cryptonote::rpc_payment::foreach | ( | const std::function< bool(const crypto::public_key &client, const client_info &info)> & | f | ) | const |
| uint64_t cryptonote::rpc_payment::get_hashes | ( | unsigned int | seconds | ) | const |
| bool cryptonote::rpc_payment::get_info | ( | const crypto::public_key & | client, |
| const std::function< bool(const cryptonote::blobdata &, cryptonote::block &, uint64_t &seed_height, crypto::hash &seed_hash)> & | get_block_template, | ||
| cryptonote::blobdata & | hashing_blob, | ||
| uint64_t & | seed_height, | ||
| crypto::hash & | seed_hash, | ||
| const crypto::hash & | top, | ||
| uint64_t & | diff, | ||
| uint64_t & | credits_per_hash_found, | ||
| uint64_t & | credits, | ||
| uint32_t & | cookie | ||
| ) |
|
inline |
| bool cryptonote::rpc_payment::load | ( | std::string | directory | ) |
| bool cryptonote::rpc_payment::on_idle | ( | ) |
| bool cryptonote::rpc_payment::pay | ( | const crypto::public_key & | client, |
| uint64_t | ts, | ||
| uint64_t | payment, | ||
| const std::string & | rpc, | ||
| bool | same_ts, | ||
| uint64_t & | credits | ||
| ) |
| void cryptonote::rpc_payment::prune_hashrate | ( | unsigned int | seconds | ) |
|
inline |
| bool cryptonote::rpc_payment::store | ( | const std::string & | directory = std::string() | ) | const |
| bool cryptonote::rpc_payment::submit_nonce | ( | const crypto::public_key & | client, |
| uint32_t | nonce, | ||
| const crypto::hash & | top, | ||
| int64_t & | error_code, | ||
| std::string & | error_message, | ||
| uint64_t & | credits, | ||
| crypto::hash & | hash, | ||
| cryptonote::block & | block, | ||
| uint32_t | cookie, | ||
| bool & | stale | ||
| ) |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
mutableprivate |