<html> <head> <title>Struct Locale</title> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <link rel="stylesheet" type="text/css" href="../../../../idl.css"> </head> <body> <div id="adc-idlref"> <a name="_top_"> </a><table class="navimain" border="0" cellpadding="3"> <tr> <td class="navimain"><a href="../module-ix.html" class="navimain">Overview</a></td> <td class="navimain"><a href="module-ix.html" class="navimain">Module</a></td> <td class="navimain"><a href="Locale-xref.html" class="navimain">Use</a></td> <td class="navimainnone">Devguide</td> <td class="navimain"><a href="../../../../index-files/index-1.html" class="navimain">Index</a></td> </tr> </table> <table class="navisub" border="0" cellpadding="0"> <tr> <td class="navisub"><a href="#Elements" class="navisub">Elements' Summary</a></td> <td class="navisub"><a href="#ElementDetails" class="navisub">Elements' Details</a></td> </tr> </table> <hr> <table border="0" width="100%" cellpadding="5" cellspacing="3" class="title-table" style="margin-bottom:6pt;"> <tr> <td><p class="namechain"><a href="../../../../module-ix.html" class="namechain">::</a> <a href="../../../module-ix.html" class="namechain">com</a> :: <a href="../../module-ix.html" class="namechain">sun</a> :: <a href="../module-ix.html" class="namechain">star</a> :: <a href="module-ix.html" class="namechain">lang</a> :: </p> </td> </tr> <tr> <td class="title">struct Locale</td> </tr> <tr> <td/></tr> <tr> <td><dl> <dt><b>Description</b></dt> <dd>object represents a specific geographical, political, or cultural region. </dd> <dd><p>An operation that requires a <code>Locale</code> to perform its task is called <em>locale-sensitive</em> and uses the <code>Locale</code> to tailor information for the user. For example, displaying a number is a locale-sensitive operation; the number should be formatted according to the customs/conventions of the user's native country, region, or culture. </p> <p> Because a <code>Locale</code> object is just an identifier for a region, no validity check is performed. If you want to see whether particular resources are available for the <code>Locale</code>, use the <method scope="com::sun::star::resource">XLocale::getAvailableLocales</method> method to ask for the locales it supports.</p> <p> <strong>Note:</strong> When you ask for a resource for a particular locale, you get the best available match, not necessarily precisely what you asked for. For more information, see ::com::sun::star::<a href="../resource/module-ix.html">resource</a>::<a href="../resource/XResourceBundle.html">XResourceBundle</a>.</p> <p> Each implementation that performs locale-sensitive operations allows you to get all the available objects of that type. Use the ::com::sun::star::<a href="../resource/module-ix.html">resource</a>::<a href="../resource/XLocale.html">XLocale</a> interface to set the locale. </p> </dd> </dl> </td> </tr> </table> <hr> <a name="Elements"/><table border="1" width="100%" cellpadding="5" cellspacing="0" class="subtitle"> <tr> <td class="subtitle" colspan="2">Elements' Summary</td> </tr> <tr> <td class="imsum_left"><a href="#Language">Language</a></td> <td class="imsum_right">specifies an <strong>ISO Language Code</strong>. </td> </tr> <tr> <td class="imsum_left"><a href="#Country">Country</a></td> <td class="imsum_right">specifies an <strong>ISO Country Code.</strong> </td> </tr> <tr> <td class="imsum_left"><a href="#Variant">Variant</a></td> <td class="imsum_right">contains a variant of the locale; codes are vendor and browser-specific. </td> </tr> </table> <a name="ElementDetails"/><table border="1" width="100%" cellpadding="5" cellspacing="0" class="subtitle"> <tr> <td class="subtitle">Elements' Details</td> </tr> <tr> <td class="imdetail"><a name="Language" class="membertitle">Language</a><table border="0" width="96%" cellpadding="5" cellspacing="0" class="table-in-data" bgcolor="#ffffff" align="center"> <tr> <td>string <b>Language</b>;<hr> <dl> <dt><b>Description</b></dt> <dd>specifies an <strong>ISO Language Code</strong>. </dd> <dd><p>These codes are the lower-case two-letter codes as defined by ISO-639. You can find a full list of these codes at a number of sites, such as: <br> <a href="http://www.ics.uci.edu/pub/ietf/http/related/iso639.txt"> <code>http://www.ics.uci.edu/pub/ietf/http/related/iso639.txt</code></a>. </p> <p>If this field contains an empty string, the meaning depends on the context.</p> </dd> </dl> </td> </tr> </table> </td> </tr> <tr> <td class="imdetail"><a name="Country" class="membertitle">Country</a><table border="0" width="96%" cellpadding="5" cellspacing="0" class="table-in-data" bgcolor="#ffffff" align="center"> <tr> <td>string <b>Country</b>;<hr> <dl> <dt><b>Description</b></dt> <dd>specifies an <strong>ISO Country Code.</strong> </dd> <dd><p>These codes are the upper-case two-letter codes as defined by ISO-3166. You can find a full list of these codes at a number of sites, such as: <br> <a href="http://www.chemie.fu-berlin.de/diverse/doc/ISO_3166.html"> <code>http://www.chemie.fu-berlin.de/diverse/doc/ISO_3166.html</code></a>. </p> <p>If this field contains an empty string, the meaning depends on the context.</p> </dd> </dl> </td> </tr> </table> </td> </tr> <tr> <td class="imdetail"><a name="Variant" class="membertitle">Variant</a><table border="0" width="96%" cellpadding="5" cellspacing="0" class="table-in-data" bgcolor="#ffffff" align="center"> <tr> <td>string <b>Variant</b>;<hr> <dl> <dt><b>Description</b></dt> <dd>contains a variant of the locale; codes are vendor and browser-specific. </dd> <dd><p>For example, use WIN for Windows, MAC for Macintosh, and POSIX for POSIX. Wherever there are two variants, separate them with an underscore, and put the most important one first. For example, a traditional Spanish collation might construct a locale with parameters for language, country and variant as: "es", "ES", "Traditional_WIN".</p> </dd> </dl> </td> </tr> </table> </td> </tr> </table> <a href="#_top_">Top of Page</a><hr size="3"><p class="copyright" align="center">Copyright © 2009 Sun Microsystems, Inc.</p> </div> <!-- id="adc-idlref" --> </body> </html>