rippled
|
Presents and consumes the offers in an order book. More...
Public Member Functions | |
TOffer< STAmount, STAmount > & | tip () const |
Returns the offer at the tip of the order book. More... | |
bool | step () |
Advance to the next valid offer. More... | |
STAmount | ownerFunds () const |
Protected Member Functions | |
void | permRmOffer (uint256 const &offerIndex) override |
void | erase (ApplyView &view) |
bool | shouldRmSmallIncreasedQOffer () const |
Protected Attributes | |
const beast::Journal | j_ |
ApplyView & | view_ |
ApplyView & | cancelView_ |
Book | book_ |
bool | validBook_ |
const NetClock::time_point | expire_ |
BookTip | tip_ |
TOffer< STAmount, STAmount > | offer_ |
std::optional< STAmount > | ownerFunds_ |
StepCounter & | counter_ |
Presents and consumes the offers in an order book.
Two ApplyView
objects accumulate changes to the ledger. view
is applied when the calling transaction succeeds. If the calling transaction fails, then view_cancel
is applied.
Certain invalid offers are automatically removed:
When an offer is removed, it is removed from both views. This grooms the order book regardless of whether or not the transaction is successful.
Definition at line 147 of file OfferStream.h.
|
overrideprotectedvirtual |
Implements ripple::TOfferStreamBase< STAmount, STAmount >.
Definition at line 365 of file OfferStream.cpp.
|
protectedinherited |
Definition at line 61 of file OfferStream.cpp.
|
protectedinherited |
Definition at line 139 of file OfferStream.cpp.
Returns the offer at the tip of the order book.
Offers are always presented in decreasing quality. Only valid if step() returned true
.
Definition at line 108 of file OfferStream.h.
|
inherited |
Advance to the next valid offer.
This automatically removes:
true
if there is a valid offer. Definition at line 205 of file OfferStream.cpp.
|
inherited |
Definition at line 124 of file OfferStream.h.
|
protectedinherited |
Definition at line 71 of file OfferStream.h.
|
protectedinherited |
Definition at line 72 of file OfferStream.h.
|
protectedinherited |
Definition at line 73 of file OfferStream.h.
|
protectedinherited |
Definition at line 74 of file OfferStream.h.
|
protectedinherited |
Definition at line 75 of file OfferStream.h.
|
protectedinherited |
Definition at line 76 of file OfferStream.h.
|
protectedinherited |
Definition at line 77 of file OfferStream.h.
|
protectedinherited |
Definition at line 78 of file OfferStream.h.
|
protectedinherited |
Definition at line 79 of file OfferStream.h.
|
protectedinherited |
Definition at line 80 of file OfferStream.h.