1#include <xrpld/app/paths/Flow.h>
2#include <xrpld/app/paths/RippleCalc.h>
3#include <xrpld/app/paths/detail/FlowDebugInfo.h>
5#include <xrpl/basics/Log.h>
6#include <xrpl/ledger/View.h>
7#include <xrpl/protocol/Feature.h>
40 Input const*
const pInputs)
51 <<
"Old payment rules are required for this transaction. Assuming "
52 "this is a replay and running with the new rules.";
56 bool const defaultPaths =
59 bool const partialPayment =
64 saMaxAmountReq > beast::zero)
65 return Quality{Amounts(saMaxAmountReq, saDstAmountReq)};
70 if (saMaxAmountReq >= beast::zero ||
72 saMaxAmountReq.
getIssuer() != uSrcAccountID)
74 return saMaxAmountReq;
99 JLOG(j.error()) <<
"Exception from flow: " << e.
what();
108 j.debug() <<
"RippleCalc Result> "
111 <<
", result: " << flowOut.
result()
112 <<
", dstAmtReq: " << saDstAmountReq
113 <<
", sendMax: " << saMaxAmountReq;
Manages partitions for logging.
beast::Journal journal(std::string const &name)
A wrapper which makes credits unavailable to balances.
void apply(RawView &to)
Apply changes to base view.
bool enabled(uint256 const &feature) const
Returns true if a feature is enabled.
Currency const & getCurrency() const
AccountID const & getIssuer() const
Rules const & rules() const override
Returns the tx processing rules.
static Output rippleCalculate(PaymentSandbox &view, STAmount const &saMaxAmountReq, STAmount const &saDstAmountReq, AccountID const &uDstAccountID, AccountID const &uSrcAccountID, STPathSet const &spsPaths, std::optional< uint256 > const &domainID, Logs &l, Input const *const pInputs=nullptr)
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
StrandResult< TInAmt, TOutAmt > flow(PaymentSandbox const &baseView, Strand const &strand, std::optional< TInAmt > const &maxIn, TOutAmt const &out, beast::Journal j)
Request out amount from a strand.
void setResult(TER const value)