var searchIndex = {}; searchIndex["bitcoin"] = {"doc":"# Rust Bitcoin Library","items":[[0,"macros","bitcoin","# Macros",null,null],[0,"network","","# Network Support",null,null],[0,"constants","bitcoin::network","# Network constants",null,null],[4,"Network","bitcoin::network::constants","The cryptocurrency to act on",null,null],[13,"Bitcoin","","Classic Bitcoin",0,null],[13,"Testnet","","Bitcoin's testnet",0,null],[5,"magic","","Return the network magic bytes, which should be encoded little-endian\nat the start of every message",null,{"inputs":[{"name":"network"}],"output":{"name":"u32"}}],[17,"PROTOCOL_VERSION","","Version of the protocol as appearing in network message headers",null,null],[17,"SERVICES","","Bitfield of services provided by this node",null,null],[17,"USER_AGENT","","User agent as it appears in the version message",null,null],[11,"hash","","",0,null],[11,"clone","","",0,null],[11,"eq","","",0,null],[11,"fmt","","",0,null],[11,"fmt","","",0,null],[11,"deserialize","","",0,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"serialize","","",0,null],[11,"consensus_encode","","",0,null],[11,"consensus_decode","","",0,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[0,"encodable","bitcoin::network","# Consensus-encodable types",null,null],[3,"VarInt","bitcoin::network::encodable","A variable-length unsigned integer",null,null],[12,"0","","",1,null],[3,"CheckedData","","Data which must be preceded by a 4-byte checksum",null,null],[12,"0","","",2,null],[8,"ConsensusEncodable","","Data which can be encoded in a consensus-consistent way",null,null],[10,"consensus_encode","","Encode an object with a well-defined format",3,null],[8,"ConsensusDecodable","","Data which can be encoded in a consensus-consistent way",null,null],[10,"consensus_decode","","Decode an object with a well-defined format",4,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"fmt","","",1,null],[11,"clone","","",1,null],[11,"cmp","","",1,null],[11,"partial_cmp","","",1,null],[11,"lt","","",1,null],[11,"le","","",1,null],[11,"gt","","",1,null],[11,"ge","","",1,null],[11,"eq","","",1,null],[11,"ne","","",1,null],[11,"fmt","","",2,null],[11,"clone","","",2,null],[11,"eq","","",2,null],[11,"ne","","",2,null],[11,"consensus_encode","","",1,null],[11,"consensus_decode","","",1,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"consensus_encode","","",2,null],[11,"consensus_decode","","",2,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[0,"socket","bitcoin::network","# Sockets",null,null],[3,"Socket","bitcoin::network::socket","A network socket along with information about the peer",null,null],[12,"services","","Services supported by us",5,null],[12,"user_agent","","Our user agent",5,null],[12,"version_nonce","","Nonce to identify our `version` messages",5,null],[12,"magic","","Network magic",5,null],[11,"clone","","",5,null],[11,"new","","Construct a new socket",5,{"inputs":[{"name":"network"}],"output":{"name":"socket"}}],[11,"connect","","(Re)connect to the peer",5,null],[11,"receiver_address","","Peer address",5,null],[11,"sender_address","","Our own address",5,null],[11,"version_message","","Produce a version message appropriate for this socket",5,null],[11,"send_message","","Send a general message across the line",5,null],[11,"receive_message","","Receive the next message from the peer, decoding the network header\nand verifying its correctness. Returns the undecoded payload.",5,null],[0,"serialize","bitcoin::network","# Network Serialization",null,null],[3,"RawEncoder","bitcoin::network::serialize","An encoder for raw binary data",null,null],[3,"RawDecoder","","An decoder for raw binary data",null,null],[5,"serialize","","Encode an object into a vector",null,{"inputs":[{"name":"t"}],"output":{"name":"result"}}],[5,"serialize_hex","","Encode an object into a hex-encoded string",null,{"inputs":[{"name":"t"}],"output":{"name":"result"}}],[5,"deserialize","","Deserialize an object from a vector",null,null],[8,"BitcoinHash","","Objects which are referred to by hash",null,null],[10,"bitcoin_hash","","Produces a Sha256dHash which can be used to refer to the object",6,null],[8,"SimpleEncoder","","A simple Encoder trait",null,null],[16,"Error","","An encoding error",7,null],[10,"emit_u64","","Output a 64-bit uint",7,null],[10,"emit_u32","","Output a 32-bit uint",7,null],[10,"emit_u16","","Output a 16-bit uint",7,null],[10,"emit_u8","","Output a 8-bit uint",7,null],[10,"emit_i64","","Output a 64-bit int",7,null],[10,"emit_i32","","Output a 32-bit int",7,null],[10,"emit_i16","","Output a 16-bit int",7,null],[10,"emit_i8","","Output a 8-bit int",7,null],[10,"emit_bool","","Output a boolean",7,null],[8,"SimpleDecoder","","A simple Decoder trait",null,null],[16,"Error","","A decoding error",8,null],[10,"read_u64","","Read a 64-bit uint",8,null],[10,"read_u32","","Read a 32-bit uint",8,null],[10,"read_u16","","Read a 16-bit uint",8,null],[10,"read_u8","","Read a 8-bit uint",8,null],[10,"read_i64","","Read a 64-bit int",8,null],[10,"read_i32","","Read a 32-bit int",8,null],[10,"read_i16","","Read a 16-bit int",8,null],[10,"read_i8","","Read a 8-bit int",8,null],[10,"read_bool","","Read a boolean",8,null],[10,"error","","Signal a decoding error",8,null],[11,"new","","Constructor",9,{"inputs":[{"name":"w"}],"output":{"name":"rawencoder"}}],[11,"into_inner","","Returns the underlying Writer",9,null],[11,"new","","Constructor",10,{"inputs":[{"name":"r"}],"output":{"name":"rawdecoder"}}],[11,"into_inner","","Returns the underlying Reader",10,null],[11,"emit_u64","","",9,null],[11,"emit_u32","","",9,null],[11,"emit_u16","","",9,null],[11,"emit_i64","","",9,null],[11,"emit_i32","","",9,null],[11,"emit_i16","","",9,null],[11,"emit_i8","","",9,null],[11,"emit_u8","","",9,null],[11,"emit_bool","","",9,null],[11,"read_u64","","",10,null],[11,"read_u32","","",10,null],[11,"read_u16","","",10,null],[11,"read_i64","","",10,null],[11,"read_i32","","",10,null],[11,"read_i16","","",10,null],[11,"read_u8","","",10,null],[11,"read_i8","","",10,null],[11,"read_bool","","",10,null],[11,"error","","",10,null],[0,"address","bitcoin::network","# Bitcoin network addresses",null,null],[3,"Address","bitcoin::network::address","A message which can be sent on the Bitcoin network",null,null],[12,"services","","Services provided by the peer whose address this is",11,null],[12,"address","","Network byte-order ipv6 address, or ipv4-mapped ipv6 address",11,null],[12,"port","","Network port",11,null],[11,"consensus_encode","","",11,null],[11,"consensus_decode","","",11,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"fmt","","",11,null],[11,"clone","","",11,null],[11,"eq","","",11,null],[0,"listener","bitcoin::network","# Abstract Bitcoin listener",null,null],[8,"Listener","bitcoin::network::listener","A message which can be sent on the Bitcoin network",null,null],[10,"peer","","Return a string encoding of the peer's network address",12,null],[10,"port","","Return the port we have connected to the peer on",12,null],[10,"network","","Return the network this `Listener` is operating on",12,null],[11,"start","","Main listen loop",12,null],[0,"message","bitcoin::network","# Network message",null,null],[3,"CommandString","bitcoin::network::message","Serializer for command string",null,null],[12,"0","","",13,null],[3,"RawNetworkMessage","","A Network message",null,null],[12,"magic","","Magic bytes to identify the network these messages are meant for",14,null],[12,"payload","","The actual message data",14,null],[4,"SocketResponse","","A response from the peer-connected socket",null,null],[13,"MessageReceived","","A message was received",15,null],[13,"ConnectionFailed","","An error occured and the socket needs to close",15,null],[4,"NetworkMessage","","A Network message payload. Proper documentation is available on at\n[Bitcoin Wiki: Protocol Specification](https://en.bitcoin.it/wiki/Protocol_specification)",null,null],[13,"Version","","`version`",16,null],[13,"Verack","","`verack`",16,null],[13,"Addr","","`addr`",16,null],[13,"Inv","","`inv`",16,null],[13,"GetData","","`getdata`",16,null],[13,"NotFound","","`notfound`",16,null],[13,"GetBlocks","","`getblocks`",16,null],[13,"GetHeaders","","`getheaders`",16,null],[13,"MemPool","","`mempool`",16,null],[13,"Tx","","tx",16,null],[13,"Block","","`block`",16,null],[13,"Headers","","`headers`",16,null],[13,"Ping","","`ping`",16,null],[13,"Pong","","`pong`",16,null],[11,"fmt","","",13,null],[11,"clone","","",13,null],[11,"eq","","",13,null],[11,"ne","","",13,null],[11,"consensus_encode","","",13,null],[11,"consensus_decode","","",13,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"fmt","","",16,null],[11,"eq","","",16,null],[11,"ne","","",16,null],[11,"clone","","",16,null],[11,"consensus_encode","","",14,null],[11,"consensus_decode","","",14,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[0,"message_blockdata","bitcoin::network","# Blockdata network messages",null,null],[3,"GetBlocksMessage","bitcoin::network::message_blockdata","The `getblocks` message",null,null],[12,"version","","The protocol version",17,null],[12,"locator_hashes","","Locator hashes --- ordered newest to oldest. The remote peer will\nreply with its longest known chain, starting from a locator hash\nif possible and block 1 otherwise.",17,null],[12,"stop_hash","","References the block to stop at, or zero to just fetch the maximum 500 blocks",17,null],[3,"GetHeadersMessage","","The `getheaders` message",null,null],[12,"version","","The protocol version",18,null],[12,"locator_hashes","","Locator hashes --- ordered newest to oldest. The remote peer will\nreply with its longest known chain, starting from a locator hash\nif possible and block 1 otherwise.",18,null],[12,"stop_hash","","References the header to stop at, or zero to just fetch the maximum 2000 headers",18,null],[3,"Inventory","","An inventory object --- a reference to a Bitcoin object",null,null],[12,"inv_type","","The type of object that is referenced",19,null],[12,"hash","","The object's hash",19,null],[4,"InvType","","The type of an inventory object",null,null],[13,"Error","","Error --- these inventories can be ignored",20,null],[13,"Transaction","","Transaction",20,null],[13,"Block","","Block",20,null],[11,"fmt","","",20,null],[11,"clone","","",20,null],[11,"eq","","",20,null],[11,"fmt","","",17,null],[11,"clone","","",17,null],[11,"eq","","",17,null],[11,"ne","","",17,null],[11,"fmt","","",18,null],[11,"clone","","",18,null],[11,"eq","","",18,null],[11,"ne","","",18,null],[11,"fmt","","",19,null],[11,"clone","","",19,null],[11,"eq","","",19,null],[11,"ne","","",19,null],[11,"new","","Construct a new `getblocks` message",17,{"inputs":[{"name":"vec"},{"name":"sha256dhash"}],"output":{"name":"getblocksmessage"}}],[11,"consensus_encode","","",17,null],[11,"consensus_decode","","",17,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"new","","Construct a new `getheaders` message",18,{"inputs":[{"name":"vec"},{"name":"sha256dhash"}],"output":{"name":"getheadersmessage"}}],[11,"consensus_encode","","",18,null],[11,"consensus_decode","","",18,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"consensus_encode","","",19,null],[11,"consensus_decode","","",19,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[0,"message_network","bitcoin::network","# Network-related network messages",null,null],[3,"VersionMessage","bitcoin::network::message_network","Some simple messages\nThe `version` message",null,null],[12,"version","","The P2P network protocol version",21,null],[12,"services","","A bitmask describing the services supported by this node",21,null],[12,"timestamp","","The time at which the `version` message was sent",21,null],[12,"receiver","","The network address of the peer receiving the message",21,null],[12,"sender","","The network address of the peer sending the message",21,null],[12,"nonce","","A random nonce used to detect loops in the network",21,null],[12,"user_agent","","A string describing the peer's software",21,null],[12,"start_height","","The height of the maxmimum-work blockchain that the peer is aware of",21,null],[12,"relay","","Whether the receiving peer should relay messages to the sender; used\nif the sender is bandwidth-limited and would like to support bloom\nfiltering. Defaults to true.",21,null],[11,"fmt","","",21,null],[11,"clone","","",21,null],[11,"eq","","",21,null],[11,"ne","","",21,null],[11,"new","","Constructs a new `version` message",21,{"inputs":[{"name":"i64"},{"name":"socket"},{"name":"u64"},{"name":"i32"}],"output":{"name":"result"}}],[11,"consensus_encode","","",21,null],[11,"consensus_decode","","",21,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[0,"blockdata","bitcoin","# Blockdata",null,null],[0,"constants","bitcoin::blockdata","# Blockdata constants",null,null],[5,"max_target","bitcoin::blockdata::constants","In Bitcoind this is insanely described as ~((u256)0 >> 32)",null,{"inputs":[{"name":"network"}],"output":{"name":"uint256"}}],[5,"max_money","","The maximum value allowed in an output (useful for sanity checking,\nsince keeping everything below this value should prevent overflows\nif you are doing anything remotely sane with monetary values).",null,{"inputs":[{"name":"network"}],"output":{"name":"u64"}}],[5,"genesis_block","","Constructs and returns the genesis block",null,{"inputs":[{"name":"network"}],"output":{"name":"block"}}],[7,"MAX_SEQUENCE","","The maximum allowable sequence number",null,null],[7,"COIN_VALUE","","How many satoshis are in "one bitcoin"",null,null],[7,"TARGET_BLOCK_SPACING","","How many seconds between blocks we expect on average",null,null],[7,"DIFFCHANGE_INTERVAL","","How many blocks between diffchanges",null,null],[7,"DIFFCHANGE_TIMESPAN","","How much time on average should occur between diffchanges",null,null],[0,"opcodes","bitcoin::blockdata","# Opcodes",null,null],[4,"All","bitcoin::blockdata::opcodes","A script Opcode",null,null],[13,"OP_PUSHBYTES_0","","Push an empty array onto the stack",22,null],[13,"OP_PUSHBYTES_1","","Push the next byte as an array onto the stack",22,null],[13,"OP_PUSHBYTES_2","","Push the next 2 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_3","","Push the next 2 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_4","","Push the next 4 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_5","","Push the next 5 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_6","","Push the next 6 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_7","","Push the next 7 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_8","","Push the next 8 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_9","","Push the next 9 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_10","","Push the next 10 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_11","","Push the next 11 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_12","","Push the next 12 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_13","","Push the next 13 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_14","","Push the next 14 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_15","","Push the next 15 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_16","","Push the next 16 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_17","","Push the next 17 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_18","","Push the next 18 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_19","","Push the next 19 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_20","","Push the next 20 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_21","","Push the next 21 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_22","","Push the next 22 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_23","","Push the next 23 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_24","","Push the next 24 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_25","","Push the next 25 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_26","","Push the next 26 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_27","","Push the next 27 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_28","","Push the next 28 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_29","","Push the next 29 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_30","","Push the next 30 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_31","","Push the next 31 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_32","","Push the next 32 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_33","","Push the next 33 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_34","","Push the next 34 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_35","","Push the next 35 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_36","","Push the next 36 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_37","","Push the next 37 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_38","","Push the next 38 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_39","","Push the next 39 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_40","","Push the next 40 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_41","","Push the next 41 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_42","","Push the next 42 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_43","","Push the next 43 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_44","","Push the next 44 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_45","","Push the next 45 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_46","","Push the next 46 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_47","","Push the next 47 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_48","","Push the next 48 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_49","","Push the next 49 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_50","","Push the next 50 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_51","","Push the next 51 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_52","","Push the next 52 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_53","","Push the next 53 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_54","","Push the next 54 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_55","","Push the next 55 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_56","","Push the next 56 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_57","","Push the next 57 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_58","","Push the next 58 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_59","","Push the next 59 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_60","","Push the next 60 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_61","","Push the next 61 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_62","","Push the next 62 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_63","","Push the next 63 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_64","","Push the next 64 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_65","","Push the next 65 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_66","","Push the next 66 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_67","","Push the next 67 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_68","","Push the next 68 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_69","","Push the next 69 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_70","","Push the next 70 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_71","","Push the next 71 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_72","","Push the next 72 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_73","","Push the next 73 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_74","","Push the next 74 bytes as an array onto the stack",22,null],[13,"OP_PUSHBYTES_75","","Push the next 75 bytes as an array onto the stack",22,null],[13,"OP_PUSHDATA1","","Read the next byte as N; push the next N bytes as an array onto the stack",22,null],[13,"OP_PUSHDATA2","","Read the next 2 bytes as N; push the next N bytes as an array onto the stack",22,null],[13,"OP_PUSHDATA4","","Read the next 4 bytes as N; push the next N bytes as an array onto the stack",22,null],[13,"OP_PUSHNUM_NEG1","","Push the array [0x80] onto the stack",22,null],[13,"OP_RESERVED","","Synonym for OP_RETURN",22,null],[13,"OP_PUSHNUM_1","","Push the array [0x01] onto the stack",22,null],[13,"OP_PUSHNUM_2","","Push the array [0x02] onto the stack",22,null],[13,"OP_PUSHNUM_3","","Push the array [0x03] onto the stack",22,null],[13,"OP_PUSHNUM_4","","Push the array [0x04] onto the stack",22,null],[13,"OP_PUSHNUM_5","","Push the array [0x05] onto the stack",22,null],[13,"OP_PUSHNUM_6","","Push the array [0x06] onto the stack",22,null],[13,"OP_PUSHNUM_7","","Push the array [0x07] onto the stack",22,null],[13,"OP_PUSHNUM_8","","Push the array [0x08] onto the stack",22,null],[13,"OP_PUSHNUM_9","","Push the array [0x09] onto the stack",22,null],[13,"OP_PUSHNUM_10","","Push the array [0x0a] onto the stack",22,null],[13,"OP_PUSHNUM_11","","Push the array [0x0b] onto the stack",22,null],[13,"OP_PUSHNUM_12","","Push the array [0x0c] onto the stack",22,null],[13,"OP_PUSHNUM_13","","Push the array [0x0d] onto the stack",22,null],[13,"OP_PUSHNUM_14","","Push the array [0x0e] onto the stack",22,null],[13,"OP_PUSHNUM_15","","Push the array [0x0f] onto the stack",22,null],[13,"OP_PUSHNUM_16","","Push the array [0x10] onto the stack",22,null],[13,"OP_NOP","","Does nothing",22,null],[13,"OP_VER","","Synonym for OP_RETURN",22,null],[13,"OP_IF","","Pop and execute the next statements if a nonzero element was popped",22,null],[13,"OP_NOTIF","","Pop and execute the next statements if a zero element was popped",22,null],[13,"OP_VERIF","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_VERNOTIF","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_ELSE","","Execute statements if those after the previous OP_IF were not, and vice-versa.\nIf there is no previous OP_IF, this acts as a RETURN.",22,null],[13,"OP_ENDIF","","Pop and execute the next statements if a zero element was popped",22,null],[13,"OP_VERIFY","","If the top value is zero or the stack is empty, fail; otherwise, pop the stack",22,null],[13,"OP_RETURN","","Fail the script immediately. (Must be executed.)",22,null],[13,"OP_TOALTSTACK","","Pop one element from the main stack onto the alt stack",22,null],[13,"OP_FROMALTSTACK","","Pop one element from the alt stack onto the main stack",22,null],[13,"OP_2DROP","","Drops the top two stack items",22,null],[13,"OP_2DUP","","Duplicates the top two stack items as AB -> ABAB",22,null],[13,"OP_3DUP","","Duplicates the two three stack items as ABC -> ABCABC",22,null],[13,"OP_2OVER","","Copies the two stack items of items two spaces back to\nthe front, as xxAB -> ABxxAB",22,null],[13,"OP_2ROT","","Moves the two stack items four spaces back to the front,\nas xxxxAB -> ABxxxx",22,null],[13,"OP_2SWAP","","Swaps the top two pairs, as ABCD -> CDAB",22,null],[13,"OP_IFDUP","","Duplicate the top stack element unless it is zero",22,null],[13,"OP_DEPTH","","Push the current number of stack items onto te stack",22,null],[13,"OP_DROP","","Drops the top stack item",22,null],[13,"OP_DUP","","Duplicates the top stack item",22,null],[13,"OP_NIP","","Drops the second-to-top stack item",22,null],[13,"OP_OVER","","Copies the second-to-top stack item, as xA -> AxA",22,null],[13,"OP_PICK","","Pop the top stack element as N. Copy the Nth stack element to the top",22,null],[13,"OP_ROLL","","Pop the top stack element as N. Move the Nth stack element to the top",22,null],[13,"OP_ROT","","Rotate the top three stack items, as [top next1 next2] -> [next2 top next1]",22,null],[13,"OP_SWAP","","Swap the top two stack items",22,null],[13,"OP_TUCK","","Copy the top stack item to before the second item, as [top next] -> [top next top]",22,null],[13,"OP_CAT","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_SUBSTR","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_LEFT","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_RIGHT","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_SIZE","","Pushes the length of the top stack item onto the stack",22,null],[13,"OP_INVERT","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_AND","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_OR","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_XOR","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_EQUAL","","Pushes 1 if the inputs are exactly equal, 0 otherwise",22,null],[13,"OP_EQUALVERIFY","","Returns success if the inputs are exactly equal, failure otherwise",22,null],[13,"OP_RESERVED1","","Synonym for OP_RETURN",22,null],[13,"OP_RESERVED2","","Synonym for OP_RETURN",22,null],[13,"OP_1ADD","","Increment the top stack element in place",22,null],[13,"OP_1SUB","","Decrement the top stack element in place",22,null],[13,"OP_2MUL","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_2DIV","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_NEGATE","","Multiply the top stack item by -1 in place",22,null],[13,"OP_ABS","","Absolute value the top stack item in place",22,null],[13,"OP_NOT","","Map 0 to 1 and everything else to 0, in place",22,null],[13,"OP_0NOTEQUAL","","Map 0 to 0 and everything else to 1, in place",22,null],[13,"OP_ADD","","Pop two stack items and push their sum",22,null],[13,"OP_SUB","","Pop two stack items and push the second minus the top",22,null],[13,"OP_MUL","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_DIV","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_MOD","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_LSHIFT","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_RSHIFT","","Fail the script unconditionally, does not even need to be executed",22,null],[13,"OP_BOOLAND","","Pop the top two stack items and push 1 if both are nonzero, else push 0",22,null],[13,"OP_BOOLOR","","Pop the top two stack items and push 1 if either is nonzero, else push 0",22,null],[13,"OP_NUMEQUAL","","Pop the top two stack items and push 1 if both are numerically equal, else push 0",22,null],[13,"OP_NUMEQUALVERIFY","","Pop the top two stack items and return success if both are numerically equal, else return failure",22,null],[13,"OP_NUMNOTEQUAL","","Pop the top two stack items and push 0 if both are numerically equal, else push 1",22,null],[13,"OP_LESSTHAN","","Pop the top two items; push 1 if the second is less than the top, 0 otherwise",22,null],[13,"OP_GREATERTHAN","","Pop the top two items; push 1 if the second is greater than the top, 0 otherwise",22,null],[13,"OP_LESSTHANOREQUAL","","Pop the top two items; push 1 if the second is <= the top, 0 otherwise",22,null],[13,"OP_GREATERTHANOREQUAL","","Pop the top two items; push 1 if the second is >= the top, 0 otherwise",22,null],[13,"OP_MIN","","Pop the top two items; push the smaller",22,null],[13,"OP_MAX","","Pop the top two items; push the larger",22,null],[13,"OP_WITHIN","","Pop the top three items; if the top is >= the second and < the third, push 1, otherwise push 0",22,null],[13,"OP_RIPEMD160","","Pop the top stack item and push its RIPEMD160 hash",22,null],[13,"OP_SHA1","","Pop the top stack item and push its SHA1 hash",22,null],[13,"OP_SHA256","","Pop the top stack item and push its SHA256 hash",22,null],[13,"OP_HASH160","","Pop the top stack item and push its RIPEMD(SHA256) hash",22,null],[13,"OP_HASH256","","Pop the top stack item and push its SHA256(SHA256) hash",22,null],[13,"OP_CODESEPARATOR","","Ignore this and everything preceding when deciding what to sign when signature-checking",22,null],[13,"OP_CHECKSIG","","https://en.bitcoin.it/wiki/OP_CHECKSIG pushing 1/0 for success/failure",22,null],[13,"OP_CHECKSIGVERIFY","","https://en.bitcoin.it/wiki/OP_CHECKSIG returning success/failure",22,null],[13,"OP_CHECKMULTISIG","","Pop N, N pubkeys, M, M signatures, a dummy (due to bug in reference code), and verify that all M signatures are valid.\nPush 1 for "all valid", 0 otherwise",22,null],[13,"OP_CHECKMULTISIGVERIFY","","Like the above but return success/failure",22,null],[13,"OP_NOP1","","Does nothing",22,null],[13,"OP_NOP2","","Does nothing",22,null],[13,"OP_NOP3","","Does nothing",22,null],[13,"OP_NOP4","","Does nothing",22,null],[13,"OP_NOP5","","Does nothing",22,null],[13,"OP_NOP6","","Does nothing",22,null],[13,"OP_NOP7","","Does nothing",22,null],[13,"OP_NOP8","","Does nothing",22,null],[13,"OP_NOP9","","Does nothing",22,null],[13,"OP_NOP10","","Does nothing",22,null],[13,"OP_RETURN_186","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_187","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_188","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_189","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_190","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_191","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_192","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_193","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_194","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_195","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_196","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_197","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_198","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_199","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_200","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_201","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_202","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_203","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_204","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_205","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_206","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_207","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_208","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_209","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_210","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_211","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_212","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_213","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_214","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_215","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_216","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_217","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_218","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_219","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_220","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_221","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_222","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_223","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_224","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_225","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_226","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_227","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_228","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_229","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_230","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_231","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_232","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_233","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_234","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_235","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_236","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_237","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_238","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_239","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_240","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_241","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_242","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_243","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_244","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_245","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_246","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_247","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_248","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_249","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_250","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_251","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_252","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_253","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_254","","Synonym for OP_RETURN",22,null],[13,"OP_RETURN_255","","Synonym for OP_RETURN",22,null],[4,"Class","","Broad categories of opcodes with similar behavior",null,null],[13,"PushNum","","Pushes the given number onto the stack",23,null],[13,"PushBytes","","Pushes the given number of bytes onto the stack",23,null],[13,"ReturnOp","","Fails the script if executed",23,null],[13,"IllegalOp","","Fails the script even if not executed",23,null],[13,"NoOp","","Does nothing",23,null],[13,"Ordinary","","Any opcode not covered above",23,null],[7,"OP_FALSE","","Empty stack is also FALSE",null,null],[7,"OP_TRUE","","Number 1 is also TRUE",null,null],[11,"fmt","","",22,null],[11,"eq","","",22,null],[11,"clone","","",22,null],[11,"classify","","Classifies an Opcode into a broad class",22,null],[11,"from","","",22,{"inputs":[{"name":"u8"}],"output":{"name":"all"}}],[11,"fmt","","",22,null],[11,"consensus_decode","","",22,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"consensus_encode","","",22,null],[11,"serialize","","",22,null],[11,"fmt","","",23,null],[11,"eq","","",23,null],[11,"ne","","",23,null],[11,"clone","","",23,null],[11,"fmt","","",23,null],[11,"serialize","","",23,null],[0,"script","bitcoin::blockdata","# Script",null,null],[3,"Script","bitcoin::blockdata::script","A Bitcoin script",null,null],[3,"Builder","","An object which can be used to construct a script piece by piece",null,null],[3,"Instructions","","Iterator over a script returning parsed opcodes",null,null],[4,"Error","","Ways that a script might fail. Not everything is split up as\nmuch as it could be; patches welcome if more detailed errors\nwould help you.",null,null],[13,"EarlyEndOfScript","","Some opcode expected a parameter, but it was missing or truncated",24,null],[13,"NumericOverflow","","Tried to read an array off the stack as a number when it was more than 4 bytes",24,null],[4,"Instruction","","A "parsed opcode" which allows iterating over a Script in a more sensible way",null,null],[13,"PushBytes","","Push a bunch of data",25,null],[13,"Op","","Some non-push opcode",25,null],[13,"Error","","An opcode we were unable to parse",25,null],[5,"read_scriptint","","Helper to decode an integer in script format\nNotice that this fails on overflow: the result is the same as in\nbitcoind, that only 4-byte signed-magnitude values may be read as\nnumbers. They can be added or subtracted (and a long time ago,\nmultiplied and divided), and this may result in numbers which\ncan't be written out in 4 bytes or less. This is ok! The number\njust can't be read as a number again.\nThis is a bit crazy and subtle, but it makes sense: you can load\n32-bit numbers and do anything with them, which back when mult/div\nwas allowed, could result in up to a 64-bit number. We don't want\noverflow since that's suprising --- and we don't want numbers that\ndon't fit in 64 bits (for efficiency on modern processors) so we\nsimply say, anything in excess of 32 bits is no longer a number.\nThis is basically a ranged type implementation.",null,null],[5,"read_scriptbool","","This is like "`read_scriptint` then map 0 to false and everything\nelse as true", except that the overflow rules don't apply.",null,null],[5,"read_uint","","Read a script-encoded unsigned integer",null,null],[11,"hash","","",26,null],[11,"eq","","",26,null],[11,"ne","","",26,null],[11,"clone","","",26,null],[11,"fmt","","",26,null],[11,"fmt","","",26,null],[11,"fmt","","",26,null],[11,"fmt","","",26,null],[11,"clone","","",27,null],[11,"fmt","","",27,null],[11,"eq","","",27,null],[11,"ne","","",27,null],[11,"fmt","","",27,null],[11,"clone","","",24,null],[11,"fmt","","",24,null],[11,"eq","","",24,null],[11,"fmt","","",24,null],[11,"cause","","",24,null],[11,"description","","",24,null],[11,"new","","Creates a new empty script",26,{"inputs":[],"output":{"name":"script"}}],[11,"len","","The length in bytes of the script",26,null],[11,"is_empty","","Whether the script is the empty script",26,null],[11,"into_vec","","Convert the script into a byte vector",26,null],[11,"is_p2sh","","Checks whether a script pubkey is a p2sh output",26,null],[11,"is_provably_unspendable","","Whether a script can be proven to have no satisfying input",26,null],[11,"default","","",26,{"inputs":[],"output":{"name":"script"}}],[11,"from","","",26,{"inputs":[{"name":"vec"}],"output":{"name":"script"}}],[11,"index","","",26,null],[11,"index","","",26,null],[11,"index","","",26,null],[11,"index","","",26,null],[11,"clone","","",25,null],[11,"eq","","",25,null],[11,"ne","","",25,null],[11,"fmt","","",25,null],[11,"next","","",28,null],[11,"new","","Creates a new empty script",27,{"inputs":[],"output":{"name":"builder"}}],[11,"len","","The length in bytes of the script",27,null],[11,"is_empty","","Whether the script is the empty script",27,null],[11,"push_int","","Adds instructions to push an integer onto the stack. Integers are\nencoded as little-endian signed-magnitude numbers, but there are\ndedicated opcodes to push some small integers.",27,null],[11,"push_scriptint","","Adds instructions to push an integer onto the stack, using the explicit\nencoding regardless of the availability of dedicated opcodes.",27,null],[11,"push_slice","","Adds instructions to push some arbitrary data onto the stack",27,null],[11,"push_opcode","","Adds a single opcode to the script",27,null],[11,"into_script","","Converts the `Builder` into an unmodifiable `Script`",27,null],[11,"default","","",27,{"inputs":[],"output":{"name":"builder"}}],[11,"from","","",27,{"inputs":[{"name":"vec"}],"output":{"name":"builder"}}],[11,"index","","",27,null],[11,"index","","",27,null],[11,"index","","",27,null],[11,"index","","",27,null],[11,"serialize","","",26,null],[11,"deserialize","","",26,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"consensus_encode","","",26,null],[11,"consensus_decode","","",26,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[0,"transaction","bitcoin::blockdata","# Bitcoin Transaction",null,null],[3,"TxOutRef","bitcoin::blockdata::transaction","A reference to a transaction output",null,null],[12,"txid","","The referenced transaction's txid",29,null],[12,"index","","The index of the referenced output in its transaction's vout",29,null],[3,"TxIn","","A transaction input, which defines old coins to be consumed",null,null],[12,"prev_hash","","The hash of the transaction whose output is being used an an input",30,null],[12,"prev_index","","The index of the output in the previous transaction, which may have several",30,null],[12,"script_sig","","The script which pushes values on the stack which will cause\nthe referenced output's script to accept",30,null],[12,"sequence","","The sequence number, which suggests to miners which of two\nconflicting transactions should be preferred, or 0xFFFFFFFF\nto ignore this feature. This is generally never used since\nthe miner behaviour cannot be enforced.",30,null],[3,"TxOut","","A transaction output, which defines new coins to be created from old ones.",null,null],[12,"value","","The value of the output, in satoshis",31,null],[12,"script_pubkey","","The script which must satisfy for the output to be spent",31,null],[3,"Transaction","","A Bitcoin transaction, which describes an authenticated movement of coins",null,null],[12,"version","","The protocol version, should always be 1.",32,null],[12,"lock_time","","Block number before which this transaction is valid, or 0 for\nvalid immediately.",32,null],[12,"input","","List of inputs",32,null],[12,"output","","List of outputs",32,null],[12,"witness","","Witness data: for each txin, an array of byte-arrays",32,null],[4,"SigHashType","","Hashtype of a transaction, encoded in the last byte of a signature\nFixed values so they can be casted as integer types for encoding",null,null],[13,"All","","0x1: Sign all outputs",33,null],[13,"None","","0x2: Sign no outputs --- anyone can choose the destination",33,null],[13,"Single","","0x3: Sign the output whose index matches this input's index. If none exists,\nsign the hash `0000000000000000000000000000000000000000000000000000000000000001`.\n(This rule is probably an unintentional C++ism, but it's consensus so we have\nto follow it.)",33,null],[13,"AllPlusAnyoneCanPay","","0x81: Sign all outputs but only this input",33,null],[13,"NonePlusAnyoneCanPay","","0x82: Sign no outputs and only this input",33,null],[13,"SinglePlusAnyoneCanPay","","0x83: Sign one output and only this input (see `Single` for what "one output" means)",33,null],[11,"hash","","",29,null],[11,"fmt","","",29,null],[11,"cmp","","",29,null],[11,"partial_cmp","","",29,null],[11,"lt","","",29,null],[11,"le","","",29,null],[11,"gt","","",29,null],[11,"ge","","",29,null],[11,"eq","","",29,null],[11,"ne","","",29,null],[11,"clone","","",29,null],[11,"deserialize","","",29,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"serialize","","",29,null],[11,"fmt","","",29,null],[11,"hash","","",30,null],[11,"fmt","","",30,null],[11,"eq","","",30,null],[11,"ne","","",30,null],[11,"clone","","",30,null],[11,"deserialize","","",30,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"serialize","","",30,null],[11,"hash","","",31,null],[11,"fmt","","",31,null],[11,"eq","","",31,null],[11,"ne","","",31,null],[11,"clone","","",31,null],[11,"deserialize","","",31,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"serialize","","",31,null],[11,"default","","",31,{"inputs":[],"output":{"name":"txout"}}],[11,"hash","","",32,null],[11,"fmt","","",32,null],[11,"eq","","",32,null],[11,"ne","","",32,null],[11,"clone","","",32,null],[11,"deserialize","","",32,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"serialize","","",32,null],[11,"ntxid","","Computes a "normalized TXID" which does not include any signatures.\nThis gives a way to identify a transaction that is ``the same'' as\nanother in the sense of having same inputs and outputs.",32,null],[11,"signature_hash","","Computes a signature hash for a given input index with a given sighash flag.\nTo actually produce a scriptSig, this hash needs to be run through an\nECDSA signer, the SigHashType appended to the resulting sig, and a\nscript written around this, but this is the general (and hard) part.",32,null],[11,"bitcoin_hash","","",32,null],[11,"consensus_encode","","",30,null],[11,"consensus_decode","","",30,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"consensus_encode","","",31,null],[11,"consensus_decode","","",31,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"consensus_encode","","",32,null],[11,"consensus_decode","","",32,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"clone","","",33,null],[11,"fmt","","",33,null],[11,"eq","","",33,null],[11,"from_u32","","Reads a 4-byte uint32 as a sighash type",33,{"inputs":[{"name":"u32"}],"output":{"name":"sighashtype"}}],[11,"as_u32","","Converts to a u32",33,null],[0,"block","bitcoin::blockdata","# Bitcoin Block",null,null],[3,"BlockHeader","bitcoin::blockdata::block","A block header, which contains all the block's information except\nthe actual transactions",null,null],[12,"version","","The protocol version. Should always be 1.",34,null],[12,"prev_blockhash","","Reference to the previous block in the chain",34,null],[12,"merkle_root","","The root hash of the merkle tree of transactions in the block",34,null],[12,"time","","The timestamp of the block, as claimed by the mainer",34,null],[12,"bits","","The target value below which the blockhash must lie, encoded as a\na float (with well-defined rounding, of course)",34,null],[12,"nonce","","The nonce, selected to obtain a low enough blockhash",34,null],[3,"Block","","A Bitcoin block, which is a collection of transactions with an attached\nproof of work.",null,null],[12,"header","","The block header",35,null],[12,"txdata","","List of transactions contained in the block",35,null],[3,"LoneBlockHeader","","A block header with txcount attached, which is given in the `headers`\nnetwork message.",null,null],[12,"header","","The actual block header",36,null],[12,"tx_count","","The number of transactions in the block. This will always be zero\nwhen the LoneBlockHeader is returned as part ef a `headers` message.",36,null],[11,"fmt","","",34,null],[11,"clone","","",34,null],[11,"eq","","",34,null],[11,"ne","","",34,null],[11,"fmt","","",35,null],[11,"clone","","",35,null],[11,"eq","","",35,null],[11,"ne","","",35,null],[11,"fmt","","",36,null],[11,"clone","","",36,null],[11,"eq","","",36,null],[11,"ne","","",36,null],[11,"target","","Computes the target [0, T] that a blockhash must land in to be valid",34,null],[11,"spv_validate","","Performs an SPV validation of a block, which confirms that the proof-of-work\nis correct, but does not verify that the transactions are valid or encoded\ncorrectly.",34,null],[11,"work","","Returns the total work of the block",34,null],[11,"bitcoin_hash","","",34,null],[11,"bitcoin_hash","","",35,null],[11,"consensus_encode","","",34,null],[11,"consensus_decode","","",34,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"consensus_encode","","",35,null],[11,"consensus_decode","","",35,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"consensus_encode","","",36,null],[11,"consensus_decode","","",36,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[0,"blockchain","bitcoin::blockdata","# Bitcoin Blockchain",null,null],[3,"BlockchainNode","bitcoin::blockdata::blockchain","A link in the blockchain",null,null],[12,"block","","The actual block",37,null],[12,"total_work","","Total work from genesis to this point",37,null],[12,"required_difficulty","","Expected value of `block.header.bits` for this block; only changes every\n`blockdata::constants::DIFFCHANGE_INTERVAL;` blocks",37,null],[12,"height","","Height above genesis",37,null],[12,"has_txdata","","Whether the transaction data is stored",37,null],[3,"Blockchain","","The blockchain",null,null],[3,"BlockIter","","An iterator over blocks in blockheight order",null,null],[3,"RevBlockIter","","An iterator over blocks in reverse blockheight order. Note that this\nis essentially the same as if we'd implemented `DoubleEndedIterator`\non `BlockIter` --- but we can't do that since if `BlockIter` is started\noff the main chain, it will not reach the best tip, so the iterator\nand its `.rev()` would be iterators over different chains! To avoid\nthis suprising behaviour we simply use separate iterators.",null,null],[3,"RevStaleBlockIter","","An iterator over blocks in reverse blockheight order, which yielding only\nstale blocks (ending at the point where it would've returned a block on\nthe main chain). It does this by checking if the `next` pointer of the\nnext-to-by-yielded block matches the currently-yielded block. If not, scan\nforward from next-to-be-yielded block. If we hit the best tip, set the\nnext-to-by-yielded block to None instead.",null,null],[11,"consensus_encode","","",37,null],[11,"consensus_decode","","",37,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"bitcoin_hash","","",37,null],[11,"consensus_encode","","",38,null],[11,"consensus_decode","","",38,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"next","","",39,null],[11,"next","","",40,null],[11,"next","","",41,null],[11,"new","","Constructs a new blockchain",38,{"inputs":[{"name":"network"}],"output":{"name":"blockchain"}}],[11,"get_block","","Looks up a block in the chain and returns the BlockchainNode containing it",38,null],[11,"add_txdata","","Locates a block in the chain and overwrites its txdata",38,null],[11,"remove_txdata","","Locates a block in the chain and removes its txdata",38,null],[11,"add_header","","Adds a block header to the chain",38,null],[11,"add_block","","Adds a block to the chain",38,null],[11,"genesis_hash","","Returns the genesis block's blockhash",38,null],[11,"best_tip","","Returns the best tip",38,null],[11,"best_tip_hash","","Returns the best tip's blockhash",38,null],[11,"locator_hashes","","Returns an array of locator hashes used in `getheaders` messages",38,null],[11,"iter","","An iterator over all blocks in the chain starting from `start_hash`",38,null],[11,"rev_iter","","An iterator over all blocks in reverse order to the genesis, starting with `start_hash`",38,null],[11,"rev_stale_iter","","An iterator over all blocks -not- in the best chain, in reverse order, starting from `start_hash`",38,null],[0,"util","bitcoin","# Utility functions",null,null],[4,"Error","bitcoin::util","A general error code",null,null],[13,"Io","","An I/O error",42,null],[13,"ByteOrder","","Order from the `byteorder` crate",42,null],[13,"BadNetworkMagic","","Network magic was not what we expected",42,null],[13,"BadNetworkMessage","","Network message was unrecognized",42,null],[13,"DuplicateHash","","An object was attempted to be added twice",42,null],[13,"BlockNotFound","","Some operation was attempted on a block (or blockheader) that doesn't exist",42,null],[13,"ParseFailed","","Parsing error",42,null],[13,"PrevHashNotFound","","An object was added but it does not link into existing history",42,null],[13,"SpvBadTarget","","The `target` field of a block header did not match the expected difficulty",42,null],[13,"SpvBadProofOfWork","","The header hash is not below the target",42,null],[13,"Detail","","Error propagated from subsystem",42,null],[5,"propagate_err","","Prepend the detail of an `IoResult`'s error with some text to get poor man's backtracing",null,{"inputs":[{"name":"string"},{"name":"result"}],"output":{"name":"result"}}],[0,"address","","# Addresses\nSupport for ordinary base58 Bitcoin addresses and private keys",null,null],[3,"Address","bitcoin::util::address","A Bitcoin address",null,null],[12,"ty","","The type of the address",43,null],[12,"network","","The network on which this address is usable",43,null],[12,"hash","","The pubkeyhash that this address encodes",43,null],[3,"Privkey","","A Bitcoin ECDSA private key",null,null],[12,"compressed","","Whether this private key represents a compressed address",44,null],[12,"network","","The network on which this key should be used",44,null],[12,"key","","The actual ECDSA key",44,null],[4,"Type","","The method used to produce an address",null,null],[13,"PubkeyHash","","Standard pay-to-pkhash address",45,null],[13,"ScriptHash","","New-fangled P2SH address",45,null],[4,"Error","","An address-related error",null,null],[13,"Secp","","Private key did not represent a valid ECDSA secret key",46,null],[11,"fmt","","",45,null],[11,"eq","","",45,null],[11,"clone","","",45,null],[11,"fmt","","",46,null],[11,"eq","","",46,null],[11,"ne","","",46,null],[11,"clone","","",46,null],[11,"eq","","",43,null],[11,"ne","","",43,null],[11,"clone","","",43,null],[11,"from_key","","Creates an address from a public key",43,{"inputs":[{"name":"network"},{"name":"publickey"},{"name":"bool"}],"output":{"name":"address"}}],[11,"from_script","","Creates a P2SH address from a script",43,{"inputs":[{"name":"network"},{"name":"script"}],"output":{"name":"address"}}],[11,"script_pubkey","","Generates a script pubkey spending to this address",43,null],[11,"base58_layout","","",43,null],[11,"from_base58_layout","","",43,{"inputs":[{"name":"vec"}],"output":{"name":"result"}}],[11,"fmt","","",43,null],[11,"eq","","",44,null],[11,"ne","","",44,null],[11,"clone","","",44,null],[11,"from_key","","Creates an address from a public key",44,{"inputs":[{"name":"network"},{"name":"secretkey"},{"name":"bool"}],"output":{"name":"privkey"}}],[11,"to_address","","Converts a private key to an address",44,null],[11,"secret_key","","Accessor for the underlying secp key",44,null],[11,"into_secret_key","","Accessor for the underlying secp key that consumes the privkey",44,null],[11,"network","","Accessor for the network type",44,null],[11,"is_compressed","","Accessor for the compressed flag",44,null],[11,"base58_layout","","",44,null],[11,"from_base58_layout","","",44,{"inputs":[{"name":"vec"}],"output":{"name":"result"}}],[0,"base58","bitcoin::util","# Base58 encoder and decoder",null,null],[4,"Error","bitcoin::util::base58","An error that might occur during base58 decoding",null,null],[13,"BadByte","","Invalid character encountered",47,null],[13,"BadChecksum","","Checksum was not correct (expected, actual)",47,null],[13,"InvalidLength","","The length (in bytes) of the object was not correct",47,null],[13,"InvalidVersion","","Version byte(s) were not recognized",47,null],[13,"TooShort","","Checked data was less than 4 bytes",47,null],[13,"Other","","Any other error",47,null],[5,"base58_encode_slice","","Directly encode a slice as base58",null,null],[8,"FromBase58","","Trait for objects which can be read as base58",null,null],[10,"from_base58_layout","","Constructs an object from the byte-encoding (base 256)\nrepresentation of its base58 format",48,{"inputs":[{"name":"vec"}],"output":{"name":"result"}}],[11,"from_base58","","Obtain an object from its base58 encoding",48,{"inputs":[{"name":"str"}],"output":{"name":"result"}}],[11,"from_base58check","","Obtain an object from its base58check encoding",48,{"inputs":[{"name":"str"}],"output":{"name":"result"}}],[8,"ToBase58","","Trait for objects which can be written as base58",null,null],[10,"base58_layout","","The serialization to be converted into base58",49,null],[11,"to_base58","","Obtain a string with the base58 encoding of the object",49,null],[11,"to_base58check","","Obtain a string with the base58check encoding of the object\n(Tack the first 4 256-digits of the object's Bitcoin hash onto the end.)",49,null],[11,"clone","","",47,null],[11,"eq","","",47,null],[11,"ne","","",47,null],[11,"fmt","","",47,null],[11,"fmt","","",47,null],[11,"cause","","",47,null],[11,"description","","",47,null],[0,"bip32","bitcoin::util","# BIP32 Implementation",null,null],[3,"ChainCode","bitcoin::util::bip32","A chain code",null,null],[3,"Fingerprint","","A fingerprint",null,null],[3,"ExtendedPrivKey","","Extended private key",null,null],[12,"network","","The network this key is to be used on",50,null],[12,"depth","","How many derivations this key is from the master (which is 0)",50,null],[12,"parent_fingerprint","","Fingerprint of the parent key (0 for master)",50,null],[12,"child_number","","Child number of the key used to derive from parent (0 for master)",50,null],[12,"secret_key","","Secret key",50,null],[12,"chain_code","","Chain code",50,null],[3,"ExtendedPubKey","","Extended public key",null,null],[12,"network","","The network this key is to be used on",51,null],[12,"depth","","How many derivations this key is from the master (which is 0)",51,null],[12,"parent_fingerprint","","Fingerprint of the parent key",51,null],[12,"child_number","","Child number of the key used to derive from parent (0 for master)",51,null],[12,"public_key","","Public key",51,null],[12,"chain_code","","Chain code",51,null],[4,"ChildNumber","","A child number for a derived key",null,null],[13,"Hardened","","Hardened key index, within [0, 2^31 - 1]",52,null],[13,"Normal","","Non-hardened key, within [0, 2^31 - 1]",52,null],[4,"Error","","A BIP32 error",null,null],[13,"CannotDeriveFromHardenedKey","","A pk->pk derivation was attempted on a hardened key",53,null],[13,"Ecdsa","","A secp256k1 error occured",53,null],[13,"InvalidChildNumber","","A child number was provided that was out of range",53,null],[13,"RngError","","Error creating a master seed --- for application use",53,null],[11,"as_ptr","","Converts the object to a raw pointer",54,null],[11,"as_mut_ptr","","Converts the object to a mutable raw pointer",54,null],[11,"len","","Returns the length of the object as an array",54,null],[11,"is_empty","","Returns whether the object, as an array, is empty. Always false.",54,null],[11,"from","","",54,null],[11,"index","","",54,null],[11,"index","","",54,null],[11,"index","","",54,null],[11,"index","","",54,null],[11,"index","","",54,null],[11,"eq","","",54,null],[11,"partial_cmp","","",54,null],[11,"cmp","","",54,null],[11,"clone","","",54,null],[11,"hash","","",54,null],[11,"hash_slice","","",54,null],[11,"rand","","",54,{"inputs":[{"name":"r"}],"output":{"name":"chaincode"}}],[11,"fmt","","",54,null],[11,"deserialize","","",54,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"serialize","","",54,null],[11,"as_ptr","","Converts the object to a raw pointer",55,null],[11,"as_mut_ptr","","Converts the object to a mutable raw pointer",55,null],[11,"len","","Returns the length of the object as an array",55,null],[11,"is_empty","","Returns whether the object, as an array, is empty. Always false.",55,null],[11,"from","","",55,null],[11,"index","","",55,null],[11,"index","","",55,null],[11,"index","","",55,null],[11,"index","","",55,null],[11,"index","","",55,null],[11,"eq","","",55,null],[11,"partial_cmp","","",55,null],[11,"cmp","","",55,null],[11,"clone","","",55,null],[11,"hash","","",55,null],[11,"hash_slice","","",55,null],[11,"rand","","",55,{"inputs":[{"name":"r"}],"output":{"name":"fingerprint"}}],[11,"fmt","","",55,null],[11,"deserialize","","",55,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"serialize","","",55,null],[11,"default","","",55,{"inputs":[],"output":{"name":"fingerprint"}}],[11,"fmt","","",50,null],[11,"eq","","",50,null],[11,"ne","","",50,null],[11,"clone","","",50,null],[11,"fmt","","",51,null],[11,"eq","","",51,null],[11,"ne","","",51,null],[11,"clone","","",51,null],[11,"fmt","","",52,null],[11,"eq","","",52,null],[11,"ne","","",52,null],[11,"clone","","",52,null],[11,"fmt","","",52,null],[11,"serialize","","",52,null],[11,"deserialize","","",52,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"fmt","","",53,null],[11,"eq","","",53,null],[11,"ne","","",53,null],[11,"clone","","",53,null],[11,"fmt","","",53,null],[11,"cause","","",53,null],[11,"description","","",53,null],[11,"from","","",53,{"inputs":[{"name":"error"}],"output":{"name":"error"}}],[11,"new_master","","Construct a new master key from a seed value",50,null],[11,"from_path","","Creates a privkey from a path",50,null],[11,"ckd_priv","","Private->Private child key derivation",50,null],[11,"identifier","","Returns the HASH160 of the chaincode",50,null],[11,"fingerprint","","Returns the first four bytes of the identifier",50,null],[11,"from_private","","Derives a public key from a private key",51,{"inputs":[{"name":"secp256k1"},{"name":"extendedprivkey"}],"output":{"name":"extendedpubkey"}}],[11,"ckd_pub_tweak","","Compute the scalar tweak added to this key to get a child key",51,null],[11,"ckd_pub","","Public->Public child key derivation",51,null],[11,"identifier","","Returns the HASH160 of the chaincode",51,null],[11,"fingerprint","","Returns the first four bytes of the identifier",51,null],[11,"base58_layout","","",50,null],[11,"from_base58_layout","","",50,{"inputs":[{"name":"vec"}],"output":{"name":"result"}}],[11,"base58_layout","","",51,null],[11,"from_base58_layout","","",51,{"inputs":[{"name":"vec"}],"output":{"name":"result"}}],[0,"contracthash","bitcoin::util","# Pay-to-contract-hash supporte\nSee Appendix A of the Blockstream sidechains whitepaper\nat http://blockstream.com/sidechains.pdf for details of\nwhat this does.",null,null],[3,"Template","bitcoin::util::contracthash","A script template",null,null],[4,"Error","","A contract-hash error",null,null],[13,"BadTweak","","Contract hashed to an out-of-range value (this is basically impossible\nand much more likely suggests memory corruption or hardware failure)",56,null],[13,"Secp","","Other secp256k1 related error",56,null],[13,"Script","","Script parsing error",56,null],[13,"UncompressedKey","","Encountered an uncompressed key in a script we were deserializing. The\nreserialization will compress it which might be surprising so we call\nthis an error.",56,null],[13,"ExpectedKey","","Expected a public key when deserializing a script, but we got something else.",56,null],[13,"ExpectedChecksig","","Expected some sort of CHECKSIG operator when deserializing a script, but\nwe got something else.",56,null],[13,"TooFewKeys","","Did not have enough keys to instantiate a script template",56,null],[13,"TooManyKeys","","Had too many keys; template does not match key list",56,null],[5,"tweak_keys","","Tweak keys using some arbitrary data",null,null],[5,"compute_tweak","","Compute a tweak from some given data for the given public key",null,null],[5,"tweak_secret_key","","Tweak a secret key using some arbitrary data (calls `compute_tweak` internally)",null,null],[5,"create_address","","Takes a contract, template and key set and runs through all the steps",null,null],[5,"untemplate","","Extract the keys and template from a completed script",null,{"inputs":[{"name":"script"}],"output":{"name":"result"}}],[11,"clone","","",56,null],[11,"eq","","",56,null],[11,"ne","","",56,null],[11,"fmt","","",56,null],[11,"fmt","","",56,null],[11,"cause","","",56,null],[11,"description","","",56,null],[11,"fmt","","",57,null],[11,"eq","","",57,null],[11,"ne","","",57,null],[11,"clone","","",57,null],[11,"to_script","","Instantiate a template",57,null],[11,"required_keys","","Returns the number of keys this template requires to instantiate",57,null],[11,"first_push_as_number","","If the first push in the template is a number, return this number. For the\ncommon case of standard multisig templates, such a number will exist and\nwill represent the number of signatures that are required for the script\nto pass.",57,null],[11,"from","","",57,null],[0,"decimal","bitcoin::util","# Floating-point decimal type",null,null],[3,"Decimal","bitcoin::util::decimal","A fixed-point decimal type",null,null],[3,"UDecimal","","Unsigned fixed-point decimal type",null,null],[11,"cmp","","",58,null],[11,"fmt","","",58,null],[11,"clone","","",58,null],[11,"cmp","","",59,null],[11,"fmt","","",59,null],[11,"clone","","",59,null],[11,"eq","","",58,null],[11,"partial_cmp","","",58,null],[11,"fmt","","",58,null],[11,"add","","",58,null],[11,"neg","","",58,null],[11,"sub","","",58,null],[11,"new","","Creates a new Decimal",58,{"inputs":[{"name":"i64"},{"name":"usize"}],"output":{"name":"decimal"}}],[11,"mantissa","","Returns the mantissa",58,null],[11,"exponent","","Returns the exponent",58,null],[11,"integer_value","","Get the decimal's value in an integer type, by multiplying\nby some power of ten to ensure the returned value is 10 **\n`exponent` types the actual value.",58,null],[11,"nonnegative","","Returns whether or not the number is nonnegative",58,null],[11,"serialize","","",58,null],[11,"deserialize","","",58,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"eq","","",59,null],[11,"partial_cmp","","",59,null],[11,"fmt","","",59,null],[11,"add","","",59,null],[11,"new","","Creates a new Decimal",59,{"inputs":[{"name":"u64"},{"name":"usize"}],"output":{"name":"udecimal"}}],[11,"mantissa","","Returns the mantissa",59,null],[11,"exponent","","Returns the exponent",59,null],[11,"integer_value","","Get the decimal's value in an integer type, by multiplying\nby some power of ten to ensure the returned value is 10 **\n`exponent` types the actual value.",59,null],[11,"serialize","","",59,null],[11,"deserialize","","",59,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[0,"hash","bitcoin::util","# Hash functions",null,null],[3,"Sha256dHash","bitcoin::util::hash","A Bitcoin hash, 32-bytes, computed from x as SHA256(SHA256(x))",null,null],[3,"Ripemd160Hash","","A RIPEMD-160 hash",null,null],[3,"Hash160","","A Bitcoin hash160, 20-bytes, computed from x as RIPEMD160(SHA256(x))",null,null],[3,"Hash32","","A 32-bit hash obtained by truncating a real hash",null,null],[3,"Hash48","","A 48-bit hash obtained by truncating a real hash",null,null],[3,"Hash64","","A 64-bit hash obtained by truncating a real hash",null,null],[4,"HexError","","Hex deserialization error",null,null],[13,"BadLength","","Length was not 64 characters",60,null],[13,"BadCharacter","","Non-hex character in string",60,null],[8,"MerkleRoot","","Any collection of objects for which a merkle root makes sense to calculate",null,null],[10,"merkle_root","","Construct a merkle tree from a collection, with elements ordered as\nthey were in the original collection, and return the merkle root.",61,null],[11,"fmt","","",60,null],[11,"eq","","",60,null],[11,"ne","","",60,null],[11,"clone","","",60,null],[11,"fmt","","",60,null],[11,"cause","","",60,null],[11,"description","","",60,null],[11,"as_ptr","","Converts the object to a raw pointer",62,null],[11,"as_mut_ptr","","Converts the object to a mutable raw pointer",62,null],[11,"len","","Returns the length of the object as an array",62,null],[11,"is_empty","","Returns whether the object, as an array, is empty. Always false.",62,null],[11,"from","","",62,null],[11,"index","","",62,null],[11,"index","","",62,null],[11,"index","","",62,null],[11,"index","","",62,null],[11,"index","","",62,null],[11,"eq","","",62,null],[11,"partial_cmp","","",62,null],[11,"cmp","","",62,null],[11,"clone","","",62,null],[11,"hash","","",62,null],[11,"hash_slice","","",62,null],[11,"rand","","",62,{"inputs":[{"name":"r"}],"output":{"name":"sha256dhash"}}],[11,"as_ptr","","Converts the object to a raw pointer",63,null],[11,"as_mut_ptr","","Converts the object to a mutable raw pointer",63,null],[11,"len","","Returns the length of the object as an array",63,null],[11,"is_empty","","Returns whether the object, as an array, is empty. Always false.",63,null],[11,"from","","",63,null],[11,"index","","",63,null],[11,"index","","",63,null],[11,"index","","",63,null],[11,"index","","",63,null],[11,"index","","",63,null],[11,"eq","","",63,null],[11,"partial_cmp","","",63,null],[11,"cmp","","",63,null],[11,"clone","","",63,null],[11,"hash","","",63,null],[11,"hash_slice","","",63,null],[11,"rand","","",63,{"inputs":[{"name":"r"}],"output":{"name":"ripemd160hash"}}],[11,"as_ptr","","Converts the object to a raw pointer",64,null],[11,"as_mut_ptr","","Converts the object to a mutable raw pointer",64,null],[11,"len","","Returns the length of the object as an array",64,null],[11,"is_empty","","Returns whether the object, as an array, is empty. Always false.",64,null],[11,"from","","",64,null],[11,"index","","",64,null],[11,"index","","",64,null],[11,"index","","",64,null],[11,"index","","",64,null],[11,"index","","",64,null],[11,"eq","","",64,null],[11,"partial_cmp","","",64,null],[11,"cmp","","",64,null],[11,"clone","","",64,null],[11,"hash","","",64,null],[11,"hash_slice","","",64,null],[11,"rand","","",64,{"inputs":[{"name":"r"}],"output":{"name":"hash160"}}],[11,"fmt","","",65,null],[11,"eq","","",65,null],[11,"ne","","",65,null],[11,"clone","","",65,null],[11,"fmt","","",66,null],[11,"eq","","",66,null],[11,"ne","","",66,null],[11,"clone","","",66,null],[11,"fmt","","",67,null],[11,"eq","","",67,null],[11,"ne","","",67,null],[11,"clone","","",67,null],[11,"from_data","","Create a hash by hashing some data",63,null],[11,"from_data","","Create a hash by hashing some data",64,null],[11,"default","","",62,{"inputs":[],"output":{"name":"sha256dhash"}}],[11,"from_data","","Create a hash by hashing some data",62,null],[11,"into_le","","Converts a hash to a little-endian Uint256",62,null],[11,"into_be","","Converts a hash to a big-endian Uint256",62,null],[11,"into_hash32","","Converts a hash to a Hash32 by truncation",62,null],[11,"into_hash48","","Converts a hash to a Hash48 by truncation",62,null],[11,"from_hex","","Decodes a big-endian (i.e. reversed vs sha256sum output) hex string as a Sha256dHash",62,{"inputs":[{"name":"str"}],"output":{"name":"result"}}],[11,"into_hash64","","Converts a hash to a Hash64 by truncation",62,null],[11,"le_hex_string","","Human-readable hex output",62,null],[11,"be_hex_string","","Human-readable hex output",62,null],[11,"serialize","","",62,null],[11,"deserialize","","",62,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"consensus_encode","","",65,null],[11,"consensus_decode","","",65,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"consensus_encode","","",66,null],[11,"consensus_decode","","",66,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"consensus_encode","","",67,null],[11,"consensus_decode","","",67,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"consensus_encode","","",62,null],[11,"consensus_decode","","",62,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"fmt","","",62,null],[11,"fmt","","",62,null],[11,"fmt","","",62,null],[11,"fmt","","",62,null],[0,"iter","bitcoin::util","# Iterator adaptors",null,null],[3,"Pair","bitcoin::util::iter","An iterator that returns pairs of elements",null,null],[8,"Pairable","","Returns an iterator that returns elements of the original iterator 2 at a time",null,null],[10,"pair","","Returns an iterator that returns elements of the original iterator 2 at a time",68,null],[11,"next","","",69,null],[11,"size_hint","","",69,null],[11,"remainder","","Returns the last element of the iterator if there were an odd\nnumber of elements remaining before it was Pair-ified.",69,null],[0,"misc","bitcoin::util","# Miscellaneous functions",null,null],[5,"hex_bytes","bitcoin::util::misc","Convert a hexadecimal-encoded string to its corresponding bytes",null,{"inputs":[{"name":"str"}],"output":{"name":"result"}}],[5,"consume_err","","Dump an error message to the screen\nTODO all uses of this should be replaced with some sort of logging infrastructure",null,{"inputs":[{"name":"str"},{"name":"result"}],"output":null}],[5,"script_find_and_remove","","Search for `needle` in the vector `haystack` and remove every\ninstance of it, returning the number of instances removed.\nLoops through the vector opcode by opcode, skipping pushed data.",null,null],[0,"patricia_tree","bitcoin::util","# Patricia/Radix Trie",null,null],[3,"PatriciaTree","bitcoin::util::patricia_tree","Patricia troo",null,null],[3,"Items","","Iterator",null,null],[3,"MutItems","","Mutable iterator",null,null],[11,"new","","Constructs a new Patricia tree",70,{"inputs":[],"output":{"name":"patriciatree"}}],[11,"lookup_mut","","Lookup a value by exactly matching `key` and return a referenc",70,null],[11,"lookup","","Lookup a value by exactly matching `key` and return a mutable reference",70,null],[11,"insert","","Inserts a value with key `key`, returning true on success. If a value is already\nstored against `key`, do nothing and return false.",70,null],[11,"insert_or_update","","Inserts a value with key `key`, returning true on success. If a value is already\nstored against `key`, overwrite it and return false.",70,null],[11,"delete","","Deletes a value with key `key`, returning it on success. If no value with\nthe given key is found, return None",70,null],[11,"node_count","","Count all the nodes",70,null],[11,"iter","","Returns an iterator over all elements in the tree",70,null],[11,"mut_iter","","Returns a mutable iterator over all elements in the tree",70,null],[11,"fmt","","Print the entire tree",70,null],[11,"consensus_encode","","",70,null],[11,"consensus_decode","","",70,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"next","","",71,null],[11,"next","","",72,null],[0,"uint","bitcoin::util","# Big unsigned integer types",null,null],[3,"Uint256","bitcoin::util::uint","Little-endian large integer type",null,null],[12,"0","","",73,null],[3,"Uint128","","Little-endian large integer type",null,null],[12,"0","","",74,null],[11,"as_ptr","","Converts the object to a raw pointer",73,null],[11,"as_mut_ptr","","Converts the object to a mutable raw pointer",73,null],[11,"len","","Returns the length of the object as an array",73,null],[11,"is_empty","","Returns whether the object, as an array, is empty. Always false.",73,null],[11,"from","","",73,null],[11,"index","","",73,null],[11,"index","","",73,null],[11,"index","","",73,null],[11,"index","","",73,null],[11,"index","","",73,null],[11,"eq","","",73,null],[11,"partial_cmp","","",73,null],[11,"cmp","","",73,null],[11,"clone","","",73,null],[11,"hash","","",73,null],[11,"hash_slice","","",73,null],[11,"rand","","",73,{"inputs":[{"name":"r"}],"output":{"name":"uint256"}}],[11,"low_u32","","Conversion to u32",73,null],[11,"bits","","Return the least number of bits needed to represent the number",73,null],[11,"mul_u32","","Multiplication by u32",73,null],[11,"from_u64","","",73,{"inputs":[{"name":"u64"}],"output":{"name":"option"}}],[11,"from_i64","","",73,{"inputs":[{"name":"i64"}],"output":{"name":"option"}}],[11,"zero","","",73,{"inputs":[],"output":{"name":"uint256"}}],[11,"is_zero","","",73,null],[11,"one","","",73,{"inputs":[],"output":{"name":"uint256"}}],[11,"add","","",73,null],[11,"sub","","",73,null],[11,"mul","","",73,null],[11,"div","","",73,null],[11,"bit","","",73,null],[11,"bit_slice","","",73,null],[11,"mask","","",73,null],[11,"trailing_zeros","","",73,null],[11,"bitand","","",73,null],[11,"bitxor","","",73,null],[11,"bitor","","",73,null],[11,"not","","",73,null],[11,"shl","","",73,null],[11,"shr","","",73,null],[11,"fmt","","",73,null],[11,"consensus_encode","","",73,null],[11,"consensus_decode","","",73,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"as_ptr","","Converts the object to a raw pointer",74,null],[11,"as_mut_ptr","","Converts the object to a mutable raw pointer",74,null],[11,"len","","Returns the length of the object as an array",74,null],[11,"is_empty","","Returns whether the object, as an array, is empty. Always false.",74,null],[11,"from","","",74,null],[11,"index","","",74,null],[11,"index","","",74,null],[11,"index","","",74,null],[11,"index","","",74,null],[11,"index","","",74,null],[11,"eq","","",74,null],[11,"partial_cmp","","",74,null],[11,"cmp","","",74,null],[11,"clone","","",74,null],[11,"hash","","",74,null],[11,"hash_slice","","",74,null],[11,"rand","","",74,{"inputs":[{"name":"r"}],"output":{"name":"uint128"}}],[11,"low_u32","","Conversion to u32",74,null],[11,"bits","","Return the least number of bits needed to represent the number",74,null],[11,"mul_u32","","Multiplication by u32",74,null],[11,"from_u64","","",74,{"inputs":[{"name":"u64"}],"output":{"name":"option"}}],[11,"from_i64","","",74,{"inputs":[{"name":"i64"}],"output":{"name":"option"}}],[11,"zero","","",74,{"inputs":[],"output":{"name":"uint128"}}],[11,"is_zero","","",74,null],[11,"one","","",74,{"inputs":[],"output":{"name":"uint128"}}],[11,"add","","",74,null],[11,"sub","","",74,null],[11,"mul","","",74,null],[11,"div","","",74,null],[11,"bit","","",74,null],[11,"bit_slice","","",74,null],[11,"mask","","",74,null],[11,"trailing_zeros","","",74,null],[11,"bitand","","",74,null],[11,"bitxor","","",74,null],[11,"bitor","","",74,null],[11,"not","","",74,null],[11,"shl","","",74,null],[11,"shr","","",74,null],[11,"fmt","","",74,null],[11,"consensus_encode","","",74,null],[11,"consensus_decode","","",74,{"inputs":[{"name":"d"}],"output":{"name":"result"}}],[11,"increment","","Increment by 1",73,null],[11,"low_128","","Decay to a uint128",73,null],[8,"BitArray","bitcoin::util","A trait which allows numbers to act as fixed-size bit arrays",null,null],[10,"bit","","Is bit set?",75,null],[10,"bit_slice","","Returns an array which is just the bits from start to end",75,null],[10,"mask","","Bitwise and with `n` ones",75,null],[10,"trailing_zeros","","Trailing zeros",75,null],[11,"fmt","","",42,null],[11,"fmt","","",42,null],[11,"cause","","",42,null],[11,"description","","",42,null],[14,"nu_select!","bitcoin","",null,null],[14,"user_enum!","","",null,null]],"paths":[[4,"Network"],[3,"VarInt"],[3,"CheckedData"],[8,"ConsensusEncodable"],[8,"ConsensusDecodable"],[3,"Socket"],[8,"BitcoinHash"],[8,"SimpleEncoder"],[8,"SimpleDecoder"],[3,"RawEncoder"],[3,"RawDecoder"],[3,"Address"],[8,"Listener"],[3,"CommandString"],[3,"RawNetworkMessage"],[4,"SocketResponse"],[4,"NetworkMessage"],[3,"GetBlocksMessage"],[3,"GetHeadersMessage"],[3,"Inventory"],[4,"InvType"],[3,"VersionMessage"],[4,"All"],[4,"Class"],[4,"Error"],[4,"Instruction"],[3,"Script"],[3,"Builder"],[3,"Instructions"],[3,"TxOutRef"],[3,"TxIn"],[3,"TxOut"],[3,"Transaction"],[4,"SigHashType"],[3,"BlockHeader"],[3,"Block"],[3,"LoneBlockHeader"],[3,"BlockchainNode"],[3,"Blockchain"],[3,"BlockIter"],[3,"RevBlockIter"],[3,"RevStaleBlockIter"],[4,"Error"],[3,"Address"],[3,"Privkey"],[4,"Type"],[4,"Error"],[4,"Error"],[8,"FromBase58"],[8,"ToBase58"],[3,"ExtendedPrivKey"],[3,"ExtendedPubKey"],[4,"ChildNumber"],[4,"Error"],[3,"ChainCode"],[3,"Fingerprint"],[4,"Error"],[3,"Template"],[3,"Decimal"],[3,"UDecimal"],[4,"HexError"],[8,"MerkleRoot"],[3,"Sha256dHash"],[3,"Ripemd160Hash"],[3,"Hash160"],[3,"Hash32"],[3,"Hash48"],[3,"Hash64"],[8,"Pairable"],[3,"Pair"],[3,"PatriciaTree"],[3,"Items"],[3,"MutItems"],[3,"Uint256"],[3,"Uint128"],[8,"BitArray"]]}; initSearch(searchIndex);