| <!DOCTYPE HTML> |
| <!-- NewPage --> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc (11.0.4) on Fri Sep 20 12:10:30 CEST 2019 --> |
| <title>DefaultInternationalString (Apache SIS 1.0 API)</title> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <meta name="dc.created" content="2019-09-20"> |
| <meta name="keywords" content="org.apache.sis.util.iso.DefaultInternationalString class"> |
| <meta name="keywords" content="add()"> |
| <meta name="keywords" content="getLocales()"> |
| <meta name="keywords" content="toString()"> |
| <meta name="keywords" content="isSubsetOf()"> |
| <meta name="keywords" content="equals()"> |
| <meta name="keywords" content="hashCode()"> |
| <link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style"> |
| <link rel="stylesheet" type="text/css" href="../../../../../sis.css" title="Style"> |
| <link rel="stylesheet" type="text/css" href="../../../../../jquery/jquery-ui.css" title="Style"> |
| <script type="text/javascript" src="../../../../../script.js"></script> |
| <script type="text/javascript" src="../../../../../jquery/jszip/dist/jszip.min.js"></script> |
| <script type="text/javascript" src="../../../../../jquery/jszip-utils/dist/jszip-utils.min.js"></script> |
| <!--[if IE]> |
| <script type="text/javascript" src="../../../../../jquery/jszip-utils/dist/jszip-utils-ie.min.js"></script> |
| <![endif]--> |
| <script type="text/javascript" src="../../../../../jquery/jquery-3.3.1.js"></script> |
| <script type="text/javascript" src="../../../../../jquery/jquery-migrate-3.0.1.js"></script> |
| <script type="text/javascript" src="../../../../../jquery/jquery-ui.js"></script> |
| </head> |
| <body> |
| <script type="text/javascript"><!-- |
| try { |
| if (location.href.indexOf('is-external=true') == -1) { |
| parent.document.title="DefaultInternationalString (Apache SIS 1.0 API)"; |
| } |
| } |
| catch(err) { |
| } |
| //--> |
| var data = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10}; |
| var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]}; |
| var altColor = "altColor"; |
| var rowColor = "rowColor"; |
| var tableTab = "tableTab"; |
| var activeTableTab = "activeTableTab"; |
| var pathtoroot = "../../../../../"; |
| var useModuleDirectories = false; |
| loadScripts(document, 'script');</script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <header role="banner"> |
| <nav role="navigation"> |
| <div class="fixedNav"> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="topNav"><a id="navbar.top"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div> |
| <a id="navbar.top.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../../index.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/DefaultInternationalString.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList" id="allclasses_navbar_top"> |
| <li><a href="../../../../../allclasses.html">All Classes</a></li> |
| </ul> |
| <ul class="navListSearch"> |
| <li><label for="search">SEARCH:</label> |
| <input type="text" id="search" value="search" disabled="disabled"> |
| <input type="reset" id="reset" value="reset" disabled="disabled"> |
| </li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_top"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li><a href="#constructor.summary">Constr</a> | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li><a href="#constructor.detail">Constr</a> | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a id="skip.navbar.top"> |
| <!-- --> |
| </a></div> |
| <!-- ========= END OF TOP NAVBAR ========= --> |
| </div> |
| <div class="navPadding"> </div> |
| <script type="text/javascript"><!-- |
| $('.navPadding').css('padding-top', $('.fixedNav').css("height")); |
| //--> |
| </script> |
| </nav> |
| </header> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <main role="main"> |
| <div class="header"> |
| <div class="subTitle"><span class="packageLabelInType">Package</span> <a href="package-summary.html">org.apache.sis.util.iso</a></div> |
| <h2 title="Class DefaultInternationalString" class="title">Class DefaultInternationalString</h2> |
| </div> |
| <div class="contentContainer"> |
| <ul class="inheritance"> |
| <li><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></li> |
| <li> |
| <ul class="inheritance"> |
| <li><a href="AbstractInternationalString.html" title="class in org.apache.sis.util.iso">AbstractInternationalString</a></li> |
| <li> |
| <ul class="inheritance"> |
| <li>DefaultInternationalString</li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| <div class="description"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <dl> |
| <dt>All Implemented Interfaces:</dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io" class="externalLink">Serializable</a></code>, <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang" class="externalLink">CharSequence</a></code>, <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><<a href="http://www.geoapi.org/3.0/javadoc/org/opengis/util/InternationalString.html?is-external=true" title="class or interface in org.opengis.util" class="externalLink">InternationalString</a>></code>, <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Formattable.html?is-external=true" title="class or interface in java.util" class="externalLink">Formattable</a></code>, <code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/util/InternationalString.html?is-external=true" title="class or interface in org.opengis.util" class="externalLink">InternationalString</a></code></dd> |
| </dl> |
| <hr> |
| <pre>public class <span class="typeNameLabel">DefaultInternationalString</span> |
| extends <a href="AbstractInternationalString.html" title="class in org.apache.sis.util.iso">AbstractInternationalString</a> |
| implements <a href="https://docs.oracle.com/javase/8/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io" class="externalLink">Serializable</a></pre> |
| <div class="block">An international string using a map of strings for different locales. |
| Strings for new locales can be <a href="#add(java.util.Locale,java.lang.String)">added</a>, |
| but existing strings can not be removed or modified. |
| This behavior is a compromise between making constructions easier, and being suitable for |
| use in immutable objects. |
| |
| <div class="section">Thread safety</div> |
| Instances of <code>DefaultInternationalString</code> are thread-safe. While those instances are not strictly immutable, |
| SIS typically references them as if they were immutable because of their <cite>add-only</cite> behavior.</div> |
| <dl> |
| <dt><span class="simpleTagLabel">Since:</span></dt> |
| <dd>0.3</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="Types.html#toInternationalString(java.util.Map,java.lang.String)"><code>Types.toInternationalString(Map, String)</code></a>, |
| <a href="../../../../../serialized-form.html#org.apache.sis.util.iso.DefaultInternationalString">Serialized Form</a></dd> |
| |
| <p><font size="-1">Defined in the <code>sis-utility</code> module</font></p> |
| </dl> |
| </li> |
| </ul> |
| </div> |
| <div class="summary"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ======== CONSTRUCTOR SUMMARY ======== --> |
| <section role="region"> |
| <ul class="blockList"> |
| <li class="blockList"><a id="constructor.summary"> |
| <!-- --> |
| </a> |
| <h3>Constructor Summary</h3> |
| <table class="memberSummary"> |
| <caption><span>Constructors</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Constructor</th> |
| <th class="colLast" scope="col">Description</th> |
| </tr> |
| <tr class="altColor"> |
| <th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E()">DefaultInternationalString</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Creates an initially empty international string.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(java.lang.String)">DefaultInternationalString</a></span>​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a> string)</code></th> |
| <td class="colLast"> |
| <div class="block">Creates an international string initialized with the given string.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(java.util.Map)">DefaultInternationalString</a></span>​(<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util" class="externalLink">Map</a><<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true" title="class or interface in java.util" class="externalLink">Locale</a>,​<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>> strings)</code></th> |
| <td class="colLast"> |
| <div class="block">Creates an international string initialized with the given localized strings.</div> |
| </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| </section> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <section role="region"> |
| <ul class="blockList"> |
| <li class="blockList"><a id="method.summary"> |
| <!-- --> |
| </a> |
| <h3>Method Summary</h3> |
| <table class="memberSummary"> |
| <caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd"> </span></span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colSecond" scope="col">Method</th> |
| <th class="colLast" scope="col">Description</th> |
| </tr> |
| <tr id="i0" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#add(java.util.Locale,java.lang.String)">add</a></span>​(<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true" title="class or interface in java.util" class="externalLink">Locale</a> locale, |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a> string)</code></th> |
| <td class="colLast"> |
| <div class="block">Adds a string for the given locale.</div> |
| </td> |
| </tr> |
| <tr id="i1" class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#equals(java.lang.Object)">equals</a></span>​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a> object)</code></th> |
| <td class="colLast"> |
| <div class="block">Compares this international string with the specified object for equality.</div> |
| </td> |
| </tr> |
| <tr id="i2" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a><<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true" title="class or interface in java.util" class="externalLink">Locale</a>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getLocales()">getLocales</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns the set of locales defined in this international string.</div> |
| </td> |
| </tr> |
| <tr id="i3" class="rowColor"> |
| <td class="colFirst"><code>int</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#hashCode()">hashCode</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a hash code value for this international text.</div> |
| </td> |
| </tr> |
| <tr id="i4" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isSubsetOf(java.lang.Object)">isSubsetOf</a></span>​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a> candidate)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns <code>true</code> if all localized texts stored in this international string are |
| contained in the specified object.</div> |
| </td> |
| </tr> |
| <tr id="i5" class="rowColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#toString(java.util.Locale)">toString</a></span>​(<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true" title="class or interface in java.util" class="externalLink">Locale</a> locale)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a string in the specified locale.</div> |
| </td> |
| </tr> |
| </table> |
| <ul class="blockList"> |
| <li class="blockList"><a id="methods.inherited.from.class.AbstractInternationalString"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class <a href="AbstractInternationalString.html" title="class in org.apache.sis.util.iso">AbstractInternationalString</a></h3> |
| <code><a href="AbstractInternationalString.html#charAt(int)">charAt</a>, <a href="AbstractInternationalString.html#compareTo(org.opengis.util.InternationalString)">compareTo</a>, <a href="AbstractInternationalString.html#formatTo(java.util.Formatter,int,int,int)">formatTo</a>, <a href="AbstractInternationalString.html#length()">length</a>, <a href="AbstractInternationalString.html#subSequence(int,int)">subSequence</a>, <a href="AbstractInternationalString.html#toString()">toString</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a id="methods.inherited.from.class.Object"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang" class="externalLink">clone</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang" class="externalLink">finalize</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang" class="externalLink">getClass</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang" class="externalLink">notify</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang" class="externalLink">notifyAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang" class="externalLink">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang" class="externalLink">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait(long,int)" title="class or interface in java.lang" class="externalLink">wait</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a id="methods.inherited.from.class.CharSequence"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from interface <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang" class="externalLink">CharSequence</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/CharSequence.html?is-external=true#chars()" title="class or interface in java.lang" class="externalLink">chars</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/CharSequence.html?is-external=true#codePoints()" title="class or interface in java.lang" class="externalLink">codePoints</a></code></li> |
| </ul> |
| </li> |
| </ul> |
| </section> |
| </li> |
| </ul> |
| </div> |
| <div class="details"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ========= CONSTRUCTOR DETAIL ======== --> |
| <section role="region"> |
| <ul class="blockList"> |
| <li class="blockList"><a id="constructor.detail"> |
| <!-- --> |
| </a> |
| <h3>Constructor Detail</h3> |
| <a id="<init>()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>DefaultInternationalString</h4> |
| <pre>public DefaultInternationalString()</pre> |
| <div class="block">Creates an initially empty international string. Localized strings can been added |
| using one of <a href="#add(java.util.Locale,java.lang.String)"><code>add(…)</code></a> methods.</div> |
| </li> |
| </ul> |
| <a id="<init>(java.lang.String)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>DefaultInternationalString</h4> |
| <pre>public DefaultInternationalString​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a> string)</pre> |
| <div class="block">Creates an international string initialized with the given string. |
| Additional localized strings can been added using one of <a href="#add(java.util.Locale,java.lang.String)"><code>add(…)</code></a> methods. |
| The string specified to this constructor is the one that will be returned if no localized |
| string is found for the <code>Locale</code> argument in a call to <a href="#toString(java.util.Locale)"><code>toString(Locale)</code></a>.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>string</code> - the string in no specific locale, or <code>null</code> if none.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="<init>(java.util.Map)"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>DefaultInternationalString</h4> |
| <pre>public DefaultInternationalString​(<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util" class="externalLink">Map</a><<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true" title="class or interface in java.util" class="externalLink">Locale</a>,​<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>> strings)</pre> |
| <div class="block">Creates an international string initialized with the given localized strings. |
| The content of the given map is copied, so changes to that map after construction |
| will not be reflected into this international string.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>strings</code> - the strings in various locales, or <code>null</code> if none.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="Types.html#toInternationalString(java.util.Map,java.lang.String)"><code>Types.toInternationalString(Map, String)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </section> |
| <!-- ============ METHOD DETAIL ========== --> |
| <section role="region"> |
| <ul class="blockList"> |
| <li class="blockList"><a id="method.detail"> |
| <!-- --> |
| </a> |
| <h3>Method Detail</h3> |
| <a id="add(java.util.Locale,java.lang.String)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>add</h4> |
| <pre class="methodSignature">public void add​(<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true" title="class or interface in java.util" class="externalLink">Locale</a> locale, |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a> string) |
| throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IllegalArgumentException</a></pre> |
| <div class="block">Adds a string for the given locale.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>locale</code> - the locale for the <code>string</code> value.</dd> |
| <dd><code>string</code> - the localized string.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IllegalArgumentException</a></code> - if a different string value was already set for the given locale.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="getLocales()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getLocales</h4> |
| <pre class="methodSignature">public <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a><<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true" title="class or interface in java.util" class="externalLink">Locale</a>> getLocales()</pre> |
| <div class="block">Returns the set of locales defined in this international string.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the set of locales.</dd> |
| <dt><span class="simpleTagLabel">TODO:</span></dt> |
| <dd>Current implementation does not return a synchronized set. We should synchronize |
| on the same lock than the one used for accessing the internal locale map.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="toString(java.util.Locale)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>toString</h4> |
| <pre class="methodSignature">public <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a> toString​(<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true" title="class or interface in java.util" class="externalLink">Locale</a> locale)</pre> |
| <div class="block">Returns a string in the specified locale. If there is no string for that <code>locale</code>, |
| then this method searches for a locale without the <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true#getVariant()" title="class or interface in java.util" class="externalLink">variant</a> |
| part. If no string are found, then this method searches for a locale without the |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true#getCountry()" title="class or interface in java.util" class="externalLink">country</a> part. For example if the <code>"fr_CA"</code> locale |
| was requested but not found, then this method looks for the <code>"fr"</code> locale. |
| The <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true#ROOT" title="class or interface in java.util" class="externalLink">root locale</a> is tried last. |
| |
| <div class="section">Handling of <code>Locale.ROOT</code> argument value</div> |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true#ROOT" title="class or interface in java.util" class="externalLink"><code>Locale.ROOT</code></a> can be given to this method for requesting a "unlocalized" string, |
| typically some programmatic values like enumerations or identifiers. |
| While identifiers often look like English words, <code>Locale.ROOT</code> is not considered |
| synonymous to <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true#ENGLISH" title="class or interface in java.util" class="externalLink"><code>Locale.ENGLISH</code></a> because the values may differ in the way numbers and |
| dates are formatted (e.g. using the ISO 8601 standard for dates instead than English conventions). |
| In order to produce a value close to the common practice, this method handles <code>Locale.ROOT</code> |
| as below: |
| |
| <ul> |
| <li>If a string has been explicitly <a href="#add(java.util.Locale,java.lang.String)">added</a> for |
| <code>Locale.ROOT</code>, then that string is returned.</li> |
| <li>Otherwise, acknowledging that UML identifiers in OGC/ISO specifications are primarily |
| expressed in the English language, this method looks for strings associated to |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true#US" title="class or interface in java.util" class="externalLink"><code>Locale.US</code></a> as an approximation of "unlocalized" strings.</li> |
| <li>If no English string was found, then this method looks for a string for the |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true#getDefault()" title="class or interface in java.util" class="externalLink">system default locale</a>.</li> |
| <li>If none of the above steps found a string, then this method returns |
| an arbitrary string.</li> |
| </ul> |
| |
| <div class="section">Handling of <code>null</code> argument value</div> |
| In the default implementation, the <code>null</code> locale is handled as a synonymous of |
| <code>Locale.ROOT</code>. However subclasses are free to use a different fallback. Client |
| code are encouraged to specify only non-null values for more determinist behavior.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/util/InternationalString.html?is-external=true#toString(java.util.Locale)" title="class or interface in org.opengis.util" class="externalLink">toString</a></code> in interface <code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/util/InternationalString.html?is-external=true" title="class or interface in org.opengis.util" class="externalLink">InternationalString</a></code></dd> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="AbstractInternationalString.html#toString(java.util.Locale)">toString</a></code> in class <code><a href="AbstractInternationalString.html" title="class in org.apache.sis.util.iso">AbstractInternationalString</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>locale</code> - the desired locale for the string to be returned.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the string in the given locale if available, or in an |
| implementation-dependent fallback locale otherwise.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true#getDefault()" title="class or interface in java.util" class="externalLink"><code>Locale.getDefault()</code></a>, |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true#ROOT" title="class or interface in java.util" class="externalLink"><code>Locale.ROOT</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="isSubsetOf(java.lang.Object)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isSubsetOf</h4> |
| <pre class="methodSignature">public boolean isSubsetOf​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a> candidate)</pre> |
| <div class="block">Returns <code>true</code> if all localized texts stored in this international string are |
| contained in the specified object. More specifically: |
| |
| <ul> |
| <li>If <code>candidate</code> is an instance of <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/util/InternationalString.html?is-external=true" title="class or interface in org.opengis.util" class="externalLink"><code>InternationalString</code></a>, then this method |
| returns <code>true</code> if, for all <var><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true" title="class or interface in java.util" class="externalLink">locale</a></var>-<var><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">string</a></var> pairs contained in <code>this</code>, <code>candidate.<a href="http://www.geoapi.org/3.0/javadoc/org/opengis/util/InternationalString.html?is-external=true#toString(java.util.Locale)" title="class or interface in org.opengis.util" class="externalLink">toString</a>(locale)</code> returns a string |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang" class="externalLink">equals</a> to <code>string</code>.</li> |
| |
| <li>If <code>candidate</code> is an instance of <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/CharSequence.html?is-external=true" title="class or interface in java.lang" class="externalLink"><code>CharSequence</code></a>, then this method |
| returns <code>true</code> if <a href="#toString(java.util.Locale)"><code>toString(Locale)</code></a> returns a string <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang" class="externalLink">equals</a> to <code>candidate.<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/CharSequence.html?is-external=true#toString()" title="class or interface in java.lang" class="externalLink">toString()</a></code> for all locales.</li> |
| |
| <li>If <code>candidate</code> is an instance of <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util" class="externalLink"><code>Map</code></a>, then this methods returns |
| <code>true</code> if all <var><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Locale.html?is-external=true" title="class or interface in java.util" class="externalLink">locale</a></var>-<var><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">string</a></var> pairs are contained into <code>candidate</code>.</li> |
| |
| <li>Otherwise, this method returns <code>false</code>.</li> |
| </ul></div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>candidate</code> - the object which may contains this international string.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><code>true</code> if the given object contains all localized strings found in this international string.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="equals(java.lang.Object)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>equals</h4> |
| <pre class="methodSignature">public boolean equals​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a> object)</pre> |
| <div class="block">Compares this international string with the specified object for equality.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang" class="externalLink">equals</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>object</code> - the object to compare with this international string.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><code>true</code> if the given object is equal to this string.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="hashCode()"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>hashCode</h4> |
| <pre class="methodSignature">public int hashCode()</pre> |
| <div class="block">Returns a hash code value for this international text.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang" class="externalLink">hashCode</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a hash code value for this international text.</dd> |
| </dl> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </section> |
| </li> |
| </ul> |
| </div> |
| </div> |
| </main> |
| <!-- ========= END OF CLASS DATA ========= --> |
| <footer role="contentinfo"> |
| <nav role="navigation"> |
| <!-- ======= START OF BOTTOM NAVBAR ====== --> |
| <div class="bottomNav"><a id="navbar.bottom"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div> |
| <a id="navbar.bottom.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../../index.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/DefaultInternationalString.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList" id="allclasses_navbar_bottom"> |
| <li><a href="../../../../../allclasses.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_bottom"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li><a href="#constructor.summary">Constr</a> | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li><a href="#constructor.detail">Constr</a> | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a id="skip.navbar.bottom"> |
| <!-- --> |
| </a></div> |
| <!-- ======== END OF BOTTOM NAVBAR ======= --> |
| </nav> |
| <p class="legalCopy"><small>Copyright © 2010–2019 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p> |
| </footer> |
| </body> |
| </html> |