Changeset View
Changeset View
Standalone View
Standalone View
src/rpc/protocol.h
Show First 20 Lines • Show All 124 Lines • ▼ Show 20 Lines | |||||
UniValue JSONRPCRequestObj(const std::string &strMethod, const UniValue ¶ms, | UniValue JSONRPCRequestObj(const std::string &strMethod, const UniValue ¶ms, | ||||
const UniValue &id); | const UniValue &id); | ||||
UniValue JSONRPCReplyObj(const UniValue &result, const UniValue &error, | UniValue JSONRPCReplyObj(const UniValue &result, const UniValue &error, | ||||
const UniValue &id); | const UniValue &id); | ||||
std::string JSONRPCReply(const UniValue &result, const UniValue &error, | std::string JSONRPCReply(const UniValue &result, const UniValue &error, | ||||
const UniValue &id); | const UniValue &id); | ||||
UniValue JSONRPCError(int code, const std::string &message); | UniValue JSONRPCError(int code, const std::string &message); | ||||
/** Get name of RPC authentication cookie file */ | |||||
fs::path GetAuthCookieFile(); | |||||
/** Generate a new RPC authentication cookie and write it to disk */ | /** Generate a new RPC authentication cookie and write it to disk */ | ||||
bool GenerateAuthCookie(std::string *cookie_out); | bool GenerateAuthCookie(std::string *cookie_out); | ||||
/** Read the RPC authentication cookie from disk */ | /** Read the RPC authentication cookie from disk */ | ||||
bool GetAuthCookie(std::string *cookie_out); | bool GetAuthCookie(std::string *cookie_out); | ||||
/** Delete RPC authentication cookie from disk */ | /** Delete RPC authentication cookie from disk */ | ||||
void DeleteAuthCookie(); | void DeleteAuthCookie(); | ||||
/** Parse JSON-RPC batch reply into a vector */ | /** Parse JSON-RPC batch reply into a vector */ | ||||
std::vector<UniValue> JSONRPCProcessBatchReply(const UniValue &in, size_t num); | std::vector<UniValue> JSONRPCProcessBatchReply(const UniValue &in, size_t num); | ||||
#endif // BITCOIN_RPC_PROTOCOL_H | #endif // BITCOIN_RPC_PROTOCOL_H |