<!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"/> <title>ICU 52.1: icu::TimeUnitFormat 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" /> </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 style="padding-left: 0.5em;"> <div id="projectname">ICU 52.1  <span id="projectnumber">52.1</span> </div> </td> </tr> </tbody> </table> </div> <!-- end header part --> <!-- Generated by Doxygen 1.8.1.2 --> <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>Data Structures</span></a></li> <li><a href="files.html"><span>Files</span></a></li> </ul> </div> <div id="navrow2" class="tabs2"> <ul class="tablist"> <li><a href="annotated.html"><span>Data Structures</span></a></li> <li><a href="classes.html"><span>Data Structure Index</span></a></li> <li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li> <li><a href="functions.html"><span>Data Fields</span></a></li> </ul> </div> <div id="nav-path" class="navpath"> <ul> <li class="navelem"><a class="el" href="namespaceicu.html">icu</a></li><li class="navelem"><a class="el" href="classicu_1_1TimeUnitFormat.html">TimeUnitFormat</a></li> </ul> </div> </div><!-- top --> <div class="header"> <div class="summary"> <a href="#pub-methods">Public Member Functions</a> | <a href="#pub-static-methods">Static Public Member Functions</a> </div> <div class="headertitle"> <div class="title">icu::TimeUnitFormat Class Reference</div> </div> </div><!--header--> <div class="contents"> <p><a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> or parse a <a class="el" href="classicu_1_1TimeUnitAmount.html" title="Express a duration as a time unit and number.">TimeUnitAmount</a>, using plural rules for the units where available. <a href="classicu_1_1TimeUnitFormat.html#details">More...</a></p> <p><code>#include <<a class="el" href="tmutfmt_8h_source.html">tmutfmt.h</a>></code></p> <div class="dynheader"> Inheritance diagram for icu::TimeUnitFormat:</div> <div class="dyncontent"> <div class="center"> <img src="classicu_1_1TimeUnitFormat.png" usemap="#icu::TimeUnitFormat_map" alt=""/> <map id="icu::TimeUnitFormat_map" name="icu::TimeUnitFormat_map"> <area href="classicu_1_1MeasureFormat.html" title="A formatter for measure objects." alt="icu::MeasureFormat" shape="rect" coords="0,168,124,192"/> <area href="classicu_1_1Format.html" title="Base class for all formats." alt="icu::Format" shape="rect" coords="0,112,124,136"/> <area href="classicu_1_1UObject.html" title="UObject is the common ICU "boilerplate" class." alt="icu::UObject" shape="rect" coords="0,56,124,80"/> <area href="classicu_1_1UMemory.html" title="UMemory is the common ICU base class." alt="icu::UMemory" shape="rect" coords="0,0,124,24"/> </map> </div></div> <table class="memberdecls"> <tr class="heading"><td colspan="2"><h2><a name="pub-methods"></a> Public Member Functions</h2></td></tr> <tr class="memitem:a5aae4577405f403834160a7f1809f61e"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#a5aae4577405f403834160a7f1809f61e">TimeUnitFormat</a> (<a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &status)</td></tr> <tr class="memdesc:a5aae4577405f403834160a7f1809f61e"><td class="mdescLeft"> </td><td class="mdescRight">Create <a class="el" href="classicu_1_1TimeUnitFormat.html" title="Format or parse a TimeUnitAmount, using plural rules for the units where available.">TimeUnitFormat</a> with default locale, and full name style. <a href="#a5aae4577405f403834160a7f1809f61e"></a><br/></td></tr> <tr class="memitem:a11f6aefb6b3036bac2954f38d4373856"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#a11f6aefb6b3036bac2954f38d4373856">TimeUnitFormat</a> (const <a class="el" href="classicu_1_1Locale.html">Locale</a> &locale, <a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &status)</td></tr> <tr class="memdesc:a11f6aefb6b3036bac2954f38d4373856"><td class="mdescLeft"> </td><td class="mdescRight">Create <a class="el" href="classicu_1_1TimeUnitFormat.html" title="Format or parse a TimeUnitAmount, using plural rules for the units where available.">TimeUnitFormat</a> given locale, and full name style. <a href="#a11f6aefb6b3036bac2954f38d4373856"></a><br/></td></tr> <tr class="memitem:ab707db6de5c751a98618ebbb3c0384d6"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#ab707db6de5c751a98618ebbb3c0384d6">TimeUnitFormat</a> (const <a class="el" href="classicu_1_1Locale.html">Locale</a> &locale, <a class="el" href="tmutfmt_8h.html#ace3ab3a9adff9b70f2e8f153e0f18e3f">UTimeUnitFormatStyle</a> style, <a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &status)</td></tr> <tr class="memdesc:ab707db6de5c751a98618ebbb3c0384d6"><td class="mdescLeft"> </td><td class="mdescRight">Create <a class="el" href="classicu_1_1TimeUnitFormat.html" title="Format or parse a TimeUnitAmount, using plural rules for the units where available.">TimeUnitFormat</a> given locale and style. <a href="#ab707db6de5c751a98618ebbb3c0384d6"></a><br/></td></tr> <tr class="memitem:a29e77f5c6d65a396fbe94219cdabaa48"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#a29e77f5c6d65a396fbe94219cdabaa48">TimeUnitFormat</a> (const <a class="el" href="classicu_1_1TimeUnitFormat.html">TimeUnitFormat</a> &)</td></tr> <tr class="memdesc:a29e77f5c6d65a396fbe94219cdabaa48"><td class="mdescLeft"> </td><td class="mdescRight">Copy constructor. <a href="#a29e77f5c6d65a396fbe94219cdabaa48"></a><br/></td></tr> <tr class="memitem:ae6de877387e3ead7a212e9e6827bc342"><td class="memItemLeft" align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#ae6de877387e3ead7a212e9e6827bc342">~TimeUnitFormat</a> ()</td></tr> <tr class="memdesc:ae6de877387e3ead7a212e9e6827bc342"><td class="mdescLeft"> </td><td class="mdescRight">deconstructor <a href="#ae6de877387e3ead7a212e9e6827bc342"></a><br/></td></tr> <tr class="memitem:ae8cb2d782de67cceaa9b44fb70a870c1"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classicu_1_1Format.html">Format</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#ae8cb2d782de67cceaa9b44fb70a870c1">clone</a> (void) const </td></tr> <tr class="memdesc:ae8cb2d782de67cceaa9b44fb70a870c1"><td class="mdescLeft"> </td><td class="mdescRight">Clone this <a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> object polymorphically. <a href="#ae8cb2d782de67cceaa9b44fb70a870c1"></a><br/></td></tr> <tr class="memitem:aba3485a783dd724982cc3ed2a8ed986a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classicu_1_1TimeUnitFormat.html">TimeUnitFormat</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#aba3485a783dd724982cc3ed2a8ed986a">operator=</a> (const <a class="el" href="classicu_1_1TimeUnitFormat.html">TimeUnitFormat</a> &other)</td></tr> <tr class="memdesc:aba3485a783dd724982cc3ed2a8ed986a"><td class="mdescLeft"> </td><td class="mdescRight">Assignment operator. <a href="#aba3485a783dd724982cc3ed2a8ed986a"></a><br/></td></tr> <tr class="memitem:afbd6320787f646c9b95c64b71e1f47c3"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="umachine_8h.html#a349ef00011f20ccd1d3b424445681aa5">UBool</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#afbd6320787f646c9b95c64b71e1f47c3">operator==</a> (const <a class="el" href="classicu_1_1Format.html">Format</a> &other) const </td></tr> <tr class="memdesc:afbd6320787f646c9b95c64b71e1f47c3"><td class="mdescLeft"> </td><td class="mdescRight">Return true if the given <a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> objects are semantically equal. <a href="#afbd6320787f646c9b95c64b71e1f47c3"></a><br/></td></tr> <tr class="memitem:a3a93826570265111194c4951cfcba9fa"><td class="memItemLeft" align="right" valign="top"><a class="el" href="umachine_8h.html#a349ef00011f20ccd1d3b424445681aa5">UBool</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#a3a93826570265111194c4951cfcba9fa">operator!=</a> (const <a class="el" href="classicu_1_1Format.html">Format</a> &other) const </td></tr> <tr class="memdesc:a3a93826570265111194c4951cfcba9fa"><td class="mdescLeft"> </td><td class="mdescRight">Return true if the given <a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> objects are not semantically equal. <a href="#a3a93826570265111194c4951cfcba9fa"></a><br/></td></tr> <tr class="memitem:ab82c6199888dc555cf8f695c99e5be37"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#ab82c6199888dc555cf8f695c99e5be37">setLocale</a> (const <a class="el" href="classicu_1_1Locale.html">Locale</a> &locale, <a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &status)</td></tr> <tr class="memdesc:ab82c6199888dc555cf8f695c99e5be37"><td class="mdescLeft"> </td><td class="mdescRight">Set the locale used for formatting or parsing. <a href="#ab82c6199888dc555cf8f695c99e5be37"></a><br/></td></tr> <tr class="memitem:a578dadf8944292e071a2b5a86b9b135f"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#a578dadf8944292e071a2b5a86b9b135f">setNumberFormat</a> (const <a class="el" href="classicu_1_1NumberFormat.html">NumberFormat</a> &<a class="el" href="classicu_1_1TimeUnitFormat.html#a1675d751098ec0061f039423d8200bcc">format</a>, <a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &status)</td></tr> <tr class="memdesc:a578dadf8944292e071a2b5a86b9b135f"><td class="mdescLeft"> </td><td class="mdescRight">Set the number format used for formatting or parsing. <a href="#a578dadf8944292e071a2b5a86b9b135f"></a><br/></td></tr> <tr class="memitem:a1675d751098ec0061f039423d8200bcc"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classicu_1_1UnicodeString.html">UnicodeString</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#a1675d751098ec0061f039423d8200bcc">format</a> (const <a class="el" href="classicu_1_1Formattable.html">Formattable</a> &obj, <a class="el" href="classicu_1_1UnicodeString.html">UnicodeString</a> &toAppendTo, <a class="el" href="classicu_1_1FieldPosition.html">FieldPosition</a> &pos, <a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &status) const </td></tr> <tr class="memdesc:a1675d751098ec0061f039423d8200bcc"><td class="mdescLeft"> </td><td class="mdescRight"><a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> a <a class="el" href="classicu_1_1TimeUnitAmount.html" title="Express a duration as a time unit and number.">TimeUnitAmount</a>. <a href="#a1675d751098ec0061f039423d8200bcc"></a><br/></td></tr> <tr class="memitem:a42f817d0a828a836d60720a5bb4bd1a0"><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#a42f817d0a828a836d60720a5bb4bd1a0">parseObject</a> (const <a class="el" href="classicu_1_1UnicodeString.html">UnicodeString</a> &source, <a class="el" href="classicu_1_1Formattable.html">Formattable</a> &result, <a class="el" href="classicu_1_1ParsePosition.html">ParsePosition</a> &pos) const </td></tr> <tr class="memdesc:a42f817d0a828a836d60720a5bb4bd1a0"><td class="mdescLeft"> </td><td class="mdescRight">Parse a <a class="el" href="classicu_1_1TimeUnitAmount.html" title="Express a duration as a time unit and number.">TimeUnitAmount</a>. <a href="#a42f817d0a828a836d60720a5bb4bd1a0"></a><br/></td></tr> <tr class="memitem:a94cf22aa31269644c2ab0f70ee8bd1ca"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="uobject_8h.html#a22af10545208a455a6e884008df48e9f">UClassID</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#a94cf22aa31269644c2ab0f70ee8bd1ca">getDynamicClassID</a> (void) const </td></tr> <tr class="memdesc:a94cf22aa31269644c2ab0f70ee8bd1ca"><td class="mdescLeft"> </td><td class="mdescRight">Returns a unique class ID POLYMORPHICALLY. <a href="#a94cf22aa31269644c2ab0f70ee8bd1ca"></a><br/></td></tr> <tr class="inherit_header pub_methods_classicu_1_1MeasureFormat"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_classicu_1_1MeasureFormat')"><img src="closed.png" alt="-"/> Public Member Functions inherited from <a class="el" href="classicu_1_1MeasureFormat.html">icu::MeasureFormat</a></td></tr> <tr class="memitem:a8c7c78a6ac0dec94173f7755dbfe803a inherit pub_methods_classicu_1_1MeasureFormat"><td class="memItemLeft" align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1MeasureFormat.html#a8c7c78a6ac0dec94173f7755dbfe803a">~MeasureFormat</a> ()</td></tr> <tr class="memdesc:a8c7c78a6ac0dec94173f7755dbfe803a inherit pub_methods_classicu_1_1MeasureFormat"><td class="mdescLeft"> </td><td class="mdescRight">Destructor. <a href="#a8c7c78a6ac0dec94173f7755dbfe803a"></a><br/></td></tr> <tr class="inherit_header pub_methods_classicu_1_1Format"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_classicu_1_1Format')"><img src="closed.png" alt="-"/> Public Member Functions inherited from <a class="el" href="classicu_1_1Format.html">icu::Format</a></td></tr> <tr class="memitem:ab5b0d091d165c5576af62b3ee246058a inherit pub_methods_classicu_1_1Format"><td class="memItemLeft" align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1Format.html#ab5b0d091d165c5576af62b3ee246058a">~Format</a> ()</td></tr> <tr class="memdesc:ab5b0d091d165c5576af62b3ee246058a inherit pub_methods_classicu_1_1Format"><td class="mdescLeft"> </td><td class="mdescRight">Destructor. <a href="#ab5b0d091d165c5576af62b3ee246058a"></a><br/></td></tr> <tr class="memitem:ab510bded8f13465d98b950db03f15297 inherit pub_methods_classicu_1_1Format"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classicu_1_1UnicodeString.html">UnicodeString</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1Format.html#ab510bded8f13465d98b950db03f15297">format</a> (const <a class="el" href="classicu_1_1Formattable.html">Formattable</a> &obj, <a class="el" href="classicu_1_1UnicodeString.html">UnicodeString</a> &appendTo, <a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &status) const </td></tr> <tr class="memdesc:ab510bded8f13465d98b950db03f15297 inherit pub_methods_classicu_1_1Format"><td class="mdescLeft"> </td><td class="mdescRight">Formats an object to produce a string. <a href="#ab510bded8f13465d98b950db03f15297"></a><br/></td></tr> <tr class="memitem:a3a24241eabda236878b4f93395ca5218 inherit pub_methods_classicu_1_1Format"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classicu_1_1UnicodeString.html">UnicodeString</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1Format.html#a3a24241eabda236878b4f93395ca5218">format</a> (const <a class="el" href="classicu_1_1Formattable.html">Formattable</a> &obj, <a class="el" href="classicu_1_1UnicodeString.html">UnicodeString</a> &appendTo, <a class="el" href="classicu_1_1FieldPositionIterator.html">FieldPositionIterator</a> *posIter, <a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &status) const </td></tr> <tr class="memdesc:a3a24241eabda236878b4f93395ca5218 inherit pub_methods_classicu_1_1Format"><td class="mdescLeft"> </td><td class="mdescRight"><a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> an object to produce a string. <a href="#a3a24241eabda236878b4f93395ca5218"></a><br/></td></tr> <tr class="memitem:a14835811eb14a1826b8529704de07bbf inherit pub_methods_classicu_1_1Format"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1Format.html#a14835811eb14a1826b8529704de07bbf">parseObject</a> (const <a class="el" href="classicu_1_1UnicodeString.html">UnicodeString</a> &source, <a class="el" href="classicu_1_1Formattable.html">Formattable</a> &result, <a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &status) const </td></tr> <tr class="memdesc:a14835811eb14a1826b8529704de07bbf inherit pub_methods_classicu_1_1Format"><td class="mdescLeft"> </td><td class="mdescRight">Parses a string to produce an object. <a href="#a14835811eb14a1826b8529704de07bbf"></a><br/></td></tr> <tr class="memitem:a5064d4b46b3f5882fb339960089bf87e inherit pub_methods_classicu_1_1Format"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classicu_1_1Locale.html">Locale</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1Format.html#a5064d4b46b3f5882fb339960089bf87e">getLocale</a> (<a class="el" href="uloc_8h.html#adf053345d343f8d82ae080f7a5871f34">ULocDataLocaleType</a> type, <a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &status) const </td></tr> <tr class="memdesc:a5064d4b46b3f5882fb339960089bf87e inherit pub_methods_classicu_1_1Format"><td class="mdescLeft"> </td><td class="mdescRight">Get the locale for this format object. <a href="#a5064d4b46b3f5882fb339960089bf87e"></a><br/></td></tr> <tr class="memitem:a1b0f21f3e3f6cc3ed196af5e6559b421 inherit pub_methods_classicu_1_1Format"><td class="memItemLeft" align="right" valign="top">const char * </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1Format.html#a1b0f21f3e3f6cc3ed196af5e6559b421">getLocaleID</a> (<a class="el" href="uloc_8h.html#adf053345d343f8d82ae080f7a5871f34">ULocDataLocaleType</a> type, <a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &status) const </td></tr> <tr class="memdesc:a1b0f21f3e3f6cc3ed196af5e6559b421 inherit pub_methods_classicu_1_1Format"><td class="mdescLeft"> </td><td class="mdescRight">Get the locale for this format object. <a href="#a1b0f21f3e3f6cc3ed196af5e6559b421"></a><br/></td></tr> <tr class="inherit_header pub_methods_classicu_1_1UObject"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_classicu_1_1UObject')"><img src="closed.png" alt="-"/> Public Member Functions inherited from <a class="el" href="classicu_1_1UObject.html">icu::UObject</a></td></tr> <tr class="memitem:af10026497704f510d3d1f2eff50acb18 inherit pub_methods_classicu_1_1UObject"><td class="memItemLeft" align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1UObject.html#af10026497704f510d3d1f2eff50acb18">~UObject</a> ()</td></tr> <tr class="memdesc:af10026497704f510d3d1f2eff50acb18 inherit pub_methods_classicu_1_1UObject"><td class="mdescLeft"> </td><td class="mdescRight">Destructor. <a href="#af10026497704f510d3d1f2eff50acb18"></a><br/></td></tr> </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2><a name="pub-static-methods"></a> Static Public Member Functions</h2></td></tr> <tr class="memitem:a7e7d9ddb28042723371da1ebf2f1c4a2"><td class="memItemLeft" align="right" valign="top">static <a class="el" href="uobject_8h.html#a22af10545208a455a6e884008df48e9f">UClassID</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1TimeUnitFormat.html#a7e7d9ddb28042723371da1ebf2f1c4a2">getStaticClassID</a> (void)</td></tr> <tr class="memdesc:a7e7d9ddb28042723371da1ebf2f1c4a2"><td class="mdescLeft"> </td><td class="mdescRight">Return the class ID for this class. <a href="#a7e7d9ddb28042723371da1ebf2f1c4a2"></a><br/></td></tr> <tr class="inherit_header pub_static_methods_classicu_1_1MeasureFormat"><td colspan="2" onclick="javascript:toggleInherit('pub_static_methods_classicu_1_1MeasureFormat')"><img src="closed.png" alt="-"/> Static Public Member Functions inherited from <a class="el" href="classicu_1_1MeasureFormat.html">icu::MeasureFormat</a></td></tr> <tr class="memitem:ac95d2a9807fa5e97e9d94a1dedcf5580 inherit pub_static_methods_classicu_1_1MeasureFormat"><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classicu_1_1MeasureFormat.html">MeasureFormat</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1MeasureFormat.html#ac95d2a9807fa5e97e9d94a1dedcf5580">createCurrencyFormat</a> (const <a class="el" href="classicu_1_1Locale.html">Locale</a> &locale, <a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &ec)</td></tr> <tr class="memdesc:ac95d2a9807fa5e97e9d94a1dedcf5580 inherit pub_static_methods_classicu_1_1MeasureFormat"><td class="mdescLeft"> </td><td class="mdescRight">Return a formatter for <a class="el" href="classicu_1_1CurrencyAmount.html" title="A currency together with a numeric amount, such as 200 USD.">CurrencyAmount</a> objects in the given locale. <a href="#ac95d2a9807fa5e97e9d94a1dedcf5580"></a><br/></td></tr> <tr class="memitem:a13e8a2dd1ed138a2aeeb7e191405cd80 inherit pub_static_methods_classicu_1_1MeasureFormat"><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classicu_1_1MeasureFormat.html">MeasureFormat</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1MeasureFormat.html#a13e8a2dd1ed138a2aeeb7e191405cd80">createCurrencyFormat</a> (<a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> &ec)</td></tr> <tr class="memdesc:a13e8a2dd1ed138a2aeeb7e191405cd80 inherit pub_static_methods_classicu_1_1MeasureFormat"><td class="mdescLeft"> </td><td class="mdescRight">Return a formatter for <a class="el" href="classicu_1_1CurrencyAmount.html" title="A currency together with a numeric amount, such as 200 USD.">CurrencyAmount</a> objects in the default locale. <a href="#a13e8a2dd1ed138a2aeeb7e191405cd80"></a><br/></td></tr> </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2><a name="inherited"></a> Additional Inherited Members</h2></td></tr> <tr class="inherit_header pro_methods_classicu_1_1MeasureFormat"><td colspan="2" onclick="javascript:toggleInherit('pro_methods_classicu_1_1MeasureFormat')"><img src="closed.png" alt="-"/> Protected Member Functions inherited from <a class="el" href="classicu_1_1MeasureFormat.html">icu::MeasureFormat</a></td></tr> <tr class="memitem:ad53a53a8d01785c369a2d2522f37f833 inherit pro_methods_classicu_1_1MeasureFormat"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1MeasureFormat.html#ad53a53a8d01785c369a2d2522f37f833">MeasureFormat</a> ()</td></tr> <tr class="memdesc:ad53a53a8d01785c369a2d2522f37f833 inherit pro_methods_classicu_1_1MeasureFormat"><td class="mdescLeft"> </td><td class="mdescRight">Default constructor. <a href="#ad53a53a8d01785c369a2d2522f37f833"></a><br/></td></tr> <tr class="inherit_header pro_static_methods_classicu_1_1Format"><td colspan="2" onclick="javascript:toggleInherit('pro_static_methods_classicu_1_1Format')"><img src="closed.png" alt="-"/> Static Protected Member Functions inherited from <a class="el" href="classicu_1_1Format.html">icu::Format</a></td></tr> <tr class="memitem:a4667230f833245c55ba081c163d8bb71 inherit pro_static_methods_classicu_1_1Format"><td class="memItemLeft" align="right" valign="top">static void </td><td class="memItemRight" valign="bottom"><a class="el" href="classicu_1_1Format.html#a4667230f833245c55ba081c163d8bb71">syntaxError</a> (const <a class="el" href="classicu_1_1UnicodeString.html">UnicodeString</a> &pattern, int32_t pos, <a class="el" href="structUParseError.html">UParseError</a> &parseError)</td></tr> <tr class="memdesc:a4667230f833245c55ba081c163d8bb71 inherit pro_static_methods_classicu_1_1Format"><td class="mdescLeft"> </td><td class="mdescRight">Simple function for initializing a <a class="el" href="structUParseError.html" title="A UParseError struct is used to returned detailed information about parsing errors.">UParseError</a> from a <a class="el" href="classicu_1_1UnicodeString.html" title="UnicodeString is a string class that stores Unicode characters directly and provides similar function...">UnicodeString</a>. <a href="#a4667230f833245c55ba081c163d8bb71"></a><br/></td></tr> </table> <a name="details" id="details"></a><h2>Detailed Description</h2> <div class="textblock"><p><a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> or parse a <a class="el" href="classicu_1_1TimeUnitAmount.html" title="Express a duration as a time unit and number.">TimeUnitAmount</a>, using plural rules for the units where available. </p> <p>Code Sample: </p> <pre> // create time unit amount instance - a combination of Number and time unit UErrorCode status = U_ZERO_ERROR; TimeUnitAmount* source = new TimeUnitAmount(2, TimeUnit::UTIMEUNIT_YEAR, status); // create time unit format instance TimeUnitFormat* format = new <a class="el" href="classicu_1_1TimeUnitFormat.html" title="Format or parse a TimeUnitAmount, using plural rules for the units where available.">TimeUnitFormat</a>(<a class="el" href="classicu_1_1Locale.html" title="A Locale object represents a specific geographical, political, or cultural region.">Locale</a>("en"), status); // format a time unit amount <a class="el" href="classicu_1_1UnicodeString.html" title="UnicodeString is a string class that stores Unicode characters directly and provides similar function...">UnicodeString</a> formatted; <a class="el" href="classicu_1_1Formattable.html" title="Formattable objects can be passed to the Format class or its subclasses for formatting.">Formattable</a> formattable; if (<a class="el" href="utypes_8h.html#a527f2c69e6b2e3b2c53ad8a99fb36711" title="Does the error code indicate success?">U_SUCCESS(status)</a>) { formattable.adoptObject(source); formatted = ((Format*)format)->format(formattable, formatted, status); <a class="el" href="classicu_1_1Formattable.html" title="Formattable objects can be passed to the Format class or its subclasses for formatting.">Formattable</a> result; ((Format*)format)->parseObject(formatted, result, status); if (<a class="el" href="utypes_8h.html#a527f2c69e6b2e3b2c53ad8a99fb36711" title="Does the error code indicate success?">U_SUCCESS(status)</a>) { assert (result == formattable); } } </pre><dl class="section see"><dt>See Also</dt><dd><a class="el" href="classicu_1_1TimeUnitAmount.html" title="Express a duration as a time unit and number.">TimeUnitAmount</a> </dd> <dd> <a class="el" href="classicu_1_1TimeUnitFormat.html" title="Format or parse a TimeUnitAmount, using plural rules for the units where available.">TimeUnitFormat</a> </dd></dl> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004103">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> <p>Definition at line <a class="el" href="tmutfmt_8h_source.html#l00080">80</a> of file <a class="el" href="tmutfmt_8h_source.html">tmutfmt.h</a>.</p> </div><h2>Constructor & Destructor Documentation</h2> <a class="anchor" id="a5aae4577405f403834160a7f1809f61e"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">icu::TimeUnitFormat::TimeUnitFormat </td> <td>(</td> <td class="paramtype"><a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> & </td> <td class="paramname"><em>status</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Create <a class="el" href="classicu_1_1TimeUnitFormat.html" title="Format or parse a TimeUnitAmount, using plural rules for the units where available.">TimeUnitFormat</a> with default locale, and full name style. </p> <p>Use setLocale and/or setFormat to modify. </p> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004104">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> </div> </div> <a class="anchor" id="a11f6aefb6b3036bac2954f38d4373856"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">icu::TimeUnitFormat::TimeUnitFormat </td> <td>(</td> <td class="paramtype">const <a class="el" href="classicu_1_1Locale.html">Locale</a> & </td> <td class="paramname"><em>locale</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> & </td> <td class="paramname"><em>status</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div><div class="memdoc"> <p>Create <a class="el" href="classicu_1_1TimeUnitFormat.html" title="Format or parse a TimeUnitAmount, using plural rules for the units where available.">TimeUnitFormat</a> given locale, and full name style. </p> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004105">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> </div> </div> <a class="anchor" id="ab707db6de5c751a98618ebbb3c0384d6"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">icu::TimeUnitFormat::TimeUnitFormat </td> <td>(</td> <td class="paramtype">const <a class="el" href="classicu_1_1Locale.html">Locale</a> & </td> <td class="paramname"><em>locale</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="tmutfmt_8h.html#ace3ab3a9adff9b70f2e8f153e0f18e3f">UTimeUnitFormatStyle</a> </td> <td class="paramname"><em>style</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> & </td> <td class="paramname"><em>status</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div><div class="memdoc"> <p>Create <a class="el" href="classicu_1_1TimeUnitFormat.html" title="Format or parse a TimeUnitAmount, using plural rules for the units where available.">TimeUnitFormat</a> given locale and style. </p> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004106">Stable:</a></b></dt><dd>ICU 4.8 </dd></dl> </div> </div> <a class="anchor" id="a29e77f5c6d65a396fbe94219cdabaa48"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">icu::TimeUnitFormat::TimeUnitFormat </td> <td>(</td> <td class="paramtype">const <a class="el" href="classicu_1_1TimeUnitFormat.html">TimeUnitFormat</a> & </td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Copy constructor. </p> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004107">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> </div> </div> <a class="anchor" id="ae6de877387e3ead7a212e9e6827bc342"></a> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">virtual icu::TimeUnitFormat::~TimeUnitFormat </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p>deconstructor </p> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004108">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> </div> </div> <h2>Member Function Documentation</h2> <a class="anchor" id="ae8cb2d782de67cceaa9b44fb70a870c1"></a> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">virtual <a class="el" href="classicu_1_1Format.html">Format</a>* icu::TimeUnitFormat::clone </td> <td>(</td> <td class="paramtype">void </td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p>Clone this <a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> object polymorphically. </p> <p>The caller owns the result and should delete it when done. </p> <dl class="section return"><dt>Returns</dt><dd>A copy of the object. </dd></dl> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004109">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> <p>Implements <a class="el" href="classicu_1_1Format.html#ad606fa4ed45908fe4220085c6276c65a">icu::Format</a>.</p> </div> </div> <a class="anchor" id="a1675d751098ec0061f039423d8200bcc"></a> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">virtual <a class="el" href="classicu_1_1UnicodeString.html">UnicodeString</a>& icu::TimeUnitFormat::format </td> <td>(</td> <td class="paramtype">const <a class="el" href="classicu_1_1Formattable.html">Formattable</a> & </td> <td class="paramname"><em>obj</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="classicu_1_1UnicodeString.html">UnicodeString</a> & </td> <td class="paramname"><em>toAppendTo</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="classicu_1_1FieldPosition.html">FieldPosition</a> & </td> <td class="paramname"><em>pos</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> & </td> <td class="paramname"><em>status</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td> const</td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p><a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> a <a class="el" href="classicu_1_1TimeUnitAmount.html" title="Express a duration as a time unit and number.">TimeUnitAmount</a>. </p> <p>If the formattable object is not a time unit amount object, or the number in time unit amount is not a double type or long type numeric, it returns a failing status: U_ILLEGAL_ARGUMENT_ERROR. </p> <dl class="section see"><dt>See Also</dt><dd><a class="el" href="classicu_1_1Format.html#a68fb0a8875645f7ab11bb5230c03c212" title="Format an object to produce a string.">Format::format(const Formattable&, UnicodeString&, FieldPosition&, UErrorCode&) const</a> </dd></dl> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004115">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> <p>Implements <a class="el" href="classicu_1_1Format.html#a68fb0a8875645f7ab11bb5230c03c212">icu::Format</a>.</p> </div> </div> <a class="anchor" id="a94cf22aa31269644c2ab0f70ee8bd1ca"></a> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">virtual <a class="el" href="uobject_8h.html#a22af10545208a455a6e884008df48e9f">UClassID</a> icu::TimeUnitFormat::getDynamicClassID </td> <td>(</td> <td class="paramtype">void </td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p>Returns a unique class ID POLYMORPHICALLY. </p> <p>Pure virtual override. This method is to implement a simple version of RTTI, since not all C++ compilers support genuine RTTI. Polymorphic <a class="el" href="classicu_1_1TimeUnitFormat.html#afbd6320787f646c9b95c64b71e1f47c3" title="Return true if the given Format objects are semantically equal.">operator==()</a> and <a class="el" href="classicu_1_1TimeUnitFormat.html#ae8cb2d782de67cceaa9b44fb70a870c1" title="Clone this Format object polymorphically.">clone()</a> methods call this method.</p> <dl class="section return"><dt>Returns</dt><dd>The class ID for this object. All objects of a given class have the same class ID. Objects of other classes have different class IDs. </dd></dl> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004118">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> <p>Reimplemented from <a class="el" href="classicu_1_1UObject.html#a1aa93096e880907080b503ff1fb0f8bc">icu::UObject</a>.</p> </div> </div> <a class="anchor" id="a7e7d9ddb28042723371da1ebf2f1c4a2"></a> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">static <a class="el" href="uobject_8h.html#a22af10545208a455a6e884008df48e9f">UClassID</a> icu::TimeUnitFormat::getStaticClassID </td> <td>(</td> <td class="paramtype">void </td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">static</span></span> </td> </tr> </table> </div><div class="memdoc"> <p>Return the class ID for this class. </p> <p>This is useful only for comparing to a return value from <a class="el" href="classicu_1_1TimeUnitFormat.html#a94cf22aa31269644c2ab0f70ee8bd1ca" title="Returns a unique class ID POLYMORPHICALLY.">getDynamicClassID()</a>. For example: </p> <pre> . Base* polymorphic_pointer = createPolymorphicObject(); . if (polymorphic_pointer-><a class="el" href="classicu_1_1TimeUnitFormat.html#a94cf22aa31269644c2ab0f70ee8bd1ca" title="Returns a unique class ID POLYMORPHICALLY.">getDynamicClassID()</a> == . erived::getStaticClassID()) ... </pre> <dl class="section return"><dt>Returns</dt><dd>The class ID for all objects of this class. </dd></dl> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004117">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> </div> </div> <a class="anchor" id="a3a93826570265111194c4951cfcba9fa"></a> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname"><a class="el" href="umachine_8h.html#a349ef00011f20ccd1d3b424445681aa5">UBool</a> icu::TimeUnitFormat::operator!= </td> <td>(</td> <td class="paramtype">const <a class="el" href="classicu_1_1Format.html">Format</a> & </td> <td class="paramname"><em>other</em></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"> <p>Return true if the given <a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> objects are not semantically equal. </p> <p>Objects of different subclasses are considered unequal. </p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">other</td><td>the object to be compared with. </td></tr> </table> </dd> </dl> <dl class="section return"><dt>Returns</dt><dd>true if the given <a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> objects are not semantically equal. </dd></dl> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004112">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> <p>Reimplemented from <a class="el" href="classicu_1_1Format.html#a6805569ed12cf68e0e8359dadcbe9b1c">icu::Format</a>.</p> <p>Definition at line <a class="el" href="tmutfmt_8h_source.html#l00261">261</a> of file <a class="el" href="tmutfmt_8h_source.html">tmutfmt.h</a>.</p> <p>References <a class="el" href="namespaceicu.html#a1c2f6ca43e636f38d1a3291eb851e9f0">icu::operator==()</a>.</p> </div> </div> <a class="anchor" id="aba3485a783dd724982cc3ed2a8ed986a"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classicu_1_1TimeUnitFormat.html">TimeUnitFormat</a>& icu::TimeUnitFormat::operator= </td> <td>(</td> <td class="paramtype">const <a class="el" href="classicu_1_1TimeUnitFormat.html">TimeUnitFormat</a> & </td> <td class="paramname"><em>other</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Assignment operator. </p> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004110">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> </div> </div> <a class="anchor" id="afbd6320787f646c9b95c64b71e1f47c3"></a> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">virtual <a class="el" href="umachine_8h.html#a349ef00011f20ccd1d3b424445681aa5">UBool</a> icu::TimeUnitFormat::operator== </td> <td>(</td> <td class="paramtype">const <a class="el" href="classicu_1_1Format.html">Format</a> & </td> <td class="paramname"><em>other</em></td><td>)</td> <td> const</td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p>Return true if the given <a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> objects are semantically equal. </p> <p>Objects of different subclasses are considered unequal. </p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">other</td><td>the object to be compared with. </td></tr> </table> </dd> </dl> <dl class="section return"><dt>Returns</dt><dd>true if the given <a class="el" href="classicu_1_1Format.html" title="Base class for all formats.">Format</a> objects are semantically equal. </dd></dl> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004111">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> <p>Implements <a class="el" href="classicu_1_1Format.html#ab2db8f1097b03f3660d329752370bdf7">icu::Format</a>.</p> </div> </div> <a class="anchor" id="a42f817d0a828a836d60720a5bb4bd1a0"></a> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">virtual void icu::TimeUnitFormat::parseObject </td> <td>(</td> <td class="paramtype">const <a class="el" href="classicu_1_1UnicodeString.html">UnicodeString</a> & </td> <td class="paramname"><em>source</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="classicu_1_1Formattable.html">Formattable</a> & </td> <td class="paramname"><em>result</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="classicu_1_1ParsePosition.html">ParsePosition</a> & </td> <td class="paramname"><em>pos</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td> const</td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p>Parse a <a class="el" href="classicu_1_1TimeUnitAmount.html" title="Express a duration as a time unit and number.">TimeUnitAmount</a>. </p> <dl class="section see"><dt>See Also</dt><dd><a class="el" href="classicu_1_1Format.html#a292d797eb9d3bc8a42d8d8efba119a83" title="Parse a string to produce an object.">Format::parseObject(const UnicodeString&, Formattable&, ParsePosition&) const</a>; </dd></dl> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004116">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> <p>Implements <a class="el" href="classicu_1_1Format.html#a292d797eb9d3bc8a42d8d8efba119a83">icu::Format</a>.</p> </div> </div> <a class="anchor" id="ab82c6199888dc555cf8f695c99e5be37"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void icu::TimeUnitFormat::setLocale </td> <td>(</td> <td class="paramtype">const <a class="el" href="classicu_1_1Locale.html">Locale</a> & </td> <td class="paramname"><em>locale</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> & </td> <td class="paramname"><em>status</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div><div class="memdoc"> <p>Set the locale used for formatting or parsing. </p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">locale</td><td>the locale to be set </td></tr> <tr><td class="paramname">status</td><td>output param set to success/failure code on exit </td></tr> </table> </dd> </dl> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004113">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> </div> </div> <a class="anchor" id="a578dadf8944292e071a2b5a86b9b135f"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void icu::TimeUnitFormat::setNumberFormat </td> <td>(</td> <td class="paramtype">const <a class="el" href="classicu_1_1NumberFormat.html">NumberFormat</a> & </td> <td class="paramname"><em>format</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="utypes_8h.html#a3343c1c8a8377277046774691c98d78c">UErrorCode</a> & </td> <td class="paramname"><em>status</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div><div class="memdoc"> <p>Set the number format used for formatting or parsing. </p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">format</td><td>the number formatter to be set </td></tr> <tr><td class="paramname">status</td><td>output param set to success/failure code on exit </td></tr> </table> </dd> </dl> <dl class="stable"><dt><b><a class="el" href="stable.html#_stable004114">Stable:</a></b></dt><dd>ICU 4.2 </dd></dl> </div> </div> <hr/>The documentation for this class was generated from the following file:<ul> <li><a class="el" href="tmutfmt_8h_source.html">tmutfmt.h</a></li> </ul> </div><!-- contents --> <!-- start footer part --> <hr class="footer"/><address class="footer"><small> Generated on Fri Oct 4 2013 14:10:26 for ICU 52.1 by  <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/> </a> 1.8.1.2 </small></address> </body> </html>