mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-24 04:55:52 +00:00
516 lines
137 KiB
HTML
516 lines
137 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
<meta name="generator" content="Doxygen 1.8.17"/>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<title>rippled: Taker_test.cpp Source File</title>
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="jquery.js"></script>
|
|
<script type="text/javascript" src="dynsections.js"></script>
|
|
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
<script type="text/javascript" src="search/search.js"></script>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
</head>
|
|
<body>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<div id="titlearea">
|
|
<table cellspacing="0" cellpadding="0">
|
|
<tbody>
|
|
<tr style="height: 56px;">
|
|
<td id="projectalign" style="padding-left: 0.5em;">
|
|
<div id="projectname">rippled
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.8.17 -->
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
/* @license-end */
|
|
</script>
|
|
<script type="text/javascript" src="menudata.js"></script>
|
|
<script type="text/javascript" src="menu.js"></script>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
$(function() {
|
|
initMenu('',true,false,'search.php','Search');
|
|
$(document).ready(function() { init_search(); });
|
|
});
|
|
/* @license-end */</script>
|
|
<div id="main-nav"></div>
|
|
<!-- window showing the filter options -->
|
|
<div id="MSearchSelectWindow"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
</div>
|
|
|
|
<!-- iframe showing the search results (closed by default) -->
|
|
<div id="MSearchResultsWindow">
|
|
<iframe src="javascript:void(0)" frameborder="0"
|
|
name="MSearchResults" id="MSearchResults">
|
|
</iframe>
|
|
</div>
|
|
|
|
<div id="nav-path" class="navpath">
|
|
<ul>
|
|
<li class="navelem"><a class="el" href="dir_120ed4da3e3217b1e7fc0b4f48568e79.html">test</a></li><li class="navelem"><a class="el" href="dir_7ab758b8a77751d62709b12ccae53e10.html">app</a></li> </ul>
|
|
</div>
|
|
</div><!-- top -->
|
|
<div class="header">
|
|
<div class="headertitle">
|
|
<div class="title">Taker_test.cpp</div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> <span class="comment">//------------------------------------------------------------------------------</span></div>
|
|
<div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="comment">/*</span></div>
|
|
<div class="line"><a name="l00003"></a><span class="lineno"> 3</span> <span class="comment"> This file is part of rippled: https://github.com/ripple/rippled</span></div>
|
|
<div class="line"><a name="l00004"></a><span class="lineno"> 4</span> <span class="comment"> Copyright (c) 2012, 2013 Ripple Labs Inc.</span></div>
|
|
<div class="line"><a name="l00005"></a><span class="lineno"> 5</span> <span class="comment"></span> </div>
|
|
<div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="comment"> Permission to use, copy, modify, and/or distribute this software for any</span></div>
|
|
<div class="line"><a name="l00007"></a><span class="lineno"> 7</span> <span class="comment"> purpose with or without fee is hereby granted, provided that the above</span></div>
|
|
<div class="line"><a name="l00008"></a><span class="lineno"> 8</span> <span class="comment"> copyright notice and this permission notice appear in all copies.</span></div>
|
|
<div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="comment"></span> </div>
|
|
<div class="line"><a name="l00010"></a><span class="lineno"> 10</span> <span class="comment"> THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES</span></div>
|
|
<div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="comment"> WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF</span></div>
|
|
<div class="line"><a name="l00012"></a><span class="lineno"> 12</span> <span class="comment"> MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR</span></div>
|
|
<div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="comment"> ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES</span></div>
|
|
<div class="line"><a name="l00014"></a><span class="lineno"> 14</span> <span class="comment"> WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN</span></div>
|
|
<div class="line"><a name="l00015"></a><span class="lineno"> 15</span> <span class="comment"> ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF</span></div>
|
|
<div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="comment"> OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.</span></div>
|
|
<div class="line"><a name="l00017"></a><span class="lineno"> 17</span> <span class="comment">*/</span></div>
|
|
<div class="line"><a name="l00018"></a><span class="lineno"> 18</span> <span class="comment">//==============================================================================</span></div>
|
|
<div class="line"><a name="l00019"></a><span class="lineno"> 19</span>  </div>
|
|
<div class="line"><a name="l00020"></a><span class="lineno"> 20</span> <span class="preprocessor">#include <ripple/app/tx/impl/Taker.h></span></div>
|
|
<div class="line"><a name="l00021"></a><span class="lineno"> 21</span> <span class="preprocessor">#include <ripple/beast/unit_test.h></span></div>
|
|
<div class="line"><a name="l00022"></a><span class="lineno"> 22</span> <span class="preprocessor">#include <ripple/beast/core/LexicalCast.h></span></div>
|
|
<div class="line"><a name="l00023"></a><span class="lineno"> 23</span> <span class="preprocessor">#include <<a class="codeRef" href="http://en.cppreference.com/w/cpp/header/type_traits.html">type_traits</a>></span></div>
|
|
<div class="line"><a name="l00024"></a><span class="lineno"> 24</span>  </div>
|
|
<div class="line"><a name="l00025"></a><span class="lineno"> 25</span> <span class="keyword">namespace </span><a class="code" href="namespaceripple.html">ripple</a> {</div>
|
|
<div class="line"><a name="l00026"></a><span class="lineno"> 26</span>  </div>
|
|
<div class="line"><a name="l00027"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html"> 27</a></span> <span class="keyword">class </span><a class="code" href="classripple_1_1Taker__test.html">Taker_test</a> : <span class="keyword">public</span> beast::unit_test::suite</div>
|
|
<div class="line"><a name="l00028"></a><span class="lineno"> 28</span> {</div>
|
|
<div class="line"><a name="l00029"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301"> 29</a></span>  <span class="keyword">static</span> <span class="keywordtype">bool</span> <span class="keyword">const</span> <a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a> = <span class="keyword">false</span>;</div>
|
|
<div class="line"><a name="l00030"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7"> 30</a></span>  <span class="keyword">static</span> <span class="keywordtype">bool</span> <span class="keyword">const</span> <a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a> = <span class="keyword">true</span>;</div>
|
|
<div class="line"><a name="l00031"></a><span class="lineno"> 31</span>  </div>
|
|
<div class="line"><a name="l00032"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test_1_1TestTaker.html"> 32</a></span>  <span class="keyword">class </span><a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html">TestTaker</a></div>
|
|
<div class="line"><a name="l00033"></a><span class="lineno"> 33</span>  : <span class="keyword">public</span> <a class="code" href="classripple_1_1BasicTaker.html">BasicTaker</a></div>
|
|
<div class="line"><a name="l00034"></a><span class="lineno"> 34</span>  {</div>
|
|
<div class="line"><a name="l00035"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test_1_1TestTaker.html#ac903b7f1ea6fb73138e1ea548bec5dcd"> 35</a></span>  <a class="code" href="classripple_1_1STAmount.html">STAmount</a> <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#ac903b7f1ea6fb73138e1ea548bec5dcd">funds_</a>;</div>
|
|
<div class="line"><a name="l00036"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test_1_1TestTaker.html#ad6aa65477ffc8cc6981696a8c3399454"> 36</a></span>  <a class="code" href="classripple_1_1STAmount.html">STAmount</a> <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#ad6aa65477ffc8cc6981696a8c3399454">cross_funds</a>;</div>
|
|
<div class="line"><a name="l00037"></a><span class="lineno"> 37</span>  </div>
|
|
<div class="line"><a name="l00038"></a><span class="lineno"> 38</span>  <span class="keyword">public</span>:</div>
|
|
<div class="line"><a name="l00039"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test_1_1TestTaker.html#ab4e3b230ec32048830c6c54d2c50334e"> 39</a></span>  <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#ab4e3b230ec32048830c6c54d2c50334e">TestTaker</a> (</div>
|
|
<div class="line"><a name="l00040"></a><span class="lineno"> 40</span>  <a class="code" href="namespaceripple.html#ae9b6ac4bca5f49e1aa2753e0d9faa2a1">CrossType</a> <a class="code" href="classripple_1_1BasicTaker.html#a6dd41ec89debfd1a7f86305e1a752272">cross_type</a>,</div>
|
|
<div class="line"><a name="l00041"></a><span class="lineno"> 41</span>  Amounts <span class="keyword">const</span>& amount,</div>
|
|
<div class="line"><a name="l00042"></a><span class="lineno"> 42</span>  Quality <span class="keyword">const</span>& quality,</div>
|
|
<div class="line"><a name="l00043"></a><span class="lineno"> 43</span>  <a class="code" href="classripple_1_1STAmount.html">STAmount</a> <span class="keyword">const</span>& funds,</div>
|
|
<div class="line"><a name="l00044"></a><span class="lineno"> 44</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a> flags,</div>
|
|
<div class="line"><a name="l00045"></a><span class="lineno"> 45</span>  <a class="code" href="structripple_1_1Rate.html">Rate</a> <span class="keyword">const</span>& rate_in,</div>
|
|
<div class="line"><a name="l00046"></a><span class="lineno"> 46</span>  <a class="code" href="structripple_1_1Rate.html">Rate</a> <span class="keyword">const</span>& rate_out)</div>
|
|
<div class="line"><a name="l00047"></a><span class="lineno"> 47</span>  : <a class="code" href="classripple_1_1BasicTaker.html">BasicTaker</a> (</div>
|
|
<div class="line"><a name="l00048"></a><span class="lineno"> 48</span>  <a class="code" href="classripple_1_1BasicTaker.html#a6dd41ec89debfd1a7f86305e1a752272">cross_type</a>,</div>
|
|
<div class="line"><a name="l00049"></a><span class="lineno"> 49</span>  <a class="code" href="classripple_1_1base__uint.html">AccountID</a>(0x4701),</div>
|
|
<div class="line"><a name="l00050"></a><span class="lineno"> 50</span>  amount,</div>
|
|
<div class="line"><a name="l00051"></a><span class="lineno"> 51</span>  quality,</div>
|
|
<div class="line"><a name="l00052"></a><span class="lineno"> 52</span>  flags,</div>
|
|
<div class="line"><a name="l00053"></a><span class="lineno"> 53</span>  rate_in,</div>
|
|
<div class="line"><a name="l00054"></a><span class="lineno"> 54</span>  rate_out)</div>
|
|
<div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  , <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#ac903b7f1ea6fb73138e1ea548bec5dcd">funds_</a> (funds)</div>
|
|
<div class="line"><a name="l00056"></a><span class="lineno"> 56</span>  {</div>
|
|
<div class="line"><a name="l00057"></a><span class="lineno"> 57</span>  }</div>
|
|
<div class="line"><a name="l00058"></a><span class="lineno"> 58</span>  </div>
|
|
<div class="line"><a name="l00059"></a><span class="lineno"> 59</span>  <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00060"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test_1_1TestTaker.html#a443d4b07451efd27f2c2233f0cb563e4"> 60</a></span>  <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#a443d4b07451efd27f2c2233f0cb563e4">set_funds</a> (<a class="code" href="classripple_1_1STAmount.html">STAmount</a> <span class="keyword">const</span>& funds)</div>
|
|
<div class="line"><a name="l00061"></a><span class="lineno"> 61</span>  {</div>
|
|
<div class="line"><a name="l00062"></a><span class="lineno"> 62</span>  <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#ad6aa65477ffc8cc6981696a8c3399454">cross_funds</a> = funds;</div>
|
|
<div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  }</div>
|
|
<div class="line"><a name="l00064"></a><span class="lineno"> 64</span>  </div>
|
|
<div class="line"><a name="l00065"></a><span class="lineno"> 65</span>  <a class="code" href="classripple_1_1STAmount.html">STAmount</a></div>
|
|
<div class="line"><a name="l00066"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test_1_1TestTaker.html#a272da0e03776ed606702808ea4db21ab"> 66</a></span>  <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#a272da0e03776ed606702808ea4db21ab">get_funds</a> (<a class="code" href="classripple_1_1base__uint.html">AccountID</a> <span class="keyword">const</span>& owner, <a class="code" href="classripple_1_1STAmount.html">STAmount</a> <span class="keyword">const</span>& funds)<span class="keyword"> const override</span></div>
|
|
<div class="line"><a name="l00067"></a><span class="lineno"> 67</span> <span class="keyword"> </span>{</div>
|
|
<div class="line"><a name="l00068"></a><span class="lineno"> 68</span>  <span class="keywordflow">if</span> (owner == <a class="code" href="classripple_1_1BasicTaker.html#ac208f3e27e0dfa925dcb34414b9a8ba4">account</a> ())</div>
|
|
<div class="line"><a name="l00069"></a><span class="lineno"> 69</span>  <span class="keywordflow">return</span> <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#ac903b7f1ea6fb73138e1ea548bec5dcd">funds_</a>;</div>
|
|
<div class="line"><a name="l00070"></a><span class="lineno"> 70</span>  </div>
|
|
<div class="line"><a name="l00071"></a><span class="lineno"> 71</span>  <span class="keywordflow">return</span> <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#ad6aa65477ffc8cc6981696a8c3399454">cross_funds</a>;</div>
|
|
<div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  }</div>
|
|
<div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  </div>
|
|
<div class="line"><a name="l00074"></a><span class="lineno"> 74</span>  Amounts</div>
|
|
<div class="line"><a name="l00075"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test_1_1TestTaker.html#a5cc0c788e59c9af26cbb3993a583441a"> 75</a></span>  <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#a5cc0c788e59c9af26cbb3993a583441a">cross</a> (Amounts offer, Quality quality)</div>
|
|
<div class="line"><a name="l00076"></a><span class="lineno"> 76</span>  {</div>
|
|
<div class="line"><a name="l00077"></a><span class="lineno"> 77</span>  <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1BasicTaker.html#a767e75e4d5d6181a3419d0df1b1bebc9">reject</a> (quality))</div>
|
|
<div class="line"><a name="l00078"></a><span class="lineno"> 78</span>  <span class="keywordflow">return</span> Amounts (offer.in.zeroed (), offer.out.zeroed ());</div>
|
|
<div class="line"><a name="l00079"></a><span class="lineno"> 79</span>  </div>
|
|
<div class="line"><a name="l00080"></a><span class="lineno"> 80</span>  <span class="comment">// we need to emulate "unfunded offers" behavior</span></div>
|
|
<div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#a272da0e03776ed606702808ea4db21ab">get_funds</a> (<a class="code" href="classripple_1_1base__uint.html">AccountID</a> (0x4702), offer.out) == beast::zero)</div>
|
|
<div class="line"><a name="l00082"></a><span class="lineno"> 82</span>  <span class="keywordflow">return</span> Amounts (offer.in.zeroed (), offer.out.zeroed ());</div>
|
|
<div class="line"><a name="l00083"></a><span class="lineno"> 83</span>  </div>
|
|
<div class="line"><a name="l00084"></a><span class="lineno"> 84</span>  <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1BasicTaker.html#a27d9a56a69cd21c25afe074a095a6995">done</a> ())</div>
|
|
<div class="line"><a name="l00085"></a><span class="lineno"> 85</span>  <span class="keywordflow">return</span> Amounts (offer.in.zeroed (), offer.out.zeroed ());</div>
|
|
<div class="line"><a name="l00086"></a><span class="lineno"> 86</span>  </div>
|
|
<div class="line"><a name="l00087"></a><span class="lineno"> 87</span>  <span class="keyword">auto</span> result = <a class="code" href="classripple_1_1BasicTaker.html#ae67e802167cb58a7701345924fefe4ff">do_cross</a> (offer, quality, <a class="code" href="classripple_1_1base__uint.html">AccountID</a> (0x4702));</div>
|
|
<div class="line"><a name="l00088"></a><span class="lineno"> 88</span>  </div>
|
|
<div class="line"><a name="l00089"></a><span class="lineno"> 89</span>  <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#ac903b7f1ea6fb73138e1ea548bec5dcd">funds_</a> -= result.order.in;</div>
|
|
<div class="line"><a name="l00090"></a><span class="lineno"> 90</span>  </div>
|
|
<div class="line"><a name="l00091"></a><span class="lineno"> 91</span>  <span class="keywordflow">return</span> result.order;</div>
|
|
<div class="line"><a name="l00092"></a><span class="lineno"> 92</span>  }</div>
|
|
<div class="line"><a name="l00093"></a><span class="lineno"> 93</span>  </div>
|
|
<div class="line"><a name="l00094"></a><span class="lineno"> 94</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/pair.html">std::pair<Amounts, Amounts></a></div>
|
|
<div class="line"><a name="l00095"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test_1_1TestTaker.html#a24b1e3e4f89d479d359a013b38af56cd"> 95</a></span>  <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#a24b1e3e4f89d479d359a013b38af56cd">cross</a> (Amounts offer1, Quality quality1, Amounts offer2, Quality quality2)</div>
|
|
<div class="line"><a name="l00096"></a><span class="lineno"> 96</span>  {</div>
|
|
<div class="line"><a name="l00097"></a><span class="lineno"> 97</span>  <span class="comment">/* check if composed quality should be rejected */</span></div>
|
|
<div class="line"><a name="l00098"></a><span class="lineno"> 98</span>  Quality <span class="keyword">const</span> quality (<a class="code" href="namespaceripple.html#a7c8945b5034bba5f9df719cff2503495">composed_quality</a> (</div>
|
|
<div class="line"><a name="l00099"></a><span class="lineno"> 99</span>  quality1, quality2));</div>
|
|
<div class="line"><a name="l00100"></a><span class="lineno"> 100</span>  </div>
|
|
<div class="line"><a name="l00101"></a><span class="lineno"> 101</span>  <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1BasicTaker.html#a767e75e4d5d6181a3419d0df1b1bebc9">reject</a> (quality))</div>
|
|
<div class="line"><a name="l00102"></a><span class="lineno"> 102</span>  <span class="keywordflow">return</span> <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/pair/make_pair.html">std::make_pair</a>(</div>
|
|
<div class="line"><a name="l00103"></a><span class="lineno"> 103</span>  Amounts { offer1.in.zeroed (), offer1.out.zeroed () },</div>
|
|
<div class="line"><a name="l00104"></a><span class="lineno"> 104</span>  Amounts { offer2.in.zeroed (), offer2.out.zeroed () });</div>
|
|
<div class="line"><a name="l00105"></a><span class="lineno"> 105</span>  </div>
|
|
<div class="line"><a name="l00106"></a><span class="lineno"> 106</span>  <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1BasicTaker.html#a27d9a56a69cd21c25afe074a095a6995">done</a> ())</div>
|
|
<div class="line"><a name="l00107"></a><span class="lineno"> 107</span>  <span class="keywordflow">return</span> <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/pair/make_pair.html">std::make_pair</a>(</div>
|
|
<div class="line"><a name="l00108"></a><span class="lineno"> 108</span>  Amounts { offer1.in.zeroed (), offer1.out.zeroed () },</div>
|
|
<div class="line"><a name="l00109"></a><span class="lineno"> 109</span>  Amounts { offer2.in.zeroed (), offer2.out.zeroed () });</div>
|
|
<div class="line"><a name="l00110"></a><span class="lineno"> 110</span>  </div>
|
|
<div class="line"><a name="l00111"></a><span class="lineno"> 111</span>  <span class="keyword">auto</span> result = <a class="code" href="classripple_1_1BasicTaker.html#ae67e802167cb58a7701345924fefe4ff">do_cross</a> (</div>
|
|
<div class="line"><a name="l00112"></a><span class="lineno"> 112</span>  offer1, quality1, <a class="code" href="classripple_1_1base__uint.html">AccountID</a> (0x4703),</div>
|
|
<div class="line"><a name="l00113"></a><span class="lineno"> 113</span>  offer2, quality2, <a class="code" href="classripple_1_1base__uint.html">AccountID</a> (0x4704));</div>
|
|
<div class="line"><a name="l00114"></a><span class="lineno"> 114</span>  </div>
|
|
<div class="line"><a name="l00115"></a><span class="lineno"> 115</span>  <span class="keywordflow">return</span> <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/pair/make_pair.html">std::make_pair</a> (result.first.order, result.second.order);</div>
|
|
<div class="line"><a name="l00116"></a><span class="lineno"> 116</span>  }</div>
|
|
<div class="line"><a name="l00117"></a><span class="lineno"> 117</span>  };</div>
|
|
<div class="line"><a name="l00118"></a><span class="lineno"> 118</span>  </div>
|
|
<div class="line"><a name="l00119"></a><span class="lineno"> 119</span> <span class="keyword">private</span>:</div>
|
|
<div class="line"><a name="l00120"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab"> 120</a></span>  <a class="code" href="classripple_1_1Issue.html">Issue</a> <span class="keyword">const</span>& <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a> ()<span class="keyword"> const</span></div>
|
|
<div class="line"><a name="l00121"></a><span class="lineno"> 121</span> <span class="keyword"> </span>{</div>
|
|
<div class="line"><a name="l00122"></a><span class="lineno"> 122</span>  <span class="keyword">static</span> <a class="code" href="classripple_1_1Issue.html">Issue</a> <span class="keyword">const</span> issue (</div>
|
|
<div class="line"><a name="l00123"></a><span class="lineno"> 123</span>  <a class="code" href="classripple_1_1base__uint.html">Currency</a> (0x5553440000000000), <a class="code" href="classripple_1_1base__uint.html">AccountID</a> (0x4985601));</div>
|
|
<div class="line"><a name="l00124"></a><span class="lineno"> 124</span>  <span class="keywordflow">return</span> issue;</div>
|
|
<div class="line"><a name="l00125"></a><span class="lineno"> 125</span>  }</div>
|
|
<div class="line"><a name="l00126"></a><span class="lineno"> 126</span>  </div>
|
|
<div class="line"><a name="l00127"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#a12e2c1d08d76040a624e3cf2f92bbe51"> 127</a></span>  <a class="code" href="classripple_1_1Issue.html">Issue</a> <span class="keyword">const</span>& <a class="code" href="classripple_1_1Taker__test.html#a12e2c1d08d76040a624e3cf2f92bbe51">eur</a> ()<span class="keyword"> const</span></div>
|
|
<div class="line"><a name="l00128"></a><span class="lineno"> 128</span> <span class="keyword"> </span>{</div>
|
|
<div class="line"><a name="l00129"></a><span class="lineno"> 129</span>  <span class="keyword">static</span> <a class="code" href="classripple_1_1Issue.html">Issue</a> <span class="keyword">const</span> issue (</div>
|
|
<div class="line"><a name="l00130"></a><span class="lineno"> 130</span>  <a class="code" href="classripple_1_1base__uint.html">Currency</a> (0x4555520000000000), <a class="code" href="classripple_1_1base__uint.html">AccountID</a> (0x4985602));</div>
|
|
<div class="line"><a name="l00131"></a><span class="lineno"> 131</span>  <span class="keywordflow">return</span> issue;</div>
|
|
<div class="line"><a name="l00132"></a><span class="lineno"> 132</span>  }</div>
|
|
<div class="line"><a name="l00133"></a><span class="lineno"> 133</span>  </div>
|
|
<div class="line"><a name="l00134"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01"> 134</a></span>  <a class="code" href="classripple_1_1Issue.html">Issue</a> <span class="keyword">const</span>& <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a> ()<span class="keyword"> const</span></div>
|
|
<div class="line"><a name="l00135"></a><span class="lineno"> 135</span> <span class="keyword"> </span>{</div>
|
|
<div class="line"><a name="l00136"></a><span class="lineno"> 136</span>  <span class="keyword">static</span> <a class="code" href="classripple_1_1Issue.html">Issue</a> <span class="keyword">const</span> issue (</div>
|
|
<div class="line"><a name="l00137"></a><span class="lineno"> 137</span>  <a class="code" href="namespaceripple.html#a91af9326e7f471001066b6b59f24599c">xrpCurrency</a> (), <a class="code" href="namespaceripple.html#a21696ba0d0fac348f88f1b9da51091b0">xrpAccount</a> ());</div>
|
|
<div class="line"><a name="l00138"></a><span class="lineno"> 138</span>  <span class="keywordflow">return</span> issue;</div>
|
|
<div class="line"><a name="l00139"></a><span class="lineno"> 139</span>  }</div>
|
|
<div class="line"><a name="l00140"></a><span class="lineno"> 140</span>  </div>
|
|
<div class="line"><a name="l00141"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#a8c5681e544ba369b1d8d8a7fa8308326"> 141</a></span>  <a class="code" href="classripple_1_1STAmount.html">STAmount</a> <a class="code" href="classripple_1_1Taker__test.html#a8c5681e544ba369b1d8d8a7fa8308326">parse_amount</a> (<a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <span class="keyword">const</span>& amount, <a class="code" href="classripple_1_1Issue.html">Issue</a> <span class="keyword">const</span>& issue)</div>
|
|
<div class="line"><a name="l00142"></a><span class="lineno"> 142</span>  {</div>
|
|
<div class="line"><a name="l00143"></a><span class="lineno"> 143</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#a554a0e32abce925cc434c3a03e584ceb">amountFromString</a> (issue, amount);</div>
|
|
<div class="line"><a name="l00144"></a><span class="lineno"> 144</span>  }</div>
|
|
<div class="line"><a name="l00145"></a><span class="lineno"> 145</span>  </div>
|
|
<div class="line"><a name="l00146"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#af842fd8b8e50c9d2813fbba65562217e"> 146</a></span>  Amounts <a class="code" href="classripple_1_1Taker__test.html#af842fd8b8e50c9d2813fbba65562217e">parse_amounts</a> (</div>
|
|
<div class="line"><a name="l00147"></a><span class="lineno"> 147</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <span class="keyword">const</span>& amount_in, <a class="code" href="classripple_1_1Issue.html">Issue</a> <span class="keyword">const</span>& issue_in,</div>
|
|
<div class="line"><a name="l00148"></a><span class="lineno"> 148</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <span class="keyword">const</span>& amount_out, <a class="code" href="classripple_1_1Issue.html">Issue</a> <span class="keyword">const</span>& issue_out)</div>
|
|
<div class="line"><a name="l00149"></a><span class="lineno"> 149</span>  {</div>
|
|
<div class="line"><a name="l00150"></a><span class="lineno"> 150</span>  <a class="code" href="classripple_1_1STAmount.html">STAmount</a> <span class="keyword">const</span> <a class="code" href="namespaceripple.html#a7cc64e12723fbc9606d85442a2569feda13b5bfe96f3e2fe411c9f66f4a582adf">in</a> (<a class="code" href="classripple_1_1Taker__test.html#a8c5681e544ba369b1d8d8a7fa8308326">parse_amount</a> (amount_in, issue_in));</div>
|
|
<div class="line"><a name="l00151"></a><span class="lineno"> 151</span>  <a class="code" href="classripple_1_1STAmount.html">STAmount</a> <span class="keyword">const</span> <a class="code" href="namespaceripple.html#a7cc64e12723fbc9606d85442a2569fedac68271a63ddbc431c307beb7d2918275">out</a> (<a class="code" href="classripple_1_1Taker__test.html#a8c5681e544ba369b1d8d8a7fa8308326">parse_amount</a> (amount_out, issue_out));</div>
|
|
<div class="line"><a name="l00152"></a><span class="lineno"> 152</span>  </div>
|
|
<div class="line"><a name="l00153"></a><span class="lineno"> 153</span>  <span class="keywordflow">return</span> { <a class="code" href="namespaceripple.html#a7cc64e12723fbc9606d85442a2569feda13b5bfe96f3e2fe411c9f66f4a582adf">in</a>, <a class="code" href="namespaceripple.html#a7cc64e12723fbc9606d85442a2569fedac68271a63ddbc431c307beb7d2918275">out</a> };</div>
|
|
<div class="line"><a name="l00154"></a><span class="lineno"> 154</span>  }</div>
|
|
<div class="line"><a name="l00155"></a><span class="lineno"> 155</span>  </div>
|
|
<div class="line"><a name="l00156"></a><span class="lineno"><a class="line" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html"> 156</a></span>  <span class="keyword">struct </span><a class="code" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html">cross_attempt_offer</a></div>
|
|
<div class="line"><a name="l00157"></a><span class="lineno"> 157</span>  {</div>
|
|
<div class="line"><a name="l00158"></a><span class="lineno"><a class="line" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#af9b07975d33b85eda1af7c9490a04a7c"> 158</a></span>  <a class="code" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#af9b07975d33b85eda1af7c9490a04a7c">cross_attempt_offer</a> (<a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <span class="keyword">const</span>& in_,</div>
|
|
<div class="line"><a name="l00159"></a><span class="lineno"> 159</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <span class="keyword">const</span> &out_)</div>
|
|
<div class="line"><a name="l00160"></a><span class="lineno"> 160</span>  : <a class="code" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#a67008047e2492e25db392e8fb8be1dae">in</a> (in_)</div>
|
|
<div class="line"><a name="l00161"></a><span class="lineno"> 161</span>  , <a class="code" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#aaacd92d602ca639656ba7c0e1a1f10a5">out</a> (out_)</div>
|
|
<div class="line"><a name="l00162"></a><span class="lineno"> 162</span>  {</div>
|
|
<div class="line"><a name="l00163"></a><span class="lineno"> 163</span>  }</div>
|
|
<div class="line"><a name="l00164"></a><span class="lineno"> 164</span>  </div>
|
|
<div class="line"><a name="l00165"></a><span class="lineno"><a class="line" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#a67008047e2492e25db392e8fb8be1dae"> 165</a></span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <a class="code" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#a67008047e2492e25db392e8fb8be1dae">in</a>;</div>
|
|
<div class="line"><a name="l00166"></a><span class="lineno"><a class="line" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#aaacd92d602ca639656ba7c0e1a1f10a5"> 166</a></span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <a class="code" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#aaacd92d602ca639656ba7c0e1a1f10a5">out</a>;</div>
|
|
<div class="line"><a name="l00167"></a><span class="lineno"> 167</span>  };</div>
|
|
<div class="line"><a name="l00168"></a><span class="lineno"> 168</span>  </div>
|
|
<div class="line"><a name="l00169"></a><span class="lineno"> 169</span> <span class="keyword">private</span>:</div>
|
|
<div class="line"><a name="l00170"></a><span class="lineno"> 170</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a></div>
|
|
<div class="line"><a name="l00171"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#a9863d3d1412138fc834ff640230821ed"> 171</a></span>  <a class="code" href="classripple_1_1Taker__test.html#a9863d3d1412138fc834ff640230821ed">format_amount</a> (<a class="code" href="classripple_1_1STAmount.html">STAmount</a> <span class="keyword">const</span>& amount)</div>
|
|
<div class="line"><a name="l00172"></a><span class="lineno"> 172</span>  {</div>
|
|
<div class="line"><a name="l00173"></a><span class="lineno"> 173</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> txt = amount.<a class="code" href="classripple_1_1STAmount.html#aa65826cb148b5d15412fceecca5ae47c">getText</a> ();</div>
|
|
<div class="line"><a name="l00174"></a><span class="lineno"> 174</span>  txt += <span class="stringliteral">"/"</span>;</div>
|
|
<div class="line"><a name="l00175"></a><span class="lineno"> 175</span>  txt += <a class="code" href="namespaceripple.html#a96888695e8d79474e080c334f149e30a">to_string</a> (amount.<a class="code" href="classripple_1_1STAmount.html#a60d8449d2915fa495f12994f56ceca34">issue</a>().<a class="code" href="classripple_1_1Issue.html#a4b723aa4198e4c630e41de06586e2fe7">currency</a>);</div>
|
|
<div class="line"><a name="l00176"></a><span class="lineno"> 176</span>  <span class="keywordflow">return</span> txt;</div>
|
|
<div class="line"><a name="l00177"></a><span class="lineno"> 177</span>  }</div>
|
|
<div class="line"><a name="l00178"></a><span class="lineno"> 178</span>  </div>
|
|
<div class="line"><a name="l00179"></a><span class="lineno"> 179</span>  <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00180"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea"> 180</a></span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (</div>
|
|
<div class="line"><a name="l00181"></a><span class="lineno"> 181</span>  <span class="keywordtype">bool</span> sell,</div>
|
|
<div class="line"><a name="l00182"></a><span class="lineno"> 182</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> name,</div>
|
|
<div class="line"><a name="l00183"></a><span class="lineno"> 183</span>  Quality taker_quality,</div>
|
|
<div class="line"><a name="l00184"></a><span class="lineno"> 184</span>  <a class="code" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html">cross_attempt_offer</a> <span class="keyword">const</span> offer,</div>
|
|
<div class="line"><a name="l00185"></a><span class="lineno"> 185</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <span class="keyword">const</span> funds,</div>
|
|
<div class="line"><a name="l00186"></a><span class="lineno"> 186</span>  Quality cross_quality,</div>
|
|
<div class="line"><a name="l00187"></a><span class="lineno"> 187</span>  <a class="code" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html">cross_attempt_offer</a> <span class="keyword">const</span> cross,</div>
|
|
<div class="line"><a name="l00188"></a><span class="lineno"> 188</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <span class="keyword">const</span> cross_funds,</div>
|
|
<div class="line"><a name="l00189"></a><span class="lineno"> 189</span>  <a class="code" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html">cross_attempt_offer</a> <span class="keyword">const</span> <a class="code" href="namespaceripple.html#aea839338eb91258b10d5d14262ef079f">flow</a>,</div>
|
|
<div class="line"><a name="l00190"></a><span class="lineno"> 190</span>  <a class="code" href="classripple_1_1Issue.html">Issue</a> <span class="keyword">const</span>& issue_in,</div>
|
|
<div class="line"><a name="l00191"></a><span class="lineno"> 191</span>  <a class="code" href="classripple_1_1Issue.html">Issue</a> <span class="keyword">const</span>& issue_out,</div>
|
|
<div class="line"><a name="l00192"></a><span class="lineno"> 192</span>  <a class="code" href="structripple_1_1Rate.html">Rate</a> rate_in = <a class="code" href="namespaceripple.html#a8ca9b43bfc508a3fdbc296fb926320ce">parityRate</a>,</div>
|
|
<div class="line"><a name="l00193"></a><span class="lineno"> 193</span>  <a class="code" href="structripple_1_1Rate.html">Rate</a> rate_out = <a class="code" href="namespaceripple.html#a8ca9b43bfc508a3fdbc296fb926320ce">parityRate</a>)</div>
|
|
<div class="line"><a name="l00194"></a><span class="lineno"> 194</span>  {</div>
|
|
<div class="line"><a name="l00195"></a><span class="lineno"> 195</span>  Amounts taker_offer (<a class="code" href="classripple_1_1Taker__test.html#af842fd8b8e50c9d2813fbba65562217e">parse_amounts</a> (</div>
|
|
<div class="line"><a name="l00196"></a><span class="lineno"> 196</span>  offer.in, issue_in,</div>
|
|
<div class="line"><a name="l00197"></a><span class="lineno"> 197</span>  offer.out, issue_out));</div>
|
|
<div class="line"><a name="l00198"></a><span class="lineno"> 198</span>  </div>
|
|
<div class="line"><a name="l00199"></a><span class="lineno"> 199</span>  Amounts cross_offer (<a class="code" href="classripple_1_1Taker__test.html#af842fd8b8e50c9d2813fbba65562217e">parse_amounts</a> (</div>
|
|
<div class="line"><a name="l00200"></a><span class="lineno"> 200</span>  cross.<a class="code" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#a67008047e2492e25db392e8fb8be1dae">in</a>, issue_in,</div>
|
|
<div class="line"><a name="l00201"></a><span class="lineno"> 201</span>  cross.<a class="code" href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#aaacd92d602ca639656ba7c0e1a1f10a5">out</a>, issue_out));</div>
|
|
<div class="line"><a name="l00202"></a><span class="lineno"> 202</span>  </div>
|
|
<div class="line"><a name="l00203"></a><span class="lineno"> 203</span>  <a class="code" href="namespaceripple.html#ae9b6ac4bca5f49e1aa2753e0d9faa2a1">CrossType</a> cross_type;</div>
|
|
<div class="line"><a name="l00204"></a><span class="lineno"> 204</span>  </div>
|
|
<div class="line"><a name="l00205"></a><span class="lineno"> 205</span>  <span class="keywordflow">if</span> (<a class="code" href="namespaceripple.html#a20d30277b9c78756b3d14493055a307c">isXRP</a> (issue_out))</div>
|
|
<div class="line"><a name="l00206"></a><span class="lineno"> 206</span>  cross_type = <a class="code" href="namespaceripple.html#ae9b6ac4bca5f49e1aa2753e0d9faa2a1accb98a576f83dae3d3c01ecffcb2e38e">CrossType::IouToXrp</a>;</div>
|
|
<div class="line"><a name="l00207"></a><span class="lineno"> 207</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="namespaceripple.html#a20d30277b9c78756b3d14493055a307c">isXRP</a> (issue_in))</div>
|
|
<div class="line"><a name="l00208"></a><span class="lineno"> 208</span>  cross_type = <a class="code" href="namespaceripple.html#ae9b6ac4bca5f49e1aa2753e0d9faa2a1a5453323c4d02a5c6a6ec19cbcdfb70e5">CrossType::XrpToIou</a>;</div>
|
|
<div class="line"><a name="l00209"></a><span class="lineno"> 209</span>  <span class="keywordflow">else</span></div>
|
|
<div class="line"><a name="l00210"></a><span class="lineno"> 210</span>  cross_type = <a class="code" href="namespaceripple.html#ae9b6ac4bca5f49e1aa2753e0d9faa2a1aa1208156363280ec3589296c38553e82">CrossType::IouToIou</a>;</div>
|
|
<div class="line"><a name="l00211"></a><span class="lineno"> 211</span>  </div>
|
|
<div class="line"><a name="l00212"></a><span class="lineno"> 212</span>  <span class="comment">// FIXME: We are always invoking the IOU-to-IOU taker. We should select</span></div>
|
|
<div class="line"><a name="l00213"></a><span class="lineno"> 213</span>  <span class="comment">// the correct type dynamically.</span></div>
|
|
<div class="line"><a name="l00214"></a><span class="lineno"> 214</span>  <a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html">TestTaker</a> taker (cross_type, taker_offer, taker_quality,</div>
|
|
<div class="line"><a name="l00215"></a><span class="lineno"> 215</span>  <a class="code" href="classripple_1_1Taker__test.html#a8c5681e544ba369b1d8d8a7fa8308326">parse_amount</a> (funds, issue_in), sell ? <a class="code" href="namespaceripple.html#adafd11da2168f16934fcf2764864cc86">tfSell</a> : 0,</div>
|
|
<div class="line"><a name="l00216"></a><span class="lineno"> 216</span>  rate_in, rate_out);</div>
|
|
<div class="line"><a name="l00217"></a><span class="lineno"> 217</span>  </div>
|
|
<div class="line"><a name="l00218"></a><span class="lineno"> 218</span>  taker.<a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#a443d4b07451efd27f2c2233f0cb563e4">set_funds</a> (<a class="code" href="classripple_1_1Taker__test.html#a8c5681e544ba369b1d8d8a7fa8308326">parse_amount</a> (cross_funds, issue_out));</div>
|
|
<div class="line"><a name="l00219"></a><span class="lineno"> 219</span>  </div>
|
|
<div class="line"><a name="l00220"></a><span class="lineno"> 220</span>  <span class="keyword">auto</span> result = taker.<a class="code" href="classripple_1_1Taker__test_1_1TestTaker.html#a5cc0c788e59c9af26cbb3993a583441a">cross</a> (cross_offer, cross_quality);</div>
|
|
<div class="line"><a name="l00221"></a><span class="lineno"> 221</span>  </div>
|
|
<div class="line"><a name="l00222"></a><span class="lineno"> 222</span>  Amounts <span class="keyword">const</span> expected (<a class="code" href="classripple_1_1Taker__test.html#af842fd8b8e50c9d2813fbba65562217e">parse_amounts</a> (</div>
|
|
<div class="line"><a name="l00223"></a><span class="lineno"> 223</span>  <a class="code" href="namespaceripple.html#aea839338eb91258b10d5d14262ef079f">flow</a>.in, issue_in,</div>
|
|
<div class="line"><a name="l00224"></a><span class="lineno"> 224</span>  <a class="code" href="namespaceripple.html#aea839338eb91258b10d5d14262ef079f">flow</a>.out, issue_out));</div>
|
|
<div class="line"><a name="l00225"></a><span class="lineno"> 225</span>  </div>
|
|
<div class="line"><a name="l00226"></a><span class="lineno"> 226</span>  BEAST_EXPECT(expected == result);</div>
|
|
<div class="line"><a name="l00227"></a><span class="lineno"> 227</span>  </div>
|
|
<div class="line"><a name="l00228"></a><span class="lineno"> 228</span>  <span class="keywordflow">if</span> (expected != result)</div>
|
|
<div class="line"><a name="l00229"></a><span class="lineno"> 229</span>  {</div>
|
|
<div class="line"><a name="l00230"></a><span class="lineno"> 230</span>  log <<</div>
|
|
<div class="line"><a name="l00231"></a><span class="lineno"> 231</span>  <span class="stringliteral">"Expected: "</span> << <a class="code" href="classripple_1_1Taker__test.html#a9863d3d1412138fc834ff640230821ed">format_amount</a> (expected.in) <<</div>
|
|
<div class="line"><a name="l00232"></a><span class="lineno"> 232</span>  <span class="stringliteral">" : "</span> << <a class="code" href="classripple_1_1Taker__test.html#a9863d3d1412138fc834ff640230821ed">format_amount</a> (expected.out) << <span class="charliteral">'\n'</span> <<</div>
|
|
<div class="line"><a name="l00233"></a><span class="lineno"> 233</span>  <span class="stringliteral">" Actual: "</span> << <a class="code" href="classripple_1_1Taker__test.html#a9863d3d1412138fc834ff640230821ed">format_amount</a> (result.in) <<</div>
|
|
<div class="line"><a name="l00234"></a><span class="lineno"> 234</span>  <span class="stringliteral">" : "</span> << <a class="code" href="classripple_1_1Taker__test.html#a9863d3d1412138fc834ff640230821ed">format_amount</a> (result.out) << <a class="codeRef" href="http://en.cppreference.com/w/cpp/io/manip/endl.html">std::endl</a>;</div>
|
|
<div class="line"><a name="l00235"></a><span class="lineno"> 235</span>  }</div>
|
|
<div class="line"><a name="l00236"></a><span class="lineno"> 236</span>  }</div>
|
|
<div class="line"><a name="l00237"></a><span class="lineno"> 237</span>  </div>
|
|
<div class="line"><a name="l00238"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#a287bc7b339994c63a94da2d019b4babb"> 238</a></span>  Quality <a class="code" href="classripple_1_1Taker__test.html#a287bc7b339994c63a94da2d019b4babb">get_quality</a>(<a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> in, <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> out)</div>
|
|
<div class="line"><a name="l00239"></a><span class="lineno"> 239</span>  {</div>
|
|
<div class="line"><a name="l00240"></a><span class="lineno"> 240</span>  <span class="keywordflow">return</span> Quality (<a class="code" href="classripple_1_1Taker__test.html#af842fd8b8e50c9d2813fbba65562217e">parse_amounts</a> (<a class="code" href="namespaceripple.html#a7cc64e12723fbc9606d85442a2569feda13b5bfe96f3e2fe411c9f66f4a582adf">in</a>, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="namespaceripple.html#a7cc64e12723fbc9606d85442a2569fedac68271a63ddbc431c307beb7d2918275">out</a>, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a> ()));</div>
|
|
<div class="line"><a name="l00241"></a><span class="lineno"> 241</span>  }</div>
|
|
<div class="line"><a name="l00242"></a><span class="lineno"> 242</span>  </div>
|
|
<div class="line"><a name="l00243"></a><span class="lineno"> 243</span> <span class="keyword">public</span>:</div>
|
|
<div class="line"><a name="l00244"></a><span class="lineno"> 244</span>  <span class="comment">// Notation for clamp scenario descriptions:</span></div>
|
|
<div class="line"><a name="l00245"></a><span class="lineno"> 245</span>  <span class="comment">//</span></div>
|
|
<div class="line"><a name="l00246"></a><span class="lineno"> 246</span>  <span class="comment">// IN:OUT (with the last in the list being limiting factor)</span></div>
|
|
<div class="line"><a name="l00247"></a><span class="lineno"> 247</span>  <span class="comment">// N = Nothing</span></div>
|
|
<div class="line"><a name="l00248"></a><span class="lineno"> 248</span>  <span class="comment">// T = Taker Offer Balance</span></div>
|
|
<div class="line"><a name="l00249"></a><span class="lineno"> 249</span>  <span class="comment">// A = Taker Account Balance</span></div>
|
|
<div class="line"><a name="l00250"></a><span class="lineno"> 250</span>  <span class="comment">// B = Owner Account Balance</span></div>
|
|
<div class="line"><a name="l00251"></a><span class="lineno"> 251</span>  <span class="comment">//</span></div>
|
|
<div class="line"><a name="l00252"></a><span class="lineno"> 252</span>  <span class="comment">// (s) = sell semantics: taker wants unlimited output</span></div>
|
|
<div class="line"><a name="l00253"></a><span class="lineno"> 253</span>  <span class="comment">// (b) = buy semantics: taker wants a limited amount out</span></div>
|
|
<div class="line"><a name="l00254"></a><span class="lineno"> 254</span>  </div>
|
|
<div class="line"><a name="l00255"></a><span class="lineno"> 255</span>  <span class="comment">// NIKB TODO: Augment TestTaker so currencies and rates can be specified</span></div>
|
|
<div class="line"><a name="l00256"></a><span class="lineno"> 256</span>  <span class="comment">// once without need for repetition.</span></div>
|
|
<div class="line"><a name="l00257"></a><span class="lineno"> 257</span>  <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00258"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#a35005bcf7245566cacdd23390c707f2b"> 258</a></span>  <a class="code" href="classripple_1_1Taker__test.html#a35005bcf7245566cacdd23390c707f2b">test_xrp_to_iou</a> ()</div>
|
|
<div class="line"><a name="l00259"></a><span class="lineno"> 259</span>  {</div>
|
|
<div class="line"><a name="l00260"></a><span class="lineno"> 260</span>  testcase (<span class="stringliteral">"XRP Quantization: input"</span>);</div>
|
|
<div class="line"><a name="l00261"></a><span class="lineno"> 261</span>  </div>
|
|
<div class="line"><a name="l00262"></a><span class="lineno"> 262</span>  Quality q1 = <a class="code" href="classripple_1_1Taker__test.html#a287bc7b339994c63a94da2d019b4babb">get_quality</a> (<span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span>);</div>
|
|
<div class="line"><a name="l00263"></a><span class="lineno"> 263</span>  </div>
|
|
<div class="line"><a name="l00264"></a><span class="lineno"> 264</span>  <span class="comment">// TAKER OWNER</span></div>
|
|
<div class="line"><a name="l00265"></a><span class="lineno"> 265</span>  <span class="comment">// QUAL OFFER FUNDS QUAL OFFER FUNDS EXPECTED</span></div>
|
|
<div class="line"><a name="l00266"></a><span class="lineno"> 266</span>  <span class="comment">// XRP USD</span></div>
|
|
<div class="line"><a name="l00267"></a><span class="lineno"> 267</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"N:N"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00268"></a><span class="lineno"> 268</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"N:B"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.8"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1.8"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00269"></a><span class="lineno"> 269</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"N:T"</span>, q1, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00270"></a><span class="lineno"> 270</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"N:BT"</span>, q1, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.8"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00271"></a><span class="lineno"> 271</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"N:TB"</span>, q1, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"0.8"</span>, { <span class="stringliteral">"0"</span>, <span class="stringliteral">"0.8"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00272"></a><span class="lineno"> 272</span>  </div>
|
|
<div class="line"><a name="l00273"></a><span class="lineno"> 273</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"T:N"</span>, q1, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00274"></a><span class="lineno"> 274</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"T:B"</span>, q1, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.8"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1.8"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00275"></a><span class="lineno"> 275</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"T:T"</span>, q1, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00276"></a><span class="lineno"> 276</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"T:BT"</span>, q1, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.8"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00277"></a><span class="lineno"> 277</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"T:TB"</span>, q1, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"0.8"</span>, { <span class="stringliteral">"0"</span>, <span class="stringliteral">"0.8"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00278"></a><span class="lineno"> 278</span>  </div>
|
|
<div class="line"><a name="l00279"></a><span class="lineno"> 279</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"A:N"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00280"></a><span class="lineno"> 280</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"A:B"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.8"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1.8"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00281"></a><span class="lineno"> 281</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"A:T"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"3"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00282"></a><span class="lineno"> 282</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"A:BT"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"2.4"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00283"></a><span class="lineno"> 283</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"A:TB"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"0.8"</span>, { <span class="stringliteral">"0"</span>, <span class="stringliteral">"0.8"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00284"></a><span class="lineno"> 284</span>  </div>
|
|
<div class="line"><a name="l00285"></a><span class="lineno"> 285</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"TA:N"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00286"></a><span class="lineno"> 286</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"TA:B"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"1.8"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1.8"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00287"></a><span class="lineno"> 287</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"TA:T"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"3"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00288"></a><span class="lineno"> 288</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"TA:BT"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"1.8"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1.8"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00289"></a><span class="lineno"> 289</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"TA:TB"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"1.8"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1.8"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00290"></a><span class="lineno"> 290</span>  </div>
|
|
<div class="line"><a name="l00291"></a><span class="lineno"> 291</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"AT:N"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"3"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00292"></a><span class="lineno"> 292</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"AT:B"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"1.8"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1.8"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00293"></a><span class="lineno"> 293</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"AT:T"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"3"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00294"></a><span class="lineno"> 294</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"AT:BT"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"1.8"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1.8"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00295"></a><span class="lineno"> 295</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"AT:TB"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"0.8"</span>, { <span class="stringliteral">"0"</span>, <span class="stringliteral">"0.8"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>());</div>
|
|
<div class="line"><a name="l00296"></a><span class="lineno"> 296</span>  }</div>
|
|
<div class="line"><a name="l00297"></a><span class="lineno"> 297</span>  </div>
|
|
<div class="line"><a name="l00298"></a><span class="lineno"> 298</span>  <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00299"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#ad619cc495a5e51141abfe217c4feeb1a"> 299</a></span>  <a class="code" href="classripple_1_1Taker__test.html#ad619cc495a5e51141abfe217c4feeb1a">test_iou_to_xrp</a> ()</div>
|
|
<div class="line"><a name="l00300"></a><span class="lineno"> 300</span>  {</div>
|
|
<div class="line"><a name="l00301"></a><span class="lineno"> 301</span>  testcase (<span class="stringliteral">"XRP Quantization: output"</span>);</div>
|
|
<div class="line"><a name="l00302"></a><span class="lineno"> 302</span>  </div>
|
|
<div class="line"><a name="l00303"></a><span class="lineno"> 303</span>  Quality q1 = <a class="code" href="classripple_1_1Taker__test.html#a287bc7b339994c63a94da2d019b4babb">get_quality</a> (<span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span>);</div>
|
|
<div class="line"><a name="l00304"></a><span class="lineno"> 304</span>  </div>
|
|
<div class="line"><a name="l00305"></a><span class="lineno"> 305</span>  <span class="comment">// TAKER OWNER</span></div>
|
|
<div class="line"><a name="l00306"></a><span class="lineno"> 306</span>  <span class="comment">// QUAL OFFER FUNDS QUAL OFFER FUNDS EXPECTED</span></div>
|
|
<div class="line"><a name="l00307"></a><span class="lineno"> 307</span>  <span class="comment">// USD XRP</span></div>
|
|
<div class="line"><a name="l00308"></a><span class="lineno"> 308</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"N:N"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"3"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"3"</span>, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00309"></a><span class="lineno"> 309</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"N:B"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"3"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00310"></a><span class="lineno"> 310</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"N:T"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"2.5"</span>, q1, { <span class="stringliteral">"5"</span>, <span class="stringliteral">"5"</span> }, <span class="stringliteral">"5"</span>, { <span class="stringliteral">"2.5"</span>, <span class="stringliteral">"2"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00311"></a><span class="lineno"> 311</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"N:BT"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"1.5"</span>, q1, { <span class="stringliteral">"5"</span>, <span class="stringliteral">"5"</span> }, <span class="stringliteral">"4"</span>, { <span class="stringliteral">"1.5"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00312"></a><span class="lineno"> 312</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"N:TB"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"2.2"</span>, q1, { <span class="stringliteral">"5"</span>, <span class="stringliteral">"5"</span> }, <span class="stringliteral">"1"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00313"></a><span class="lineno"> 313</span>  </div>
|
|
<div class="line"><a name="l00314"></a><span class="lineno"> 314</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"T:N"</span>, q1, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00315"></a><span class="lineno"> 315</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"T:B"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"1"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00316"></a><span class="lineno"> 316</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"T:T"</span>, q1, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00317"></a><span class="lineno"> 317</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"T:BT"</span>, q1, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00318"></a><span class="lineno"> 318</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"T:TB"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"1"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00319"></a><span class="lineno"> 319</span>  </div>
|
|
<div class="line"><a name="l00320"></a><span class="lineno"> 320</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"A:N"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.5"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"1.5"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00321"></a><span class="lineno"> 321</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"A:B"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.8"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"1.8"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00322"></a><span class="lineno"> 322</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"A:T"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.2"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"3"</span>, { <span class="stringliteral">"1.2"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00323"></a><span class="lineno"> 323</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"A:BT"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.5"</span>, q1, { <span class="stringliteral">"4"</span>, <span class="stringliteral">"4"</span> }, <span class="stringliteral">"3"</span>, { <span class="stringliteral">"1.5"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00324"></a><span class="lineno"> 324</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"A:TB"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.5"</span>, q1, { <span class="stringliteral">"4"</span>, <span class="stringliteral">"4"</span> }, <span class="stringliteral">"1"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00325"></a><span class="lineno"> 325</span>  </div>
|
|
<div class="line"><a name="l00326"></a><span class="lineno"> 326</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"TA:N"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.5"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, { <span class="stringliteral">"1.5"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00327"></a><span class="lineno"> 327</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"TA:B"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.5"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"1"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00328"></a><span class="lineno"> 328</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"TA:T"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.5"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"3"</span>, { <span class="stringliteral">"1.5"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00329"></a><span class="lineno"> 329</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"TA:BT"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.8"</span>, q1, { <span class="stringliteral">"4"</span>, <span class="stringliteral">"4"</span> }, <span class="stringliteral">"3"</span>, { <span class="stringliteral">"1.8"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00330"></a><span class="lineno"> 330</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"TA:TB"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"1.2"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"1"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00331"></a><span class="lineno"> 331</span>  </div>
|
|
<div class="line"><a name="l00332"></a><span class="lineno"> 332</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"AT:N"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2.5"</span>, q1, { <span class="stringliteral">"4"</span>, <span class="stringliteral">"4"</span> }, <span class="stringliteral">"4"</span>, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00333"></a><span class="lineno"> 333</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"AT:B"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2.5"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"1"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00334"></a><span class="lineno"> 334</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"AT:T"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2.5"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"3"</span>, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00335"></a><span class="lineno"> 335</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"AT:BT"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2.5"</span>, q1, { <span class="stringliteral">"4"</span>, <span class="stringliteral">"4"</span> }, <span class="stringliteral">"3"</span>, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00336"></a><span class="lineno"> 336</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"AT:TB"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2.5"</span>, q1, { <span class="stringliteral">"3"</span>, <span class="stringliteral">"3"</span> }, <span class="stringliteral">"1"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), <a class="code" href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">xrp</a>());</div>
|
|
<div class="line"><a name="l00337"></a><span class="lineno"> 337</span>  }</div>
|
|
<div class="line"><a name="l00338"></a><span class="lineno"> 338</span>  </div>
|
|
<div class="line"><a name="l00339"></a><span class="lineno"> 339</span>  <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00340"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#a4f70f52e77d5a64a24c3ede6465eb051"> 340</a></span>  <a class="code" href="classripple_1_1Taker__test.html#a4f70f52e77d5a64a24c3ede6465eb051">test_iou_to_iou</a> ()</div>
|
|
<div class="line"><a name="l00341"></a><span class="lineno"> 341</span>  {</div>
|
|
<div class="line"><a name="l00342"></a><span class="lineno"> 342</span>  testcase (<span class="stringliteral">"IOU to IOU"</span>);</div>
|
|
<div class="line"><a name="l00343"></a><span class="lineno"> 343</span>  </div>
|
|
<div class="line"><a name="l00344"></a><span class="lineno"> 344</span>  Quality q1 = <a class="code" href="classripple_1_1Taker__test.html#a287bc7b339994c63a94da2d019b4babb">get_quality</a> (<span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span>);</div>
|
|
<div class="line"><a name="l00345"></a><span class="lineno"> 345</span>  </div>
|
|
<div class="line"><a name="l00346"></a><span class="lineno"> 346</span>  <span class="comment">// Highly exaggerated 50% transfer rate for the input and output:</span></div>
|
|
<div class="line"><a name="l00347"></a><span class="lineno"> 347</span>  <a class="code" href="structripple_1_1Rate.html">Rate</a> <span class="keyword">const</span> rate { <a class="code" href="namespaceripple.html#a8ca9b43bfc508a3fdbc296fb926320ce">parityRate</a>.<a class="code" href="structripple_1_1Rate.html#a59fd441d04e641347e6dc62c2301f671">value</a> + (<a class="code" href="namespaceripple.html#a8ca9b43bfc508a3fdbc296fb926320ce">parityRate</a>.<a class="code" href="structripple_1_1Rate.html#a59fd441d04e641347e6dc62c2301f671">value</a> / 2) };</div>
|
|
<div class="line"><a name="l00348"></a><span class="lineno"> 348</span>  </div>
|
|
<div class="line"><a name="l00349"></a><span class="lineno"> 349</span>  <span class="comment">// TAKER OWNER</span></div>
|
|
<div class="line"><a name="l00350"></a><span class="lineno"> 350</span>  <span class="comment">// QUAL OFFER FUNDS QUAL OFFER FUNDS EXPECTED</span></div>
|
|
<div class="line"><a name="l00351"></a><span class="lineno"> 351</span>  <span class="comment">// EUR USD</span></div>
|
|
<div class="line"><a name="l00352"></a><span class="lineno"> 352</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"N:N"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"10"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"10"</span>, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a12e2c1d08d76040a624e3cf2f92bbe51">eur</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), rate, rate);</div>
|
|
<div class="line"><a name="l00353"></a><span class="lineno"> 353</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"N:B"</span>, q1, { <span class="stringliteral">"4"</span>, <span class="stringliteral">"4"</span> }, <span class="stringliteral">"10"</span>, q1, { <span class="stringliteral">"4"</span>, <span class="stringliteral">"4"</span> }, <span class="stringliteral">"4"</span>, { <span class="stringliteral">"2.666666666666666"</span>, <span class="stringliteral">"2.666666666666666"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a12e2c1d08d76040a624e3cf2f92bbe51">eur</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), rate, rate);</div>
|
|
<div class="line"><a name="l00354"></a><span class="lineno"> 354</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"N:T"</span>, q1, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <span class="stringliteral">"10"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"10"</span>, { <span class="stringliteral">"1"</span>, <span class="stringliteral">"1"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a12e2c1d08d76040a624e3cf2f92bbe51">eur</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), rate, rate);</div>
|
|
<div class="line"><a name="l00355"></a><span class="lineno"> 355</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"N:BT"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"10"</span>, q1, { <span class="stringliteral">"6"</span>, <span class="stringliteral">"6"</span> }, <span class="stringliteral">"5"</span>, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a12e2c1d08d76040a624e3cf2f92bbe51">eur</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), rate, rate);</div>
|
|
<div class="line"><a name="l00356"></a><span class="lineno"> 356</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">Buy</a>, <span class="stringliteral">"N:TB"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2"</span>, q1, { <span class="stringliteral">"6"</span>, <span class="stringliteral">"6"</span> }, <span class="stringliteral">"1"</span>, { <span class="stringliteral">"0.6666666666666667"</span>, <span class="stringliteral">"0.6666666666666667"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a12e2c1d08d76040a624e3cf2f92bbe51">eur</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), rate, rate);</div>
|
|
<div class="line"><a name="l00357"></a><span class="lineno"> 357</span>  <a class="code" href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">attempt</a> (<a class="code" href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">Sell</a>, <span class="stringliteral">"A:N"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"2.5"</span>, q1, { <span class="stringliteral">"2"</span>, <span class="stringliteral">"2"</span> }, <span class="stringliteral">"10"</span>, { <span class="stringliteral">"1.666666666666666"</span>, <span class="stringliteral">"1.666666666666666"</span> }, <a class="code" href="classripple_1_1Taker__test.html#a12e2c1d08d76040a624e3cf2f92bbe51">eur</a>(), <a class="code" href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">usd</a>(), rate, rate);</div>
|
|
<div class="line"><a name="l00358"></a><span class="lineno"> 358</span>  }</div>
|
|
<div class="line"><a name="l00359"></a><span class="lineno"> 359</span>  </div>
|
|
<div class="line"><a name="l00360"></a><span class="lineno"> 360</span>  <span class="keywordtype">void</span></div>
|
|
<div class="line"><a name="l00361"></a><span class="lineno"><a class="line" href="classripple_1_1Taker__test.html#a07a2e3a550f8ebbea4361276081e7b41"> 361</a></span>  <a class="code" href="classripple_1_1Taker__test.html#a07a2e3a550f8ebbea4361276081e7b41">run</a>()<span class="keyword"> override</span></div>
|
|
<div class="line"><a name="l00362"></a><span class="lineno"> 362</span> <span class="keyword"> </span>{</div>
|
|
<div class="line"><a name="l00363"></a><span class="lineno"> 363</span>  <a class="code" href="classripple_1_1Taker__test.html#a35005bcf7245566cacdd23390c707f2b">test_xrp_to_iou</a> ();</div>
|
|
<div class="line"><a name="l00364"></a><span class="lineno"> 364</span>  <a class="code" href="classripple_1_1Taker__test.html#ad619cc495a5e51141abfe217c4feeb1a">test_iou_to_xrp</a> ();</div>
|
|
<div class="line"><a name="l00365"></a><span class="lineno"> 365</span>  <a class="code" href="classripple_1_1Taker__test.html#a4f70f52e77d5a64a24c3ede6465eb051">test_iou_to_iou</a> ();</div>
|
|
<div class="line"><a name="l00366"></a><span class="lineno"> 366</span>  }</div>
|
|
<div class="line"><a name="l00367"></a><span class="lineno"> 367</span> };</div>
|
|
<div class="line"><a name="l00368"></a><span class="lineno"> 368</span>  </div>
|
|
<div class="line"><a name="l00369"></a><span class="lineno"> 369</span> <a class="code" href="namespaceripple.html#a2701412a11b118c19256a4c901db2938">BEAST_DEFINE_TESTSUITE</a>(Taker,tx,<a class="code" href="namespaceripple.html">ripple</a>);</div>
|
|
<div class="line"><a name="l00370"></a><span class="lineno"> 370</span>  </div>
|
|
<div class="line"><a name="l00371"></a><span class="lineno"> 371</span> }</div>
|
|
</div><!-- fragment --></div><!-- contents -->
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_1_1TestTaker_html_a443d4b07451efd27f2c2233f0cb563e4"><div class="ttname"><a href="classripple_1_1Taker__test_1_1TestTaker.html#a443d4b07451efd27f2c2233f0cb563e4">ripple::Taker_test::TestTaker::set_funds</a></div><div class="ttdeci">void set_funds(STAmount const &funds)</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00060">Taker_test.cpp:60</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Issue_html"><div class="ttname"><a href="classripple_1_1Issue.html">ripple::Issue</a></div><div class="ttdoc">A currency issued by an account.</div><div class="ttdef"><b>Definition:</b> <a href="Issue_8h_source.html#l00034">Issue.h:34</a></div></div>
|
|
<div class="ttc" id="abasic_string_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a></div><div class="ttdoc">STL class.</div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a2701412a11b118c19256a4c901db2938"><div class="ttname"><a href="namespaceripple.html#a2701412a11b118c19256a4c901db2938">ripple::BEAST_DEFINE_TESTSUITE</a></div><div class="ttdeci">BEAST_DEFINE_TESTSUITE(AccountTxPaging, app, ripple)</div></div>
|
|
<div class="ttc" id="astructripple_1_1Rate_html"><div class="ttname"><a href="structripple_1_1Rate.html">ripple::Rate</a></div><div class="ttdoc">Represents a transfer rate.</div><div class="ttdef"><b>Definition:</b> <a href="Rate_8h_source.html#l00037">Rate.h:37</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a7c8945b5034bba5f9df719cff2503495"><div class="ttname"><a href="namespaceripple.html#a7c8945b5034bba5f9df719cff2503495">ripple::composed_quality</a></div><div class="ttdeci">Quality composed_quality(Quality const &lhs, Quality const &rhs)</div><div class="ttdef"><b>Definition:</b> <a href="Quality_8cpp_source.html#l00103">Quality.cpp:103</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_a10f3b77cfc0433eba45414563a099c01"><div class="ttname"><a href="classripple_1_1Taker__test.html#a10f3b77cfc0433eba45414563a099c01">ripple::Taker_test::xrp</a></div><div class="ttdeci">Issue const & xrp() const</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00134">Taker_test.cpp:134</a></div></div>
|
|
<div class="ttc" id="apair_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/utility/pair.html">std::pair</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_ac66b6d3f0b628da3fe309adf1020d4ea"><div class="ttname"><a href="classripple_1_1Taker__test.html#ac66b6d3f0b628da3fe309adf1020d4ea">ripple::Taker_test::attempt</a></div><div class="ttdeci">void attempt(bool sell, std::string name, Quality taker_quality, cross_attempt_offer const offer, std::string const funds, Quality cross_quality, cross_attempt_offer const cross, std::string const cross_funds, cross_attempt_offer const flow, Issue const &issue_in, Issue const &issue_out, Rate rate_in=parityRate, Rate rate_out=parityRate)</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00180">Taker_test.cpp:180</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_ae30c855544c0855851273e9fefd50cd7"><div class="ttname"><a href="classripple_1_1Taker__test.html#ae30c855544c0855851273e9fefd50cd7">ripple::Taker_test::Sell</a></div><div class="ttdeci">static const bool Sell</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00030">Taker_test.cpp:30</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1BasicTaker_html_ae67e802167cb58a7701345924fefe4ff"><div class="ttname"><a href="classripple_1_1BasicTaker.html#ae67e802167cb58a7701345924fefe4ff">ripple::BasicTaker::do_cross</a></div><div class="ttdeci">BasicTaker::Flow do_cross(Amounts offer, Quality quality, AccountID const &owner)</div><div class="ttdoc">Perform direct crossing through given offer.</div><div class="ttdef"><b>Definition:</b> <a href="Taker_8cpp_source.html#l00372">Taker.cpp:372</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_1_1TestTaker_html_ac903b7f1ea6fb73138e1ea548bec5dcd"><div class="ttname"><a href="classripple_1_1Taker__test_1_1TestTaker.html#ac903b7f1ea6fb73138e1ea548bec5dcd">ripple::Taker_test::TestTaker::funds_</a></div><div class="ttdeci">STAmount funds_</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00035">Taker_test.cpp:35</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1BasicTaker_html_a767e75e4d5d6181a3419d0df1b1bebc9"><div class="ttname"><a href="classripple_1_1BasicTaker.html#a767e75e4d5d6181a3419d0df1b1bebc9">ripple::BasicTaker::reject</a></div><div class="ttdeci">bool reject(Quality const &quality) const noexcept</div><div class="ttdoc">Returns true if the quality does not meet the taker's requirements.</div><div class="ttdef"><b>Definition:</b> <a href="Taker_8h_source.html#l00169">Taker.h:169</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1STAmount_html_aa65826cb148b5d15412fceecca5ae47c"><div class="ttname"><a href="classripple_1_1STAmount.html#aa65826cb148b5d15412fceecca5ae47c">ripple::STAmount::getText</a></div><div class="ttdeci">std::string getText() const override</div><div class="ttdef"><b>Definition:</b> <a href="STAmount_8cpp_source.html#l00492">STAmount.cpp:492</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_ae9b6ac4bca5f49e1aa2753e0d9faa2a1a5453323c4d02a5c6a6ec19cbcdfb70e5"><div class="ttname"><a href="namespaceripple.html#ae9b6ac4bca5f49e1aa2753e0d9faa2a1a5453323c4d02a5c6a6ec19cbcdfb70e5">ripple::CrossType::XrpToIou</a></div><div class="ttdeci">@ XrpToIou</div></div>
|
|
<div class="ttc" id="aclassripple_1_1Issue_html_a4b723aa4198e4c630e41de06586e2fe7"><div class="ttname"><a href="classripple_1_1Issue.html#a4b723aa4198e4c630e41de06586e2fe7">ripple::Issue::currency</a></div><div class="ttdeci">Currency currency</div><div class="ttdef"><b>Definition:</b> <a href="Issue_8h_source.html#l00037">Issue.h:37</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_ae9b6ac4bca5f49e1aa2753e0d9faa2a1accb98a576f83dae3d3c01ecffcb2e38e"><div class="ttname"><a href="namespaceripple.html#ae9b6ac4bca5f49e1aa2753e0d9faa2a1accb98a576f83dae3d3c01ecffcb2e38e">ripple::CrossType::IouToXrp</a></div><div class="ttdeci">@ IouToXrp</div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a7cc64e12723fbc9606d85442a2569feda13b5bfe96f3e2fe411c9f66f4a582adf"><div class="ttname"><a href="namespaceripple.html#a7cc64e12723fbc9606d85442a2569feda13b5bfe96f3e2fe411c9f66f4a582adf">ripple::QualityDirection::in</a></div><div class="ttdeci">@ in</div></div>
|
|
<div class="ttc" id="aclassripple_1_1BasicTaker_html"><div class="ttname"><a href="classripple_1_1BasicTaker.html">ripple::BasicTaker</a></div><div class="ttdoc">State for the active party during order book or payment operations.</div><div class="ttdef"><b>Definition:</b> <a href="Taker_8h_source.html#l00044">Taker.h:44</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html"><div class="ttname"><a href="classripple_1_1Taker__test.html">ripple::Taker_test</a></div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00027">Taker_test.cpp:27</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_a12e2c1d08d76040a624e3cf2f92bbe51"><div class="ttname"><a href="classripple_1_1Taker__test.html#a12e2c1d08d76040a624e3cf2f92bbe51">ripple::Taker_test::eur</a></div><div class="ttdeci">Issue const & eur() const</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00127">Taker_test.cpp:127</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a96888695e8d79474e080c334f149e30a"><div class="ttname"><a href="namespaceripple.html#a96888695e8d79474e080c334f149e30a">ripple::to_string</a></div><div class="ttdeci">std::string to_string(ListDisposition disposition)</div><div class="ttdef"><b>Definition:</b> <a href="ValidatorList_8cpp_source.html#l00041">ValidatorList.cpp:41</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_1_1TestTaker_html_a5cc0c788e59c9af26cbb3993a583441a"><div class="ttname"><a href="classripple_1_1Taker__test_1_1TestTaker.html#a5cc0c788e59c9af26cbb3993a583441a">ripple::Taker_test::TestTaker::cross</a></div><div class="ttdeci">Amounts cross(Amounts offer, Quality quality)</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00075">Taker_test.cpp:75</a></div></div>
|
|
<div class="ttc" id="astructripple_1_1Taker__test_1_1cross__attempt__offer_html_aaacd92d602ca639656ba7c0e1a1f10a5"><div class="ttname"><a href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#aaacd92d602ca639656ba7c0e1a1f10a5">ripple::Taker_test::cross_attempt_offer::out</a></div><div class="ttdeci">std::string out</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00166">Taker_test.cpp:166</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1BasicTaker_html_a6dd41ec89debfd1a7f86305e1a752272"><div class="ttname"><a href="classripple_1_1BasicTaker.html#a6dd41ec89debfd1a7f86305e1a752272">ripple::BasicTaker::cross_type</a></div><div class="ttdeci">CrossType cross_type() const</div><div class="ttdoc">Returns the type of crossing that is being performed.</div><div class="ttdef"><b>Definition:</b> <a href="Taker_8h_source.html#l00176">Taker.h:176</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a8ca9b43bfc508a3fdbc296fb926320ce"><div class="ttname"><a href="namespaceripple.html#a8ca9b43bfc508a3fdbc296fb926320ce">ripple::parityRate</a></div><div class="ttdeci">const Rate parityRate(QUALITY_ONE)</div><div class="ttdoc">A transfer rate signifying a 1:1 exchange.</div><div class="ttdef"><b>Definition:</b> <a href="Rate_8h_source.html#l00110">Rate.h:110</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_af842fd8b8e50c9d2813fbba65562217e"><div class="ttname"><a href="classripple_1_1Taker__test.html#af842fd8b8e50c9d2813fbba65562217e">ripple::Taker_test::parse_amounts</a></div><div class="ttdeci">Amounts parse_amounts(std::string const &amount_in, Issue const &issue_in, std::string const &amount_out, Issue const &issue_out)</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00146">Taker_test.cpp:146</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_a9863d3d1412138fc834ff640230821ed"><div class="ttname"><a href="classripple_1_1Taker__test.html#a9863d3d1412138fc834ff640230821ed">ripple::Taker_test::format_amount</a></div><div class="ttdeci">std::string format_amount(STAmount const &amount)</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00171">Taker_test.cpp:171</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_1_1TestTaker_html"><div class="ttname"><a href="classripple_1_1Taker__test_1_1TestTaker.html">ripple::Taker_test::TestTaker</a></div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00032">Taker_test.cpp:32</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1base__uint_html"><div class="ttname"><a href="classripple_1_1base__uint.html">ripple::base_uint< 160, detail::AccountIDTag ></a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_ae9b6ac4bca5f49e1aa2753e0d9faa2a1"><div class="ttname"><a href="namespaceripple.html#ae9b6ac4bca5f49e1aa2753e0d9faa2a1">ripple::CrossType</a></div><div class="ttdeci">CrossType</div><div class="ttdoc">The flavor of an offer crossing.</div><div class="ttdef"><b>Definition:</b> <a href="Taker_8h_source.html#l00036">Taker.h:36</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_ae9b6ac4bca5f49e1aa2753e0d9faa2a1aa1208156363280ec3589296c38553e82"><div class="ttname"><a href="namespaceripple.html#ae9b6ac4bca5f49e1aa2753e0d9faa2a1aa1208156363280ec3589296c38553e82">ripple::CrossType::IouToIou</a></div><div class="ttdeci">@ IouToIou</div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a7cc64e12723fbc9606d85442a2569fedac68271a63ddbc431c307beb7d2918275"><div class="ttname"><a href="namespaceripple.html#a7cc64e12723fbc9606d85442a2569fedac68271a63ddbc431c307beb7d2918275">ripple::QualityDirection::out</a></div><div class="ttdeci">@ out</div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_a35005bcf7245566cacdd23390c707f2b"><div class="ttname"><a href="classripple_1_1Taker__test.html#a35005bcf7245566cacdd23390c707f2b">ripple::Taker_test::test_xrp_to_iou</a></div><div class="ttdeci">void test_xrp_to_iou()</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00258">Taker_test.cpp:258</a></div></div>
|
|
<div class="ttc" id="astructripple_1_1Taker__test_1_1cross__attempt__offer_html_a67008047e2492e25db392e8fb8be1dae"><div class="ttname"><a href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#a67008047e2492e25db392e8fb8be1dae">ripple::Taker_test::cross_attempt_offer::in</a></div><div class="ttdeci">std::string in</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00165">Taker_test.cpp:165</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_1_1TestTaker_html_a272da0e03776ed606702808ea4db21ab"><div class="ttname"><a href="classripple_1_1Taker__test_1_1TestTaker.html#a272da0e03776ed606702808ea4db21ab">ripple::Taker_test::TestTaker::get_funds</a></div><div class="ttdeci">STAmount get_funds(AccountID const &owner, STAmount const &funds) const override</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00066">Taker_test.cpp:66</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1STAmount_html"><div class="ttname"><a href="classripple_1_1STAmount.html">ripple::STAmount</a></div><div class="ttdef"><b>Definition:</b> <a href="STAmount_8h_source.html#l00042">STAmount.h:42</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a21696ba0d0fac348f88f1b9da51091b0"><div class="ttname"><a href="namespaceripple.html#a21696ba0d0fac348f88f1b9da51091b0">ripple::xrpAccount</a></div><div class="ttdeci">AccountID const & xrpAccount()</div><div class="ttdoc">Compute AccountID from public key.</div><div class="ttdef"><b>Definition:</b> <a href="AccountID_8cpp_source.html#l00149">AccountID.cpp:149</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a20d30277b9c78756b3d14493055a307c"><div class="ttname"><a href="namespaceripple.html#a20d30277b9c78756b3d14493055a307c">ripple::isXRP</a></div><div class="ttdeci">bool isXRP(AccountID const &c)</div><div class="ttdef"><b>Definition:</b> <a href="AccountID_8h_source.html#l00121">AccountID.h:121</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_a4f70f52e77d5a64a24c3ede6465eb051"><div class="ttname"><a href="classripple_1_1Taker__test.html#a4f70f52e77d5a64a24c3ede6465eb051">ripple::Taker_test::test_iou_to_iou</a></div><div class="ttdeci">void test_iou_to_iou()</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00340">Taker_test.cpp:340</a></div></div>
|
|
<div class="ttc" id="astructripple_1_1Taker__test_1_1cross__attempt__offer_html_af9b07975d33b85eda1af7c9490a04a7c"><div class="ttname"><a href="structripple_1_1Taker__test_1_1cross__attempt__offer.html#af9b07975d33b85eda1af7c9490a04a7c">ripple::Taker_test::cross_attempt_offer::cross_attempt_offer</a></div><div class="ttdeci">cross_attempt_offer(std::string const &in_, std::string const &out_)</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00158">Taker_test.cpp:158</a></div></div>
|
|
<div class="ttc" id="ainteger_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_ad619cc495a5e51141abfe217c4feeb1a"><div class="ttname"><a href="classripple_1_1Taker__test.html#ad619cc495a5e51141abfe217c4feeb1a">ripple::Taker_test::test_iou_to_xrp</a></div><div class="ttdeci">void test_iou_to_xrp()</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00299">Taker_test.cpp:299</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_1_1TestTaker_html_ab4e3b230ec32048830c6c54d2c50334e"><div class="ttname"><a href="classripple_1_1Taker__test_1_1TestTaker.html#ab4e3b230ec32048830c6c54d2c50334e">ripple::Taker_test::TestTaker::TestTaker</a></div><div class="ttdeci">TestTaker(CrossType cross_type, Amounts const &amount, Quality const &quality, STAmount const &funds, std::uint32_t flags, Rate const &rate_in, Rate const &rate_out)</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00039">Taker_test.cpp:39</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_a59f5e388267ec3044c9ae0139a7658ab"><div class="ttname"><a href="classripple_1_1Taker__test.html#a59f5e388267ec3044c9ae0139a7658ab">ripple::Taker_test::usd</a></div><div class="ttdeci">Issue const & usd() const</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00120">Taker_test.cpp:120</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_a8c5681e544ba369b1d8d8a7fa8308326"><div class="ttname"><a href="classripple_1_1Taker__test.html#a8c5681e544ba369b1d8d8a7fa8308326">ripple::Taker_test::parse_amount</a></div><div class="ttdeci">STAmount parse_amount(std::string const &amount, Issue const &issue)</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00141">Taker_test.cpp:141</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1BasicTaker_html_a27d9a56a69cd21c25afe074a095a6995"><div class="ttname"><a href="classripple_1_1BasicTaker.html#a27d9a56a69cd21c25afe074a095a6995">ripple::BasicTaker::done</a></div><div class="ttdeci">bool done() const</div><div class="ttdoc">Returns true if order crossing should not continue.</div><div class="ttdef"><b>Definition:</b> <a href="Taker_8cpp_source.html#l00106">Taker.cpp:106</a></div></div>
|
|
<div class="ttc" id="astructripple_1_1Rate_html_a59fd441d04e641347e6dc62c2301f671"><div class="ttname"><a href="structripple_1_1Rate.html#a59fd441d04e641347e6dc62c2301f671">ripple::Rate::value</a></div><div class="ttdeci">std::uint32_t value</div><div class="ttdef"><b>Definition:</b> <a href="Rate_8h_source.html#l00040">Rate.h:40</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html"><div class="ttname"><a href="namespaceripple.html">ripple</a></div><div class="ttdoc">Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.</div><div class="ttdef"><b>Definition:</b> <a href="RCLCensorshipDetector_8h_source.html#l00029">RCLCensorshipDetector.h:29</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a554a0e32abce925cc434c3a03e584ceb"><div class="ttname"><a href="namespaceripple.html#a554a0e32abce925cc434c3a03e584ceb">ripple::amountFromString</a></div><div class="ttdeci">STAmount amountFromString(Issue const &issue, std::string const &amount)</div><div class="ttdef"><b>Definition:</b> <a href="STAmount_8cpp_source.html#l00741">STAmount.cpp:741</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_adafd11da2168f16934fcf2764864cc86"><div class="ttname"><a href="namespaceripple.html#adafd11da2168f16934fcf2764864cc86">ripple::tfSell</a></div><div class="ttdeci">const std::uint32_t tfSell</div><div class="ttdef"><b>Definition:</b> <a href="TxFlags_8h_source.html#l00079">TxFlags.h:79</a></div></div>
|
|
<div class="ttc" id="aendl_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/io/manip/endl.html">std::endl</a></div><div class="ttdeci">T endl(T... args)</div></div>
|
|
<div class="ttc" id="astructripple_1_1Taker__test_1_1cross__attempt__offer_html"><div class="ttname"><a href="structripple_1_1Taker__test_1_1cross__attempt__offer.html">ripple::Taker_test::cross_attempt_offer</a></div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00156">Taker_test.cpp:156</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1STAmount_html_a60d8449d2915fa495f12994f56ceca34"><div class="ttname"><a href="classripple_1_1STAmount.html#a60d8449d2915fa495f12994f56ceca34">ripple::STAmount::issue</a></div><div class="ttdeci">Issue const & issue() const</div><div class="ttdef"><b>Definition:</b> <a href="STAmount_8h_source.html#l00156">STAmount.h:156</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_a2900acc3b8a7e232614d5c39ca71e301"><div class="ttname"><a href="classripple_1_1Taker__test.html#a2900acc3b8a7e232614d5c39ca71e301">ripple::Taker_test::Buy</a></div><div class="ttdeci">static const bool Buy</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00029">Taker_test.cpp:29</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_1_1TestTaker_html_ad6aa65477ffc8cc6981696a8c3399454"><div class="ttname"><a href="classripple_1_1Taker__test_1_1TestTaker.html#ad6aa65477ffc8cc6981696a8c3399454">ripple::Taker_test::TestTaker::cross_funds</a></div><div class="ttdeci">STAmount cross_funds</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00036">Taker_test.cpp:36</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_aea839338eb91258b10d5d14262ef079f"><div class="ttname"><a href="namespaceripple.html#aea839338eb91258b10d5d14262ef079f">ripple::flow</a></div><div class="ttdeci">path::RippleCalc::Output flow(PaymentSandbox &view, STAmount const &deliver, AccountID const &src, AccountID const &dst, STPathSet const &paths, bool defaultPaths, bool partialPayment, bool ownerPaysTransferFee, bool offerCrossing, boost::optional< Quality > const &limitQuality, boost::optional< STAmount > const &sendMax, beast::Journal j, path::detail::FlowDebugInfo *flowDebugInfo=nullptr)</div><div class="ttdoc">Make a payment from the src account to the dst account.</div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_1_1TestTaker_html_a24b1e3e4f89d479d359a013b38af56cd"><div class="ttname"><a href="classripple_1_1Taker__test_1_1TestTaker.html#a24b1e3e4f89d479d359a013b38af56cd">ripple::Taker_test::TestTaker::cross</a></div><div class="ttdeci">std::pair< Amounts, Amounts > cross(Amounts offer1, Quality quality1, Amounts offer2, Quality quality2)</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00095">Taker_test.cpp:95</a></div></div>
|
|
<div class="ttc" id="amake_pair_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/utility/pair/make_pair.html">std::make_pair</a></div><div class="ttdeci">T make_pair(T... args)</div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_a287bc7b339994c63a94da2d019b4babb"><div class="ttname"><a href="classripple_1_1Taker__test.html#a287bc7b339994c63a94da2d019b4babb">ripple::Taker_test::get_quality</a></div><div class="ttdeci">Quality get_quality(std::string in, std::string out)</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00238">Taker_test.cpp:238</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1BasicTaker_html_ac208f3e27e0dfa925dcb34414b9a8ba4"><div class="ttname"><a href="classripple_1_1BasicTaker.html#ac208f3e27e0dfa925dcb34414b9a8ba4">ripple::BasicTaker::account</a></div><div class="ttdeci">AccountID const & account() const noexcept</div><div class="ttdoc">Returns the account identifier of the taker.</div><div class="ttdef"><b>Definition:</b> <a href="Taker_8h_source.html#l00162">Taker.h:162</a></div></div>
|
|
<div class="ttc" id="atype_traits_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/header/type_traits.html">type_traits</a></div></div>
|
|
<div class="ttc" id="anamespaceripple_html_a91af9326e7f471001066b6b59f24599c"><div class="ttname"><a href="namespaceripple.html#a91af9326e7f471001066b6b59f24599c">ripple::xrpCurrency</a></div><div class="ttdeci">Currency const & xrpCurrency()</div><div class="ttdoc">XRP currency.</div><div class="ttdef"><b>Definition:</b> <a href="UintTypes_8cpp_source.html#l00111">UintTypes.cpp:111</a></div></div>
|
|
<div class="ttc" id="aclassripple_1_1Taker__test_html_a07a2e3a550f8ebbea4361276081e7b41"><div class="ttname"><a href="classripple_1_1Taker__test.html#a07a2e3a550f8ebbea4361276081e7b41">ripple::Taker_test::run</a></div><div class="ttdeci">void run() override</div><div class="ttdef"><b>Definition:</b> <a href="Taker__test_8cpp_source.html#l00361">Taker_test.cpp:361</a></div></div>
|
|
<!-- start footer part -->
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated by  <a href="http://www.doxygen.org/index.html">
|
|
<img class="footer" src="doxygen.png" alt="doxygen"/>
|
|
</a> 1.8.17
|
|
</small></address>
|
|
</body>
|
|
</html>
|