Files
rippled/classJson_1_1Compact.html
2025-03-11 18:21:06 +00:00

227 lines
11 KiB
HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.9.5"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>rippled: Json::Compact Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr id="projectrow">
<td id="projectalign">
<div id="projectname">rippled
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.5 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search/",'.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
/* @license-end */
</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<div id="MSearchResults">
<div class="SRPage">
<div id="SRIndex">
<div id="SRResults"></div>
<div class="SRStatus" id="Loading">Loading...</div>
<div class="SRStatus" id="Searching">Searching...</div>
<div class="SRStatus" id="NoMatches">No Matches</div>
</div>
</div>
</div>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="namespaceJson.html">Json</a></li><li class="navelem"><a class="el" href="classJson_1_1Compact.html">Compact</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a> &#124;
<a href="#friends">Friends</a> &#124;
<a href="classJson_1_1Compact-members.html">List of all members</a> </div>
<div class="headertitle"><div class="title">Json::Compact Class Reference</div></div>
</div><!--header-->
<div class="contents">
<p>Decorator for streaming out compact json.
<a href="classJson_1_1Compact.html#details">More...</a></p>
<p><code>#include &lt;<a class="el" href="json__writer_8h_source.html">json_writer.h</a>&gt;</code></p>
<div class="dynheader">
Collaboration diagram for Json::Compact:</div>
<div class="dyncontent">
<div class="center"><img src="classJson_1_1Compact__coll__graph.png" border="0" usemap="#aJson_1_1Compact_coll__map" alt="Collaboration graph"/></div>
<map name="aJson_1_1Compact_coll__map" id="aJson_1_1Compact_coll__map">
<area shape="rect" title="Decorator for streaming out compact json." alt="" coords="38,357,153,383"/>
<area shape="rect" href="classJson_1_1Value.html" title="Represents a JSON value." alt="" coords="49,269,142,295"/>
<area shape="rect" href="unionJson_1_1Value_1_1ValueHolder.html" title=" " alt="" coords="5,181,185,207"/>
<area shape="rect" target="_parent" href="http://en.cppreference.com/w/cpp/container/map.html" title=" " alt="" coords="28,93,163,119"/>
<area shape="rect" title=" " alt="" coords="44,5,83,31"/>
<area shape="rect" title=" " alt="" coords="109,5,148,31"/>
</map>
<center><span class="legend">[<a href="graph_legend.html">legend</a>]</span></center></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-methods" name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a85bd6b6bc58576239cbf3691ccf91c94"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classJson_1_1Compact.html#a85bd6b6bc58576239cbf3691ccf91c94">Compact</a> (<a class="el" href="classJson_1_1Value.html">Json::Value</a> &amp;&amp;jv)</td></tr>
<tr class="memdesc:a85bd6b6bc58576239cbf3691ccf91c94"><td class="mdescLeft">&#160;</td><td class="mdescRight">Wrap a <a class="el" href="classJson_1_1Value.html" title="Represents a JSON value.">Json::Value</a> for compact streaming. <a href="classJson_1_1Compact.html#a85bd6b6bc58576239cbf3691ccf91c94">More...</a><br /></td></tr>
<tr class="separator:a85bd6b6bc58576239cbf3691ccf91c94"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pri-attribs" name="pri-attribs"></a>
Private Attributes</h2></td></tr>
<tr class="memitem:ad1bc8ca5b4c71f54c37872f959a9e5e2"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classJson_1_1Value.html">Json::Value</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classJson_1_1Compact.html#ad1bc8ca5b4c71f54c37872f959a9e5e2">jv_</a></td></tr>
<tr class="separator:ad1bc8ca5b4c71f54c37872f959a9e5e2"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="friends" name="friends"></a>
Friends</h2></td></tr>
<tr class="memitem:aa932546c50fa3a54acbc726522a7f756"><td class="memItemLeft" align="right" valign="top"><a class="elRef" href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::ostream</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classJson_1_1Compact.html#aa932546c50fa3a54acbc726522a7f756">operator&lt;&lt;</a> (<a class="elRef" href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::ostream</a> &amp;o, <a class="el" href="classJson_1_1Compact.html">Compact</a> const &amp;cJv)</td></tr>
<tr class="separator:aa932546c50fa3a54acbc726522a7f756"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p >Decorator for streaming out compact json. </p>
<p >Use </p><pre class="fragment">Json::Value jv;
out &lt;&lt; Json::Compact{jv}
</pre><p> to write a single-line, compact version of <code>jv</code> to the stream, rather than the styled format that comes from undecorated streaming. </p>
<p class="definition">Definition at line <a class="el" href="json__writer_8h_source.html#l00317">317</a> of file <a class="el" href="json__writer_8h_source.html">json_writer.h</a>.</p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="a85bd6b6bc58576239cbf3691ccf91c94" name="a85bd6b6bc58576239cbf3691ccf91c94"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a85bd6b6bc58576239cbf3691ccf91c94">&#9670;&#160;</a></span>Compact()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">Json::Compact::Compact </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classJson_1_1Value.html">Json::Value</a> &amp;&amp;&#160;</td>
<td class="paramname"><em>jv</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Wrap a <a class="el" href="classJson_1_1Value.html" title="Represents a JSON value.">Json::Value</a> for compact streaming. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">jv</td><td>The <a class="el" href="classJson_1_1Value.html" title="Represents a JSON value.">Json::Value</a> to stream</td></tr>
</table>
</dd>
</dl>
<dl class="section note"><dt>Note</dt><dd>For now, we do not support wrapping lvalues to avoid potentially costly copies. If we find a need, we can consider adding support for compact lvalue streaming in the future. </dd></dl>
<p class="definition">Definition at line <a class="el" href="json__writer_8h_source.html#l00330">330</a> of file <a class="el" href="json__writer_8h_source.html">json_writer.h</a>.</p>
</div>
</div>
<h2 class="groupheader">Friends And Related Function Documentation</h2>
<a id="aa932546c50fa3a54acbc726522a7f756" name="aa932546c50fa3a54acbc726522a7f756"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa932546c50fa3a54acbc726522a7f756">&#9670;&#160;</a></span>operator&lt;&lt;</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="elRef" href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::ostream</a> &amp; operator&lt;&lt; </td>
<td>(</td>
<td class="paramtype"><a class="elRef" href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::ostream</a> &amp;&#160;</td>
<td class="paramname"><em>o</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="classJson_1_1Compact.html">Compact</a> const &amp;&#160;</td>
<td class="paramname"><em>cJv</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">friend</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p class="definition">Definition at line <a class="el" href="json__writer_8h_source.html#l00334">334</a> of file <a class="el" href="json__writer_8h_source.html">json_writer.h</a>.</p>
</div>
</div>
<h2 class="groupheader">Member Data Documentation</h2>
<a id="ad1bc8ca5b4c71f54c37872f959a9e5e2" name="ad1bc8ca5b4c71f54c37872f959a9e5e2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad1bc8ca5b4c71f54c37872f959a9e5e2">&#9670;&#160;</a></span>jv_</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classJson_1_1Value.html">Json::Value</a> Json::Compact::jv_</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p class="definition">Definition at line <a class="el" href="json__writer_8h_source.html#l00319">319</a> of file <a class="el" href="json__writer_8h_source.html">json_writer.h</a>.</p>
</div>
</div>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.5
</small></address>
</body>
</html>