update constructor to create wallet from keys

This commit is contained in:
woodser
2019-07-05 15:35:34 -04:00
parent 9f7497fc32
commit d09b613700
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -460,7 +460,7 @@ namespace monero {
cout << "Mnemonic: " << string(fetchedMnemonic.data(), fetchedMnemonic.size()) << endl;
}
MoneroWallet::MoneroWallet(const string& path, const string& password, const string& address, const string& viewKey, const string& spendKey, const MoneroNetworkType networkType, const string& daemonConnection, uint64_t restoreHeight, const string& language) {
MoneroWallet::MoneroWallet(const string& path, const string& password, const string& address, const string& viewKey, const string& spendKey, const MoneroNetworkType networkType, const MoneroRpcConnection& daemonConnection, uint64_t restoreHeight, const string& language) {
cout << "MoneroWallet(7)" << endl;
throw runtime_error("Not implemented");
}
@@ -1367,7 +1367,7 @@ namespace monero {
}
// return tx
if (txs.size() != 1) throw runtime_error("Expected 1 transaction but was " + txs.size());
if (txs.size() != 1) throw runtime_error("Expected 1 transaction but was " + boost::lexical_cast<std::string>(txs.size()));
return txs[0];
}
+1 -1
View File
@@ -138,7 +138,7 @@ namespace monero {
* @param restoreHeight is the block height to restore (i.e. scan the chain) from (default = 0)
* @param language is the wallet and mnemonic's language (default = "English")
*/
MoneroWallet(const string& path, const string& password, const string& address, const string& viewKey, const string& spendKey, const MoneroNetworkType networkType, const string& daemonConnection, uint64_t restoreHeight, const string& language);
MoneroWallet(const string& path, const string& password, const string& address, const string& viewKey, const string& spendKey, const MoneroNetworkType networkType, const MoneroRpcConnection& daemonConnection, uint64_t restoreHeight, const string& language);
/**
* Construct a wallet by opening a wallet file on disk.