Support Mempool message
This does not yet push requests into services that actually respond with transaction hashes in our node's mempool, which doesn't exist yet. Pertains to #26
This commit is contained in:
parent
6d79352fb6
commit
98079c9d77
|
|
@ -258,7 +258,7 @@ impl Codec {
|
||||||
writer.write_u32::<LittleEndian>(version.0)?;
|
writer.write_u32::<LittleEndian>(version.0)?;
|
||||||
transaction.zcash_serialize(&mut writer)?
|
transaction.zcash_serialize(&mut writer)?
|
||||||
}
|
}
|
||||||
// Mempool => {}
|
Mempool => { /* Empty payload -- no-op */ }
|
||||||
// FilterLoad => {}
|
// FilterLoad => {}
|
||||||
// FilterAdd => {}
|
// FilterAdd => {}
|
||||||
// FilterClear => {}
|
// FilterClear => {}
|
||||||
|
|
@ -557,7 +557,7 @@ impl Codec {
|
||||||
}
|
}
|
||||||
|
|
||||||
fn read_mempool<R: Read>(&self, mut _reader: R) -> Result<Message, Error> {
|
fn read_mempool<R: Read>(&self, mut _reader: R) -> Result<Message, Error> {
|
||||||
return Err(Error::Parse("mempool messages are not implemented"));
|
Ok(Message::Mempool)
|
||||||
}
|
}
|
||||||
|
|
||||||
fn read_filterload<R: Read>(&self, mut _reader: R) -> Result<Message, Error> {
|
fn read_filterload<R: Read>(&self, mut _reader: R) -> Result<Message, Error> {
|
||||||
|
|
|
||||||
|
|
@ -272,7 +272,7 @@ pub enum Message {
|
||||||
///
|
///
|
||||||
/// [Bitcoin reference](https://en.bitcoin.it/wiki/Protocol_documentation#mempool)
|
/// [Bitcoin reference](https://en.bitcoin.it/wiki/Protocol_documentation#mempool)
|
||||||
/// [BIP35]: https://github.com/bitcoin/bips/blob/master/bip-0035.mediawiki
|
/// [BIP35]: https://github.com/bitcoin/bips/blob/master/bip-0035.mediawiki
|
||||||
Mempool {/* XXX add fields */},
|
Mempool,
|
||||||
|
|
||||||
/// A `filterload` message.
|
/// A `filterload` message.
|
||||||
///
|
///
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue