mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-06 17:27:52 +00:00
Modify to meet new state spec.
This commit is contained in:
@@ -5,6 +5,7 @@
|
|||||||
#include "AccountState.h"
|
#include "AccountState.h"
|
||||||
|
|
||||||
// Operations that clients may wish to perform against the network
|
// Operations that clients may wish to perform against the network
|
||||||
|
// Master operational handler, server sequencer, network tracker
|
||||||
|
|
||||||
class Peer;
|
class Peer;
|
||||||
|
|
||||||
@@ -18,17 +19,13 @@ class NetworkOPs
|
|||||||
|
|
||||||
enum OperatingMode
|
enum OperatingMode
|
||||||
{ // how we process transactions or account balance requests
|
{ // how we process transactions or account balance requests
|
||||||
FAULTED=0, // we are unable to process requests (not ready or no network)
|
DISCONNECTED=0, // not ready to process requests
|
||||||
FULL_LOCAL=1, // we are in full local sync
|
CONNECTED=1, // convinced we are talking to the network
|
||||||
PART_LOCAL=2, // we can validate remote data but have to request it
|
TRACKING=2, // convinced we agree with the network
|
||||||
REMOTE=3 // we have to trust remote nodes
|
FULL=3 // we have the ledger and can even validate
|
||||||
};
|
};
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
// context information
|
|
||||||
OperatingMode getOperatingMode();
|
|
||||||
|
|
||||||
// network information
|
// network information
|
||||||
uint64 getNetworkTime();
|
uint64 getNetworkTime();
|
||||||
uint32 getCurrentLedgerID();
|
uint32 getCurrentLedgerID();
|
||||||
@@ -44,8 +41,6 @@ public:
|
|||||||
// account operations
|
// account operations
|
||||||
AccountState::pointer getAccountState(const NewcoinAddress& accountID);
|
AccountState::pointer getAccountState(const NewcoinAddress& accountID);
|
||||||
|
|
||||||
// contact block operations
|
|
||||||
|
|
||||||
// raw object operations
|
// raw object operations
|
||||||
bool findRawLedger(const uint256& ledgerHash, std::vector<unsigned char>& rawLedger);
|
bool findRawLedger(const uint256& ledgerHash, std::vector<unsigned char>& rawLedger);
|
||||||
bool findRawTransaction(const uint256& transactionHash, std::vector<unsigned char>& rawTransaction);
|
bool findRawTransaction(const uint256& transactionHash, std::vector<unsigned char>& rawTransaction);
|
||||||
|
|||||||
Reference in New Issue
Block a user