1 // Copyright (c) 2009-2014 The Bitcoin developers
2 // Distributed under the MIT/X11 software license, see the accompanying
3 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
5 #ifndef __BITCOIN_CORE_IO_H__
6 #define __BITCOIN_CORE_IO_H__
18 extern CScript ParseScript(std::string s);
19 extern bool DecodeHexTx(CTransaction& tx, const std::string& strHexTx);
20 extern bool DecodeHexBlk(CBlock&, const std::string& strHexBlk);
21 extern uint256 ParseHashUV(const UniValue& v, const std::string& strName);
22 extern std::vector<unsigned char> ParseHexUV(const UniValue& v, const std::string& strName);
25 extern std::string FormatScript(const CScript& script);
26 extern std::string EncodeHexTx(const CTransaction& tx);
27 extern void ScriptPubKeyToUniv(const CScript& scriptPubKey,
28 UniValue& out, bool fIncludeHex);
29 extern void TxToUniv(const CTransaction& tx, const uint256& hashBlock, UniValue& entry);
31 #endif // __BITCOIN_CORE_IO_H__