mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-29 07:25:51 +00:00
deploy: 83faf43140
This commit is contained in:
@@ -117,205 +117,215 @@ $(function() {
|
||||
<div class="line"><a name="l00046"></a><span class="lineno"> 46</span>  <span class="keyword">auto</span> <span class="keyword">const</span> nftFlags = <a class="code" href="namespaceripple_1_1nft.html#a1a5f9170a15fd6861ab81b1d021410cc">nft::getFlags</a>(ctx.<a class="code" href="structripple_1_1PreflightContext.html#af202c00e509cfbb1df4fe69f4d6d6560">tx</a>[<a class="code" href="namespaceripple.html#af4bc0178db9a613df9f7f1c7bf75a7eb">sfNFTokenID</a>]);</div>
|
||||
<div class="line"><a name="l00047"></a><span class="lineno"> 47</span>  </div>
|
||||
<div class="line"><a name="l00048"></a><span class="lineno"> 48</span>  {</div>
|
||||
<div class="line"><a name="l00049"></a><span class="lineno"> 49</span>  <span class="keyword">auto</span> <span class="keyword">const</span> amount = ctx.<a class="code" href="structripple_1_1PreflightContext.html#af202c00e509cfbb1df4fe69f4d6d6560">tx</a>[<a class="code" href="namespaceripple.html#a29758397ce451beaa436c3a9dfc83030">sfAmount</a>];</div>
|
||||
<div class="line"><a name="l00049"></a><span class="lineno"> 49</span>  <a class="code" href="classripple_1_1STAmount.html">STAmount</a> <span class="keyword">const</span> amount = ctx.<a class="code" href="structripple_1_1PreflightContext.html#af202c00e509cfbb1df4fe69f4d6d6560">tx</a>[<a class="code" href="namespaceripple.html#a29758397ce451beaa436c3a9dfc83030">sfAmount</a>];</div>
|
||||
<div class="line"><a name="l00050"></a><span class="lineno"> 50</span>  </div>
|
||||
<div class="line"><a name="l00051"></a><span class="lineno"> 51</span>  <span class="keywordflow">if</span> (!<a class="code" href="namespaceripple.html#a20d30277b9c78756b3d14493055a307c">isXRP</a>(amount))</div>
|
||||
<div class="line"><a name="l00052"></a><span class="lineno"> 52</span>  {</div>
|
||||
<div class="line"><a name="l00053"></a><span class="lineno"> 53</span>  <span class="keywordflow">if</span> (nftFlags & <a class="code" href="namespaceripple_1_1nft.html#abf5771bfc2c9f62196dfe02b087b7b7c">nft::flagOnlyXRP</a>)</div>
|
||||
<div class="line"><a name="l00054"></a><span class="lineno"> 54</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a07dedb576e47ed9570e5acc5b4b1d3ea">temBAD_AMOUNT</a>;</div>
|
||||
<div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  </div>
|
||||
<div class="line"><a name="l00056"></a><span class="lineno"> 56</span>  <span class="keywordflow">if</span> (!amount)</div>
|
||||
<div class="line"><a name="l00057"></a><span class="lineno"> 57</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a07dedb576e47ed9570e5acc5b4b1d3ea">temBAD_AMOUNT</a>;</div>
|
||||
<div class="line"><a name="l00058"></a><span class="lineno"> 58</span>  }</div>
|
||||
<div class="line"><a name="l00051"></a><span class="lineno"> 51</span>  <span class="keywordflow">if</span> (amount.<a class="code" href="classripple_1_1STAmount.html#aa830654962840253139aa891659f7551">negative</a>() && ctx.<a class="code" href="structripple_1_1PreflightContext.html#af305cba8e0b5dd06e61d2dc6ac74c1a8">rules</a>.<a class="code" href="classripple_1_1Rules.html#a1a8388a2b9588aa9446ece92a88e0dd2">enabled</a>(<a class="code" href="namespaceripple.html#a451091d6bfaf55f18f3bcdfe7df65acd">fixNFTokenNegOffer</a>))</div>
|
||||
<div class="line"><a name="l00052"></a><span class="lineno"> 52</span>  <span class="comment">// An offer for a negative amount makes no sense.</span></div>
|
||||
<div class="line"><a name="l00053"></a><span class="lineno"> 53</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a07dedb576e47ed9570e5acc5b4b1d3ea">temBAD_AMOUNT</a>;</div>
|
||||
<div class="line"><a name="l00054"></a><span class="lineno"> 54</span>  </div>
|
||||
<div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  <span class="keywordflow">if</span> (!<a class="code" href="namespaceripple.html#a20d30277b9c78756b3d14493055a307c">isXRP</a>(amount))</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>  <span class="keywordflow">if</span> (nftFlags & <a class="code" href="namespaceripple_1_1nft.html#abf5771bfc2c9f62196dfe02b087b7b7c">nft::flagOnlyXRP</a>)</div>
|
||||
<div class="line"><a name="l00058"></a><span class="lineno"> 58</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a07dedb576e47ed9570e5acc5b4b1d3ea">temBAD_AMOUNT</a>;</div>
|
||||
<div class="line"><a name="l00059"></a><span class="lineno"> 59</span>  </div>
|
||||
<div class="line"><a name="l00060"></a><span class="lineno"> 60</span>  <span class="comment">// If this is an offer to buy, you must offer something; if it's an</span></div>
|
||||
<div class="line"><a name="l00061"></a><span class="lineno"> 61</span>  <span class="comment">// offer to sell, you can ask for nothing.</span></div>
|
||||
<div class="line"><a name="l00062"></a><span class="lineno"> 62</span>  <span class="keywordflow">if</span> (!isSellOffer && !amount)</div>
|
||||
<div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a07dedb576e47ed9570e5acc5b4b1d3ea">temBAD_AMOUNT</a>;</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>  </div>
|
||||
<div class="line"><a name="l00066"></a><span class="lineno"> 66</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> exp = ctx.<a class="code" href="structripple_1_1PreflightContext.html#af202c00e509cfbb1df4fe69f4d6d6560">tx</a>[~<a class="code" href="namespaceripple.html#ae3182ff3db5f7f67e4fe8bcd69316727">sfExpiration</a>]; exp == 0)</div>
|
||||
<div class="line"><a name="l00067"></a><span class="lineno"> 67</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a8845e05d481141ea5e8e5274796f45a7">temBAD_EXPIRATION</a>;</div>
|
||||
<div class="line"><a name="l00068"></a><span class="lineno"> 68</span>  </div>
|
||||
<div class="line"><a name="l00069"></a><span class="lineno"> 69</span>  <span class="keyword">auto</span> <span class="keyword">const</span> owner = ctx.<a class="code" href="structripple_1_1PreflightContext.html#af202c00e509cfbb1df4fe69f4d6d6560">tx</a>[~<a class="code" href="namespaceripple.html#a7e1ed9c5ea9eff7dd3046420f228399f">sfOwner</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="comment">// The 'Owner' field must be present when offering to buy, but can't</span></div>
|
||||
<div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  <span class="comment">// be present when selling (it's implicit):</span></div>
|
||||
<div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  <span class="keywordflow">if</span> (owner.has_value() == isSellOffer)</div>
|
||||
<div class="line"><a name="l00074"></a><span class="lineno"> 74</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a6c750a245b6efb84fdc4ab34dc010328">temMALFORMED</a>;</div>
|
||||
<div class="line"><a name="l00075"></a><span class="lineno"> 75</span>  </div>
|
||||
<div class="line"><a name="l00076"></a><span class="lineno"> 76</span>  <span class="keywordflow">if</span> (owner && owner == account)</div>
|
||||
<div class="line"><a name="l00077"></a><span class="lineno"> 77</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a6c750a245b6efb84fdc4ab34dc010328">temMALFORMED</a>;</div>
|
||||
<div class="line"><a name="l00078"></a><span class="lineno"> 78</span>  </div>
|
||||
<div class="line"><a name="l00079"></a><span class="lineno"> 79</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> dest = ctx.<a class="code" href="structripple_1_1PreflightContext.html#af202c00e509cfbb1df4fe69f4d6d6560">tx</a>[~<a class="code" href="namespaceripple.html#a15aa3b3032d0908932dc5abf4b1ef862">sfDestination</a>])</div>
|
||||
<div class="line"><a name="l00080"></a><span class="lineno"> 80</span>  {</div>
|
||||
<div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  <span class="comment">// The destination field is only valid on a sell offer; it makes no</span></div>
|
||||
<div class="line"><a name="l00082"></a><span class="lineno"> 82</span>  <span class="comment">// sense in a buy offer.</span></div>
|
||||
<div class="line"><a name="l00083"></a><span class="lineno"> 83</span>  <span class="keywordflow">if</span> (!isSellOffer)</div>
|
||||
<div class="line"><a name="l00084"></a><span class="lineno"> 84</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a6c750a245b6efb84fdc4ab34dc010328">temMALFORMED</a>;</div>
|
||||
<div class="line"><a name="l00085"></a><span class="lineno"> 85</span>  </div>
|
||||
<div class="line"><a name="l00086"></a><span class="lineno"> 86</span>  <span class="comment">// The destination can't be the account executing the transaction.</span></div>
|
||||
<div class="line"><a name="l00087"></a><span class="lineno"> 87</span>  <span class="keywordflow">if</span> (dest == account)</div>
|
||||
<div class="line"><a name="l00088"></a><span class="lineno"> 88</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a6c750a245b6efb84fdc4ab34dc010328">temMALFORMED</a>;</div>
|
||||
<div class="line"><a name="l00089"></a><span class="lineno"> 89</span>  }</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> <a class="code" href="namespaceripple.html#a8b257ff89d14ac75ce240946f32d3773">preflight2</a>(ctx);</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="code" href="classripple_1_1TERSubset.html">TER</a></div>
|
||||
<div class="line"><a name="l00095"></a><span class="lineno"><a class="line" href="classripple_1_1NFTokenCreateOffer.html#aed38ff6667eb8e6f03f02b3a304965bc"> 95</a></span> <a class="code" href="classripple_1_1NFTokenCreateOffer.html#aed38ff6667eb8e6f03f02b3a304965bc">NFTokenCreateOffer::preclaim</a>(<a class="code" href="structripple_1_1PreclaimContext.html">PreclaimContext</a> <span class="keyword">const</span>& ctx)</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="keywordflow">if</span> (<a class="code" href="namespaceripple.html#ad574e2b04fc8231900df14881418af18">hasExpired</a>(ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>, ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[~<a class="code" href="namespaceripple.html#ae3182ff3db5f7f67e4fe8bcd69316727">sfExpiration</a>]))</div>
|
||||
<div class="line"><a name="l00098"></a><span class="lineno"> 98</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38caede598f88bbd44e4df1c4e0d418c4cdc">tecEXPIRED</a>;</div>
|
||||
<div class="line"><a name="l00060"></a><span class="lineno"> 60</span>  <span class="keywordflow">if</span> (!amount)</div>
|
||||
<div class="line"><a name="l00061"></a><span class="lineno"> 61</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a07dedb576e47ed9570e5acc5b4b1d3ea">temBAD_AMOUNT</a>;</div>
|
||||
<div class="line"><a name="l00062"></a><span class="lineno"> 62</span>  }</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>  <span class="comment">// If this is an offer to buy, you must offer something; if it's an</span></div>
|
||||
<div class="line"><a name="l00065"></a><span class="lineno"> 65</span>  <span class="comment">// offer to sell, you can ask for nothing.</span></div>
|
||||
<div class="line"><a name="l00066"></a><span class="lineno"> 66</span>  <span class="keywordflow">if</span> (!isSellOffer && !amount)</div>
|
||||
<div class="line"><a name="l00067"></a><span class="lineno"> 67</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a07dedb576e47ed9570e5acc5b4b1d3ea">temBAD_AMOUNT</a>;</div>
|
||||
<div class="line"><a name="l00068"></a><span class="lineno"> 68</span>  }</div>
|
||||
<div class="line"><a name="l00069"></a><span class="lineno"> 69</span>  </div>
|
||||
<div class="line"><a name="l00070"></a><span class="lineno"> 70</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> exp = ctx.<a class="code" href="structripple_1_1PreflightContext.html#af202c00e509cfbb1df4fe69f4d6d6560">tx</a>[~<a class="code" href="namespaceripple.html#ae3182ff3db5f7f67e4fe8bcd69316727">sfExpiration</a>]; exp == 0)</div>
|
||||
<div class="line"><a name="l00071"></a><span class="lineno"> 71</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a8845e05d481141ea5e8e5274796f45a7">temBAD_EXPIRATION</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>  <span class="keyword">auto</span> <span class="keyword">const</span> owner = ctx.<a class="code" href="structripple_1_1PreflightContext.html#af202c00e509cfbb1df4fe69f4d6d6560">tx</a>[~<a class="code" href="namespaceripple.html#a7e1ed9c5ea9eff7dd3046420f228399f">sfOwner</a>];</div>
|
||||
<div class="line"><a name="l00074"></a><span class="lineno"> 74</span>  </div>
|
||||
<div class="line"><a name="l00075"></a><span class="lineno"> 75</span>  <span class="comment">// The 'Owner' field must be present when offering to buy, but can't</span></div>
|
||||
<div class="line"><a name="l00076"></a><span class="lineno"> 76</span>  <span class="comment">// be present when selling (it's implicit):</span></div>
|
||||
<div class="line"><a name="l00077"></a><span class="lineno"> 77</span>  <span class="keywordflow">if</span> (owner.has_value() == isSellOffer)</div>
|
||||
<div class="line"><a name="l00078"></a><span class="lineno"> 78</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a6c750a245b6efb84fdc4ab34dc010328">temMALFORMED</a>;</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="keywordflow">if</span> (owner && owner == account)</div>
|
||||
<div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a6c750a245b6efb84fdc4ab34dc010328">temMALFORMED</a>;</div>
|
||||
<div class="line"><a name="l00082"></a><span class="lineno"> 82</span>  </div>
|
||||
<div class="line"><a name="l00083"></a><span class="lineno"> 83</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> dest = ctx.<a class="code" href="structripple_1_1PreflightContext.html#af202c00e509cfbb1df4fe69f4d6d6560">tx</a>[~<a class="code" href="namespaceripple.html#a15aa3b3032d0908932dc5abf4b1ef862">sfDestination</a>])</div>
|
||||
<div class="line"><a name="l00084"></a><span class="lineno"> 84</span>  {</div>
|
||||
<div class="line"><a name="l00085"></a><span class="lineno"> 85</span>  <span class="comment">// Some folks think it makes sense for a buy offer to specify a</span></div>
|
||||
<div class="line"><a name="l00086"></a><span class="lineno"> 86</span>  <span class="comment">// specific broker using the Destination field. This change doesn't</span></div>
|
||||
<div class="line"><a name="l00087"></a><span class="lineno"> 87</span>  <span class="comment">// deserve it's own amendment, so we're piggy-backing on</span></div>
|
||||
<div class="line"><a name="l00088"></a><span class="lineno"> 88</span>  <span class="comment">// fixNFTokenNegOffer.</span></div>
|
||||
<div class="line"><a name="l00089"></a><span class="lineno"> 89</span>  <span class="comment">//</span></div>
|
||||
<div class="line"><a name="l00090"></a><span class="lineno"> 90</span>  <span class="comment">// Prior to fixNFTokenNegOffer any use of the Destination field on</span></div>
|
||||
<div class="line"><a name="l00091"></a><span class="lineno"> 91</span>  <span class="comment">// a buy offer was malformed.</span></div>
|
||||
<div class="line"><a name="l00092"></a><span class="lineno"> 92</span>  <span class="keywordflow">if</span> (!isSellOffer && !ctx.<a class="code" href="structripple_1_1PreflightContext.html#af305cba8e0b5dd06e61d2dc6ac74c1a8">rules</a>.<a class="code" href="classripple_1_1Rules.html#a1a8388a2b9588aa9446ece92a88e0dd2">enabled</a>(<a class="code" href="namespaceripple.html#a451091d6bfaf55f18f3bcdfe7df65acd">fixNFTokenNegOffer</a>))</div>
|
||||
<div class="line"><a name="l00093"></a><span class="lineno"> 93</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a6c750a245b6efb84fdc4ab34dc010328">temMALFORMED</a>;</div>
|
||||
<div class="line"><a name="l00094"></a><span class="lineno"> 94</span>  </div>
|
||||
<div class="line"><a name="l00095"></a><span class="lineno"> 95</span>  <span class="comment">// The destination can't be the account executing the transaction.</span></div>
|
||||
<div class="line"><a name="l00096"></a><span class="lineno"> 96</span>  <span class="keywordflow">if</span> (dest == account)</div>
|
||||
<div class="line"><a name="l00097"></a><span class="lineno"> 97</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#afe21c8454670d46fb93751a5edffed46a6c750a245b6efb84fdc4ab34dc010328">temMALFORMED</a>;</div>
|
||||
<div class="line"><a name="l00098"></a><span class="lineno"> 98</span>  }</div>
|
||||
<div class="line"><a name="l00099"></a><span class="lineno"> 99</span>  </div>
|
||||
<div class="line"><a name="l00100"></a><span class="lineno"> 100</span>  <span class="keyword">auto</span> <span class="keyword">const</span> nftokenID = ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[<a class="code" href="namespaceripple.html#af4bc0178db9a613df9f7f1c7bf75a7eb">sfNFTokenID</a>];</div>
|
||||
<div class="line"><a name="l00101"></a><span class="lineno"> 101</span>  <span class="keywordtype">bool</span> <span class="keyword">const</span> isSellOffer = ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>.<a class="code" href="classripple_1_1STObject.html#a40025a423b41e20dd78cb2627e17d678">isFlag</a>(<a class="code" href="namespaceripple.html#a0a58f25b2ddd02a1c0fcfc4c056e4fa8">tfSellNFToken</a>);</div>
|
||||
<div class="line"><a name="l00100"></a><span class="lineno"> 100</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#a8b257ff89d14ac75ce240946f32d3773">preflight2</a>(ctx);</div>
|
||||
<div class="line"><a name="l00101"></a><span class="lineno"> 101</span> }</div>
|
||||
<div class="line"><a name="l00102"></a><span class="lineno"> 102</span>  </div>
|
||||
<div class="line"><a name="l00103"></a><span class="lineno"> 103</span>  <span class="keywordflow">if</span> (!<a class="code" href="namespaceripple_1_1nft.html#a85dc7006d747123fc93c4fac11678a62">nft::findToken</a>(</div>
|
||||
<div class="line"><a name="l00104"></a><span class="lineno"> 104</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>, ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[isSellOffer ? <a class="code" href="namespaceripple.html#a5bab99595719d22579e10d21cf048eb0">sfAccount</a> : <a class="code" href="namespaceripple.html#a7e1ed9c5ea9eff7dd3046420f228399f">sfOwner</a>], nftokenID))</div>
|
||||
<div class="line"><a name="l00105"></a><span class="lineno"> 105</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca02ea20c787300a40fe375ba3d6405258">tecNO_ENTRY</a>;</div>
|
||||
<div class="line"><a name="l00106"></a><span class="lineno"> 106</span>  </div>
|
||||
<div class="line"><a name="l00107"></a><span class="lineno"> 107</span>  <span class="keyword">auto</span> <span class="keyword">const</span> nftFlags = <a class="code" href="namespaceripple_1_1nft.html#a1a5f9170a15fd6861ab81b1d021410cc">nft::getFlags</a>(nftokenID);</div>
|
||||
<div class="line"><a name="l00108"></a><span class="lineno"> 108</span>  <span class="keyword">auto</span> <span class="keyword">const</span> issuer = <a class="code" href="namespaceripple_1_1nft.html#a5a717e41d61c4e7c1b2636ca6c8f7c6e">nft::getIssuer</a>(nftokenID);</div>
|
||||
<div class="line"><a name="l00109"></a><span class="lineno"> 109</span>  <span class="keyword">auto</span> <span class="keyword">const</span> amount = ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[<a class="code" href="namespaceripple.html#a29758397ce451beaa436c3a9dfc83030">sfAmount</a>];</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="keywordflow">if</span> (!(nftFlags & <a class="code" href="namespaceripple_1_1nft.html#afc8993c59f0cb0b829043738f91887a0">nft::flagCreateTrustLines</a>) && !amount.native() &&</div>
|
||||
<div class="line"><a name="l00112"></a><span class="lineno"> 112</span>  <a class="code" href="namespaceripple_1_1nft.html#a19ab99ac39a753e73810e317d9253f83">nft::getTransferFee</a>(nftokenID))</div>
|
||||
<div class="line"><a name="l00113"></a><span class="lineno"> 113</span>  {</div>
|
||||
<div class="line"><a name="l00114"></a><span class="lineno"> 114</span>  <span class="keywordflow">if</span> (!ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>.<a class="code" href="classripple_1_1ReadView.html#ac1d377c35a8332d069b09be8f4008dec">exists</a>(<a class="code" href="namespaceripple_1_1keylet.html#a50c370db96b4fdcdd202d9c2c38afce9">keylet::account</a>(issuer)))</div>
|
||||
<div class="line"><a name="l00115"></a><span class="lineno"> 115</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca33d363e51ee15c8bd4f5d7c4e4518def">tecNO_ISSUER</a>;</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>  <span class="keywordflow">if</span> (!ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>.<a class="code" href="classripple_1_1ReadView.html#ac1d377c35a8332d069b09be8f4008dec">exists</a>(<a class="code" href="namespaceripple_1_1keylet.html#ad7913ec52c58534ee1601ab21956123f">keylet::line</a>(issuer, amount.issue())))</div>
|
||||
<div class="line"><a name="l00118"></a><span class="lineno"> 118</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38cac480d742e7760c48047bb3ccc50a40ef">tecNO_LINE</a>;</div>
|
||||
<div class="line"><a name="l00103"></a><span class="lineno"> 103</span> <a class="code" href="classripple_1_1TERSubset.html">TER</a></div>
|
||||
<div class="line"><a name="l00104"></a><span class="lineno"><a class="line" href="classripple_1_1NFTokenCreateOffer.html#aed38ff6667eb8e6f03f02b3a304965bc"> 104</a></span> <a class="code" href="classripple_1_1NFTokenCreateOffer.html#aed38ff6667eb8e6f03f02b3a304965bc">NFTokenCreateOffer::preclaim</a>(<a class="code" href="structripple_1_1PreclaimContext.html">PreclaimContext</a> <span class="keyword">const</span>& ctx)</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="namespaceripple.html#ad574e2b04fc8231900df14881418af18">hasExpired</a>(ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>, ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[~<a class="code" href="namespaceripple.html#ae3182ff3db5f7f67e4fe8bcd69316727">sfExpiration</a>]))</div>
|
||||
<div class="line"><a name="l00107"></a><span class="lineno"> 107</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38caede598f88bbd44e4df1c4e0d418c4cdc">tecEXPIRED</a>;</div>
|
||||
<div class="line"><a name="l00108"></a><span class="lineno"> 108</span>  </div>
|
||||
<div class="line"><a name="l00109"></a><span class="lineno"> 109</span>  <span class="keyword">auto</span> <span class="keyword">const</span> nftokenID = ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[<a class="code" href="namespaceripple.html#af4bc0178db9a613df9f7f1c7bf75a7eb">sfNFTokenID</a>];</div>
|
||||
<div class="line"><a name="l00110"></a><span class="lineno"> 110</span>  <span class="keywordtype">bool</span> <span class="keyword">const</span> isSellOffer = ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>.<a class="code" href="classripple_1_1STObject.html#a40025a423b41e20dd78cb2627e17d678">isFlag</a>(<a class="code" href="namespaceripple.html#a0a58f25b2ddd02a1c0fcfc4c056e4fa8">tfSellNFToken</a>);</div>
|
||||
<div class="line"><a name="l00111"></a><span class="lineno"> 111</span>  </div>
|
||||
<div class="line"><a name="l00112"></a><span class="lineno"> 112</span>  <span class="keywordflow">if</span> (!<a class="code" href="namespaceripple_1_1nft.html#a85dc7006d747123fc93c4fac11678a62">nft::findToken</a>(</div>
|
||||
<div class="line"><a name="l00113"></a><span class="lineno"> 113</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>, ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[isSellOffer ? <a class="code" href="namespaceripple.html#a5bab99595719d22579e10d21cf048eb0">sfAccount</a> : <a class="code" href="namespaceripple.html#a7e1ed9c5ea9eff7dd3046420f228399f">sfOwner</a>], nftokenID))</div>
|
||||
<div class="line"><a name="l00114"></a><span class="lineno"> 114</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca02ea20c787300a40fe375ba3d6405258">tecNO_ENTRY</a>;</div>
|
||||
<div class="line"><a name="l00115"></a><span class="lineno"> 115</span>  </div>
|
||||
<div class="line"><a name="l00116"></a><span class="lineno"> 116</span>  <span class="keyword">auto</span> <span class="keyword">const</span> nftFlags = <a class="code" href="namespaceripple_1_1nft.html#a1a5f9170a15fd6861ab81b1d021410cc">nft::getFlags</a>(nftokenID);</div>
|
||||
<div class="line"><a name="l00117"></a><span class="lineno"> 117</span>  <span class="keyword">auto</span> <span class="keyword">const</span> issuer = <a class="code" href="namespaceripple_1_1nft.html#a5a717e41d61c4e7c1b2636ca6c8f7c6e">nft::getIssuer</a>(nftokenID);</div>
|
||||
<div class="line"><a name="l00118"></a><span class="lineno"> 118</span>  <span class="keyword">auto</span> <span class="keyword">const</span> amount = ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[<a class="code" href="namespaceripple.html#a29758397ce451beaa436c3a9dfc83030">sfAmount</a>];</div>
|
||||
<div class="line"><a name="l00119"></a><span class="lineno"> 119</span>  </div>
|
||||
<div class="line"><a name="l00120"></a><span class="lineno"> 120</span>  <span class="keywordflow">if</span> (<a class="code" href="namespaceripple.html#a6cb89b79bc073abda42953c323d36cda">isFrozen</a>(</div>
|
||||
<div class="line"><a name="l00121"></a><span class="lineno"> 121</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>, issuer, amount.getCurrency(), amount.getIssuer()))</div>
|
||||
<div class="line"><a name="l00122"></a><span class="lineno"> 122</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca608da193a4a22ae1c78d76b6e843b7e6">tecFROZEN</a>;</div>
|
||||
<div class="line"><a name="l00123"></a><span class="lineno"> 123</span>  }</div>
|
||||
<div class="line"><a name="l00124"></a><span class="lineno"> 124</span>  </div>
|
||||
<div class="line"><a name="l00125"></a><span class="lineno"> 125</span>  <span class="keywordflow">if</span> (issuer != ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[<a class="code" href="namespaceripple.html#a5bab99595719d22579e10d21cf048eb0">sfAccount</a>] && !(nftFlags & <a class="code" href="namespaceripple_1_1nft.html#a85206f984cd8f8255ff7e4f35a13d90e">nft::flagTransferable</a>))</div>
|
||||
<div class="line"><a name="l00126"></a><span class="lineno"> 126</span>  {</div>
|
||||
<div class="line"><a name="l00127"></a><span class="lineno"> 127</span>  <span class="keyword">auto</span> <span class="keyword">const</span> root = ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>.<a class="code" href="classripple_1_1ReadView.html#a3351e0244f921234d5ba005a07ddf539">read</a>(<a class="code" href="namespaceripple_1_1keylet.html#a50c370db96b4fdcdd202d9c2c38afce9">keylet::account</a>(issuer));</div>
|
||||
<div class="line"><a name="l00128"></a><span class="lineno"> 128</span>  assert(root);</div>
|
||||
<div class="line"><a name="l00129"></a><span class="lineno"> 129</span>  </div>
|
||||
<div class="line"><a name="l00130"></a><span class="lineno"> 130</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> minter = (*root)[~<a class="code" href="namespaceripple.html#a85870fe5e629b0a50482d1bb68bb8028">sfNFTokenMinter</a>];</div>
|
||||
<div class="line"><a name="l00131"></a><span class="lineno"> 131</span>  minter != ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[<a class="code" href="namespaceripple.html#a5bab99595719d22579e10d21cf048eb0">sfAccount</a>])</div>
|
||||
<div class="line"><a name="l00132"></a><span class="lineno"> 132</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#a75cb21d7f1df42f2fdc8efddb79b63f4a6700b7b7664a3b6c0611d9f943b5625f">tefNFTOKEN_IS_NOT_TRANSFERABLE</a>;</div>
|
||||
<div class="line"><a name="l00133"></a><span class="lineno"> 133</span>  }</div>
|
||||
<div class="line"><a name="l00134"></a><span class="lineno"> 134</span>  </div>
|
||||
<div class="line"><a name="l00135"></a><span class="lineno"> 135</span>  <span class="keywordflow">if</span> (<a class="code" href="namespaceripple.html#a6cb89b79bc073abda42953c323d36cda">isFrozen</a>(</div>
|
||||
<div class="line"><a name="l00136"></a><span class="lineno"> 136</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>,</div>
|
||||
<div class="line"><a name="l00137"></a><span class="lineno"> 137</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[<a class="code" href="namespaceripple.html#a5bab99595719d22579e10d21cf048eb0">sfAccount</a>],</div>
|
||||
<div class="line"><a name="l00138"></a><span class="lineno"> 138</span>  amount.getCurrency(),</div>
|
||||
<div class="line"><a name="l00139"></a><span class="lineno"> 139</span>  amount.getIssuer()))</div>
|
||||
<div class="line"><a name="l00140"></a><span class="lineno"> 140</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca608da193a4a22ae1c78d76b6e843b7e6">tecFROZEN</a>;</div>
|
||||
<div class="line"><a name="l00141"></a><span class="lineno"> 141</span>  </div>
|
||||
<div class="line"><a name="l00142"></a><span class="lineno"> 142</span>  <span class="comment">// If this is an offer to buy the token, the account must have the</span></div>
|
||||
<div class="line"><a name="l00143"></a><span class="lineno"> 143</span>  <span class="comment">// needed funds at hand; but note that funds aren't reserved and the</span></div>
|
||||
<div class="line"><a name="l00144"></a><span class="lineno"> 144</span>  <span class="comment">// offer may later become unfunded.</span></div>
|
||||
<div class="line"><a name="l00145"></a><span class="lineno"> 145</span>  <span class="keywordflow">if</span> (!isSellOffer)</div>
|
||||
<div class="line"><a name="l00146"></a><span class="lineno"> 146</span>  {</div>
|
||||
<div class="line"><a name="l00147"></a><span class="lineno"> 147</span>  <span class="keyword">auto</span> <span class="keyword">const</span> funds = <a class="code" href="namespaceripple.html#ab001e43f50e612727b1ce5985a2770d6">accountHolds</a>(</div>
|
||||
<div class="line"><a name="l00148"></a><span class="lineno"> 148</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>,</div>
|
||||
<div class="line"><a name="l00149"></a><span class="lineno"> 149</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[<a class="code" href="namespaceripple.html#a5bab99595719d22579e10d21cf048eb0">sfAccount</a>],</div>
|
||||
<div class="line"><a name="l00150"></a><span class="lineno"> 150</span>  amount.getCurrency(),</div>
|
||||
<div class="line"><a name="l00151"></a><span class="lineno"> 151</span>  amount.getIssuer(),</div>
|
||||
<div class="line"><a name="l00152"></a><span class="lineno"> 152</span>  FreezeHandling::fhZERO_IF_FROZEN,</div>
|
||||
<div class="line"><a name="l00153"></a><span class="lineno"> 153</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a534551c8ca0dd7afc8fe9098bf9da780">j</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>  <span class="keywordflow">if</span> (funds.signum() <= 0)</div>
|
||||
<div class="line"><a name="l00156"></a><span class="lineno"> 156</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca5d1f0daadc43667fc3775d53cd6e3420">tecUNFUNDED_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"> 158</span>  </div>
|
||||
<div class="line"><a name="l00159"></a><span class="lineno"> 159</span>  <span class="comment">// If a destination is specified, the destination must already be in</span></div>
|
||||
<div class="line"><a name="l00160"></a><span class="lineno"> 160</span>  <span class="comment">// the ledger.</span></div>
|
||||
<div class="line"><a name="l00161"></a><span class="lineno"> 161</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> <span class="keyword">const</span> destination = ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[~<a class="code" href="namespaceripple.html#a15aa3b3032d0908932dc5abf4b1ef862">sfDestination</a>];</div>
|
||||
<div class="line"><a name="l00162"></a><span class="lineno"> 162</span>  destination && !ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>.<a class="code" href="classripple_1_1ReadView.html#ac1d377c35a8332d069b09be8f4008dec">exists</a>(<a class="code" href="namespaceripple_1_1keylet.html#a50c370db96b4fdcdd202d9c2c38afce9">keylet::account</a>(*destination)))</div>
|
||||
<div class="line"><a name="l00163"></a><span class="lineno"> 163</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca1207baad8c378dc23cd2fa4c4276844d">tecNO_DST</a>;</div>
|
||||
<div class="line"><a name="l00164"></a><span class="lineno"> 164</span>  </div>
|
||||
<div class="line"><a name="l00165"></a><span class="lineno"> 165</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aabc7f150d5082c73116a1cd5962b434da28c7d8b3ed759d363503a05fcd59f151">tesSUCCESS</a>;</div>
|
||||
<div class="line"><a name="l00166"></a><span class="lineno"> 166</span> }</div>
|
||||
<div class="line"><a name="l00120"></a><span class="lineno"> 120</span>  <span class="keywordflow">if</span> (!(nftFlags & <a class="code" href="namespaceripple_1_1nft.html#afc8993c59f0cb0b829043738f91887a0">nft::flagCreateTrustLines</a>) && !amount.native() &&</div>
|
||||
<div class="line"><a name="l00121"></a><span class="lineno"> 121</span>  <a class="code" href="namespaceripple_1_1nft.html#a19ab99ac39a753e73810e317d9253f83">nft::getTransferFee</a>(nftokenID))</div>
|
||||
<div class="line"><a name="l00122"></a><span class="lineno"> 122</span>  {</div>
|
||||
<div class="line"><a name="l00123"></a><span class="lineno"> 123</span>  <span class="keywordflow">if</span> (!ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>.<a class="code" href="classripple_1_1ReadView.html#ac1d377c35a8332d069b09be8f4008dec">exists</a>(<a class="code" href="namespaceripple_1_1keylet.html#a50c370db96b4fdcdd202d9c2c38afce9">keylet::account</a>(issuer)))</div>
|
||||
<div class="line"><a name="l00124"></a><span class="lineno"> 124</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca33d363e51ee15c8bd4f5d7c4e4518def">tecNO_ISSUER</a>;</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>  <span class="keywordflow">if</span> (!ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>.<a class="code" href="classripple_1_1ReadView.html#ac1d377c35a8332d069b09be8f4008dec">exists</a>(<a class="code" href="namespaceripple_1_1keylet.html#ad7913ec52c58534ee1601ab21956123f">keylet::line</a>(issuer, amount.issue())))</div>
|
||||
<div class="line"><a name="l00127"></a><span class="lineno"> 127</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38cac480d742e7760c48047bb3ccc50a40ef">tecNO_LINE</a>;</div>
|
||||
<div class="line"><a name="l00128"></a><span class="lineno"> 128</span>  </div>
|
||||
<div class="line"><a name="l00129"></a><span class="lineno"> 129</span>  <span class="keywordflow">if</span> (<a class="code" href="namespaceripple.html#a6cb89b79bc073abda42953c323d36cda">isFrozen</a>(</div>
|
||||
<div class="line"><a name="l00130"></a><span class="lineno"> 130</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>, issuer, amount.getCurrency(), amount.getIssuer()))</div>
|
||||
<div class="line"><a name="l00131"></a><span class="lineno"> 131</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca608da193a4a22ae1c78d76b6e843b7e6">tecFROZEN</a>;</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"> 134</span>  <span class="keywordflow">if</span> (issuer != ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[<a class="code" href="namespaceripple.html#a5bab99595719d22579e10d21cf048eb0">sfAccount</a>] && !(nftFlags & <a class="code" href="namespaceripple_1_1nft.html#a85206f984cd8f8255ff7e4f35a13d90e">nft::flagTransferable</a>))</div>
|
||||
<div class="line"><a name="l00135"></a><span class="lineno"> 135</span>  {</div>
|
||||
<div class="line"><a name="l00136"></a><span class="lineno"> 136</span>  <span class="keyword">auto</span> <span class="keyword">const</span> root = ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>.<a class="code" href="classripple_1_1ReadView.html#a3351e0244f921234d5ba005a07ddf539">read</a>(<a class="code" href="namespaceripple_1_1keylet.html#a50c370db96b4fdcdd202d9c2c38afce9">keylet::account</a>(issuer));</div>
|
||||
<div class="line"><a name="l00137"></a><span class="lineno"> 137</span>  assert(root);</div>
|
||||
<div class="line"><a name="l00138"></a><span class="lineno"> 138</span>  </div>
|
||||
<div class="line"><a name="l00139"></a><span class="lineno"> 139</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> minter = (*root)[~<a class="code" href="namespaceripple.html#a85870fe5e629b0a50482d1bb68bb8028">sfNFTokenMinter</a>];</div>
|
||||
<div class="line"><a name="l00140"></a><span class="lineno"> 140</span>  minter != ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[<a class="code" href="namespaceripple.html#a5bab99595719d22579e10d21cf048eb0">sfAccount</a>])</div>
|
||||
<div class="line"><a name="l00141"></a><span class="lineno"> 141</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#a75cb21d7f1df42f2fdc8efddb79b63f4a6700b7b7664a3b6c0611d9f943b5625f">tefNFTOKEN_IS_NOT_TRANSFERABLE</a>;</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>  </div>
|
||||
<div class="line"><a name="l00144"></a><span class="lineno"> 144</span>  <span class="keywordflow">if</span> (<a class="code" href="namespaceripple.html#a6cb89b79bc073abda42953c323d36cda">isFrozen</a>(</div>
|
||||
<div class="line"><a name="l00145"></a><span class="lineno"> 145</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>,</div>
|
||||
<div class="line"><a name="l00146"></a><span class="lineno"> 146</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[<a class="code" href="namespaceripple.html#a5bab99595719d22579e10d21cf048eb0">sfAccount</a>],</div>
|
||||
<div class="line"><a name="l00147"></a><span class="lineno"> 147</span>  amount.getCurrency(),</div>
|
||||
<div class="line"><a name="l00148"></a><span class="lineno"> 148</span>  amount.getIssuer()))</div>
|
||||
<div class="line"><a name="l00149"></a><span class="lineno"> 149</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca608da193a4a22ae1c78d76b6e843b7e6">tecFROZEN</a>;</div>
|
||||
<div class="line"><a name="l00150"></a><span class="lineno"> 150</span>  </div>
|
||||
<div class="line"><a name="l00151"></a><span class="lineno"> 151</span>  <span class="comment">// If this is an offer to buy the token, the account must have the</span></div>
|
||||
<div class="line"><a name="l00152"></a><span class="lineno"> 152</span>  <span class="comment">// needed funds at hand; but note that funds aren't reserved and the</span></div>
|
||||
<div class="line"><a name="l00153"></a><span class="lineno"> 153</span>  <span class="comment">// offer may later become unfunded.</span></div>
|
||||
<div class="line"><a name="l00154"></a><span class="lineno"> 154</span>  <span class="keywordflow">if</span> (!isSellOffer)</div>
|
||||
<div class="line"><a name="l00155"></a><span class="lineno"> 155</span>  {</div>
|
||||
<div class="line"><a name="l00156"></a><span class="lineno"> 156</span>  <span class="keyword">auto</span> <span class="keyword">const</span> funds = <a class="code" href="namespaceripple.html#ab001e43f50e612727b1ce5985a2770d6">accountHolds</a>(</div>
|
||||
<div class="line"><a name="l00157"></a><span class="lineno"> 157</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>,</div>
|
||||
<div class="line"><a name="l00158"></a><span class="lineno"> 158</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[<a class="code" href="namespaceripple.html#a5bab99595719d22579e10d21cf048eb0">sfAccount</a>],</div>
|
||||
<div class="line"><a name="l00159"></a><span class="lineno"> 159</span>  amount.getCurrency(),</div>
|
||||
<div class="line"><a name="l00160"></a><span class="lineno"> 160</span>  amount.getIssuer(),</div>
|
||||
<div class="line"><a name="l00161"></a><span class="lineno"> 161</span>  FreezeHandling::fhZERO_IF_FROZEN,</div>
|
||||
<div class="line"><a name="l00162"></a><span class="lineno"> 162</span>  ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a534551c8ca0dd7afc8fe9098bf9da780">j</a>);</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>  <span class="keywordflow">if</span> (funds.signum() <= 0)</div>
|
||||
<div class="line"><a name="l00165"></a><span class="lineno"> 165</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca5d1f0daadc43667fc3775d53cd6e3420">tecUNFUNDED_OFFER</a>;</div>
|
||||
<div class="line"><a name="l00166"></a><span class="lineno"> 166</span>  }</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> <a class="code" href="classripple_1_1TERSubset.html">TER</a></div>
|
||||
<div class="line"><a name="l00169"></a><span class="lineno"><a class="line" href="classripple_1_1NFTokenCreateOffer.html#ae3a8099d64745a8988039fa07852cdbc"> 169</a></span> <a class="code" href="classripple_1_1NFTokenCreateOffer.html#ae3a8099d64745a8988039fa07852cdbc">NFTokenCreateOffer::doApply</a>()</div>
|
||||
<div class="line"><a name="l00170"></a><span class="lineno"> 170</span> {</div>
|
||||
<div class="line"><a name="l00171"></a><span class="lineno"> 171</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> <span class="keyword">const</span> acct = <a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>().read(<a class="code" href="namespaceripple_1_1keylet.html#a50c370db96b4fdcdd202d9c2c38afce9">keylet::account</a>(<a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>[<a class="code" href="namespaceripple.html#a5bab99595719d22579e10d21cf048eb0">sfAccount</a>]));</div>
|
||||
<div class="line"><a name="l00172"></a><span class="lineno"> 172</span>  <a class="code" href="classripple_1_1Transactor.html#abb2f6f5d7fd8c663c5df76b6fcba2c49">mPriorBalance</a> < <a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>().fees().accountReserve((*acct)[<a class="code" href="namespaceripple.html#aee6c41ec9be20b8705502ae9290ef2b0">sfOwnerCount</a>] + 1))</div>
|
||||
<div class="line"><a name="l00173"></a><span class="lineno"> 173</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38cae930fb228ae74317976b57b4e87a7f0d">tecINSUFFICIENT_RESERVE</a>;</div>
|
||||
<div class="line"><a name="l00174"></a><span class="lineno"> 174</span>  </div>
|
||||
<div class="line"><a name="l00175"></a><span class="lineno"> 175</span>  <span class="keyword">auto</span> <span class="keyword">const</span> nftokenID = <a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>[<a class="code" href="namespaceripple.html#af4bc0178db9a613df9f7f1c7bf75a7eb">sfNFTokenID</a>];</div>
|
||||
<div class="line"><a name="l00168"></a><span class="lineno"> 168</span>  <span class="comment">// If a destination is specified, the destination must already be in</span></div>
|
||||
<div class="line"><a name="l00169"></a><span class="lineno"> 169</span>  <span class="comment">// the ledger.</span></div>
|
||||
<div class="line"><a name="l00170"></a><span class="lineno"> 170</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> <span class="keyword">const</span> destination = ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a8e1240b39791cf309b9caaffe8e5d306">tx</a>[~<a class="code" href="namespaceripple.html#a15aa3b3032d0908932dc5abf4b1ef862">sfDestination</a>];</div>
|
||||
<div class="line"><a name="l00171"></a><span class="lineno"> 171</span>  destination && !ctx.<a class="code" href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">view</a>.<a class="code" href="classripple_1_1ReadView.html#ac1d377c35a8332d069b09be8f4008dec">exists</a>(<a class="code" href="namespaceripple_1_1keylet.html#a50c370db96b4fdcdd202d9c2c38afce9">keylet::account</a>(*destination)))</div>
|
||||
<div class="line"><a name="l00172"></a><span class="lineno"> 172</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca1207baad8c378dc23cd2fa4c4276844d">tecNO_DST</a>;</div>
|
||||
<div class="line"><a name="l00173"></a><span class="lineno"> 173</span>  </div>
|
||||
<div class="line"><a name="l00174"></a><span class="lineno"> 174</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aabc7f150d5082c73116a1cd5962b434da28c7d8b3ed759d363503a05fcd59f151">tesSUCCESS</a>;</div>
|
||||
<div class="line"><a name="l00175"></a><span class="lineno"> 175</span> }</div>
|
||||
<div class="line"><a name="l00176"></a><span class="lineno"> 176</span>  </div>
|
||||
<div class="line"><a name="l00177"></a><span class="lineno"> 177</span>  <span class="keyword">auto</span> <span class="keyword">const</span> offerID =</div>
|
||||
<div class="line"><a name="l00178"></a><span class="lineno"> 178</span>  <a class="code" href="namespaceripple_1_1keylet.html#af22d78dcae7bfcc9d36e53f2223875f4">keylet::nftoffer</a>(<a class="code" href="classripple_1_1Transactor.html#a558a1d4288c859eb5875154a86435220">account_</a>, <a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>.<a class="code" href="classripple_1_1STTx.html#a42464c41715a5d90dfa3240118d62d9c">getSeqProxy</a>().<a class="code" href="classripple_1_1SeqProxy.html#a41c206bf5f44fe0b3f99f2dd42b0259c">value</a>());</div>
|
||||
<div class="line"><a name="l00179"></a><span class="lineno"> 179</span>  </div>
|
||||
<div class="line"><a name="l00180"></a><span class="lineno"> 180</span>  <span class="comment">// Create the offer:</span></div>
|
||||
<div class="line"><a name="l00181"></a><span class="lineno"> 181</span>  {</div>
|
||||
<div class="line"><a name="l00182"></a><span class="lineno"> 182</span>  <span class="comment">// Token offers are always added to the owner's owner directory:</span></div>
|
||||
<div class="line"><a name="l00183"></a><span class="lineno"> 183</span>  <span class="keyword">auto</span> <span class="keyword">const</span> ownerNode = <a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>().<a class="code" href="classripple_1_1ApplyView.html#ade751364c7a9580032ef5988a953a6ee">dirInsert</a>(</div>
|
||||
<div class="line"><a name="l00184"></a><span class="lineno"> 184</span>  <a class="code" href="namespaceripple_1_1keylet.html#aa9b2ba2df3c3da4cecd1c07cccf7c7f9">keylet::ownerDir</a>(<a class="code" href="classripple_1_1Transactor.html#a558a1d4288c859eb5875154a86435220">account_</a>), offerID, <a class="code" href="namespaceripple.html#a5b498122d9b8c1acbeb9fe459faac22b">describeOwnerDir</a>(<a class="code" href="classripple_1_1Transactor.html#a558a1d4288c859eb5875154a86435220">account_</a>));</div>
|
||||
<div class="line"><a name="l00177"></a><span class="lineno"> 177</span> <a class="code" href="classripple_1_1TERSubset.html">TER</a></div>
|
||||
<div class="line"><a name="l00178"></a><span class="lineno"><a class="line" href="classripple_1_1NFTokenCreateOffer.html#ae3a8099d64745a8988039fa07852cdbc"> 178</a></span> <a class="code" href="classripple_1_1NFTokenCreateOffer.html#ae3a8099d64745a8988039fa07852cdbc">NFTokenCreateOffer::doApply</a>()</div>
|
||||
<div class="line"><a name="l00179"></a><span class="lineno"> 179</span> {</div>
|
||||
<div class="line"><a name="l00180"></a><span class="lineno"> 180</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> <span class="keyword">const</span> acct = <a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>().read(<a class="code" href="namespaceripple_1_1keylet.html#a50c370db96b4fdcdd202d9c2c38afce9">keylet::account</a>(<a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>[<a class="code" href="namespaceripple.html#a5bab99595719d22579e10d21cf048eb0">sfAccount</a>]));</div>
|
||||
<div class="line"><a name="l00181"></a><span class="lineno"> 181</span>  <a class="code" href="classripple_1_1Transactor.html#abb2f6f5d7fd8c663c5df76b6fcba2c49">mPriorBalance</a> < <a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>().fees().accountReserve((*acct)[<a class="code" href="namespaceripple.html#aee6c41ec9be20b8705502ae9290ef2b0">sfOwnerCount</a>] + 1))</div>
|
||||
<div class="line"><a name="l00182"></a><span class="lineno"> 182</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38cae930fb228ae74317976b57b4e87a7f0d">tecINSUFFICIENT_RESERVE</a>;</div>
|
||||
<div class="line"><a name="l00183"></a><span class="lineno"> 183</span>  </div>
|
||||
<div class="line"><a name="l00184"></a><span class="lineno"> 184</span>  <span class="keyword">auto</span> <span class="keyword">const</span> nftokenID = <a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>[<a class="code" href="namespaceripple.html#af4bc0178db9a613df9f7f1c7bf75a7eb">sfNFTokenID</a>];</div>
|
||||
<div class="line"><a name="l00185"></a><span class="lineno"> 185</span>  </div>
|
||||
<div class="line"><a name="l00186"></a><span class="lineno"> 186</span>  <span class="keywordflow">if</span> (!ownerNode)</div>
|
||||
<div class="line"><a name="l00187"></a><span class="lineno"> 187</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca4f19fdbc12c26412215f3477f70d5feb">tecDIR_FULL</a>;</div>
|
||||
<div class="line"><a name="l00186"></a><span class="lineno"> 186</span>  <span class="keyword">auto</span> <span class="keyword">const</span> offerID =</div>
|
||||
<div class="line"><a name="l00187"></a><span class="lineno"> 187</span>  <a class="code" href="namespaceripple_1_1keylet.html#af22d78dcae7bfcc9d36e53f2223875f4">keylet::nftoffer</a>(<a class="code" href="classripple_1_1Transactor.html#a558a1d4288c859eb5875154a86435220">account_</a>, <a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>.<a class="code" href="classripple_1_1STTx.html#a42464c41715a5d90dfa3240118d62d9c">getSeqProxy</a>().<a class="code" href="classripple_1_1SeqProxy.html#a41c206bf5f44fe0b3f99f2dd42b0259c">value</a>());</div>
|
||||
<div class="line"><a name="l00188"></a><span class="lineno"> 188</span>  </div>
|
||||
<div class="line"><a name="l00189"></a><span class="lineno"> 189</span>  <span class="keywordtype">bool</span> <span class="keyword">const</span> isSellOffer = <a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>.<a class="code" href="classripple_1_1STObject.html#a40025a423b41e20dd78cb2627e17d678">isFlag</a>(<a class="code" href="namespaceripple.html#a0a58f25b2ddd02a1c0fcfc4c056e4fa8">tfSellNFToken</a>);</div>
|
||||
<div class="line"><a name="l00190"></a><span class="lineno"> 190</span>  </div>
|
||||
<div class="line"><a name="l00191"></a><span class="lineno"> 191</span>  <span class="comment">// Token offers are also added to the token's buy or sell offer</span></div>
|
||||
<div class="line"><a name="l00192"></a><span class="lineno"> 192</span>  <span class="comment">// directory</span></div>
|
||||
<div class="line"><a name="l00193"></a><span class="lineno"> 193</span>  <span class="keyword">auto</span> <span class="keyword">const</span> offerNode = <a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>().<a class="code" href="classripple_1_1ApplyView.html#ade751364c7a9580032ef5988a953a6ee">dirInsert</a>(</div>
|
||||
<div class="line"><a name="l00194"></a><span class="lineno"> 194</span>  isSellOffer ? <a class="code" href="namespaceripple_1_1keylet.html#a7bdef766607c687f8d05c699c5fb478f">keylet::nft_sells</a>(nftokenID)</div>
|
||||
<div class="line"><a name="l00195"></a><span class="lineno"> 195</span>  : <a class="code" href="namespaceripple_1_1keylet.html#a46b3edff074ddb69e14bda5b00cf8e26">keylet::nft_buys</a>(nftokenID),</div>
|
||||
<div class="line"><a name="l00196"></a><span class="lineno"> 196</span>  offerID,</div>
|
||||
<div class="line"><a name="l00197"></a><span class="lineno"> 197</span>  [&nftokenID, isSellOffer](<a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr<SLE></a> <span class="keyword">const</span>& sle) {</div>
|
||||
<div class="line"><a name="l00198"></a><span class="lineno"> 198</span>  (*sle)[<a class="code" href="namespaceripple.html#ac1371098a8a7c1e1238290d0220dc941">sfFlags</a>] =</div>
|
||||
<div class="line"><a name="l00199"></a><span class="lineno"> 199</span>  isSellOffer ? <a class="code" href="namespaceripple.html#a4a9c7b33fef9015d6406302ef80b63c5a6ef34056b7b7b1d985b5f4609c4fa904">lsfNFTokenSellOffers</a> : <a class="code" href="namespaceripple.html#a4a9c7b33fef9015d6406302ef80b63c5a51e9a2085c035de4de06c8b462382556">lsfNFTokenBuyOffers</a>;</div>
|
||||
<div class="line"><a name="l00200"></a><span class="lineno"> 200</span>  (*sle)[<a class="code" href="namespaceripple.html#af4bc0178db9a613df9f7f1c7bf75a7eb">sfNFTokenID</a>] = nftokenID;</div>
|
||||
<div class="line"><a name="l00201"></a><span class="lineno"> 201</span>  });</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>  <span class="keywordflow">if</span> (!offerNode)</div>
|
||||
<div class="line"><a name="l00204"></a><span class="lineno"> 204</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca4f19fdbc12c26412215f3477f70d5feb">tecDIR_FULL</a>;</div>
|
||||
<div class="line"><a name="l00205"></a><span class="lineno"> 205</span>  </div>
|
||||
<div class="line"><a name="l00206"></a><span class="lineno"> 206</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a> sleFlags = 0;</div>
|
||||
<div class="line"><a name="l00207"></a><span class="lineno"> 207</span>  </div>
|
||||
<div class="line"><a name="l00208"></a><span class="lineno"> 208</span>  <span class="keywordflow">if</span> (isSellOffer)</div>
|
||||
<div class="line"><a name="l00209"></a><span class="lineno"> 209</span>  sleFlags |= <a class="code" href="namespaceripple.html#a4a9c7b33fef9015d6406302ef80b63c5af09cb8ad3ecf501d7149dad344aada65">lsfSellNFToken</a>;</div>
|
||||
<div class="line"><a name="l00210"></a><span class="lineno"> 210</span>  </div>
|
||||
<div class="line"><a name="l00211"></a><span class="lineno"> 211</span>  <span class="keyword">auto</span> offer = std::make_shared<SLE>(offerID);</div>
|
||||
<div class="line"><a name="l00212"></a><span class="lineno"> 212</span>  (*offer)[<a class="code" href="namespaceripple.html#a7e1ed9c5ea9eff7dd3046420f228399f">sfOwner</a>] = <a class="code" href="classripple_1_1Transactor.html#a558a1d4288c859eb5875154a86435220">account_</a>;</div>
|
||||
<div class="line"><a name="l00213"></a><span class="lineno"> 213</span>  (*offer)[<a class="code" href="namespaceripple.html#af4bc0178db9a613df9f7f1c7bf75a7eb">sfNFTokenID</a>] = nftokenID;</div>
|
||||
<div class="line"><a name="l00214"></a><span class="lineno"> 214</span>  (*offer)[<a class="code" href="namespaceripple.html#a29758397ce451beaa436c3a9dfc83030">sfAmount</a>] = <a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>[<a class="code" href="namespaceripple.html#a29758397ce451beaa436c3a9dfc83030">sfAmount</a>];</div>
|
||||
<div class="line"><a name="l00215"></a><span class="lineno"> 215</span>  (*offer)[<a class="code" href="namespaceripple.html#ac1371098a8a7c1e1238290d0220dc941">sfFlags</a>] = sleFlags;</div>
|
||||
<div class="line"><a name="l00216"></a><span class="lineno"> 216</span>  (*offer)[<a class="code" href="namespaceripple.html#a7038e25fafd9239c031a42b0f285ddf4">sfOwnerNode</a>] = *ownerNode;</div>
|
||||
<div class="line"><a name="l00217"></a><span class="lineno"> 217</span>  (*offer)[<a class="code" href="namespaceripple.html#aea272d209d40b7bd28de57ffd294f402">sfNFTokenOfferNode</a>] = *offerNode;</div>
|
||||
<div class="line"><a name="l00218"></a><span class="lineno"> 218</span>  </div>
|
||||
<div class="line"><a name="l00219"></a><span class="lineno"> 219</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> <span class="keyword">const</span> expiration = <a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>[~<a class="code" href="namespaceripple.html#ae3182ff3db5f7f67e4fe8bcd69316727">sfExpiration</a>])</div>
|
||||
<div class="line"><a name="l00220"></a><span class="lineno"> 220</span>  (*offer)[<a class="code" href="namespaceripple.html#ae3182ff3db5f7f67e4fe8bcd69316727">sfExpiration</a>] = *expiration;</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>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> <span class="keyword">const</span> destination = <a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>[~<a class="code" href="namespaceripple.html#a15aa3b3032d0908932dc5abf4b1ef862">sfDestination</a>])</div>
|
||||
<div class="line"><a name="l00223"></a><span class="lineno"> 223</span>  (*offer)[<a class="code" href="namespaceripple.html#a15aa3b3032d0908932dc5abf4b1ef862">sfDestination</a>] = *destination;</div>
|
||||
<div class="line"><a name="l00224"></a><span class="lineno"> 224</span>  </div>
|
||||
<div class="line"><a name="l00225"></a><span class="lineno"> 225</span>  <a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>().<a class="code" href="classripple_1_1ApplyView.html#aa3c5b5cd9dca5f906be4b36640706e3c">insert</a>(offer);</div>
|
||||
<div class="line"><a name="l00226"></a><span class="lineno"> 226</span>  }</div>
|
||||
<div class="line"><a name="l00189"></a><span class="lineno"> 189</span>  <span class="comment">// Create the offer:</span></div>
|
||||
<div class="line"><a name="l00190"></a><span class="lineno"> 190</span>  {</div>
|
||||
<div class="line"><a name="l00191"></a><span class="lineno"> 191</span>  <span class="comment">// Token offers are always added to the owner's owner directory:</span></div>
|
||||
<div class="line"><a name="l00192"></a><span class="lineno"> 192</span>  <span class="keyword">auto</span> <span class="keyword">const</span> ownerNode = <a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>().<a class="code" href="classripple_1_1ApplyView.html#ade751364c7a9580032ef5988a953a6ee">dirInsert</a>(</div>
|
||||
<div class="line"><a name="l00193"></a><span class="lineno"> 193</span>  <a class="code" href="namespaceripple_1_1keylet.html#aa9b2ba2df3c3da4cecd1c07cccf7c7f9">keylet::ownerDir</a>(<a class="code" href="classripple_1_1Transactor.html#a558a1d4288c859eb5875154a86435220">account_</a>), offerID, <a class="code" href="namespaceripple.html#a5b498122d9b8c1acbeb9fe459faac22b">describeOwnerDir</a>(<a class="code" href="classripple_1_1Transactor.html#a558a1d4288c859eb5875154a86435220">account_</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>  <span class="keywordflow">if</span> (!ownerNode)</div>
|
||||
<div class="line"><a name="l00196"></a><span class="lineno"> 196</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca4f19fdbc12c26412215f3477f70d5feb">tecDIR_FULL</a>;</div>
|
||||
<div class="line"><a name="l00197"></a><span class="lineno"> 197</span>  </div>
|
||||
<div class="line"><a name="l00198"></a><span class="lineno"> 198</span>  <span class="keywordtype">bool</span> <span class="keyword">const</span> isSellOffer = <a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>.<a class="code" href="classripple_1_1STObject.html#a40025a423b41e20dd78cb2627e17d678">isFlag</a>(<a class="code" href="namespaceripple.html#a0a58f25b2ddd02a1c0fcfc4c056e4fa8">tfSellNFToken</a>);</div>
|
||||
<div class="line"><a name="l00199"></a><span class="lineno"> 199</span>  </div>
|
||||
<div class="line"><a name="l00200"></a><span class="lineno"> 200</span>  <span class="comment">// Token offers are also added to the token's buy or sell offer</span></div>
|
||||
<div class="line"><a name="l00201"></a><span class="lineno"> 201</span>  <span class="comment">// directory</span></div>
|
||||
<div class="line"><a name="l00202"></a><span class="lineno"> 202</span>  <span class="keyword">auto</span> <span class="keyword">const</span> offerNode = <a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>().<a class="code" href="classripple_1_1ApplyView.html#ade751364c7a9580032ef5988a953a6ee">dirInsert</a>(</div>
|
||||
<div class="line"><a name="l00203"></a><span class="lineno"> 203</span>  isSellOffer ? <a class="code" href="namespaceripple_1_1keylet.html#a7bdef766607c687f8d05c699c5fb478f">keylet::nft_sells</a>(nftokenID)</div>
|
||||
<div class="line"><a name="l00204"></a><span class="lineno"> 204</span>  : <a class="code" href="namespaceripple_1_1keylet.html#a46b3edff074ddb69e14bda5b00cf8e26">keylet::nft_buys</a>(nftokenID),</div>
|
||||
<div class="line"><a name="l00205"></a><span class="lineno"> 205</span>  offerID,</div>
|
||||
<div class="line"><a name="l00206"></a><span class="lineno"> 206</span>  [&nftokenID, isSellOffer](<a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr<SLE></a> <span class="keyword">const</span>& sle) {</div>
|
||||
<div class="line"><a name="l00207"></a><span class="lineno"> 207</span>  (*sle)[<a class="code" href="namespaceripple.html#ac1371098a8a7c1e1238290d0220dc941">sfFlags</a>] =</div>
|
||||
<div class="line"><a name="l00208"></a><span class="lineno"> 208</span>  isSellOffer ? <a class="code" href="namespaceripple.html#a4a9c7b33fef9015d6406302ef80b63c5a6ef34056b7b7b1d985b5f4609c4fa904">lsfNFTokenSellOffers</a> : <a class="code" href="namespaceripple.html#a4a9c7b33fef9015d6406302ef80b63c5a51e9a2085c035de4de06c8b462382556">lsfNFTokenBuyOffers</a>;</div>
|
||||
<div class="line"><a name="l00209"></a><span class="lineno"> 209</span>  (*sle)[<a class="code" href="namespaceripple.html#af4bc0178db9a613df9f7f1c7bf75a7eb">sfNFTokenID</a>] = nftokenID;</div>
|
||||
<div class="line"><a name="l00210"></a><span class="lineno"> 210</span>  });</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="keywordflow">if</span> (!offerNode)</div>
|
||||
<div class="line"><a name="l00213"></a><span class="lineno"> 213</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca4f19fdbc12c26412215f3477f70d5feb">tecDIR_FULL</a>;</div>
|
||||
<div class="line"><a name="l00214"></a><span class="lineno"> 214</span>  </div>
|
||||
<div class="line"><a name="l00215"></a><span class="lineno"> 215</span>  <a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a> sleFlags = 0;</div>
|
||||
<div class="line"><a name="l00216"></a><span class="lineno"> 216</span>  </div>
|
||||
<div class="line"><a name="l00217"></a><span class="lineno"> 217</span>  <span class="keywordflow">if</span> (isSellOffer)</div>
|
||||
<div class="line"><a name="l00218"></a><span class="lineno"> 218</span>  sleFlags |= <a class="code" href="namespaceripple.html#a4a9c7b33fef9015d6406302ef80b63c5af09cb8ad3ecf501d7149dad344aada65">lsfSellNFToken</a>;</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> offer = std::make_shared<SLE>(offerID);</div>
|
||||
<div class="line"><a name="l00221"></a><span class="lineno"> 221</span>  (*offer)[<a class="code" href="namespaceripple.html#a7e1ed9c5ea9eff7dd3046420f228399f">sfOwner</a>] = <a class="code" href="classripple_1_1Transactor.html#a558a1d4288c859eb5875154a86435220">account_</a>;</div>
|
||||
<div class="line"><a name="l00222"></a><span class="lineno"> 222</span>  (*offer)[<a class="code" href="namespaceripple.html#af4bc0178db9a613df9f7f1c7bf75a7eb">sfNFTokenID</a>] = nftokenID;</div>
|
||||
<div class="line"><a name="l00223"></a><span class="lineno"> 223</span>  (*offer)[<a class="code" href="namespaceripple.html#a29758397ce451beaa436c3a9dfc83030">sfAmount</a>] = <a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>[<a class="code" href="namespaceripple.html#a29758397ce451beaa436c3a9dfc83030">sfAmount</a>];</div>
|
||||
<div class="line"><a name="l00224"></a><span class="lineno"> 224</span>  (*offer)[<a class="code" href="namespaceripple.html#ac1371098a8a7c1e1238290d0220dc941">sfFlags</a>] = sleFlags;</div>
|
||||
<div class="line"><a name="l00225"></a><span class="lineno"> 225</span>  (*offer)[<a class="code" href="namespaceripple.html#a7038e25fafd9239c031a42b0f285ddf4">sfOwnerNode</a>] = *ownerNode;</div>
|
||||
<div class="line"><a name="l00226"></a><span class="lineno"> 226</span>  (*offer)[<a class="code" href="namespaceripple.html#aea272d209d40b7bd28de57ffd294f402">sfNFTokenOfferNode</a>] = *offerNode;</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="comment">// Update owner count.</span></div>
|
||||
<div class="line"><a name="l00229"></a><span class="lineno"> 229</span>  <a class="code" href="namespaceripple.html#a7e31af9d90dac8c9e4272bf597d83fb4">adjustOwnerCount</a>(<a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>(), <a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>().peek(<a class="code" href="namespaceripple_1_1keylet.html#a50c370db96b4fdcdd202d9c2c38afce9">keylet::account</a>(<a class="code" href="classripple_1_1Transactor.html#a558a1d4288c859eb5875154a86435220">account_</a>)), 1, <a class="code" href="classripple_1_1Transactor.html#aafdaa4e246ee6879df9cbbf2482dcc7d">j_</a>);</div>
|
||||
<div class="line"><a name="l00228"></a><span class="lineno"> 228</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> <span class="keyword">const</span> expiration = <a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>[~<a class="code" href="namespaceripple.html#ae3182ff3db5f7f67e4fe8bcd69316727">sfExpiration</a>])</div>
|
||||
<div class="line"><a name="l00229"></a><span class="lineno"> 229</span>  (*offer)[<a class="code" href="namespaceripple.html#ae3182ff3db5f7f67e4fe8bcd69316727">sfExpiration</a>] = *expiration;</div>
|
||||
<div class="line"><a name="l00230"></a><span class="lineno"> 230</span>  </div>
|
||||
<div class="line"><a name="l00231"></a><span class="lineno"> 231</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceripple.html#aabc7f150d5082c73116a1cd5962b434da28c7d8b3ed759d363503a05fcd59f151">tesSUCCESS</a>;</div>
|
||||
<div class="line"><a name="l00232"></a><span class="lineno"> 232</span> }</div>
|
||||
<div class="line"><a name="l00231"></a><span class="lineno"> 231</span>  <span class="keywordflow">if</span> (<span class="keyword">auto</span> <span class="keyword">const</span> destination = <a class="code" href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ctx_</a>.<a class="code" href="classripple_1_1ApplyContext.html#a8c8757b3b1f88baef47b31ed4e9682d0">tx</a>[~<a class="code" href="namespaceripple.html#a15aa3b3032d0908932dc5abf4b1ef862">sfDestination</a>])</div>
|
||||
<div class="line"><a name="l00232"></a><span class="lineno"> 232</span>  (*offer)[<a class="code" href="namespaceripple.html#a15aa3b3032d0908932dc5abf4b1ef862">sfDestination</a>] = *destination;</div>
|
||||
<div class="line"><a name="l00233"></a><span class="lineno"> 233</span>  </div>
|
||||
<div class="line"><a name="l00234"></a><span class="lineno"> 234</span> } <span class="comment">// namespace ripple</span></div>
|
||||
<div class="line"><a name="l00234"></a><span class="lineno"> 234</span>  <a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>().<a class="code" href="classripple_1_1ApplyView.html#aa3c5b5cd9dca5f906be4b36640706e3c">insert</a>(offer);</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>  <span class="comment">// Update owner count.</span></div>
|
||||
<div class="line"><a name="l00238"></a><span class="lineno"> 238</span>  <a class="code" href="namespaceripple.html#a7e31af9d90dac8c9e4272bf597d83fb4">adjustOwnerCount</a>(<a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>(), <a class="code" href="classripple_1_1Transactor.html#a1ac5d16d7b21e8af9cc94d7af39a85d5">view</a>().peek(<a class="code" href="namespaceripple_1_1keylet.html#a50c370db96b4fdcdd202d9c2c38afce9">keylet::account</a>(<a class="code" href="classripple_1_1Transactor.html#a558a1d4288c859eb5875154a86435220">account_</a>)), 1, <a class="code" href="classripple_1_1Transactor.html#aafdaa4e246ee6879df9cbbf2482dcc7d">j_</a>);</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> <a class="code" href="namespaceripple.html#aabc7f150d5082c73116a1cd5962b434da28c7d8b3ed759d363503a05fcd59f151">tesSUCCESS</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="comment">// namespace ripple</span></div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
<div class="ttc" id="anamespaceripple_html_aa298e929e02f59c2b05a30ee8805b38ca5d1f0daadc43667fc3775d53cd6e3420"><div class="ttname"><a href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca5d1f0daadc43667fc3775d53cd6e3420">ripple::tecUNFUNDED_OFFER</a></div><div class="ttdeci">@ tecUNFUNDED_OFFER</div><div class="ttdef"><b>Definition:</b> <a href="TER_8h_source.html#l00248">TER.h:248</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_1_1keylet_html_aa9b2ba2df3c3da4cecd1c07cccf7c7f9"><div class="ttname"><a href="namespaceripple_1_1keylet.html#aa9b2ba2df3c3da4cecd1c07cccf7c7f9">ripple::keylet::ownerDir</a></div><div class="ttdeci">Keylet ownerDir(AccountID const &id) noexcept</div><div class="ttdoc">The root page of an account's directory.</div><div class="ttdef"><b>Definition:</b> <a href="Indexes_8cpp_source.html#l00303">Indexes.cpp:303</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_aee6c41ec9be20b8705502ae9290ef2b0"><div class="ttname"><a href="namespaceripple.html#aee6c41ec9be20b8705502ae9290ef2b0">ripple::sfOwnerCount</a></div><div class="ttdeci">const SF_UINT32 sfOwnerCount</div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_aa298e929e02f59c2b05a30ee8805b38ca608da193a4a22ae1c78d76b6e843b7e6"><div class="ttname"><a href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca608da193a4a22ae1c78d76b6e843b7e6">ripple::tecFROZEN</a></div><div class="ttdeci">@ tecFROZEN</div><div class="ttdef"><b>Definition:</b> <a href="TER_8h_source.html#l00267">TER.h:267</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_a8b257ff89d14ac75ce240946f32d3773"><div class="ttname"><a href="namespaceripple.html#a8b257ff89d14ac75ce240946f32d3773">ripple::preflight2</a></div><div class="ttdeci">NotTEC preflight2(PreflightContext const &ctx)</div><div class="ttdoc">Checks whether the signature appears valid.</div><div class="ttdef"><b>Definition:</b> <a href="Transactor_8cpp_source.html#l00109">Transactor.cpp:109</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_a451091d6bfaf55f18f3bcdfe7df65acd"><div class="ttname"><a href="namespaceripple.html#a451091d6bfaf55f18f3bcdfe7df65acd">ripple::fixNFTokenNegOffer</a></div><div class="ttdeci">const uint256 fixNFTokenNegOffer</div></div>
|
||||
<div class="ttc" id="anamespaceripple_1_1nft_html_a1a5f9170a15fd6861ab81b1d021410cc"><div class="ttname"><a href="namespaceripple_1_1nft.html#a1a5f9170a15fd6861ab81b1d021410cc">ripple::nft::getFlags</a></div><div class="ttdeci">std::uint16_t getFlags(uint256 const &id)</div><div class="ttdef"><b>Definition:</b> <a href="NFTokenUtils_8h_source.html#l00116">NFTokenUtils.h:116</a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1Rules_html_a1a8388a2b9588aa9446ece92a88e0dd2"><div class="ttname"><a href="classripple_1_1Rules.html#a1a8388a2b9588aa9446ece92a88e0dd2">ripple::Rules::enabled</a></div><div class="ttdeci">bool enabled(uint256 const &feature) const</div><div class="ttdoc">Returns true if a feature is enabled.</div><div class="ttdef"><b>Definition:</b> <a href="Rules_8cpp_source.html#l00083">Rules.cpp:83</a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1Rules_html_a1a8388a2b9588aa9446ece92a88e0dd2"><div class="ttname"><a href="classripple_1_1Rules.html#a1a8388a2b9588aa9446ece92a88e0dd2">ripple::Rules::enabled</a></div><div class="ttdeci">bool enabled(uint256 const &feature) const</div><div class="ttdoc">Returns true if a feature is enabled.</div><div class="ttdef"><b>Definition:</b> <a href="Rules_8cpp_source.html#l00081">Rules.cpp:81</a></div></div>
|
||||
<div class="ttc" id="ashared_ptr_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr</a></div><div class="ttdoc">STL class.</div></div>
|
||||
<div class="ttc" id="astructripple_1_1PreclaimContext_html_a05d5cf6207c1127c25dcd7c3f763b9c5"><div class="ttname"><a href="structripple_1_1PreclaimContext.html#a05d5cf6207c1127c25dcd7c3f763b9c5">ripple::PreclaimContext::view</a></div><div class="ttdeci">ReadView const & view</div><div class="ttdef"><b>Definition:</b> <a href="Transactor_8h_source.html#l00056">Transactor.h:56</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_a7038e25fafd9239c031a42b0f285ddf4"><div class="ttname"><a href="namespaceripple.html#a7038e25fafd9239c031a42b0f285ddf4">ripple::sfOwnerNode</a></div><div class="ttdeci">const SF_UINT64 sfOwnerNode</div></div>
|
||||
<div class="ttc" id="astructripple_1_1PreclaimContext_html_a534551c8ca0dd7afc8fe9098bf9da780"><div class="ttname"><a href="structripple_1_1PreclaimContext.html#a534551c8ca0dd7afc8fe9098bf9da780">ripple::PreclaimContext::j</a></div><div class="ttdeci">const beast::Journal j</div><div class="ttdef"><b>Definition:</b> <a href="Transactor_8h_source.html#l00060">Transactor.h:60</a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1NFTokenCreateOffer_html_ae3a8099d64745a8988039fa07852cdbc"><div class="ttname"><a href="classripple_1_1NFTokenCreateOffer.html#ae3a8099d64745a8988039fa07852cdbc">ripple::NFTokenCreateOffer::doApply</a></div><div class="ttdeci">TER doApply() override</div><div class="ttdef"><b>Definition:</b> <a href="NFTokenCreateOffer_8cpp_source.html#l00169">NFTokenCreateOffer.cpp:169</a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1NFTokenCreateOffer_html_ae3a8099d64745a8988039fa07852cdbc"><div class="ttname"><a href="classripple_1_1NFTokenCreateOffer.html#ae3a8099d64745a8988039fa07852cdbc">ripple::NFTokenCreateOffer::doApply</a></div><div class="ttdeci">TER doApply() override</div><div class="ttdef"><b>Definition:</b> <a href="NFTokenCreateOffer_8cpp_source.html#l00178">NFTokenCreateOffer.cpp:178</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_a15aa3b3032d0908932dc5abf4b1ef862"><div class="ttname"><a href="namespaceripple.html#a15aa3b3032d0908932dc5abf4b1ef862">ripple::sfDestination</a></div><div class="ttdeci">const SF_ACCOUNT sfDestination</div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_a5b498122d9b8c1acbeb9fe459faac22b"><div class="ttname"><a href="namespaceripple.html#a5b498122d9b8c1acbeb9fe459faac22b">ripple::describeOwnerDir</a></div><div class="ttdeci">std::function< void(SLE::ref)> describeOwnerDir(AccountID const &account)</div><div class="ttdef"><b>Definition:</b> <a href="View_8cpp_source.html#l00731">View.cpp:731</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_a29758397ce451beaa436c3a9dfc83030"><div class="ttname"><a href="namespaceripple.html#a29758397ce451beaa436c3a9dfc83030">ripple::sfAmount</a></div><div class="ttdeci">const SF_AMOUNT sfAmount</div></div>
|
||||
@@ -330,7 +340,7 @@ $(function() {
|
||||
<div class="ttc" id="anamespaceripple_1_1nft_html_abf5771bfc2c9f62196dfe02b087b7b7c"><div class="ttname"><a href="namespaceripple_1_1nft.html#abf5771bfc2c9f62196dfe02b087b7b7c">ripple::nft::flagOnlyXRP</a></div><div class="ttdeci">constexpr const std::uint16_t flagOnlyXRP</div><div class="ttdef"><b>Definition:</b> <a href="NFTokenUtils_8h_source.html#l00052">NFTokenUtils.h:52</a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1STTx_html_a42464c41715a5d90dfa3240118d62d9c"><div class="ttname"><a href="classripple_1_1STTx.html#a42464c41715a5d90dfa3240118d62d9c">ripple::STTx::getSeqProxy</a></div><div class="ttdeci">SeqProxy getSeqProxy() const</div><div class="ttdef"><b>Definition:</b> <a href="STTx_8cpp_source.html#l00183">STTx.cpp:183</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_1_1nft_html_a85dc7006d747123fc93c4fac11678a62"><div class="ttname"><a href="namespaceripple_1_1nft.html#a85dc7006d747123fc93c4fac11678a62">ripple::nft::findToken</a></div><div class="ttdeci">std::optional< STObject > findToken(ReadView const &view, AccountID const &owner, uint256 const &nftokenID)</div><div class="ttdoc">Finds the specified token in the owner's token directory.</div><div class="ttdef"><b>Definition:</b> <a href="NFTokenUtils_8cpp_source.html#l00480">NFTokenUtils.cpp:480</a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1NFTokenCreateOffer_html_aed38ff6667eb8e6f03f02b3a304965bc"><div class="ttname"><a href="classripple_1_1NFTokenCreateOffer.html#aed38ff6667eb8e6f03f02b3a304965bc">ripple::NFTokenCreateOffer::preclaim</a></div><div class="ttdeci">static TER preclaim(PreclaimContext const &ctx)</div><div class="ttdef"><b>Definition:</b> <a href="NFTokenCreateOffer_8cpp_source.html#l00095">NFTokenCreateOffer.cpp:95</a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1NFTokenCreateOffer_html_aed38ff6667eb8e6f03f02b3a304965bc"><div class="ttname"><a href="classripple_1_1NFTokenCreateOffer.html#aed38ff6667eb8e6f03f02b3a304965bc">ripple::NFTokenCreateOffer::preclaim</a></div><div class="ttdeci">static TER preclaim(PreclaimContext const &ctx)</div><div class="ttdef"><b>Definition:</b> <a href="NFTokenCreateOffer_8cpp_source.html#l00104">NFTokenCreateOffer.cpp:104</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_aea272d209d40b7bd28de57ffd294f402"><div class="ttname"><a href="namespaceripple.html#aea272d209d40b7bd28de57ffd294f402">ripple::sfNFTokenOfferNode</a></div><div class="ttdeci">const SF_UINT64 sfNFTokenOfferNode</div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_a5dfb437ade69624474bbe4125ceb791a"><div class="ttname"><a href="namespaceripple.html#a5dfb437ade69624474bbe4125ceb791a">ripple::preflight1</a></div><div class="ttdeci">NotTEC preflight1(PreflightContext const &ctx)</div><div class="ttdoc">Performs early sanity checks on the account and fee fields.</div><div class="ttdef"><b>Definition:</b> <a href="Transactor_8cpp_source.html#l00057">Transactor.cpp:57</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_a4a9c7b33fef9015d6406302ef80b63c5af09cb8ad3ecf501d7149dad344aada65"><div class="ttname"><a href="namespaceripple.html#a4a9c7b33fef9015d6406302ef80b63c5af09cb8ad3ecf501d7149dad344aada65">ripple::lsfSellNFToken</a></div><div class="ttdeci">@ lsfSellNFToken</div><div class="ttdef"><b>Definition:</b> <a href="LedgerFormats_8h_source.html#l00258">LedgerFormats.h:258</a></div></div>
|
||||
@@ -343,6 +353,7 @@ $(function() {
|
||||
<div class="ttc" id="anamespaceripple_html_a85870fe5e629b0a50482d1bb68bb8028"><div class="ttname"><a href="namespaceripple.html#a85870fe5e629b0a50482d1bb68bb8028">ripple::sfNFTokenMinter</a></div><div class="ttdeci">const SF_ACCOUNT sfNFTokenMinter</div></div>
|
||||
<div class="ttc" id="aclassripple_1_1TERSubset_html"><div class="ttname"><a href="classripple_1_1TERSubset.html">ripple::TERSubset< CanCvtToTER ></a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1NFTokenCreateOffer_html_a7fdbd44d81f8182ae726183bf6120ca4"><div class="ttname"><a href="classripple_1_1NFTokenCreateOffer.html#a7fdbd44d81f8182ae726183bf6120ca4">ripple::NFTokenCreateOffer::preflight</a></div><div class="ttdeci">static NotTEC preflight(PreflightContext const &ctx)</div><div class="ttdef"><b>Definition:</b> <a href="NFTokenCreateOffer_8cpp_source.html#l00031">NFTokenCreateOffer.cpp:31</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#l00044">STAmount.h:44</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_1_1keylet_html_a7bdef766607c687f8d05c699c5fb478f"><div class="ttname"><a href="namespaceripple_1_1keylet.html#a7bdef766607c687f8d05c699c5fb478f">ripple::keylet::nft_sells</a></div><div class="ttdeci">Keylet nft_sells(uint256 const &id) noexcept</div><div class="ttdoc">The directory of sell offers for the specified NFT.</div><div class="ttdef"><b>Definition:</b> <a href="Indexes_8cpp_source.html#l00368">Indexes.cpp:368</a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1ReadView_html_ac1d377c35a8332d069b09be8f4008dec"><div class="ttname"><a href="classripple_1_1ReadView.html#ac1d377c35a8332d069b09be8f4008dec">ripple::ReadView::exists</a></div><div class="ttdeci">virtual bool exists(Keylet const &k) const =0</div><div class="ttdoc">Determine if a state item exists.</div></div>
|
||||
<div class="ttc" id="aclassripple_1_1STObject_html_af5aa57043ec772da30341e3c3b823d7f"><div class="ttname"><a href="classripple_1_1STObject.html#af5aa57043ec772da30341e3c3b823d7f">ripple::STObject::getFlags</a></div><div class="ttdeci">std::uint32_t getFlags() const</div><div class="ttdef"><b>Definition:</b> <a href="STObject_8cpp_source.html#l00481">STObject.cpp:481</a></div></div>
|
||||
@@ -370,6 +381,7 @@ $(function() {
|
||||
<div class="ttc" id="anamespaceripple_html_a78dc838b5e33bb42b127e594138d00c3"><div class="ttname"><a href="namespaceripple.html#a78dc838b5e33bb42b127e594138d00c3">ripple::tfNFTokenCreateOfferMask</a></div><div class="ttdeci">constexpr const std::uint32_t tfNFTokenCreateOfferMask</div><div class="ttdef"><b>Definition:</b> <a href="TxFlags_8h_source.html#l00128">TxFlags.h:128</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_aa298e929e02f59c2b05a30ee8805b38ca33d363e51ee15c8bd4f5d7c4e4518def"><div class="ttname"><a href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38ca33d363e51ee15c8bd4f5d7c4e4518def">ripple::tecNO_ISSUER</a></div><div class="ttdeci">@ tecNO_ISSUER</div><div class="ttdef"><b>Definition:</b> <a href="TER_8h_source.html#l00263">TER.h:263</a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1Transactor_html_abb2f6f5d7fd8c663c5df76b6fcba2c49"><div class="ttname"><a href="classripple_1_1Transactor.html#abb2f6f5d7fd8c663c5df76b6fcba2c49">ripple::Transactor::mPriorBalance</a></div><div class="ttdeci">XRPAmount mPriorBalance</div><div class="ttdef"><b>Definition:</b> <a href="Transactor_8h_source.html#l00092">Transactor.h:92</a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1STAmount_html_aa830654962840253139aa891659f7551"><div class="ttname"><a href="classripple_1_1STAmount.html#aa830654962840253139aa891659f7551">ripple::STAmount::negative</a></div><div class="ttdeci">bool negative() const noexcept</div><div class="ttdef"><b>Definition:</b> <a href="STAmount_8h_source.html#l00327">STAmount.h:327</a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1STObject_html_a40025a423b41e20dd78cb2627e17d678"><div class="ttname"><a href="classripple_1_1STObject.html#a40025a423b41e20dd78cb2627e17d678">ripple::STObject::isFlag</a></div><div class="ttdeci">bool isFlag(std::uint32_t) const</div><div class="ttdef"><b>Definition:</b> <a href="STObject_8cpp_source.html#l00475">STObject.cpp:475</a></div></div>
|
||||
<div class="ttc" id="anamespaceripple_html_aa298e929e02f59c2b05a30ee8805b38cae930fb228ae74317976b57b4e87a7f0d"><div class="ttname"><a href="namespaceripple.html#aa298e929e02f59c2b05a30ee8805b38cae930fb228ae74317976b57b4e87a7f0d">ripple::tecINSUFFICIENT_RESERVE</a></div><div class="ttdeci">@ tecINSUFFICIENT_RESERVE</div><div class="ttdef"><b>Definition:</b> <a href="TER_8h_source.html#l00271">TER.h:271</a></div></div>
|
||||
<div class="ttc" id="aclassripple_1_1Transactor_html_aef4ef0a89b5595b2a688b89e4ecef833"><div class="ttname"><a href="classripple_1_1Transactor.html#aef4ef0a89b5595b2a688b89e4ecef833">ripple::Transactor::ctx_</a></div><div class="ttdeci">ApplyContext & ctx_</div><div class="ttdef"><b>Definition:</b> <a href="Transactor_8h_source.html#l00088">Transactor.h:88</a></div></div>
|
||||
|
||||
Reference in New Issue
Block a user