#include "Application.h" #include #include "CallRPC.h" #include "Config.h" extern void runTests(); using namespace std; using namespace boost; /* Detect if another is running If so message it with the users command */ void startApp() { theApp=new Application(); theApp->run(); // blocks till we get a stop RPC } void printHelp() { cout << "newcoin [options] " << endl; cout << "options: " << endl; cout << " -" << endl; cout << "commands: " << endl; cout << " createfamily []" << endl; cout << " accountinfo :" << endl; cout << " newaccount []" << endl; cout << " lock " << endl; cout << " unlock " << endl; cout << " familyinfo" << endl; cout << " connect []" << endl; cout << " sendto []" << endl; cout << " stop" << endl; } int parseCommandline(int argc, char* argv[]) { int ret=0; if(argc>1) { theConfig.load(); ret=commandLineRPC(argc, argv); if(ret) printHelp(); } else startApp(); return ret; } int main(int argc, char* argv[]) { // runTests(); return(parseCommandline(argc,argv)); }