Package org.bitcoinj.core
Class FeeFilterMessage
- java.lang.Object
-
- org.bitcoinj.core.BaseMessage
-
- org.bitcoinj.core.FeeFilterMessage
-
- All Implemented Interfaces:
Message
public class FeeFilterMessage extends BaseMessage
Represents a "feefilter" message on the P2P network, which instructs a peer to filter transaction invs for transactions that fall below the feerate provided.See BIP133 for details.
Instances of this class are immutable.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected voidbitcoinSerializeToStream(java.io.OutputStream stream)Serializes this message to the provided stream.CoinfeeRate()Gets the fee rate.CoingetFeeRate()Deprecated.usefeeRate()static FeeFilterMessageof(Coin feeRate)Create a fee filter message with a given fee rate.static FeeFilterMessageread(java.nio.ByteBuffer payload)Deserialize this message from a given payload.java.lang.StringtoString()-
Methods inherited from class org.bitcoinj.core.BaseMessage
messageSize, serialize
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.bitcoinj.core.Message
bitcoinSerialize, getMessageSize, unsafeBitcoinSerialize
-
-
-
-
Method Detail
-
of
public static FeeFilterMessage of(Coin feeRate)
Create a fee filter message with a given fee rate.- Parameters:
feeRate- fee rate- Returns:
- fee filter message
-
read
public static FeeFilterMessage read(java.nio.ByteBuffer payload) throws java.nio.BufferUnderflowException, ProtocolException
Deserialize this message from a given payload.- Parameters:
payload- payload to deserialize from- Returns:
- read message
- Throws:
java.nio.BufferUnderflowException- if the read message extends beyond the remaining bytes of the payloadProtocolException
-
bitcoinSerializeToStream
protected void bitcoinSerializeToStream(java.io.OutputStream stream) throws java.io.IOExceptionDescription copied from class:BaseMessageSerializes this message to the provided stream. If you just want the raw bytes useBaseMessage.serialize().- Specified by:
bitcoinSerializeToStreamin classBaseMessage- Throws:
java.io.IOException
-
feeRate
public Coin feeRate()
Gets the fee rate.- Returns:
- fee rate
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-