| <!DOCTYPE HTML> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc (19) --> |
| <title>OptionKey (Apache SIS 1.3 API)</title> |
| <meta name="viewport" content="width=device-width, initial-scale=1"> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <meta name="description" content="declaration: package: org.apache.sis.setup, class: OptionKey"> |
| <meta name="generator" content="javadoc/ClassWriterImpl"> |
| <meta name="keywords" content="org.apache.sis.setup.OptionKey class"> |
| <meta name="keywords" content="LOCALE"> |
| <meta name="keywords" content="TIMEZONE"> |
| <meta name="keywords" content="ENCODING"> |
| <meta name="keywords" content="URL_ENCODING"> |
| <meta name="keywords" content="OPEN_OPTIONS"> |
| <meta name="keywords" content="BYTE_BUFFER"> |
| <meta name="keywords" content="GEOMETRY_LIBRARY"> |
| <meta name="keywords" content="INDENTATION"> |
| <meta name="keywords" content="getName()"> |
| <meta name="keywords" content="getElementType()"> |
| <meta name="keywords" content="getValueFrom()"> |
| <meta name="keywords" content="setValueInto()"> |
| <meta name="keywords" content="equals()"> |
| <meta name="keywords" content="hashCode()"> |
| <meta name="keywords" content="toString()"> |
| <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="../../../../script-dir/jquery-ui.min.css" title="Style"> |
| <link rel="stylesheet" type="text/css" href="../../../../jquery-ui.overrides.css" title="Style"> |
| <script type="text/javascript" src="../../../../script.js"></script> |
| <script type="text/javascript" src="../../../../script-dir/jquery-3.6.0.min.js"></script> |
| <script type="text/javascript" src="../../../../script-dir/jquery-ui.min.js"></script> |
| </head> |
| <body class="class-declaration-page"> |
| <script type="text/javascript">var pathtoroot = "../../../../"; |
| loadScripts(document, 'script');</script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <div class="flex-box"> |
| <header role="banner" class="flex-header"> |
| <nav role="navigation"> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="top-nav" id="navbar-top"><button id="navbar-toggle-button" aria-controls="navbar-top" aria-expanded="false" aria-label="Toggle navigation links"><span class="nav-bar-toggle-icon"> </span><span class="nav-bar-toggle-icon"> </span><span class="nav-bar-toggle-icon"> </span></button> |
| <div class="skip-nav"><a href="#skip-navbar-top" title="Skip navigation links">Skip navigation links</a></div> |
| <ul id="navbar-top-firstrow" class="nav-list" title="Navigation"> |
| <li><a href="../../../../index.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="nav-bar-cell1-rev">Class</li> |
| <li><a href="class-use/OptionKey.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#class">Help</a></li> |
| </ul> |
| <ul class="sub-nav-list-small"> |
| <li> |
| <p>Summary:</p> |
| <ul> |
| <li>Nested</li> |
| <li><a href="#field-summary">Field</a></li> |
| <li><a href="#constructor-summary">Constr</a></li> |
| <li><a href="#method-summary">Method</a></li> |
| </ul> |
| </li> |
| <li> |
| <p>Detail:</p> |
| <ul> |
| <li><a href="#field-detail">Field</a></li> |
| <li><a href="#constructor-detail">Constr</a></li> |
| <li><a href="#method-detail">Method</a></li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| <div class="sub-nav"> |
| <div id="navbar-sub-list"> |
| <ul class="sub-nav-list"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li><a href="#field-summary">Field</a> | </li> |
| <li><a href="#constructor-summary">Constr</a> | </li> |
| <li><a href="#method-summary">Method</a></li> |
| </ul> |
| <ul class="sub-nav-list"> |
| <li>Detail: </li> |
| <li><a href="#field-detail">Field</a> | </li> |
| <li><a href="#constructor-detail">Constr</a> | </li> |
| <li><a href="#method-detail">Method</a></li> |
| </ul> |
| </div> |
| <div class="nav-list-search"><a href="../../../../search.html">SEARCH</a> |
| <input type="text" id="search-input" disabled placeholder="Search"> |
| <input type="reset" id="reset-button" disabled value="reset"> |
| </div> |
| </div> |
| <!-- ========= END OF TOP NAVBAR ========= --> |
| <span class="skip-nav" id="skip-navbar-top"></span></nav> |
| </header> |
| <div class="flex-content"> |
| <main role="main"> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <div class="header"> |
| <div class="sub-title"><span class="package-label-in-type">Package</span> <a href="package-summary.html">org.apache.sis.setup</a></div> |
| <h1 title="Class OptionKey" class="title">Class OptionKey<T></h1> |
| </div> |
| <div class="inheritance" title="Inheritance Tree"><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> |
| <div class="inheritance">OptionKey<T></div> |
| </div> |
| <section class="class-description" id="class-description"> |
| <dl class="notes"> |
| <dt>Type Parameters:</dt> |
| <dd><code>T</code> - the type of option values.</dd> |
| </dl> |
| <dl class="notes"> |
| <dt>All Implemented Interfaces:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/io/Serializable.html" title="class or interface in java.io" class="external-link">Serializable</a></code></dd> |
| </dl> |
| <dl class="notes"> |
| <dt>Direct Known Subclasses:</dt> |
| <dd><code><a href="../storage/DataOptionKey.html" title="class in org.apache.sis.storage">DataOptionKey</a></code></dd> |
| </dl> |
| <hr> |
| <div class="type-signature"><span class="modifiers">public class </span><span class="element-name type-name-label">OptionKey<T></span> |
| <span class="extends-implements">extends <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> |
| implements <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/io/Serializable.html" title="class or interface in java.io" class="external-link">Serializable</a></span></div> |
| <div class="block">Keys in a map of options for configuring various services |
| (<a href="../storage/DataStore.html" title="class in org.apache.sis.storage"><code>DataStore</code></a>, <i>etc</i>). |
| <code>OptionKey</code>s are used for aspects that usually do not need to be configured, except in a few specialized cases. |
| For example, most data file formats read by SIS do not require the user to specify the character encoding, because |
| the encoding is often given in the file header or in the format specification. However if SIS needs to read plain |
| text files <em>and</em> the default platform encoding is not suitable, then the user can specify the desired encoding |
| explicitly using the <a href="#ENCODING"><code>ENCODING</code></a> option. |
| |
| <p>All options are <em>hints</em> and may be silently ignored. For example, most <code>DataStore</code>s will ignore the |
| <code>ENCODING</code> option if irrelevant to their format, or if the encoding is specified in the data file header.</p> |
| |
| <p>Options are <em>transitive</em>: if a service uses others services for its internal working, the given options |
| may also be given to those dependencies, at implementation choice.</p> |
| |
| <h2>Defining new options</h2> |
| Developers who wish to define their own options can define static constants in a subclass, |
| as in the following example: |
| |
| <blockquote><pre><font color="green">public</font> <font color="green">final</font> <font color="green">class</font> MyOptionKey<T> <font color="green">extends</font> OptionKey<T> { |
| <font color="green">public</font> <font color="green">static</font> <font color="green">final</font> OptionKey<String> MY_OPTION = <font color="green">new</font> MyOptionKey<>(<font color="orangered">"MY_OPTION"</font>, String.<font color="green">class</font>); |
| |
| <font color="green">private</font> <b>MyOptionKey</b>(<font color="green">final</font> String name, <font color="green">final</font> Class<T> type) { |
| <b><font color="green">super</font></b>(name, type); |
| } |
| }</pre></blockquote></div> |
| <dl class="notes"> |
| <dt>Since:</dt> |
| <dd>0.3</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="see-list"> |
| <li><a href="../../../../serialized-form.html#org.apache.sis.setup.OptionKey">Serialized Form</a></li> |
| </ul> |
| </dd> |
| |
| <p><font size="-1">Defined in the <code>sis-utility</code> module</font></p> |
| </dl> |
| </section> |
| <section class="summary"> |
| <ul class="summary-list"> |
| <!-- =========== FIELD SUMMARY =========== --> |
| <li> |
| <section class="field-summary" id="field-summary"> |
| <h2>Field Summary</h2> |
| <div class="caption"><span>Fields</span></div> |
| <div class="summary-table three-column-summary"> |
| <div class="table-header col-first">Modifier and Type</div> |
| <div class="table-header col-second">Field</div> |
| <div class="table-header col-last">Description</div> |
| <div class="col-first even-row-color"><code>static final <a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a>></code></div> |
| <div class="col-second even-row-color"><code><a href="#BYTE_BUFFER" class="member-name-link">BYTE_BUFFER</a></code></div> |
| <div class="col-last even-row-color"> |
| <div class="block">The byte buffer to use for input/output operations.</div> |
| </div> |
| <div class="col-first odd-row-color"><code>static final <a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/charset/Charset.html" title="class or interface in java.nio.charset" class="external-link">Charset</a>></code></div> |
| <div class="col-second odd-row-color"><code><a href="#ENCODING" class="member-name-link">ENCODING</a></code></div> |
| <div class="col-last odd-row-color"> |
| <div class="block">The character encoding of document content.</div> |
| </div> |
| <div class="col-first even-row-color"><code>static final <a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="GeometryLibrary.html" title="enum class in org.apache.sis.setup">GeometryLibrary</a>></code></div> |
| <div class="col-second even-row-color"><code><a href="#GEOMETRY_LIBRARY" class="member-name-link">GEOMETRY_LIBRARY</a></code></div> |
| <div class="col-last even-row-color"> |
| <div class="block">The library to use for creating geometric objects at reading time.</div> |
| </div> |
| <div class="col-first odd-row-color"><code>static final <a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Integer.html" title="class or interface in java.lang" class="external-link">Integer</a>></code></div> |
| <div class="col-second odd-row-color"><code><a href="#INDENTATION" class="member-name-link">INDENTATION</a></code></div> |
| <div class="col-last odd-row-color"> |
| <div class="block">The number of spaces to use for indentation when formatting text files in WKT or XML formats.</div> |
| </div> |
| <div class="col-first even-row-color"><code>static final <a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/Locale.html" title="class or interface in java.util" class="external-link">Locale</a>></code></div> |
| <div class="col-second even-row-color"><code><a href="#LOCALE" class="member-name-link">LOCALE</a></code></div> |
| <div class="col-last even-row-color"> |
| <div class="block">The locale to use for locale-sensitive data.</div> |
| </div> |
| <div class="col-first odd-row-color"><code>static final <a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/file/OpenOption.html" title="class or interface in java.nio.file" class="external-link">OpenOption</a>[]></code></div> |
| <div class="col-second odd-row-color"><code><a href="#OPEN_OPTIONS" class="member-name-link">OPEN_OPTIONS</a></code></div> |
| <div class="col-last odd-row-color"> |
| <div class="block">Whether a storage object (e.g. a <a href="../storage/DataStore.html" title="class in org.apache.sis.storage"><code>DataStore</code></a>) shall be opened in read, |
| write, append or other modes.</div> |
| </div> |
| <div class="col-first even-row-color"><code>static final <a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/TimeZone.html" title="class or interface in java.util" class="external-link">TimeZone</a>></code></div> |
| <div class="col-second even-row-color"><code><a href="#TIMEZONE" class="member-name-link">TIMEZONE</a></code></div> |
| <div class="col-last even-row-color"> |
| <div class="block">The timezone to use when parsing or formatting dates and times without explicit timezone.</div> |
| </div> |
| <div class="col-first odd-row-color"><code>static final <a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a>></code></div> |
| <div class="col-second odd-row-color"><code><a href="#URL_ENCODING" class="member-name-link">URL_ENCODING</a></code></div> |
| <div class="col-last odd-row-color"> |
| <div class="block">The encoding of a URL (<strong>not</strong> the encoding of the document content).</div> |
| </div> |
| </div> |
| </section> |
| </li> |
| <!-- ======== CONSTRUCTOR SUMMARY ======== --> |
| <li> |
| <section class="constructor-summary" id="constructor-summary"> |
| <h2>Constructor Summary</h2> |
| <div class="caption"><span>Constructors</span></div> |
| <div class="summary-table three-column-summary"> |
| <div class="table-header col-first">Modifier</div> |
| <div class="table-header col-second">Constructor</div> |
| <div class="table-header col-last">Description</div> |
| <div class="col-first even-row-color"><code>protected </code></div> |
| <div class="col-constructor-name even-row-color"><code><a href="#%3Cinit%3E(java.lang.String,java.lang.Class)" class="member-name-link">OptionKey</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a> name, |
| <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Class.html" title="class or interface in java.lang" class="external-link">Class</a><<a href="OptionKey.html" title="type parameter in OptionKey">T</a>> type)</code></div> |
| <div class="col-last even-row-color"> |
| <div class="block">Creates a new key of the given name for values of the given type.</div> |
| </div> |
| </div> |
| </section> |
| </li> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <li> |
| <section class="method-summary" id="method-summary"> |
| <h2>Method Summary</h2> |
| <div id="method-summary-table"> |
| <div class="table-tabs" role="tablist" aria-orientation="horizontal"><button id="method-summary-table-tab0" role="tab" aria-selected="true" aria-controls="method-summary-table.tabpanel" tabindex="0" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table', 3)" class="active-table-tab">All Methods</button><button id="method-summary-table-tab2" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab2', 3)" class="table-tab">Instance Methods</button><button id="method-summary-table-tab4" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab4', 3)" class="table-tab">Concrete Methods</button></div> |
| <div id="method-summary-table.tabpanel" role="tabpanel"> |
| <div class="summary-table three-column-summary" aria-labelledby="method-summary-table-tab0"> |
| <div class="table-header col-first">Modifier and Type</div> |
| <div class="table-header col-second">Method</div> |
| <div class="table-header col-last">Description</div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>boolean</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#equals(java.lang.Object)" class="member-name-link">equals</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> object)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns <code>true</code> if the given object is an instance of the same class having the same name and type.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>final <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Class.html" title="class or interface in java.lang" class="external-link">Class</a><<a href="OptionKey.html" title="type parameter in OptionKey">T</a>></code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getElementType()" class="member-name-link">getElementType</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the type of values associated to this option key.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a></code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getName()" class="member-name-link">getName</a>()</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the name of this option key.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="OptionKey.html" title="type parameter in OptionKey">T</a></code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getValueFrom(java.util.Map)" class="member-name-link">getValueFrom</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/Map.html" title="class or interface in java.util" class="external-link">Map</a><<a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><?>,<wbr>?> options)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the option value in the given map for this key, or <code>null</code> if none.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>int</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#hashCode()" class="member-name-link">hashCode</a>()</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns a hash code value for this object.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/Map.html" title="class or interface in java.util" class="external-link">Map</a><<a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><?>,<wbr><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a>></code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#setValueInto(java.util.Map,T)" class="member-name-link">setValueInto</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/Map.html" title="class or interface in java.util" class="external-link">Map</a><<a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><?>,<wbr><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a>> options, |
| <a href="OptionKey.html" title="type parameter in OptionKey">T</a> value)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Sets a value for this option key in the given map, or in a new map if the given map is <code>null</code>.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a></code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#toString()" class="member-name-link">toString</a>()</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns a string representation of this option key.</div> |
| </div> |
| </div> |
| </div> |
| </div> |
| <div class="inherited-list"> |
| <h3 id="methods-inherited-from-class-Object">Methods inherited from class <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a></h3> |
| <code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#clone()" title="class or interface in java.lang" class="external-link">clone</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#finalize()" title="class or interface in java.lang" class="external-link">finalize</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#getClass()" title="class or interface in java.lang" class="external-link">getClass</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#notify()" title="class or interface in java.lang" class="external-link">notify</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#notifyAll()" title="class or interface in java.lang" class="external-link">notifyAll</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#wait()" title="class or interface in java.lang" class="external-link">wait</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#wait(long)" title="class or interface in java.lang" class="external-link">wait</a>, <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#wait(long,int)" title="class or interface in java.lang" class="external-link">wait</a></code></div> |
| </section> |
| </li> |
| </ul> |
| </section> |
| <section class="details"> |
| <ul class="details-list"> |
| <!-- ============ FIELD DETAIL =========== --> |
| <li> |
| <section class="field-details" id="field-detail"> |
| <h2>Field Details</h2> |
| <ul class="member-list"> |
| <li> |
| <section class="detail" id="LOCALE"> |
| <h3>LOCALE</h3> |
| <div class="member-signature"><span class="modifiers">public static final</span> <span class="return-type"><a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/Locale.html" title="class or interface in java.util" class="external-link">Locale</a>></span> <span class="element-name">LOCALE</span></div> |
| <div class="block">The locale to use for locale-sensitive data. This option determines the language to use for writing |
| <a href="../util/AbstractInternationalString.html" title="class in org.apache.sis.util"><code>international strings</code></a> when the target |
| storage support only one language. It may also control number and date patterns in some file formats |
| like Comma Separated Values (CSV). However, most data formats will ignore this locale. |
| |
| <p>This option is <strong>not</strong> for the locale of logging or warning messages. Messages |
| locale is rather controlled by <a href="../storage/DataStore.html#setLocale(java.util.Locale)"><code>DataStore.setLocale(Locale)</code></a>.</p></div> |
| <dl class="notes"> |
| <dt>Since:</dt> |
| <dd>0.8</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="see-list"> |
| <li><a href="../xml/XML.html#LOCALE"><code>XML.LOCALE</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="TIMEZONE"> |
| <h3>TIMEZONE</h3> |
| <div class="member-signature"><span class="modifiers">public static final</span> <span class="return-type"><a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/TimeZone.html" title="class or interface in java.util" class="external-link">TimeZone</a>></span> <span class="element-name">TIMEZONE</span></div> |
| <div class="block">The timezone to use when parsing or formatting dates and times without explicit timezone. |
| If this option is not provided, then the default value is format specific. |
| That default is often, but not necessarily, the <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/TimeZone.html#getDefault()" title="class or interface in java.util" class="external-link">platform default</a>. |
| |
| <div class="warning"><b>Upcoming API change — Java time API</b>: |
| the type may be changed to <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/time/ZoneId.html" title="class or interface in java.time" class="external-link"><code>ZoneId</code></a> when Apache SIS will target Java 8. |
| This change may be applied in synchronization with GeoAPI 4.0. |
| </div></div> |
| <dl class="notes"> |
| <dt>Since:</dt> |
| <dd>0.8</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="see-list"> |
| <li><a href="../xml/XML.html#TIMEZONE"><code>XML.TIMEZONE</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="ENCODING"> |
| <h3>ENCODING</h3> |
| <div class="member-signature"><span class="modifiers">public static final</span> <span class="return-type"><a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/charset/Charset.html" title="class or interface in java.nio.charset" class="external-link">Charset</a>></span> <span class="element-name">ENCODING</span></div> |
| <div class="block">The character encoding of document content. |
| This option can be used when the file to read does not describe itself its encoding. |
| For example, this option can be used when reading plain text files, but is ignored when |
| reading XML files having a <code><?xml version="1.0" encoding="…"?></code> declaration. |
| |
| <p>If this option is not provided, then the default value is format specific. |
| That default is often, but not necessarily, the <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/charset/Charset.html#defaultCharset()" title="class or interface in java.nio.charset" class="external-link">platform default</a>.</p></div> |
| <dl class="notes"> |
| <dt>Since:</dt> |
| <dd>0.4</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="see-list"> |
| <li><code>Marshaller.JAXB_ENCODING</code></li> |
| </ul> |
| </dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="URL_ENCODING"> |
| <h3>URL_ENCODING</h3> |
| <div class="member-signature"><span class="modifiers">public static final</span> <span class="return-type"><a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a>></span> <span class="element-name">URL_ENCODING</span></div> |
| <div class="block">The encoding of a URL (<strong>not</strong> the encoding of the document content). |
| This option may be used when converting a <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link"><code>String</code></a> or a <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/net/URL.html" title="class or interface in java.net" class="external-link"><code>URL</code></a> |
| to a <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/net/URI.html" title="class or interface in java.net" class="external-link"><code>URI</code></a> or a <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/io/File.html" title="class or interface in java.io" class="external-link"><code>File</code></a>. The following rules apply: |
| |
| <ul> |
| <li>URI are always encoded in UTF-8. Consequently, this option is ignored for URI.</li> |
| <li>URL are often encoded in UTF-8, but not necessarily. Other encodings are possible |
| (while not recommended), or some URL may not be encoded at all.</li> |
| </ul> |
| |
| If this option is not provided, then the URL is assumed <strong>not</strong> encoded. |
| |
| <p><b>Example:</b> Given the <code>"file:Map%20with%20spaces.png"</code> URL, then:</p> |
| <ul> |
| <li>If the URL encoding option is set to <code>"UTF-8"</code> or <code>"ISO-8859-1"</code>, then:<ul> |
| <li>the encoded URI will be <code>"file:Map%20with%20spaces.png"</code>;</li> |
| <li>the decoded URI or the file will be <code>"file:Map with spaces.png"</code>.</li> |
| </ul></li> |
| <li>If the URL encoding option is set to <code>null</code> or is not provided, then:<ul> |
| <li>the encoded URI will be <code>"file:Map%2520with%2520spaces.png"</code>, |
| i.e. the percent sign will be encoded as <code>"%25"</code>;</li> |
| <li>the decoded URI or the file will be <code>"file:Map%20with%20spaces.png"</code>.</li> |
| </ul></li> |
| </ul> |
| |
| This option has not effect on URI encoding, which is always UTF-8.</div> |
| <dl class="notes"> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="see-list"> |
| <li><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/net/URLDecoder.html" title="class or interface in java.net" class="external-link"><code>URLDecoder</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="OPEN_OPTIONS"> |
| <h3>OPEN_OPTIONS</h3> |
| <div class="member-signature"><span class="modifiers">public static final</span> <span class="return-type"><a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/file/OpenOption.html" title="class or interface in java.nio.file" class="external-link">OpenOption</a>[]></span> <span class="element-name">OPEN_OPTIONS</span></div> |
| <div class="block">Whether a storage object (e.g. a <a href="../storage/DataStore.html" title="class in org.apache.sis.storage"><code>DataStore</code></a>) shall be opened in read, |
| write, append or other modes. The main options that can be provided are: |
| |
| <table class="sis"> |
| <caption>Supported open options</caption> |
| <tr><th>Value</th> <th>Meaning</th></tr> |
| <tr><td><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/file/StandardOpenOption.html#READ" title="class or interface in java.nio.file" class="external-link"><code>StandardOpenOption.READ</code></a></td> <td>Open for reading data from the storage object.</td></tr> |
| <tr><td><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/file/StandardOpenOption.html#WRITE" title="class or interface in java.nio.file" class="external-link"><code>StandardOpenOption.WRITE</code></a></td> <td>Open for modifying existing data in the storage object.</td></tr> |
| <tr><td><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/file/StandardOpenOption.html#APPEND" title="class or interface in java.nio.file" class="external-link"><code>StandardOpenOption.APPEND</code></a></td> <td>Open for appending new data in the storage object.</td></tr> |
| <tr><td><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/file/StandardOpenOption.html#CREATE" title="class or interface in java.nio.file" class="external-link"><code>StandardOpenOption.CREATE</code></a></td> <td>Creates a new storage object (file or database) if it does not exist.</td></tr> |
| </table></div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="BYTE_BUFFER"> |
| <h3>BYTE_BUFFER</h3> |
| <div class="member-signature"><span class="modifiers">public static final</span> <span class="return-type"><a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/ByteBuffer.html" title="class or interface in java.nio" class="external-link">ByteBuffer</a>></span> <span class="element-name">BYTE_BUFFER</span></div> |
| <div class="block">The byte buffer to use for input/output operations. Some <a href="../storage/DataStore.html" title="class in org.apache.sis.storage"><code>DataStore</code></a> |
| implementations allow a byte buffer to be specified, thus allowing users to choose the buffer |
| <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/Buffer.html#capacity()" title="class or interface in java.nio" class="external-link">capacity</a>, whether the buffer <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/ByteBuffer.html#isDirect()" title="class or interface in java.nio" class="external-link">is direct</a>, or to recycle existing buffers. |
| |
| <p>It is user's responsibility to ensure that:</p> |
| <ul> |
| <li>The buffer does not contains any valuable data, as it will be <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/nio/ByteBuffer.html#clear()" title="class or interface in java.nio" class="external-link">cleared</a>.</li> |
| <li>The same buffer is not used concurrently by two different <code>DataStore</code> instances.</li> |
| </ul></div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="GEOMETRY_LIBRARY"> |
| <h3>GEOMETRY_LIBRARY</h3> |
| <div class="member-signature"><span class="modifiers">public static final</span> <span class="return-type"><a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="GeometryLibrary.html" title="enum class in org.apache.sis.setup">GeometryLibrary</a>></span> <span class="element-name">GEOMETRY_LIBRARY</span></div> |
| <div class="block">The library to use for creating geometric objects at reading time. |
| Some libraries are the Java Topology Suite (JTS), ESRI geometry API and Java2D. |
| If this option is not specified, then a default library will be selected among |
| the libraries available in the runtime environment.</div> |
| <dl class="notes"> |
| <dt>Since:</dt> |
| <dd>0.8</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="INDENTATION"> |
| <h3>INDENTATION</h3> |
| <div class="member-signature"><span class="modifiers">public static final</span> <span class="return-type"><a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Integer.html" title="class or interface in java.lang" class="external-link">Integer</a>></span> <span class="element-name">INDENTATION</span></div> |
| <div class="block">The number of spaces to use for indentation when formatting text files in WKT or XML formats. |
| A value of <a href="../io/wkt/WKTFormat.html#SINGLE_LINE">-1</a> means to format the whole WKT |
| or XML document on a single line without line feeds or indentation. |
| |
| <p>If this option is not provided, then the most typical default value used in Apache SIS is 2. |
| Such small indentation value is used because XML documents defined by OGC standards tend to be |
| verbose.</p></div> |
| <dl class="notes"> |
| <dt>Since:</dt> |
| <dd>0.8</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="see-list-long"> |
| <li><a href="../io/wkt/WKTFormat.html#SINGLE_LINE"><code>WKTFormat.SINGLE_LINE</code></a></li> |
| <li><code>Marshaller.JAXB_FORMATTED_OUTPUT</code></li> |
| </ul> |
| </dd> |
| </dl> |
| </section> |
| </li> |
| </ul> |
| </section> |
| </li> |
| <!-- ========= CONSTRUCTOR DETAIL ======== --> |
| <li> |
| <section class="constructor-details" id="constructor-detail"> |
| <h2>Constructor Details</h2> |
| <ul class="member-list"> |
| <li> |
| <section class="detail" id="<init>(java.lang.String,java.lang.Class)"> |
| <h3>OptionKey</h3> |
| <div class="member-signature"><span class="modifiers">protected</span> <span class="element-name">OptionKey</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a> name, |
| <a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Class.html" title="class or interface in java.lang" class="external-link">Class</a><<a href="OptionKey.html" title="type parameter in OptionKey">T</a>> type)</span></div> |
| <div class="block">Creates a new key of the given name for values of the given type.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>name</code> - the key name.</dd> |
| <dd><code>type</code> - the type of values.</dd> |
| </dl> |
| </section> |
| </li> |
| </ul> |
| </section> |
| </li> |
| <!-- ============ METHOD DETAIL ========== --> |
| <li> |
| <section class="method-details" id="method-detail"> |
| <h2>Method Details</h2> |
| <ul class="member-list"> |
| <li> |
| <section class="detail" id="getName()"> |
| <h3>getName</h3> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a></span> <span class="element-name">getName</span>()</div> |
| <div class="block">Returns the name of this option key.</div> |
| <dl class="notes"> |
| <dt>Returns:</dt> |
| <dd>the name of this option key.</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getElementType()"> |
| <h3>getElementType</h3> |
| <div class="member-signature"><span class="modifiers">public final</span> <span class="return-type"><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Class.html" title="class or interface in java.lang" class="external-link">Class</a><<a href="OptionKey.html" title="type parameter in OptionKey">T</a>></span> <span class="element-name">getElementType</span>()</div> |
| <div class="block">Returns the type of values associated to this option key.</div> |
| <dl class="notes"> |
| <dt>Returns:</dt> |
| <dd>the type of values.</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getValueFrom(java.util.Map)"> |
| <h3>getValueFrom</h3> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="OptionKey.html" title="type parameter in OptionKey">T</a></span> <span class="element-name">getValueFrom</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/Map.html" title="class or interface in java.util" class="external-link">Map</a><<a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><?>,<wbr>?> options)</span></div> |
| <div class="block">Returns the option value in the given map for this key, or <code>null</code> if none. |
| This is a convenience method for implementers, which can be used as below: |
| |
| <blockquote><pre><font color="green">public</font> <T> T <b>getOption</b>(<font color="green">final</font> OptionKey<T> key) { |
| ArgumentChecks.<b>ensureNonNull</b>(<font color="orangered">"key"</font>, key); |
| <font color="green">return</font> key.<b>getValueFrom</b>(options); |
| }</pre></blockquote></div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>options</code> - the map where to search for the value, or <code>null</code> if not yet created.</dd> |
| <dt>Returns:</dt> |
| <dd>the current value in the map for the this option, or <code>null</code> if none.</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="setValueInto(java.util.Map,T)"> |
| <h3 id="setValueInto(java.util.Map,java.lang.Object)">setValueInto</h3> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/Map.html" title="class or interface in java.util" class="external-link">Map</a><<a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><?>,<wbr><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a>></span> <span class="element-name">setValueInto</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/Map.html" title="class or interface in java.util" class="external-link">Map</a><<a href="OptionKey.html" title="class in org.apache.sis.setup">OptionKey</a><?>,<wbr><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a>> options, |
| <a href="OptionKey.html" title="type parameter in OptionKey">T</a> value)</span></div> |
| <div class="block">Sets a value for this option key in the given map, or in a new map if the given map is <code>null</code>. |
| This is a convenience method for implementers, which can be used as below: |
| |
| <blockquote><pre><font color="green">public</font> <T> <font color="green">void</font> <b>setOption</b>(<font color="green">final</font> OptionKey<T> key, <font color="green">final</font> T value) { |
| ArgumentChecks.<b>ensureNonNull</b>(<font color="orangered">"key"</font>, key); |
| options = key.<b>setValueInto</b>(options, value); |
| }</pre></blockquote></div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>options</code> - the map where to set the value, or <code>null</code> if not yet created.</dd> |
| <dd><code>value</code> - the new value for the given option, or <code>null</code> for removing the value.</dd> |
| <dt>Returns:</dt> |
| <dd>the given map of options, or a new map if the given map was null. The returned value |
| may be null if the given map and the given value are both null.</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="equals(java.lang.Object)"> |
| <h3>equals</h3> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">boolean</span> <span class="element-name">equals</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> object)</span></div> |
| <div class="block">Returns <code>true</code> if the given object is an instance of the same class having the same name and type.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#equals(java.lang.Object)" title="class or interface in java.lang" class="external-link">equals</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>object</code> - the object to compare with this <code>OptionKey</code> for equality.</dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="hashCode()"> |
| <h3>hashCode</h3> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">int</span> <span class="element-name">hashCode</span>()</div> |
| <div class="block">Returns a hash code value for this object.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#hashCode()" title="class or interface in java.lang" class="external-link">hashCode</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a></code></dd> |
| </dl> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="toString()"> |
| <h3>toString</h3> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a></span> <span class="element-name">toString</span>()</div> |
| <div class="block">Returns a string representation of this option key. |
| The default implementation returns the value of <a href="#getName()"><code>getName()</code></a>.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#toString()" title="class or interface in java.lang" class="external-link">toString</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a></code></dd> |
| </dl> |
| </section> |
| </li> |
| </ul> |
| </section> |
| </li> |
| </ul> |
| </section> |
| <!-- ========= END OF CLASS DATA ========= --> |
| </main> |
| <footer role="contentinfo"> |
| <hr> |
| <p class="legal-copy"><small>Copyright © 2010–2022 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p> |
| </footer> |
| </div> |
| </div> |
| </body> |
| </html> |