autodoc.xml 75 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710
  1. <?xml version="1.0" standalone="yes"?>
  2. <library-reference><header name="boost/property_tree/exceptions.hpp">
  3. <namespace name="boost">
  4. <namespace name="property_tree">
  5. <class name="ptree_bad_data"><inherit access="public">boost::property_tree::ptree_error</inherit><purpose>Error indicating that translation from given value to the property tree data_type (or vice versa) failed. Derives from <classname alt="boost::property_tree::ptree_error">ptree_error</classname>. </purpose><method-group name="public member functions">
  6. <method name="data" cv="const"><type>T</type><template>
  7. <template-type-parameter name="T"/>
  8. </template><purpose>Retrieve the data associated with this error. This is the source value that failed to be translated. You need to explicitly specify its type. </purpose></method>
  9. </method-group>
  10. <constructor><template>
  11. <template-type-parameter name="T"/>
  12. </template><parameter name="what"><paramtype>const std::string &amp;</paramtype><description><para>The message to associate with this error. </para></description></parameter><parameter name="data"><paramtype>const T &amp;</paramtype><description><para>The value associated with this error that was the source of the translation failure. </para></description></parameter><purpose>Instantiate a <classname alt="boost::property_tree::ptree_bad_data">ptree_bad_data</classname> instance with the given message and data. </purpose><description><para>
  13. </para></description></constructor>
  14. <destructor/>
  15. </class><class name="ptree_bad_path"><inherit access="public">boost::property_tree::ptree_error</inherit><purpose>Error indicating that specified path does not exist. Derives from <classname alt="boost::property_tree::ptree_error">ptree_error</classname>. </purpose><method-group name="public member functions">
  16. <method name="path" cv="const"><type>T</type><template>
  17. <template-type-parameter name="T"/>
  18. </template><purpose>Retrieve the invalid path. You need to explicitly specify the type of path. </purpose></method>
  19. </method-group>
  20. <constructor><template>
  21. <template-type-parameter name="T"/>
  22. </template><parameter name="what"><paramtype>const std::string &amp;</paramtype><description><para>The message to associate with this error. </para></description></parameter><parameter name="path"><paramtype>const T &amp;</paramtype><description><para>The path that could not be found in the property_tree. </para></description></parameter><purpose>Instantiate a <classname alt="boost::property_tree::ptree_bad_path">ptree_bad_path</classname> with the given message and path data. </purpose><description><para>
  23. </para></description></constructor>
  24. <destructor/>
  25. </class><class name="ptree_error"><inherit access="public">runtime_error</inherit><purpose>Base class for all property tree errors. Derives from <computeroutput>std::runtime_error</computeroutput>. Call member function <computeroutput>what</computeroutput> to get human readable message associated with the error. </purpose><method-group name="public member functions">
  26. </method-group>
  27. <constructor><parameter name="what"><paramtype>const std::string &amp;</paramtype><description><para>The message to associate with this error. </para></description></parameter><purpose>Instantiate a <classname alt="boost::property_tree::ptree_error">ptree_error</classname> instance with the given message. </purpose><description><para>
  28. </para></description></constructor>
  29. <destructor/>
  30. </class>
  31. </namespace>
  32. </namespace>
  33. </header>
  34. <header name="boost/property_tree/id_translator.hpp">
  35. <namespace name="boost">
  36. <namespace name="property_tree">
  37. <struct-specialization name="translator_between"><template>
  38. <template-type-parameter name="Ch"/>
  39. <template-type-parameter name="Traits"/>
  40. <template-type-parameter name="Alloc"/>
  41. </template><specialization><template-arg>std::basic_string&lt; Ch</template-arg><template-arg>Traits</template-arg><template-arg>Alloc &gt;</template-arg><template-arg>std::basic_string&lt; Ch</template-arg><template-arg>Traits</template-arg><template-arg>Alloc &gt;</template-arg></specialization><typedef name="type"><type><classname>id_translator</classname>&lt; std::basic_string&lt; Ch, Traits, Alloc &gt; &gt;</type></typedef>
  42. </struct-specialization><struct-specialization name="translator_between"><template>
  43. <template-type-parameter name="T"/>
  44. </template><specialization><template-arg>T</template-arg><template-arg>T</template-arg></specialization><typedef name="type"><type><classname>id_translator</classname>&lt; T &gt;</type></typedef>
  45. </struct-specialization>
  46. </namespace>
  47. </namespace>
  48. </header>
  49. <header name="boost/property_tree/info_parser.hpp">
  50. <namespace name="boost">
  51. <namespace name="property_tree">
  52. <namespace name="info_parser">
  53. <function name="read_info"><type>void</type><template>
  54. <template-type-parameter name="Ptree"/>
  55. <template-type-parameter name="Ch"/>
  56. </template><parameter name="stream"><paramtype>std::basic_istream&lt; Ch &gt; &amp;</paramtype></parameter><parameter name="pt"><paramtype>Ptree &amp;</paramtype></parameter><description><para>Read INFO from a the given stream and translate it to a property tree. <note><para>Replaces the existing contents. Strong exception guarantee. </para>
  57. </note>
  58. </para></description><throws><simpara><classname>info_parser_error</classname> If the stream cannot be read, doesn't contain valid INFO, or a conversion fails. </simpara></throws></function>
  59. <function name="read_info"><type>void</type><template>
  60. <template-type-parameter name="Ptree"/>
  61. <template-type-parameter name="Ch"/>
  62. </template><parameter name="stream"><paramtype>std::basic_istream&lt; Ch &gt; &amp;</paramtype></parameter><parameter name="pt"><paramtype>Ptree &amp;</paramtype></parameter><parameter name="default_ptree"><paramtype>const Ptree &amp;</paramtype><description><para>If parsing fails, pt is set to a copy of this tree. </para></description></parameter><description><para>Read INFO from a the given stream and translate it to a property tree. <note><para>Replaces the existing contents. Strong exception guarantee. </para>
  63. </note>
  64. </para></description></function>
  65. <function name="read_info"><type>void</type><template>
  66. <template-type-parameter name="Ptree"/>
  67. </template><parameter name="filename"><paramtype>const std::string &amp;</paramtype></parameter><parameter name="pt"><paramtype>Ptree &amp;</paramtype></parameter><parameter name="loc"><paramtype>const std::locale &amp;</paramtype><default>std::locale()</default></parameter><description><para>Read INFO from a the given file and translate it to a property tree. The tree's key type must be a string type, i.e. it must have a nested value_type typedef that is a valid parameter for basic_ifstream. <note><para>Replaces the existing contents. Strong exception guarantee. </para>
  68. </note>
  69. </para></description><throws><simpara><classname>info_parser_error</classname> If the file cannot be read, doesn't contain valid INFO, or a conversion fails. </simpara></throws></function>
  70. <function name="read_info"><type>void</type><template>
  71. <template-type-parameter name="Ptree"/>
  72. </template><parameter name="filename"><paramtype>const std::string &amp;</paramtype></parameter><parameter name="pt"><paramtype>Ptree &amp;</paramtype></parameter><parameter name="default_ptree"><paramtype>const Ptree &amp;</paramtype><description><para>If parsing fails, pt is set to a copy of this tree. </para></description></parameter><parameter name="loc"><paramtype>const std::locale &amp;</paramtype><default>std::locale()</default></parameter><description><para>Read INFO from a the given file and translate it to a property tree. The tree's key type must be a string type, i.e. it must have a nested value_type typedef that is a valid parameter for basic_ifstream. <note><para>Replaces the existing contents. Strong exception guarantee. </para>
  73. </note>
  74. </para></description></function>
  75. <function name="write_info"><type>void</type><template>
  76. <template-type-parameter name="Ptree"/>
  77. <template-type-parameter name="Ch"/>
  78. </template><parameter name="stream"><paramtype>std::basic_ostream&lt; Ch &gt; &amp;</paramtype></parameter><parameter name="pt"><paramtype>const Ptree &amp;</paramtype></parameter><parameter name="settings"><paramtype>const info_writer_settings&lt; Ch &gt; &amp;</paramtype><default>info_writer_settings&lt; Ch &gt;()</default><description><para>The settings to use when writing the INFO data. </para></description></parameter><description><para>Writes a tree to the stream in INFO format.
  79. </para></description><throws><simpara><classname>info_parser_error</classname> If the stream cannot be written to, or a conversion fails. </simpara></throws></function>
  80. <function name="write_info"><type>void</type><template>
  81. <template-type-parameter name="Ptree"/>
  82. </template><parameter name="filename"><paramtype>const std::string &amp;</paramtype></parameter><parameter name="pt"><paramtype>const Ptree &amp;</paramtype></parameter><parameter name="loc"><paramtype>const std::locale &amp;</paramtype><default>std::locale()</default></parameter><parameter name="settings"><paramtype>const info_writer_settings&lt; typename Ptree::key_type::value_type &gt; &amp;</paramtype><default>info_writer_make_settings&lt; typename Ptree::key_type::value_type &gt;()</default><description><para>The settings to use when writing the INFO data. </para></description></parameter><description><para>Writes a tree to the file in INFO format. The tree's key type must be a string type, i.e. it must have a nested value_type typedef that is a valid parameter for basic_ofstream.
  83. </para></description><throws><simpara><classname>info_parser_error</classname> If the file cannot be written to, or a conversion fails. </simpara></throws></function>
  84. </namespace>
  85. </namespace>
  86. </namespace>
  87. </header>
  88. <header name="boost/property_tree/ini_parser.hpp">
  89. <namespace name="boost">
  90. <namespace name="property_tree">
  91. <namespace name="ini_parser">
  92. <class name="ini_parser_error"><inherit access="public">file_parser_error</inherit><description><para>Indicates an error parsing INI formatted data. </para></description><method-group name="public member functions">
  93. </method-group>
  94. <constructor><parameter name="message"><paramtype>const std::string &amp;</paramtype><description><para>Message describing the parser error. </para></description></parameter><parameter name="filename"><paramtype>const std::string &amp;</paramtype><description><para>The name of the file being parsed containing the error. </para></description></parameter><parameter name="line"><paramtype>unsigned long</paramtype><description><para>The line in the given file where an error was encountered. </para></description></parameter><description><para>Construct an <computeroutput><classname alt="boost::property_tree::ini_parser::ini_parser_error">ini_parser_error</classname></computeroutput>
  95. </para></description></constructor>
  96. </class><function name="validate_flags"><type>bool</type><parameter name="flags"><paramtype>int</paramtype><description><para>value to check for validity as flags to ini_parser. </para></description></parameter><description><para>Determines whether the <computeroutput>flags</computeroutput> are valid for use with the ini_parser.
  97. </para></description><returns><para>true if the flags are valid, false otherwise. </para>
  98. </returns></function>
  99. <function name="read_ini"><type>void</type><template>
  100. <template-type-parameter name="Ptree"/>
  101. </template><parameter name="stream"><paramtype>std::basic_istream&lt; typename Ptree::key_type::value_type &gt; &amp;</paramtype><description><para>Stream from which to read in the property tree. </para></description></parameter><parameter name="pt"><paramtype>Ptree &amp;</paramtype><description><para>The property tree to populate. </para></description></parameter><description><para>Read INI from a the given stream and translate it to a property tree. <note><para>Clears existing contents of property tree. In case of error the property tree is not modified. </para>
  102. </note>
  103. </para></description><throws><simpara><classname>ini_parser_error</classname> If a format violation is found. </simpara></throws></function>
  104. <function name="read_ini"><type>void</type><template>
  105. <template-type-parameter name="Ptree"/>
  106. </template><parameter name="filename"><paramtype>const std::string &amp;</paramtype><description><para>Name of file from which to read in the property tree. </para></description></parameter><parameter name="pt"><paramtype>Ptree &amp;</paramtype><description><para>The property tree to populate. </para></description></parameter><parameter name="loc"><paramtype>const std::locale &amp;</paramtype><default>std::locale()</default><description><para>The locale to use when reading in the file contents. </para></description></parameter><description><para>Read INI from a the given file and translate it to a property tree. <note><para>Clears existing contents of property tree. In case of error the property tree unmodified. </para>
  107. </note>
  108. </para></description><throws><simpara><classname>ini_parser_error</classname> In case of error deserializing the property tree. </simpara></throws></function>
  109. <function name="write_ini"><type>void</type><template>
  110. <template-type-parameter name="Ptree"/>
  111. </template><parameter name="stream"><paramtype>std::basic_ostream&lt; typename Ptree::key_type::value_type &gt; &amp;</paramtype><description><para>The stream to which to write the INI representation of the property tree. </para></description></parameter><parameter name="pt"><paramtype>const Ptree &amp;</paramtype><description><para>The property tree to tranlsate to INI and output. </para></description></parameter><parameter name="flags"><paramtype>int</paramtype><default>0</default><description><para>The flags to use when writing the INI file. No flags are currently supported. </para></description></parameter><description><para>Translates the property tree to INI and writes it the given output stream.
  112. </para></description><requires><para><emphasis>pt</emphasis> cannot have data in its root. </para>
  113. </requires><requires><para><emphasis>pt</emphasis> cannot have keys both data and children. </para>
  114. </requires><requires><para><emphasis>pt</emphasis> cannot be deeper than two levels. </para>
  115. </requires><requires><para>There cannot be duplicate keys on any given level of <emphasis>pt</emphasis>. </para>
  116. </requires><throws><simpara><classname>ini_parser_error</classname> In case of error translating the property tree to INI or writing to the output stream. </simpara></throws></function>
  117. <function name="write_ini"><type>void</type><template>
  118. <template-type-parameter name="Ptree"/>
  119. </template><parameter name="filename"><paramtype>const std::string &amp;</paramtype><description><para>The name of the file to which to write the INI representation of the property tree. </para></description></parameter><parameter name="pt"><paramtype>const Ptree &amp;</paramtype><description><para>The property tree to tranlsate to INI and output. </para></description></parameter><parameter name="flags"><paramtype>int</paramtype><default>0</default><description><para>The flags to use when writing the INI file. The following flags are supported: <itemizedlist>
  120. <listitem><para><computeroutput>skip_ini_validity_check</computeroutput> – Skip check if ptree is a valid ini. The validity check covers the preconditions but takes <computeroutput>O(n log n)</computeroutput> time. </para>
  121. </listitem>
  122. </itemizedlist>
  123. </para></description></parameter><parameter name="loc"><paramtype>const std::locale &amp;</paramtype><default>std::locale()</default><description><para>The locale to use when writing the file. </para></description></parameter><description><para>Translates the property tree to INI and writes it the given file.
  124. </para></description><requires><para><emphasis>pt</emphasis> cannot have data in its root. </para>
  125. </requires><requires><para><emphasis>pt</emphasis> cannot have keys both data and children. </para>
  126. </requires><requires><para><emphasis>pt</emphasis> cannot be deeper than two levels. </para>
  127. </requires><requires><para>There cannot be duplicate keys on any given level of <emphasis>pt</emphasis>. </para>
  128. </requires><throws><simpara><classname>info_parser_error</classname> In case of error translating the property tree to INI or writing to the file. </simpara></throws></function>
  129. </namespace>
  130. </namespace>
  131. </namespace>
  132. </header>
  133. <header name="boost/property_tree/json_parser.hpp">
  134. <namespace name="boost">
  135. <namespace name="property_tree">
  136. <namespace name="json_parser">
  137. <function name="read_json"><type>void</type><template>
  138. <template-type-parameter name="Ptree"/>
  139. </template><parameter name="stream"><paramtype>std::basic_istream&lt; typename Ptree::key_type::value_type &gt; &amp;</paramtype><description><para>Stream from which to read in the property tree. </para></description></parameter><parameter name="pt"><paramtype>Ptree &amp;</paramtype><description><para>The property tree to populate. </para></description></parameter><description><para>Read JSON from a the given stream and translate it to a property tree. <note><para>Clears existing contents of property tree. In case of error the property tree unmodified. </para>
  140. </note>
  141. <note><para>Items of JSON arrays are translated into ptree keys with empty names. Members of objects are translated into named keys. </para>
  142. </note>
  143. <note><para>JSON data can be a string, a numeric value, or one of literals "null", "true" and "false". During parse, any of the above is copied verbatim into ptree data string. </para>
  144. </note>
  145. </para></description><throws><simpara><classname>json_parser_error</classname> In case of error deserializing the property tree. </simpara></throws></function>
  146. <function name="read_json"><type>void</type><template>
  147. <template-type-parameter name="Ptree"/>
  148. </template><parameter name="filename"><paramtype>const std::string &amp;</paramtype><description><para>Name of file from which to read in the property tree. </para></description></parameter><parameter name="pt"><paramtype>Ptree &amp;</paramtype><description><para>The property tree to populate. </para></description></parameter><parameter name="loc"><paramtype>const std::locale &amp;</paramtype><default>std::locale()</default><description><para>The locale to use when reading in the file contents. </para></description></parameter><description><para>Read JSON from a the given file and translate it to a property tree. <note><para>Clears existing contents of property tree. In case of error the property tree unmodified. </para>
  149. </note>
  150. <note><para>Items of JSON arrays are translated into ptree keys with empty names. Members of objects are translated into named keys. </para>
  151. </note>
  152. <note><para>JSON data can be a string, a numeric value, or one of literals "null", "true" and "false". During parse, any of the above is copied verbatim into ptree data string. </para>
  153. </note>
  154. </para></description><throws><simpara><classname>json_parser_error</classname> In case of error deserializing the property tree. </simpara></throws></function>
  155. <function name="write_json"><type>void</type><template>
  156. <template-type-parameter name="Ptree"/>
  157. </template><parameter name="stream"><paramtype>std::basic_ostream&lt; typename Ptree::key_type::value_type &gt; &amp;</paramtype><description><para>The stream to which to write the JSON representation of the property tree. </para></description></parameter><parameter name="pt"><paramtype>const Ptree &amp;</paramtype><description><para>The property tree to tranlsate to JSON and output. </para></description></parameter><parameter name="pretty"><paramtype>bool</paramtype><default>true</default><description><para>Whether to pretty-print. Defaults to true for backward compatibility. </para></description></parameter><description><para>Translates the property tree to JSON and writes it the given output stream. <note><para>Any property tree key containing only unnamed subkeys will be rendered as JSON arrays. </para>
  158. </note>
  159. </para></description><requires><para><emphasis>pt</emphasis> cannot contain keys that have both subkeys and non-empty data. </para>
  160. </requires><throws><simpara><classname>json_parser_error</classname> In case of error translating the property tree to JSON or writing to the output stream. </simpara></throws></function>
  161. <function name="write_json"><type>void</type><template>
  162. <template-type-parameter name="Ptree"/>
  163. </template><parameter name="filename"><paramtype>const std::string &amp;</paramtype><description><para>The name of the file to which to write the JSON representation of the property tree. </para></description></parameter><parameter name="pt"><paramtype>const Ptree &amp;</paramtype><description><para>The property tree to translate to JSON and output. </para></description></parameter><parameter name="loc"><paramtype>const std::locale &amp;</paramtype><default>std::locale()</default><description><para>The locale to use when writing out to the output file. </para></description></parameter><parameter name="pretty"><paramtype>bool</paramtype><default>true</default><description><para>Whether to pretty-print. Defaults to true and last place for backward compatibility. </para></description></parameter><description><para>Translates the property tree to JSON and writes it the given file. <note><para>Any property tree key containing only unnamed subkeys will be rendered as JSON arrays. </para>
  164. </note>
  165. </para></description><requires><para><emphasis>pt</emphasis> cannot contain keys that have both subkeys and non-empty data. </para>
  166. </requires><throws><simpara><classname>json_parser_error</classname> In case of error translating the property tree to JSON or writing to the file. </simpara></throws></function>
  167. </namespace>
  168. </namespace>
  169. </namespace>
  170. </header>
  171. <header name="boost/property_tree/ptree.hpp">
  172. <namespace name="boost">
  173. <namespace name="property_tree">
  174. </namespace>
  175. </namespace>
  176. </header>
  177. <header name="boost/property_tree/ptree_fwd.hpp">
  178. <namespace name="boost">
  179. <namespace name="property_tree">
  180. <class name="basic_ptree"><template>
  181. <template-type-parameter name="Key"/>
  182. <template-type-parameter name="Data"/>
  183. <template-type-parameter name="KeyCompare"/>
  184. </template><description><para>Property tree main structure. A property tree is a hierarchical data structure which has one element of type <computeroutput>Data</computeroutput> in each node, as well as an ordered sequence of sub-nodes, which are additionally identified by a non-unique key of type <computeroutput>Key</computeroutput>.</para><para>Key equivalency is defined by <computeroutput>KeyCompare</computeroutput>, a predicate defining a strict weak ordering.</para><para>Property tree defines a Container-like interface to the (key-node) pairs of its direct sub-nodes. The iterators are bidirectional. The sequence of nodes is held in insertion order, not key order. </para></description><method-group name="public member functions">
  185. <method name="swap"><type>void</type><parameter name="rhs"><paramtype>self_type &amp;</paramtype></parameter><description><para>Swap with other tree. Only constant-time and nothrow if the data type's swap is. </para></description></method>
  186. <method name="size" cv="const"><type>size_type</type><description><para>The number of direct children of this node. </para></description></method>
  187. <method name="max_size" cv="const"><type>size_type</type></method>
  188. <method name="empty" cv="const"><type>bool</type><description><para>Whether there are any direct children. </para></description></method>
  189. <method name="begin"><type>iterator</type></method>
  190. <method name="begin" cv="const"><type>const_iterator</type></method>
  191. <method name="end"><type>iterator</type></method>
  192. <method name="end" cv="const"><type>const_iterator</type></method>
  193. <method name="rbegin"><type>reverse_iterator</type></method>
  194. <method name="rbegin" cv="const"><type>const_reverse_iterator</type></method>
  195. <method name="rend"><type>reverse_iterator</type></method>
  196. <method name="rend" cv="const"><type>const_reverse_iterator</type></method>
  197. <method name="front"><type>value_type &amp;</type></method>
  198. <method name="front" cv="const"><type>const value_type &amp;</type></method>
  199. <method name="back"><type>value_type &amp;</type></method>
  200. <method name="back" cv="const"><type>const value_type &amp;</type></method>
  201. <method name="insert"><type>iterator</type><parameter name="where"><paramtype>iterator</paramtype></parameter><parameter name="value"><paramtype>const value_type &amp;</paramtype></parameter><description><para>Insert a copy of the given tree with its key just before the given position in this node. This operation invalidates no iterators.
  202. </para></description><returns><para>An iterator to the newly created child. </para>
  203. </returns></method>
  204. <method name="insert"><type>void</type><template>
  205. <template-type-parameter name="It"/>
  206. </template><parameter name="where"><paramtype>iterator</paramtype></parameter><parameter name="first"><paramtype>It</paramtype></parameter><parameter name="last"><paramtype>It</paramtype></parameter><description><para>Range insert. Equivalent to: <programlisting language="c++">for(; first != last; ++first) insert(where, *first);
  207. </programlisting> </para></description></method>
  208. <method name="erase"><type>iterator</type><parameter name="where"><paramtype>iterator</paramtype></parameter><description><para>Erase the child pointed at by the iterator. This operation invalidates the given iterator, as well as its equivalent assoc_iterator.
  209. </para></description><returns><para>A valid iterator pointing to the element after the erased. </para>
  210. </returns></method>
  211. <method name="erase"><type>iterator</type><parameter name="first"><paramtype>iterator</paramtype></parameter><parameter name="last"><paramtype>iterator</paramtype></parameter><description><para>Range erase. Equivalent to: <programlisting language="c++">while(first != last;) first = erase(first);
  212. </programlisting> </para></description></method>
  213. <method name="push_front"><type>iterator</type><parameter name="value"><paramtype>const value_type &amp;</paramtype></parameter><description><para>Equivalent to insert(begin(), value). </para></description></method>
  214. <method name="push_back"><type>iterator</type><parameter name="value"><paramtype>const value_type &amp;</paramtype></parameter><description><para>Equivalent to insert(end(), value). </para></description></method>
  215. <method name="pop_front"><type>void</type><description><para>Equivalent to erase(begin()). </para></description></method>
  216. <method name="pop_back"><type>void</type><description><para>Equivalent to erase(boost::prior(end())). </para></description></method>
  217. <method name="reverse"><type>void</type><description><para>Reverses the order of direct children in the property tree. </para></description></method>
  218. <method name="sort"><type>void</type><template>
  219. <template-type-parameter name="Compare"/>
  220. </template><parameter name="comp"><paramtype>Compare</paramtype></parameter><description><para>Sorts the direct children of this node according to the predicate. The predicate is passed the whole pair of key and child. </para></description></method>
  221. <method name="sort"><type>void</type><description><para>Sorts the direct children of this node according to key order. </para></description></method>
  222. <method name="operator==" cv="const"><type>bool</type><parameter name="rhs"><paramtype>const self_type &amp;</paramtype></parameter><description><para>Two property trees are the same if they have the same data, the keys and order of their children are the same, and the children compare equal, recursively. </para></description></method>
  223. <method name="operator !=" cv="const"><type>bool</type><parameter name="rhs"><paramtype>const self_type &amp;</paramtype></parameter></method>
  224. <method name="ordered_begin"><type>assoc_iterator</type><description><para>Returns an iterator to the first child, in key order. </para></description></method>
  225. <method name="ordered_begin" cv="const"><type>const_assoc_iterator</type><description><para>Returns an iterator to the first child, in key order. </para></description></method>
  226. <method name="not_found"><type>assoc_iterator</type><description><para>Returns the not-found iterator. Equivalent to end() in a real associative container. </para></description></method>
  227. <method name="not_found" cv="const"><type>const_assoc_iterator</type><description><para>Returns the not-found iterator. Equivalent to end() in a real associative container. </para></description></method>
  228. <method name="find"><type>assoc_iterator</type><parameter name="key"><paramtype>const key_type &amp;</paramtype></parameter><description><para>Find a child with the given key, or not_found() if there is none. There is no guarantee about which child is returned if multiple have the same key. </para></description></method>
  229. <method name="find" cv="const"><type>const_assoc_iterator</type><parameter name="key"><paramtype>const key_type &amp;</paramtype></parameter><description><para>Find a child with the given key, or not_found() if there is none. There is no guarantee about which child is returned if multiple have the same key. </para></description></method>
  230. <method name="equal_range"><type>std::pair&lt; assoc_iterator, assoc_iterator &gt;</type><parameter name="key"><paramtype>const key_type &amp;</paramtype></parameter><description><para>Find the range of children that have the given key. </para></description></method>
  231. <method name="equal_range" cv="const"><type>std::pair&lt; const_assoc_iterator, const_assoc_iterator &gt;</type><parameter name="key"><paramtype>const key_type &amp;</paramtype></parameter><description><para>Find the range of children that have the given key. </para></description></method>
  232. <method name="count" cv="const"><type>size_type</type><parameter name="key"><paramtype>const key_type &amp;</paramtype></parameter><description><para>Count the number of direct children with the given key. </para></description></method>
  233. <method name="erase"><type>size_type</type><parameter name="key"><paramtype>const key_type &amp;</paramtype></parameter><description><para>Erase all direct children with the given key and return the count. </para></description></method>
  234. <method name="to_iterator"><type>iterator</type><parameter name="it"><paramtype>assoc_iterator</paramtype></parameter><description><para>Get the iterator that points to the same element as the argument. <note><para>A valid assoc_iterator range (a, b) does not imply that (to_iterator(a), to_iterator(b)) is a valid range. </para>
  235. </note>
  236. </para></description></method>
  237. <method name="to_iterator" cv="const"><type>const_iterator</type><parameter name="it"><paramtype>const_assoc_iterator</paramtype></parameter><description><para>Get the iterator that points to the same element as the argument. <note><para>A valid const_assoc_iterator range (a, b) does not imply that (to_iterator(a), to_iterator(b)) is a valid range. </para>
  238. </note>
  239. </para></description></method>
  240. <method name="data"><type>data_type &amp;</type><description><para>Reference to the actual data in this node. </para></description></method>
  241. <method name="data" cv="const"><type>const data_type &amp;</type><description><para>Reference to the actual data in this node. </para></description></method>
  242. <method name="clear"><type>void</type><description><para>Clear this tree completely, of both data and children. </para></description></method>
  243. <method name="get_child"><type>self_type &amp;</type><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><description><para>Get the child at the given path, or throw <computeroutput><classname alt="boost::property_tree::ptree_bad_path">ptree_bad_path</classname></computeroutput>. <note><para>Depending on the path, the result at each level may not be completely deterministic, i.e. if the same key appears multiple times, which child is chosen is not specified. This can lead to the path not being resolved even though there is a descendant with this path. Example: <programlisting language="c++">a -&gt; b -&gt; c
  244. -&gt; b
  245. </programlisting> The path "a.b.c" will succeed if the resolution of "b" chooses the first such node, but fail if it chooses the second. </para>
  246. </note>
  247. </para></description></method>
  248. <method name="get_child" cv="const"><type>const self_type &amp;</type><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><description><para>Get the child at the given path, or throw <computeroutput><classname alt="boost::property_tree::ptree_bad_path">ptree_bad_path</classname></computeroutput>. </para></description></method>
  249. <method name="get_child"><type>self_type &amp;</type><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><parameter name="default_value"><paramtype>self_type &amp;</paramtype></parameter><description><para>Get the child at the given path, or return <computeroutput>default_value</computeroutput>. </para></description></method>
  250. <method name="get_child" cv="const"><type>const self_type &amp;</type><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><parameter name="default_value"><paramtype>const self_type &amp;</paramtype></parameter><description><para>Get the child at the given path, or return <computeroutput>default_value</computeroutput>. </para></description></method>
  251. <method name="get_child_optional"><type>optional&lt; self_type &amp; &gt;</type><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><description><para>Get the child at the given path, or return boost::null. </para></description></method>
  252. <method name="get_child_optional" cv="const"><type>optional&lt; const self_type &amp; &gt;</type><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><description><para>Get the child at the given path, or return boost::null. </para></description></method>
  253. <method name="put_child"><type>self_type &amp;</type><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><parameter name="value"><paramtype>const self_type &amp;</paramtype></parameter><description><para>Set the node at the given path to the given value. Create any missing parents. If the node at the path already exists, replace it.
  254. <note><para>Because of the way paths work, it is not generally guaranteed that a node newly created can be accessed using the same path. </para>
  255. </note>
  256. <note><para>If the path could refer to multiple nodes, it is unspecified which one gets replaced. </para>
  257. </note>
  258. </para></description><returns><para>A reference to the inserted subtree. </para>
  259. </returns></method>
  260. <method name="add_child"><type>self_type &amp;</type><parameter name="path"><paramtype>const path_type &amp;</paramtype><description><para>Path to the child. The last fragment must not have an index. </para></description></parameter><parameter name="value"><paramtype>const self_type &amp;</paramtype></parameter><description><para>Add the node at the given path. Create any missing parents. If there already is a node at the path, add another one with the same key.
  261. <note><para>Because of the way paths work, it is not generally guaranteed that a node newly created can be accessed using the same path. </para>
  262. </note>
  263. </para></description><returns><para>A reference to the inserted subtree. </para>
  264. </returns></method>
  265. <method name="get_value" cv="const"><type><emphasis>unspecified</emphasis></type><template>
  266. <template-type-parameter name="Type"/>
  267. <template-type-parameter name="Translator"/>
  268. </template><parameter name="tr"><paramtype>Translator</paramtype></parameter><description><para>Take the value of this node and attempt to translate it to a <computeroutput>Type</computeroutput> object using the supplied translator.
  269. </para></description><throws><simpara><classname>ptree_bad_data</classname> if the conversion fails. </simpara></throws></method>
  270. <method name="get_value" cv="const"><type>Type</type><template>
  271. <template-type-parameter name="Type"/>
  272. </template><description><para>Take the value of this node and attempt to translate it to a <computeroutput>Type</computeroutput> object using the default translator.
  273. </para></description><throws><simpara><classname>ptree_bad_data</classname> if the conversion fails. </simpara></throws></method>
  274. <method name="get_value" cv="const"><type>Type</type><template>
  275. <template-type-parameter name="Type"/>
  276. <template-type-parameter name="Translator"/>
  277. </template><parameter name="default_value"><paramtype>const Type &amp;</paramtype></parameter><parameter name="tr"><paramtype>Translator</paramtype></parameter><description><para>Take the value of this node and attempt to translate it to a <computeroutput>Type</computeroutput> object using the supplied translator. Return <computeroutput>default_value</computeroutput> if this fails. </para></description></method>
  278. <method name="get_value" cv="const"><type><emphasis>unspecified</emphasis></type><template>
  279. <template-type-parameter name="Ch"/>
  280. <template-type-parameter name="Translator"/>
  281. </template><parameter name="default_value"><paramtype>const Ch *</paramtype></parameter><parameter name="tr"><paramtype>Translator</paramtype></parameter><description><para>Make get_value do the right thing for string literals. </para></description></method>
  282. <method name="get_value" cv="const"><type><emphasis>unspecified</emphasis></type><template>
  283. <template-type-parameter name="Type"/>
  284. </template><parameter name="default_value"><paramtype>const Type &amp;</paramtype></parameter><description><para>Take the value of this node and attempt to translate it to a <computeroutput>Type</computeroutput> object using the default translator. Return <computeroutput>default_value</computeroutput> if this fails. </para></description></method>
  285. <method name="get_value" cv="const"><type><emphasis>unspecified</emphasis></type><template>
  286. <template-type-parameter name="Ch"/>
  287. </template><parameter name="default_value"><paramtype>const Ch *</paramtype></parameter><description><para>Make get_value do the right thing for string literals. </para></description></method>
  288. <method name="get_value_optional" cv="const"><type>optional&lt; Type &gt;</type><template>
  289. <template-type-parameter name="Type"/>
  290. <template-type-parameter name="Translator"/>
  291. </template><parameter name="tr"><paramtype>Translator</paramtype></parameter><description><para>Take the value of this node and attempt to translate it to a <computeroutput>Type</computeroutput> object using the supplied translator. Return boost::null if this fails. </para></description></method>
  292. <method name="get_value_optional" cv="const"><type>optional&lt; Type &gt;</type><template>
  293. <template-type-parameter name="Type"/>
  294. </template><description><para>Take the value of this node and attempt to translate it to a <computeroutput>Type</computeroutput> object using the default translator. Return boost::null if this fails. </para></description></method>
  295. <method name="put_value"><type>void</type><template>
  296. <template-type-parameter name="Type"/>
  297. <template-type-parameter name="Translator"/>
  298. </template><parameter name="value"><paramtype>const Type &amp;</paramtype></parameter><parameter name="tr"><paramtype>Translator</paramtype></parameter><description><para>Replace the value at this node with the given value, translated to the tree's data type using the supplied translator.
  299. </para></description><throws><simpara><classname>ptree_bad_data</classname> if the conversion fails. </simpara></throws></method>
  300. <method name="put_value"><type>void</type><template>
  301. <template-type-parameter name="Type"/>
  302. </template><parameter name="value"><paramtype>const Type &amp;</paramtype></parameter><description><para>Replace the value at this node with the given value, translated to the tree's data type using the default translator.
  303. </para></description><throws><simpara><classname>ptree_bad_data</classname> if the conversion fails. </simpara></throws></method>
  304. <method name="get" cv="const"><type><emphasis>unspecified</emphasis></type><template>
  305. <template-type-parameter name="Type"/>
  306. <template-type-parameter name="Translator"/>
  307. </template><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><parameter name="tr"><paramtype>Translator</paramtype></parameter><description><para>Shorthand for get_child(path).get_value(tr). </para></description></method>
  308. <method name="get" cv="const"><type>Type</type><template>
  309. <template-type-parameter name="Type"/>
  310. </template><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><description><para>Shorthand for get_child(path).get_value&lt;Type&gt;(). </para></description></method>
  311. <method name="get" cv="const"><type>Type</type><template>
  312. <template-type-parameter name="Type"/>
  313. <template-type-parameter name="Translator"/>
  314. </template><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><parameter name="default_value"><paramtype>const Type &amp;</paramtype></parameter><parameter name="tr"><paramtype>Translator</paramtype></parameter><description><para>Shorthand for get_child(path, empty_ptree()) .get_value(default_value, tr). That is, return the translated value if possible, and the default value if the node doesn't exist or conversion fails. </para></description></method>
  315. <method name="get" cv="const"><type><emphasis>unspecified</emphasis></type><template>
  316. <template-type-parameter name="Ch"/>
  317. <template-type-parameter name="Translator"/>
  318. </template><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><parameter name="default_value"><paramtype>const Ch *</paramtype></parameter><parameter name="tr"><paramtype>Translator</paramtype></parameter><description><para>Make get do the right thing for string literals. </para></description></method>
  319. <method name="get" cv="const"><type><emphasis>unspecified</emphasis></type><template>
  320. <template-type-parameter name="Type"/>
  321. </template><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><parameter name="default_value"><paramtype>const Type &amp;</paramtype></parameter><description><para>Shorthand for get_child(path, empty_ptree()) .get_value(default_value). That is, return the translated value if possible, and the default value if the node doesn't exist or conversion fails. </para></description></method>
  322. <method name="get" cv="const"><type><emphasis>unspecified</emphasis></type><template>
  323. <template-type-parameter name="Ch"/>
  324. </template><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><parameter name="default_value"><paramtype>const Ch *</paramtype></parameter><description><para>Make get do the right thing for string literals. </para></description></method>
  325. <method name="get_optional" cv="const"><type>optional&lt; Type &gt;</type><template>
  326. <template-type-parameter name="Type"/>
  327. <template-type-parameter name="Translator"/>
  328. </template><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><parameter name="tr"><paramtype>Translator</paramtype></parameter><description><para>Shorthand for: <programlisting language="c++">if(optional\&lt;self_type&amp;\&gt; node = get_child_optional(path))
  329. return node-&gt;get_value_optional(tr);
  330. return boost::null;
  331. </programlisting> That is, return the value if it exists and can be converted, or nil. </para></description></method>
  332. <method name="get_optional" cv="const"><type>optional&lt; Type &gt;</type><template>
  333. <template-type-parameter name="Type"/>
  334. </template><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><description><para>Shorthand for: <programlisting language="c++">if(optional\&lt;const self_type&amp;\&gt; node = get_child_optional(path))
  335. return node-&gt;get_value_optional();
  336. return boost::null;
  337. </programlisting> That is, return the value if it exists and can be converted, or nil. </para></description></method>
  338. <method name="put"><type>self_type &amp;</type><template>
  339. <template-type-parameter name="Type"/>
  340. <template-type-parameter name="Translator"/>
  341. </template><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><parameter name="value"><paramtype>const Type &amp;</paramtype></parameter><parameter name="tr"><paramtype>Translator</paramtype></parameter><description><para>Set the value of the node at the given path to the supplied value, translated to the tree's data type. If the node doesn't exist, it is created, including all its missing parents.
  342. </para></description><returns><para>The node that had its value changed. </para>
  343. </returns><throws><simpara><classname>ptree_bad_data</classname> if the conversion fails. </simpara></throws></method>
  344. <method name="put"><type>self_type &amp;</type><template>
  345. <template-type-parameter name="Type"/>
  346. </template><parameter name="path"><paramtype>const path_type &amp;</paramtype></parameter><parameter name="value"><paramtype>const Type &amp;</paramtype></parameter><description><para>Set the value of the node at the given path to the supplied value, translated to the tree's data type. If the node doesn't exist, it is created, including all its missing parents.
  347. </para></description><returns><para>The node that had its value changed. </para>
  348. </returns><throws><simpara><classname>ptree_bad_data</classname> if the conversion fails. </simpara></throws></method>
  349. <method name="add"><type>self_type &amp;</type><template>
  350. <template-type-parameter name="Type"/>
  351. <template-type-parameter name="Translator"/>
  352. </template><parameter name="path"><paramtype>const path_type &amp;</paramtype><description><para>Path to the child. The last fragment must not have an index. </para></description></parameter><parameter name="value"><paramtype>const Type &amp;</paramtype><description><para>The value to add. </para></description></parameter><parameter name="tr"><paramtype>Translator</paramtype><description><para>The translator to use. </para></description></parameter><description><para>If the node identified by the path does not exist, create it, including all its missing parents. If the node already exists, add a sibling with the same key. Set the newly created node's value to the given paremeter, translated with the supplied translator.
  353. </para></description><returns><para>The node that was added. </para>
  354. </returns><throws><simpara><classname>ptree_bad_data</classname> if the conversion fails. </simpara></throws></method>
  355. <method name="add"><type>self_type &amp;</type><template>
  356. <template-type-parameter name="Type"/>
  357. </template><parameter name="path"><paramtype>const path_type &amp;</paramtype><description><para>Path to the child. The last fragment must not have an index. </para></description></parameter><parameter name="value"><paramtype>const Type &amp;</paramtype><description><para>The value to add. </para></description></parameter><description><para>If the node identified by the path does not exist, create it, including all its missing parents. If the node already exists, add a sibling with the same key. Set the newly created node's value to the given paremeter, translated with the supplied translator.
  358. </para></description><returns><para>The node that was added. </para>
  359. </returns><throws><simpara><classname>ptree_bad_data</classname> if the conversion fails. </simpara></throws></method>
  360. </method-group>
  361. <constructor><description><para>Creates a node with no children and default-constructed data. </para></description></constructor>
  362. <constructor specifiers="explicit"><parameter name="data"><paramtype>const data_type &amp;</paramtype></parameter><description><para>Creates a node with no children and a copy of the given data. </para></description></constructor>
  363. <constructor><parameter name="rhs"><paramtype>const self_type &amp;</paramtype></parameter></constructor>
  364. <destructor/>
  365. <copy-assignment><type>self_type &amp;</type><parameter name="rhs"><paramtype>const self_type &amp;</paramtype></parameter><description><para>Basic guarantee only. </para></description></copy-assignment>
  366. <method-group name="private member functions">
  367. <method name="walk_path" cv="const"><type>self_type *</type><parameter name="p"><paramtype>path_type &amp;</paramtype></parameter></method>
  368. <method name="force_path"><type>self_type &amp;</type><parameter name="p"><paramtype>path_type &amp;</paramtype></parameter></method>
  369. </method-group>
  370. </class><struct name="id_translator"><template>
  371. <template-type-parameter name="T"/>
  372. </template><purpose>Simple implementation of the Translator concept. It does no translation. </purpose><method-group name="public member functions">
  373. <method name="get_value"><type>boost::optional&lt; T &gt;</type><parameter name="v"><paramtype>const T &amp;</paramtype></parameter></method>
  374. <method name="put_value"><type>boost::optional&lt; T &gt;</type><parameter name="v"><paramtype>const T &amp;</paramtype></parameter></method>
  375. </method-group>
  376. </struct><struct name="path_of"><template>
  377. <template-type-parameter name="Key"/>
  378. </template><purpose>If you want to use a custom key type, specialize this struct for it and give it a 'type' typedef that specifies your path type. The path type must conform to the Path concept described in the documentation. This is already specialized for std::basic_string. </purpose></struct><struct name="translator_between"><template>
  379. <template-type-parameter name="Internal"/>
  380. <template-type-parameter name="External"/>
  381. </template><purpose>Specialize this struct to specify a default translator between the data in a tree whose data_type is Internal, and the external data_type specified in a get_value, get, put_value or put operation. This is already specialized for Internal being std::basic_string. </purpose></struct><typedef name="path"><description><para>Implements a path using a std::string as the key. </para></description><type><classname>string_path</classname>&lt; std::string, <classname>id_translator</classname>&lt; std::string &gt; &gt;</type></typedef>
  382. <typedef name="ptree"><description><para>A property tree with std::string for key and data, and default comparison. </para></description><type><classname>basic_ptree</classname>&lt; std::string, std::string &gt;</type></typedef>
  383. <typedef name="iptree"><description><para>A property tree with std::string for key and data, and case-insensitive comparison. </para></description><type><emphasis>unspecified</emphasis></type></typedef>
  384. <typedef name="wpath"><description><para>Implements a path using a std::wstring as the key. </para></description><type><classname>string_path</classname>&lt; std::wstring, <classname>id_translator</classname>&lt; std::wstring &gt; &gt;</type></typedef>
  385. <typedef name="wptree"><description><para>A property tree with std::wstring for key and data, and default comparison. <note><para>The type only exists if the platform supports <computeroutput>wchar_t</computeroutput>. </para>
  386. </note>
  387. </para></description><type><classname>basic_ptree</classname>&lt; std::wstring, std::wstring &gt;</type></typedef>
  388. <typedef name="wiptree"><description><para>A property tree with std::wstring for key and data, and case-insensitive comparison. <note><para>The type only exists if the platform supports <computeroutput>wchar_t</computeroutput>. </para>
  389. </note>
  390. </para></description><type><emphasis>unspecified</emphasis></type></typedef>
  391. <function name="swap"><type>void</type><template>
  392. <template-type-parameter name="K"/>
  393. <template-type-parameter name="D"/>
  394. <template-type-parameter name="C"/>
  395. </template><parameter name="pt1"><paramtype><classname>basic_ptree</classname>&lt; K, D, C &gt; &amp;</paramtype></parameter><parameter name="pt2"><paramtype><classname>basic_ptree</classname>&lt; K, D, C &gt; &amp;</paramtype></parameter><description><para>Swap two property tree instances. </para></description></function>
  396. </namespace>
  397. </namespace>
  398. </header>
  399. <header name="boost/property_tree/ptree_serialization.hpp">
  400. <namespace name="boost">
  401. <namespace name="property_tree">
  402. <function name="save"><type>void</type><template>
  403. <template-type-parameter name="Archive"/>
  404. <template-type-parameter name="K"/>
  405. <template-type-parameter name="D"/>
  406. <template-type-parameter name="C"/>
  407. </template><parameter name="ar"><paramtype>Archive &amp;</paramtype><description><para>The archive to which to save the serialized property tree. This archive should conform to the concept laid out by the Boost.Serialization library. </para></description></parameter><parameter name="t"><paramtype>const <classname>basic_ptree</classname>&lt; K, D, C &gt; &amp;</paramtype><description><para>The property tree to serialize. </para></description></parameter><parameter name="file_version"><paramtype>const unsigned int</paramtype><description><para>file_version for the archive. </para></description></parameter><description><para>Serialize the property tree to the given archive. <note><para>In addition to serializing to regular archives, this supports serializing to archives requiring name-value pairs, e.g. XML archives. However, the output format in the XML archive is not guaranteed to be the same as that when using the Boost.PropertyTree library's <computeroutput>boost::property_tree::xml_parser::write_xml</computeroutput>. </para>
  408. </note>
  409. </para></description><postconditions><para><computeroutput>ar</computeroutput> will contain the serialized form of <computeroutput>t</computeroutput>. </para>
  410. </postconditions></function>
  411. <function name="load"><type>void</type><template>
  412. <template-type-parameter name="Archive"/>
  413. <template-type-parameter name="K"/>
  414. <template-type-parameter name="D"/>
  415. <template-type-parameter name="C"/>
  416. </template><parameter name="ar"><paramtype>Archive &amp;</paramtype><description><para>The archive from which to load the serialized property tree. This archive should conform to the concept laid out by the Boost.Serialization library. </para></description></parameter><parameter name="t"><paramtype><classname>basic_ptree</classname>&lt; K, D, C &gt; &amp;</paramtype><description><para>The property tree to de-serialize. </para></description></parameter><parameter name="file_version"><paramtype>const unsigned int</paramtype><description><para>file_version for the archive. </para></description></parameter><description><para>De-serialize the property tree to the given archive. <note><para>In addition to de-serializing from regular archives, this supports loading from archives requiring name-value pairs, e.g. XML archives. The format should be that used by boost::property_tree::save. </para>
  417. </note>
  418. </para></description><postconditions><para><computeroutput>t</computeroutput> will contain the de-serialized data from <computeroutput>ar</computeroutput>. </para>
  419. </postconditions></function>
  420. <function name="serialize"><type>void</type><template>
  421. <template-type-parameter name="Archive"/>
  422. <template-type-parameter name="K"/>
  423. <template-type-parameter name="D"/>
  424. <template-type-parameter name="C"/>
  425. </template><parameter name="ar"><paramtype>Archive &amp;</paramtype><description><para>The archive from which to load or save the serialized property tree. The type of this archive will determine whether saving or loading is performed. </para></description></parameter><parameter name="t"><paramtype><classname>basic_ptree</classname>&lt; K, D, C &gt; &amp;</paramtype><description><para>The property tree to load or save. </para></description></parameter><parameter name="file_version"><paramtype>const unsigned int</paramtype><description><para>file_version for the archive. </para></description></parameter><description><para>Load or store the property tree using the given archive.
  426. </para></description></function>
  427. </namespace>
  428. </namespace>
  429. </header>
  430. <header name="boost/property_tree/stream_translator.hpp">
  431. <namespace name="boost">
  432. <namespace name="property_tree">
  433. <struct name="customize_stream"><template>
  434. <template-type-parameter name="Ch"/>
  435. <template-type-parameter name="Traits"/>
  436. <template-type-parameter name="E"/>
  437. <template-type-parameter name="Enabler"><default>void</default></template-type-parameter>
  438. </template><method-group name="public static functions">
  439. <method name="insert" specifiers="static"><type>void</type><parameter name="s"><paramtype>std::basic_ostream&lt; Ch, Traits &gt; &amp;</paramtype></parameter><parameter name="e"><paramtype>const E &amp;</paramtype></parameter></method>
  440. <method name="extract" specifiers="static"><type>void</type><parameter name="s"><paramtype>std::basic_istream&lt; Ch, Traits &gt; &amp;</paramtype></parameter><parameter name="e"><paramtype>E &amp;</paramtype></parameter></method>
  441. </method-group>
  442. </struct><struct-specialization name="customize_stream"><template>
  443. <template-type-parameter name="Ch"/>
  444. <template-type-parameter name="Traits"/>
  445. </template><specialization><template-arg>Ch</template-arg><template-arg>Traits</template-arg><template-arg>bool</template-arg><template-arg>void</template-arg></specialization><method-group name="public static functions">
  446. <method name="insert" specifiers="static"><type>void</type><parameter name="s"><paramtype>std::basic_ostream&lt; Ch, Traits &gt; &amp;</paramtype></parameter><parameter name="e"><paramtype>bool</paramtype></parameter></method>
  447. <method name="extract" specifiers="static"><type>void</type><parameter name="s"><paramtype>std::basic_istream&lt; Ch, Traits &gt; &amp;</paramtype></parameter><parameter name="e"><paramtype>bool &amp;</paramtype></parameter></method>
  448. </method-group>
  449. </struct-specialization><struct-specialization name="customize_stream"><template>
  450. <template-type-parameter name="Ch"/>
  451. <template-type-parameter name="Traits"/>
  452. </template><specialization><template-arg>Ch</template-arg><template-arg>Traits</template-arg><template-arg>Ch</template-arg><template-arg>void</template-arg></specialization><method-group name="public static functions">
  453. <method name="insert" specifiers="static"><type>void</type><parameter name="s"><paramtype>std::basic_ostream&lt; Ch, Traits &gt; &amp;</paramtype></parameter><parameter name="e"><paramtype>Ch</paramtype></parameter></method>
  454. <method name="extract" specifiers="static"><type>void</type><parameter name="s"><paramtype>std::basic_istream&lt; Ch, Traits &gt; &amp;</paramtype></parameter><parameter name="e"><paramtype>Ch &amp;</paramtype></parameter></method>
  455. </method-group>
  456. </struct-specialization><struct-specialization name="customize_stream"><template>
  457. <template-type-parameter name="Ch"/>
  458. <template-type-parameter name="Traits"/>
  459. <template-type-parameter name="F"/>
  460. </template><specialization><template-arg>Ch</template-arg><template-arg>Traits</template-arg><template-arg>F</template-arg><template-arg>typename boost::enable_if&lt; detail::is_inexact&lt; F &gt; &gt;::type</template-arg></specialization><method-group name="public static functions">
  461. <method name="insert" specifiers="static"><type>void</type><parameter name="s"><paramtype>std::basic_ostream&lt; Ch, Traits &gt; &amp;</paramtype></parameter><parameter name="e"><paramtype>const F &amp;</paramtype></parameter></method>
  462. <method name="extract" specifiers="static"><type>void</type><parameter name="s"><paramtype>std::basic_istream&lt; Ch, Traits &gt; &amp;</paramtype></parameter><parameter name="e"><paramtype>F &amp;</paramtype></parameter></method>
  463. </method-group>
  464. </struct-specialization><struct-specialization name="customize_stream"><template>
  465. <template-type-parameter name="Ch"/>
  466. <template-type-parameter name="Traits"/>
  467. </template><specialization><template-arg>Ch</template-arg><template-arg>Traits</template-arg><template-arg>signed char</template-arg><template-arg>void</template-arg></specialization><method-group name="public static functions">
  468. <method name="insert" specifiers="static"><type>void</type><parameter name="s"><paramtype>std::basic_ostream&lt; Ch, Traits &gt; &amp;</paramtype></parameter><parameter name="e"><paramtype>signed char</paramtype></parameter></method>
  469. <method name="extract" specifiers="static"><type>void</type><parameter name="s"><paramtype>std::basic_istream&lt; Ch, Traits &gt; &amp;</paramtype></parameter><parameter name="e"><paramtype>signed char &amp;</paramtype></parameter></method>
  470. </method-group>
  471. </struct-specialization><struct-specialization name="customize_stream"><template>
  472. <template-type-parameter name="Ch"/>
  473. <template-type-parameter name="Traits"/>
  474. </template><specialization><template-arg>Ch</template-arg><template-arg>Traits</template-arg><template-arg>unsigned char</template-arg><template-arg>void</template-arg></specialization><method-group name="public static functions">
  475. <method name="insert" specifiers="static"><type>void</type><parameter name="s"><paramtype>std::basic_ostream&lt; Ch, Traits &gt; &amp;</paramtype></parameter><parameter name="e"><paramtype>unsigned char</paramtype></parameter></method>
  476. <method name="extract" specifiers="static"><type>void</type><parameter name="s"><paramtype>std::basic_istream&lt; Ch, Traits &gt; &amp;</paramtype></parameter><parameter name="e"><paramtype>unsigned char &amp;</paramtype></parameter></method>
  477. </method-group>
  478. </struct-specialization><class name="stream_translator"><template>
  479. <template-type-parameter name="Ch"/>
  480. <template-type-parameter name="Traits"/>
  481. <template-type-parameter name="Alloc"/>
  482. <template-type-parameter name="E"/>
  483. </template><purpose>Implementation of Translator that uses the stream overloads. </purpose><typedef name="internal_type"><type>std::basic_string&lt; Ch, Traits, Alloc &gt;</type></typedef>
  484. <typedef name="external_type"><type>E</type></typedef>
  485. <method-group name="public member functions">
  486. <method name="get_value"><type>boost::optional&lt; E &gt;</type><parameter name="v"><paramtype>const internal_type &amp;</paramtype></parameter></method>
  487. <method name="put_value"><type>boost::optional&lt; internal_type &gt;</type><parameter name="v"><paramtype>const E &amp;</paramtype></parameter></method>
  488. </method-group>
  489. <constructor specifiers="explicit"><parameter name="loc"><paramtype>std::locale</paramtype><default>std::locale()</default></parameter></constructor>
  490. </class><struct-specialization name="translator_between"><template>
  491. <template-type-parameter name="Ch"/>
  492. <template-type-parameter name="Traits"/>
  493. <template-type-parameter name="Alloc"/>
  494. <template-type-parameter name="E"/>
  495. </template><specialization><template-arg>std::basic_string&lt; Ch</template-arg><template-arg>Traits</template-arg><template-arg>Alloc &gt;</template-arg><template-arg>E</template-arg></specialization><typedef name="type"><type><classname>stream_translator</classname>&lt; Ch, Traits, Alloc, E &gt;</type></typedef>
  496. </struct-specialization>
  497. </namespace>
  498. </namespace>
  499. </header>
  500. <header name="boost/property_tree/string_path.hpp">
  501. <namespace name="boost">
  502. <namespace name="property_tree">
  503. <struct-specialization name="path_of"><template>
  504. <template-type-parameter name="Ch"/>
  505. <template-type-parameter name="Traits"/>
  506. <template-type-parameter name="Alloc"/>
  507. </template><specialization><template-arg>std::basic_string&lt; Ch</template-arg><template-arg>Traits</template-arg><template-arg>Alloc &gt;</template-arg></specialization><typedef name="_string"><type>std::basic_string&lt; Ch, Traits, Alloc &gt;</type></typedef>
  508. <typedef name="type"><type><classname>string_path</classname>&lt; _string, <classname>id_translator</classname>&lt; _string &gt; &gt;</type></typedef>
  509. </struct-specialization><class name="string_path"><template>
  510. <template-type-parameter name="String"><purpose><para>Any Sequence. If the sequence does not support random- access iteration, concatenation of paths assumes that insertions at the end preserve iterator validity. </para></purpose></template-type-parameter>
  511. <template-type-parameter name="Translator"><purpose><para>A translator with internal_type == String. </para></purpose></template-type-parameter>
  512. </template><purpose>Default path class. A path is a sequence of values. Groups of values are separated by the separator value, which defaults to '.' cast to the sequence's value type. The group of values is then passed to the translator to get a key. </purpose><description><para>If instantiated with std::string and <classname alt="boost::property_tree::id_translator">id_translator</classname>&lt;std::string&gt;, it accepts paths of the form "one.two.three.four".</para><para>
  513. </para></description><typedef name="key_type"><type>Translator::external_type</type></typedef>
  514. <typedef name="char_type"><type>String::value_type</type></typedef>
  515. <method-group name="private member functions">
  516. <method name="BOOST_STATIC_ASSERT"><type/><parameter name=""><paramtype>(is_same&lt; String, typename Translator::internal_type &gt;::value)</paramtype></parameter></method>
  517. <method name="cstart" cv="const"><type>s_c_iter</type></method>
  518. </method-group>
  519. <method-group name="public member functions">
  520. <method name="reduce"><type>key_type</type><purpose>Take a single element off the path at the front and return it. </purpose></method>
  521. <method name="empty" cv="const"><type>bool</type><purpose>Test if the path is empty. </purpose></method>
  522. <method name="single" cv="const"><type>bool</type><purpose>Test if the path contains a single element, i.e. no separators. </purpose></method>
  523. <method name="separator" cv="const"><type>char_type</type><purpose>Get the separator used by this path. </purpose></method>
  524. <method name="dump" cv="const"><type>std::string</type></method>
  525. <method name="operator/="><type><classname>string_path</classname> &amp;</type><parameter name="o"><paramtype>const <classname>string_path</classname> &amp;</paramtype></parameter><purpose>Append a second path to this one. </purpose><description><para>
  526. </para></description><requires><para>o's separator is the same as this one's, or o has no separators </para>
  527. </requires></method>
  528. </method-group>
  529. <constructor specifiers="explicit"><parameter name="separator"><paramtype>char_type</paramtype><default>char_type('.')</default></parameter><purpose>Create an empty path. </purpose></constructor>
  530. <constructor><parameter name="value"><paramtype>const String &amp;</paramtype><description><para>A sequence, possibly with separators, that describes the path, e.g. "one.two.three". </para></description></parameter><parameter name="separator"><paramtype>char_type</paramtype><default>char_type('.')</default><description><para>The separator used in parsing. Defaults to '.'. </para></description></parameter><parameter name="tr"><paramtype>Translator</paramtype><default>Translator()</default><description><para>The translator used by this path to convert the individual parts to keys. </para></description></parameter><purpose>Create a path by parsing the given string. </purpose><description><para>
  531. </para></description></constructor>
  532. <constructor><parameter name="value"><paramtype>const char_type *</paramtype><description><para>A zero-terminated array of values. Only use if zero- termination makes sense for your type, and your sequence supports construction from it. Intended for string literals. </para></description></parameter><parameter name="separator"><paramtype>char_type</paramtype><default>char_type('.')</default><description><para>The separator used in parsing. Defaults to '.'. </para></description></parameter><parameter name="tr"><paramtype>Translator</paramtype><default>Translator()</default><description><para>The translator used by this path to convert the individual parts to keys. </para></description></parameter><purpose>Create a path by parsing the given string. </purpose><description><para>
  533. </para></description></constructor>
  534. <constructor><parameter name="o"><paramtype>const <classname>string_path</classname> &amp;</paramtype></parameter></constructor>
  535. <copy-assignment><type><classname>string_path</classname> &amp;</type><parameter name="o"><paramtype>const <classname>string_path</classname> &amp;</paramtype></parameter></copy-assignment>
  536. </class><function name="operator/"><type><classname>string_path</classname>&lt; String, Translator &gt;</type><template>
  537. <template-type-parameter name="String"/>
  538. <template-type-parameter name="Translator"/>
  539. </template><parameter name="p1"><paramtype><classname>string_path</classname>&lt; String, Translator &gt;</paramtype></parameter><parameter name="p2"><paramtype>const <classname>string_path</classname>&lt; String, Translator &gt; &amp;</paramtype></parameter></function>
  540. <function name="operator/"><type><classname>string_path</classname>&lt; String, Translator &gt;</type><template>
  541. <template-type-parameter name="String"/>
  542. <template-type-parameter name="Translator"/>
  543. </template><parameter name="p1"><paramtype><classname>string_path</classname>&lt; String, Translator &gt;</paramtype></parameter><parameter name="p2"><paramtype>const typename String::value_type *</paramtype></parameter></function>
  544. <function name="operator/"><type><classname>string_path</classname>&lt; String, Translator &gt;</type><template>
  545. <template-type-parameter name="String"/>
  546. <template-type-parameter name="Translator"/>
  547. </template><parameter name="p1"><paramtype>const typename String::value_type *</paramtype></parameter><parameter name="p2"><paramtype>const <classname>string_path</classname>&lt; String, Translator &gt; &amp;</paramtype></parameter></function>
  548. </namespace>
  549. </namespace>
  550. </header>
  551. <header name="boost/property_tree/xml_parser.hpp">
  552. <namespace name="boost">
  553. <namespace name="property_tree">
  554. <namespace name="xml_parser">
  555. <function name="read_xml"><type>void</type><template>
  556. <template-type-parameter name="Ptree"/>
  557. </template><parameter name="stream"><paramtype>std::basic_istream&lt; typename Ptree::key_type::value_type &gt; &amp;</paramtype><description><para>Stream from which to read in the property tree. </para></description></parameter><parameter name="pt"><paramtype>Ptree &amp;</paramtype><description><para>The property tree to populate. </para></description></parameter><parameter name="flags"><paramtype>int</paramtype><default>0</default><description><para>Flags controlling the behaviour of the parser. The following flags are supported: <itemizedlist>
  558. <listitem><para><computeroutput>no_concat_text</computeroutput> – Prevents concatenation of text nodes into datastring of property tree. Puts them in separate <computeroutput>&lt;xmltext&gt;</computeroutput> strings instead. </para>
  559. </listitem>
  560. <listitem><para><computeroutput>no_comments</computeroutput> – Skip XML comments. </para>
  561. </listitem>
  562. <listitem><para><computeroutput>trim_whitespace</computeroutput> – Trim leading and trailing whitespace from text, and collapse sequences of whitespace. </para>
  563. </listitem>
  564. </itemizedlist>
  565. </para></description></parameter><description><para>Reads XML from an input stream and translates it to property tree. <note><para>Clears existing contents of property tree. In case of error the property tree unmodified. </para>
  566. </note>
  567. <note><para>XML attributes are placed under keys named <computeroutput>&lt;xmlattr&gt;</computeroutput>. </para>
  568. </note>
  569. </para></description><throws><simpara><classname>xml_parser_error</classname> In case of error deserializing the property tree. </simpara></throws></function>
  570. <function name="read_xml"><type>void</type><template>
  571. <template-type-parameter name="Ptree"/>
  572. </template><parameter name="filename"><paramtype>const std::string &amp;</paramtype><description><para>The file from which to read in the property tree. </para></description></parameter><parameter name="pt"><paramtype>Ptree &amp;</paramtype><description><para>The property tree to populate. </para></description></parameter><parameter name="flags"><paramtype>int</paramtype><default>0</default><description><para>Flags controlling the bahviour of the parser. The following flags are supported: <itemizedlist>
  573. <listitem><para><computeroutput>no_concat_text</computeroutput> – Prevents concatenation of text nodes into datastring of property tree. Puts them in separate <computeroutput>&lt;xmltext&gt;</computeroutput> strings instead. </para>
  574. </listitem>
  575. <listitem><para><computeroutput>no_comments</computeroutput> – Skip XML comments. </para>
  576. </listitem>
  577. </itemizedlist>
  578. </para></description></parameter><parameter name="loc"><paramtype>const std::locale &amp;</paramtype><default>std::locale()</default><description><para>The locale to use when reading in the file contents. </para></description></parameter><description><para>Reads XML from a file using the given locale and translates it to property tree. <note><para>Clears existing contents of property tree. In case of error the property tree unmodified. </para>
  579. </note>
  580. <note><para>XML attributes are placed under keys named <computeroutput>&lt;xmlattr&gt;</computeroutput>. </para>
  581. </note>
  582. </para></description><throws><simpara><classname>xml_parser_error</classname> In case of error deserializing the property tree. </simpara></throws></function>
  583. <function name="write_xml"><type>void</type><template>
  584. <template-type-parameter name="Ptree"/>
  585. </template><parameter name="stream"><paramtype>std::basic_ostream&lt; typename Ptree::key_type::value_type &gt; &amp;</paramtype><description><para>The stream to which to write the XML representation of the property tree. </para></description></parameter><parameter name="pt"><paramtype>const Ptree &amp;</paramtype><description><para>The property tree to tranlsate to XML and output. </para></description></parameter><parameter name="settings"><paramtype>const xml_writer_settings&lt; typename Ptree::key_type &gt; &amp;</paramtype><default>xml_writer_settings&lt; typename Ptree::key_type &gt;()</default><description><para>The settings to use when writing out the property tree as XML. </para></description></parameter><description><para>Translates the property tree to XML and writes it the given output stream.
  586. </para></description><throws><simpara><classname>xml_parser_error</classname> In case of error translating the property tree to XML or writing to the output stream. </simpara></throws></function>
  587. <function name="write_xml"><type>void</type><template>
  588. <template-type-parameter name="Ptree"/>
  589. </template><parameter name="filename"><paramtype>const std::string &amp;</paramtype><description><para>The file to which to write the XML representation of the property tree. </para></description></parameter><parameter name="pt"><paramtype>const Ptree &amp;</paramtype><description><para>The property tree to tranlsate to XML and output. </para></description></parameter><parameter name="loc"><paramtype>const std::locale &amp;</paramtype><default>std::locale()</default><description><para>The locale to use when writing the output to file. </para></description></parameter><parameter name="settings"><paramtype>const xml_writer_settings&lt; typename Ptree::key_type &gt; &amp;</paramtype><default>xml_writer_settings&lt; typename Ptree::key_type &gt;()</default><description><para>The settings to use when writing out the property tree as XML. </para></description></parameter><description><para>Translates the property tree to XML and writes it the given file.
  590. </para></description><throws><simpara><classname>xml_parser_error</classname> In case of error translating the property tree to XML or writing to the output stream. </simpara></throws></function>
  591. </namespace>
  592. </namespace>
  593. </namespace>
  594. </header>
  595. </library-reference>