<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <meta http-equiv="X-UA-Compatible" content="IE=9"/> <meta name="generator" content="Doxygen 1.8.11"/> <title>glibmm: Glib::ValueBase 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="doxygen.css" rel="stylesheet" type="text/css" /> <link href="doxygen-extra.css" rel="stylesheet" type="text/css"/> </head> <body> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td id="projectalign" style="padding-left: 0.5em;"> <div id="projectname">glibmm  <span id="projectnumber">2.60.0</span> </div> </td> </tr> </tbody> </table> </div> <!-- end header part --> <!-- Generated by Doxygen 1.8.11 --> <div id="navrow1" class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="modules.html"><span>Modules</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li class="current"><a href="annotated.html"><span>Classes</span></a></li> <li><a href="examples.html"><span>Examples</span></a></li> </ul> </div> <div id="navrow2" class="tabs2"> <ul class="tablist"> <li><a href="annotated.html"><span>Class List</span></a></li> <li><a href="classes.html"><span>Class Index</span></a></li> <li><a href="inherits.html"><span>Class Hierarchy</span></a></li> <li><a href="functions.html"><span>Class Members</span></a></li> </ul> </div> <div id="nav-path" class="navpath"> <ul> <li class="navelem"><a class="el" href="namespaceGlib.html">Glib</a></li><li class="navelem"><a class="el" href="classGlib_1_1ValueBase.html">ValueBase</a></li> </ul> </div> </div><!-- top --> <div class="header"> <div class="summary"> <a href="#pub-methods">Public Member Functions</a> | <a href="#pro-attribs">Protected Attributes</a> | <a href="classGlib_1_1ValueBase-members.html">List of all members</a> </div> <div class="headertitle"> <div class="title">Glib::ValueBase Class Reference<div class="ingroups"><a class="el" href="group__glibmmValue.html">Generic Values</a></div></div> </div> </div><!--header--> <div class="contents"> <p><code>#include <glibmm/value.h></code></p> <div class="dynheader"> Inheritance diagram for Glib::ValueBase:</div> <div class="dyncontent"> <div class="center"><img src="classGlib_1_1ValueBase__inherit__graph.png" border="0" usemap="#Glib_1_1ValueBase_inherit__map" alt="Inheritance graph"/></div> <map name="Glib_1_1ValueBase_inherit__map" id="Glib_1_1ValueBase_inherit__map"> <area shape="rect" id="node2" href="classGlib_1_1Value_3_01bool_01_4.html" title="Glib::Value\< bool \>" alt="" coords="193,5,344,32"/> <area shape="rect" id="node3" href="classGlib_1_1Value_3_01char_01_4.html" title="Glib::Value\< char \>" alt="" coords="193,56,344,83"/> <area shape="rect" id="node4" href="classGlib_1_1Value_3_01double_01_4.html" title="Glib::Value\< double \>" alt="" coords="185,107,352,133"/> <area shape="rect" id="node5" href="classGlib_1_1Value_3_01float_01_4.html" title="Glib::Value\< float \>" alt="" coords="193,157,344,184"/> <area shape="rect" id="node6" href="classGlib_1_1Value_3_01int_01_4.html" title="Glib::Value\< int \>" alt="" coords="199,208,338,235"/> <area shape="rect" id="node7" href="classGlib_1_1Value_3_01long_01_4.html" title="Glib::Value\< long \>" alt="" coords="193,259,344,285"/> <area shape="rect" id="node8" href="classGlib_1_1Value_3_01long_01long_01_4.html" title="Glib::Value\< long long \>" alt="" coords="177,309,360,336"/> <area shape="rect" id="node9" href="classGlib_1_1Value_3_01signed_01char_01_4.html" title="Glib::Value\< signed\l char \>" alt="" coords="193,361,344,402"/> <area shape="rect" id="node10" href="classGlib_1_1Value_3_01unsigned_01char_01_4.html" title="Glib::Value\< unsigned\l char \>" alt="" coords="185,426,352,467"/> <area shape="rect" id="node11" href="classGlib_1_1Value_3_01unsigned_01int_01_4.html" title="Glib::Value\< unsigned\l int \>" alt="" coords="185,491,352,533"/> <area shape="rect" id="node12" href="classGlib_1_1Value_3_01unsigned_01long_01_4.html" title="Glib::Value\< unsigned\l long \>" alt="" coords="185,557,352,598"/> <area shape="rect" id="node13" href="classGlib_1_1Value_3_01unsigned_01long_01long_01_4.html" title="Glib::Value\< unsigned\l long long \>" alt="" coords="185,622,352,663"/> <area shape="rect" id="node14" href="classGlib_1_1Value_3_01void_01_5_01_4.html" title="Glib::Value\< void * \>" alt="" coords="188,688,349,715"/> <area shape="rect" id="node15" href="classGlib_1_1ValueBase__Boxed.html" title="Glib::ValueBase_Boxed" alt="" coords="183,739,355,765"/> <area shape="rect" id="node21" href="classGlib_1_1ValueBase__Enum.html" title="Glib::ValueBase_Enum" alt="" coords="185,789,353,816"/> <area shape="rect" id="node23" href="classGlib_1_1ValueBase__Flags.html" title="Glib::ValueBase_Flags" alt="" coords="186,840,351,867"/> <area shape="rect" id="node25" href="classGlib_1_1ValueBase__Object.html" title="Glib::ValueBase_Object" alt="" coords="182,997,355,1024"/> <area shape="rect" id="node33" href="classGlib_1_1ValueBase__String.html" title="Glib::ValueBase_String" alt="" coords="184,1153,353,1180"/> <area shape="rect" id="node36" href="classGlib_1_1ValueBase__Variant.html" title="Glib::ValueBase_Variant" alt="" coords="180,1204,357,1231"/> <area shape="rect" id="node16" href="classGlib_1_1Value.html" title="Generic value implementation for custom types. " alt="" coords="451,505,582,532"/> <area shape="rect" id="node17" href="classGlib_1_1Value_3_01std_1_1vector_3_01Glib_1_1ustring_01_4_01_4.html" title="Specialization for vectors of UTF-8 strings. " alt="" coords="429,557,605,598"/> <area shape="rect" id="node18" href="classGlib_1_1Value_3_01std_1_1vector_3_01std_1_1string_01_4_01_4.html" title="Specialization for vectors of strings. " alt="" coords="429,622,605,663"/> <area shape="rect" id="node19" href="classGlib_1_1Value__Boxed.html" title="Glib::Value_Boxed\< T \>" alt="" coords="427,688,606,715"/> <area shape="rect" id="node20" href="classGlib_1_1Value__RefPtrBoxed.html" title="Glib::Value_RefPtrBoxed\< T \>" alt="" coords="408,739,625,765"/> <area shape="rect" id="node22" href="classGlib_1_1Value__Enum.html" title="Base class of Glib::Value<T> specializations for enum types. " alt="" coords="429,789,604,816"/> <area shape="rect" id="node24" href="classGlib_1_1Value__Flags.html" title="Base class of Glib::Value<T> specializations for flags types. " alt="" coords="431,840,602,867"/> <area shape="rect" id="node26" href="classGlib_1_1Value_3_01Glib_1_1RefPtr_3_01const_01T_01_4_01_4.html" title="Partial specialization for RefPtr<> to const Glib::Object. " alt="" coords="440,891,593,933"/> <area shape="rect" id="node27" href="classGlib_1_1Value_3_01Glib_1_1RefPtr_3_01T_01_4_01_4.html" title="Partial specialization for RefPtr<> to Glib::Object. " alt="" coords="446,957,587,998"/> <area shape="rect" id="node28" href="classGlib_1_1Value__Pointer.html" title="Glib::Value_Pointer\l\< T, PtrT \>" alt="" coords="444,1022,589,1063"/> <area shape="rect" id="node29" href="classGlib_1_1Value__Pointer.html" title="Glib::Value_Pointer\l\< T, const T * \>" alt="" coords="444,1087,589,1129"/> <area shape="rect" id="node31" href="classGlib_1_1Value__Pointer.html" title="Glib::Value_Pointer\l\< T, T * \>" alt="" coords="444,1153,589,1194"/> <area shape="rect" id="node30" href="classGlib_1_1Value_3_01const_01T_01_5_01_4.html" title="Specialization for pointers to const instances of any type. " alt="" coords="673,1087,816,1129"/> <area shape="rect" id="node32" href="classGlib_1_1Value_3_01T_01_5_01_4.html" title="Specialization for pointers to instances of any type. " alt="" coords="674,1160,815,1187"/> <area shape="rect" id="node34" href="classGlib_1_1Value_3_01Glib_1_1ustring_01_4.html" title="Specialization for UTF-8 strings. " alt="" coords="446,1218,587,1259"/> <area shape="rect" id="node35" href="classGlib_1_1Value_3_01std_1_1string_01_4.html" title="Specialization for strings. " alt="" coords="423,1284,610,1311"/> </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 name="pub-methods"></a> Public Member Functions</h2></td></tr> <tr class="memitem:a066cc345d62be564ff53b25bd11e62e5"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classGlib_1_1ValueBase.html#a066cc345d62be564ff53b25bd11e62e5">ValueBase</a> ()</td></tr> <tr class="memdesc:a066cc345d62be564ff53b25bd11e62e5"><td class="mdescLeft"> </td><td class="mdescRight">Initializes the GValue, but without a type. <a href="#a066cc345d62be564ff53b25bd11e62e5">More...</a><br /></td></tr> <tr class="separator:a066cc345d62be564ff53b25bd11e62e5"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a1af751f0ac927df5ccba7d584cb9e63f"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classGlib_1_1ValueBase.html#a1af751f0ac927df5ccba7d584cb9e63f">ValueBase</a> (const <a class="el" href="classGlib_1_1ValueBase.html">ValueBase</a>& other)</td></tr> <tr class="separator:a1af751f0ac927df5ccba7d584cb9e63f"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a73ceadee7e4d2298b31d1dbe4bcd35e5"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classGlib_1_1ValueBase.html">ValueBase</a>& </td><td class="memItemRight" valign="bottom"><a class="el" href="classGlib_1_1ValueBase.html#a73ceadee7e4d2298b31d1dbe4bcd35e5">operator=</a> (const <a class="el" href="classGlib_1_1ValueBase.html">ValueBase</a>& other)</td></tr> <tr class="separator:a73ceadee7e4d2298b31d1dbe4bcd35e5"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:aed5fa89efb4f89f37bc51d08cfd01f6b"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classGlib_1_1ValueBase.html#aed5fa89efb4f89f37bc51d08cfd01f6b">~ValueBase</a> () noexcept</td></tr> <tr class="separator:aed5fa89efb4f89f37bc51d08cfd01f6b"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a1659121f15f5e840cc1eba2b0aaefbb1"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classGlib_1_1ValueBase.html#a1659121f15f5e840cc1eba2b0aaefbb1">init</a> (GType type)</td></tr> <tr class="memdesc:a1659121f15f5e840cc1eba2b0aaefbb1"><td class="mdescLeft"> </td><td class="mdescRight">Setup the GValue for storing the specified <em>type</em>. <a href="#a1659121f15f5e840cc1eba2b0aaefbb1">More...</a><br /></td></tr> <tr class="separator:a1659121f15f5e840cc1eba2b0aaefbb1"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a1d31168845e6bb144a66904e813240e2"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classGlib_1_1ValueBase.html#a1d31168845e6bb144a66904e813240e2">init</a> (const GValue* value)</td></tr> <tr class="memdesc:a1d31168845e6bb144a66904e813240e2"><td class="mdescLeft"> </td><td class="mdescRight">Setup the GValue storing the type and value of the specified <em>value</em>. <a href="#a1d31168845e6bb144a66904e813240e2">More...</a><br /></td></tr> <tr class="separator:a1d31168845e6bb144a66904e813240e2"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a30c7bde0d772b87dc890da7a197c4494"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classGlib_1_1ValueBase.html#a30c7bde0d772b87dc890da7a197c4494">reset</a> ()</td></tr> <tr class="memdesc:a30c7bde0d772b87dc890da7a197c4494"><td class="mdescLeft"> </td><td class="mdescRight">Reset contents to the default value of its type. <a href="#a30c7bde0d772b87dc890da7a197c4494">More...</a><br /></td></tr> <tr class="separator:a30c7bde0d772b87dc890da7a197c4494"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a33253264f47c41526ede3f78afdbe1e4"><td class="memItemLeft" align="right" valign="top">GValue* </td><td class="memItemRight" valign="bottom"><a class="el" href="classGlib_1_1ValueBase.html#a33253264f47c41526ede3f78afdbe1e4">gobj</a> ()</td></tr> <tr class="separator:a33253264f47c41526ede3f78afdbe1e4"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:ab8050dbb94b1708d7786d797a4657d2f"><td class="memItemLeft" align="right" valign="top">const GValue* </td><td class="memItemRight" valign="bottom"><a class="el" href="classGlib_1_1ValueBase.html#ab8050dbb94b1708d7786d797a4657d2f">gobj</a> () const </td></tr> <tr class="separator:ab8050dbb94b1708d7786d797a4657d2f"><td class="memSeparator" colspan="2"> </td></tr> </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pro-attribs"></a> Protected Attributes</h2></td></tr> <tr class="memitem:a3472d8f4c0bd6513c939ee3a4633be0f"><td class="memItemLeft" align="right" valign="top">GValue </td><td class="memItemRight" valign="bottom"><a class="el" href="classGlib_1_1ValueBase.html#a3472d8f4c0bd6513c939ee3a4633be0f">gobject_</a></td></tr> <tr class="separator:a3472d8f4c0bd6513c939ee3a4633be0f"><td class="memSeparator" colspan="2"> </td></tr> </table> <h2 class="groupheader">Constructor & Destructor Documentation</h2> <a class="anchor" id="a066cc345d62be564ff53b25bd11e62e5"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">Glib::ValueBase::ValueBase </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Initializes the GValue, but without a type. </p> <p>You have to call <a class="el" href="classGlib_1_1ValueBase.html#a1659121f15f5e840cc1eba2b0aaefbb1" title="Setup the GValue for storing the specified type. ">init()</a> before using the set(), <a class="elRef" href="http://gcc.gnu.org/onlinedocs/libstdc++/latest-doxygen/a01483.html#ga7f7d7109f98b031678c904fdd2a3613c">get()</a>, or <a class="el" href="classGlib_1_1ValueBase.html#a30c7bde0d772b87dc890da7a197c4494" title="Reset contents to the default value of its type. ">reset()</a> methods. </p> </div> </div> <a class="anchor" id="a1af751f0ac927df5ccba7d584cb9e63f"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">Glib::ValueBase::ValueBase </td> <td>(</td> <td class="paramtype">const <a class="el" href="classGlib_1_1ValueBase.html">ValueBase</a>& </td> <td class="paramname"><em>other</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> </div> </div> <a class="anchor" id="aed5fa89efb4f89f37bc51d08cfd01f6b"></a> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">Glib::ValueBase::~ValueBase </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">noexcept</span></span> </td> </tr> </table> </div><div class="memdoc"> </div> </div> <h2 class="groupheader">Member Function Documentation</h2> <a class="anchor" id="a33253264f47c41526ede3f78afdbe1e4"></a> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">GValue* Glib::ValueBase::gobj </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">inline</span></span> </td> </tr> </table> </div><div class="memdoc"> </div> </div> <a class="anchor" id="ab8050dbb94b1708d7786d797a4657d2f"></a> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">const GValue* Glib::ValueBase::gobj </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">inline</span></span> </td> </tr> </table> </div><div class="memdoc"> </div> </div> <a class="anchor" id="a1659121f15f5e840cc1eba2b0aaefbb1"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Glib::ValueBase::init </td> <td>(</td> <td class="paramtype">GType </td> <td class="paramname"><em>type</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Setup the GValue for storing the specified <em>type</em>. </p> <p>The contents will be initialized to the default value for this type. Note that <a class="el" href="classGlib_1_1ValueBase.html#a1659121f15f5e840cc1eba2b0aaefbb1" title="Setup the GValue for storing the specified type. ">init()</a> should never be called twice.</p> <p><a class="el" href="classGlib_1_1ValueBase.html#a1659121f15f5e840cc1eba2b0aaefbb1" title="Setup the GValue for storing the specified type. ">init()</a> is not implemented as constructor, to avoid the necessity to implement a forward constructor in each derived class.</p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">type</td><td>The type that the <a class="el" href="classGlib_1_1Value.html" title="Generic value implementation for custom types. ">Value</a> should hold. </td></tr> </table> </dd> </dl> </div> </div> <a class="anchor" id="a1d31168845e6bb144a66904e813240e2"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Glib::ValueBase::init </td> <td>(</td> <td class="paramtype">const GValue * </td> <td class="paramname"><em>value</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Setup the GValue storing the type and value of the specified <em>value</em>. </p> <p>Note that <a class="el" href="classGlib_1_1ValueBase.html#a1659121f15f5e840cc1eba2b0aaefbb1" title="Setup the GValue for storing the specified type. ">init()</a> should never be called twice.</p> <p><a class="el" href="classGlib_1_1ValueBase.html#a1659121f15f5e840cc1eba2b0aaefbb1" title="Setup the GValue for storing the specified type. ">init()</a> is not implemented as constructor, to avoid the necessity to implement a forward constructor in each derived class.</p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">value</td><td>The existing GValue. </td></tr> </table> </dd> </dl> </div> </div> <a class="anchor" id="a73ceadee7e4d2298b31d1dbe4bcd35e5"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classGlib_1_1ValueBase.html">ValueBase</a>& Glib::ValueBase::operator= </td> <td>(</td> <td class="paramtype">const <a class="el" href="classGlib_1_1ValueBase.html">ValueBase</a>& </td> <td class="paramname"><em>other</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> </div> </div> <a class="anchor" id="a30c7bde0d772b87dc890da7a197c4494"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Glib::ValueBase::reset </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Reset contents to the default value of its type. </p> </div> </div> <h2 class="groupheader">Member Data Documentation</h2> <a class="anchor" id="a3472d8f4c0bd6513c939ee3a4633be0f"></a> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">GValue Glib::ValueBase::gobject_</td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">protected</span></span> </td> </tr> </table> </div><div class="memdoc"> </div> </div> </div><!-- contents --> <!-- start footer part --> <hr class="footer"/><address class="footer"><small> Generated on Tue Mar 19 2019 09:56:47 for glibmm by  <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/> </a> 1.8.11 </small></address> </body> </html>