| <!DOCTYPE HTML> |
| <!-- NewPage --> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc (11.0.4) on Fri Sep 20 12:10:30 CEST 2019 --> |
| <title>DirectPosition2D (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.geometry.DirectPosition2D class"> |
| <meta name="keywords" content="getDirectPosition()"> |
| <meta name="keywords" content="getDimension()"> |
| <meta name="keywords" content="getCoordinateReferenceSystem()"> |
| <meta name="keywords" content="setCoordinateReferenceSystem()"> |
| <meta name="keywords" content="getCoordinate()"> |
| <meta name="keywords" content="getOrdinate()"> |
| <meta name="keywords" content="setOrdinate()"> |
| <meta name="keywords" content="setLocation()"> |
| <meta name="keywords" content="toString()"> |
| <meta name="keywords" content="hashCode()"> |
| <meta name="keywords" content="equals()"> |
| <meta name="keywords" content="clone()"> |
| <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="DirectPosition2D (Apache SIS 1.0 API)"; |
| } |
| } |
| catch(err) { |
| } |
| //--> |
| var data = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":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/DirectPosition2D.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><a href="#nested.class.summary">Nested</a> | </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="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.geometry</a></div> |
| <h2 title="Class DirectPosition2D" class="title">Class DirectPosition2D</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="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D</a></li> |
| <li> |
| <ul class="inheritance"> |
| <li><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D.Double</a></li> |
| <li> |
| <ul class="inheritance"> |
| <li>DirectPosition2D</li> |
| </ul> |
| </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/Cloneable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Cloneable</a></code>, <code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/coordinate/Position.html?is-external=true" title="class or interface in org.opengis.geometry.coordinate" class="externalLink">Position</a></code>, <code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a></code></dd> |
| </dl> |
| <hr> |
| <pre>public class <span class="typeNameLabel">DirectPosition2D</span> |
| extends <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D.Double</a> |
| implements <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Cloneable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Cloneable</a></pre> |
| <div class="block">A two-dimensional position on top of Java2D point. |
| This implementation is provided for inter-operability between Java2D and GeoAPI. |
| |
| <p>This class inherits <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true#x" title="class or interface in java.awt.geom" class="externalLink">x</a> and <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true#y" title="class or interface in java.awt.geom" class="externalLink">y</a> fields. |
| But despite their names, they don't need to be oriented toward <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/cs/AxisDirection.html?is-external=true#EAST" title="class or interface in org.opengis.referencing.cs" class="externalLink">East</a> and |
| <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/cs/AxisDirection.html?is-external=true#NORTH" title="class or interface in org.opengis.referencing.cs" class="externalLink">North</a> respectively. The (<var>x</var>,<var>y</var>) axis can have any |
| direction and should be understood as <cite>coordinate 0</cite> and <cite>coordinate 1</cite> values instead. |
| This is not specific to this implementation; in Java2D too, the visual axis orientation depend |
| on the <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/Graphics2D.html?is-external=true#getTransform()" title="class or interface in java.awt" class="externalLink">affine transform in the graphics context</a>.</p> |
| |
| <div class="note"><b>Note:</b> |
| The rational for avoiding axis orientation restriction is that other <code>DirectPosition</code> implementations |
| do not have such restriction, and it would be hard to generalize. For example there is no clear "x" or "y" |
| classification for North-East direction.</div> |
| |
| <div class="section">Caution when used in collections</div> |
| Do not mix instances of this class with ordinary <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink"><code>Point2D</code></a> instances |
| in a <code>HashSet</code> or as <code>HashMap</code> keys. |
| It is not possible to met both <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#hashCode()" title="class or interface in java.awt.geom" class="externalLink"><code>Point2D.hashCode()</code></a> and <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true#hashCode()" title="class or interface in org.opengis.geometry" class="externalLink"><code>DirectPosition.hashCode()</code></a> |
| contracts, and this class chooses to implements the later. Consequently, the <a href="#hashCode()"><code>hashCode()</code></a> |
| method of this class is inconsistent with <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.awt.geom" class="externalLink"><code>Point2D.equals(Object)</code></a> but is consistent with |
| <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true#equals(java.lang.Object)" title="class or interface in org.opengis.geometry" class="externalLink"><code>DirectPosition.equals(Object)</code></a>. |
| |
| <p>In other words, it is safe to add instances of <code>DirectPosition2D</code> in a |
| <code>HashSet<DirectPosition></code>, but it is unsafe to add them in a <code>HashSet<Point2D></code>. |
| Collections that do not rely on hash codes, like <code>ArrayList</code>, are safe in all cases.</p></div> |
| <dl> |
| <dt><span class="simpleTagLabel">Since:</span></dt> |
| <dd>0.3</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="DirectPosition1D.html" title="class in org.apache.sis.geometry"><code>DirectPosition1D</code></a>, |
| <a href="GeneralDirectPosition.html" title="class in org.apache.sis.geometry"><code>GeneralDirectPosition</code></a>, |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink"><code>Point2D</code></a>, |
| <a href="CoordinateFormat.html" title="class in org.apache.sis.geometry"><code>CoordinateFormat</code></a>, |
| <a href="../../../../serialized-form.html#org.apache.sis.geometry.DirectPosition2D">Serialized Form</a></dd> |
| |
| <p><font size="-1">Defined in the <code>sis-referencing</code> module</font></p> |
| </dl> |
| </li> |
| </ul> |
| </div> |
| <div class="summary"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ======== NESTED CLASS SUMMARY ======== --> |
| <section role="region"> |
| <ul class="blockList"> |
| <li class="blockList"><a id="nested.class.summary"> |
| <!-- --> |
| </a> |
| <h3>Nested Class Summary</h3> |
| <ul class="blockList"> |
| <li class="blockList"><a id="nested.classes.inherited.from.class.java.awt.geom.Point2D"> |
| <!-- --> |
| </a> |
| <h3>Nested classes/interfaces inherited from class <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D.Double</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Float.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D.Float</a></code></li> |
| </ul> |
| </li> |
| </ul> |
| </section> |
| <!-- =========== FIELD SUMMARY =========== --> |
| <section role="region"> |
| <ul class="blockList"> |
| <li class="blockList"><a id="field.summary"> |
| <!-- --> |
| </a> |
| <h3>Field Summary</h3> |
| <ul class="blockList"> |
| <li class="blockList"><a id="fields.inherited.from.class.Point2D.Double"> |
| <!-- --> |
| </a> |
| <h3>Fields inherited from class <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D.Double</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true#x" title="class or interface in java.awt.geom" class="externalLink">x</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true#y" title="class or interface in java.awt.geom" class="externalLink">y</a></code></li> |
| </ul> |
| </li> |
| </ul> |
| </section> |
| <!-- ======== 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()">DirectPosition2D</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Constructs a position initialized to (0,0) with a <code>null</code> coordinate reference system.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(double,double)">DirectPosition2D</a></span>​(double x, |
| double y)</code></th> |
| <td class="colLast"> |
| <div class="block">Constructs a 2D position from the specified coordinates.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(java.lang.CharSequence)">DirectPosition2D</a></span>​(<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> wkt)</code></th> |
| <td class="colLast"> |
| <div class="block">Constructs a position initialized to the values parsed from the given string in |
| <cite>Well Known Text</cite> (WKT) format.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(org.opengis.geometry.DirectPosition)">DirectPosition2D</a></span>​(<a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a> position)</code></th> |
| <td class="colLast"> |
| <div class="block">Constructs a position initialized to the same values than the specified point.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(org.opengis.referencing.crs.CoordinateReferenceSystem)">DirectPosition2D</a></span>​(<a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/crs/CoordinateReferenceSystem.html?is-external=true" title="class or interface in org.opengis.referencing.crs" class="externalLink">CoordinateReferenceSystem</a> crs)</code></th> |
| <td class="colLast"> |
| <div class="block">Constructs a position initialized to (0,0) with the specified coordinate reference system.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(org.opengis.referencing.crs.CoordinateReferenceSystem,double,double)">DirectPosition2D</a></span>​(<a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/crs/CoordinateReferenceSystem.html?is-external=true" title="class or interface in org.opengis.referencing.crs" class="externalLink">CoordinateReferenceSystem</a> crs, |
| double x, |
| double y)</code></th> |
| <td class="colLast"> |
| <div class="block">Constructs a 2D position from the specified coordinates in the specified CRS.</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><a href="DirectPosition2D.html" title="class in org.apache.sis.geometry">DirectPosition2D</a></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#clone()">clone</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a clone of this point.</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 point with the specified object for equality.</div> |
| </td> |
| </tr> |
| <tr id="i2" class="altColor"> |
| <td class="colFirst"><code>double[]</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getCoordinate()">getCoordinate</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a sequence of numbers that hold the coordinate of this position in its reference system.</div> |
| </td> |
| </tr> |
| <tr id="i3" class="rowColor"> |
| <td class="colFirst"><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/crs/CoordinateReferenceSystem.html?is-external=true" title="class or interface in org.opengis.referencing.crs" class="externalLink">CoordinateReferenceSystem</a></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getCoordinateReferenceSystem()">getCoordinateReferenceSystem</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns the coordinate reference system in which the coordinate is given.</div> |
| </td> |
| </tr> |
| <tr id="i4" class="altColor"> |
| <td class="colFirst"><code>int</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getDimension()">getDimension</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">The length of coordinate sequence (the number of entries).</div> |
| </td> |
| </tr> |
| <tr id="i5" class="rowColor"> |
| <td class="colFirst"><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getDirectPosition()">getDirectPosition</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns always <code>this</code>, the direct position for this |
| <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/coordinate/Position.html?is-external=true" title="class or interface in org.opengis.geometry.coordinate" class="externalLink">position</a>.</div> |
| </td> |
| </tr> |
| <tr id="i6" class="altColor"> |
| <td class="colFirst"><code>double</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getOrdinate(int)">getOrdinate</a></span>​(int dimension)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns the coordinate at the specified dimension.</div> |
| </td> |
| </tr> |
| <tr id="i7" 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 value for this coordinate.</div> |
| </td> |
| </tr> |
| <tr id="i8" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#setCoordinateReferenceSystem(org.opengis.referencing.crs.CoordinateReferenceSystem)">setCoordinateReferenceSystem</a></span>​(<a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/crs/CoordinateReferenceSystem.html?is-external=true" title="class or interface in org.opengis.referencing.crs" class="externalLink">CoordinateReferenceSystem</a> crs)</code></th> |
| <td class="colLast"> |
| <div class="block">Sets the coordinate reference system in which the coordinate is given.</div> |
| </td> |
| </tr> |
| <tr id="i9" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#setLocation(java.awt.geom.Point2D)">setLocation</a></span>​(<a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D</a> position)</code></th> |
| <td class="colLast"> |
| <div class="block">Sets this coordinate to the specified point.</div> |
| </td> |
| </tr> |
| <tr id="i10" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#setOrdinate(int,double)">setOrdinate</a></span>​(int dimension, |
| double value)</code></th> |
| <td class="colLast"> |
| <div class="block">Sets the coordinate value along the specified dimension.</div> |
| </td> |
| </tr> |
| <tr id="i11" 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()">toString</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Formats this position in the <cite>Well Known Text</cite> (WKT) format.</div> |
| </td> |
| </tr> |
| </table> |
| <ul class="blockList"> |
| <li class="blockList"><a id="methods.inherited.from.class.Point2D.Double"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D.Double</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true#getX()" title="class or interface in java.awt.geom" class="externalLink">getX</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true#getY()" title="class or interface in java.awt.geom" class="externalLink">getY</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true#setLocation(double,double)" title="class or interface in java.awt.geom" class="externalLink">setLocation</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a id="methods.inherited.from.class.Point2D"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#distance(double,double)" title="class or interface in java.awt.geom" class="externalLink">distance</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#distance(double,double,double,double)" title="class or interface in java.awt.geom" class="externalLink">distance</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#distance(java.awt.geom.Point2D)" title="class or interface in java.awt.geom" class="externalLink">distance</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#distanceSq(double,double)" title="class or interface in java.awt.geom" class="externalLink">distanceSq</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#distanceSq(double,double,double,double)" title="class or interface in java.awt.geom" class="externalLink">distanceSq</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#distanceSq(java.awt.geom.Point2D)" title="class or interface in java.awt.geom" class="externalLink">distanceSq</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#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> |
| </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>DirectPosition2D</h4> |
| <pre>public DirectPosition2D()</pre> |
| <div class="block">Constructs a position initialized to (0,0) with a <code>null</code> coordinate reference system.</div> |
| </li> |
| </ul> |
| <a id="<init>(org.opengis.referencing.crs.CoordinateReferenceSystem)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>DirectPosition2D</h4> |
| <pre>public DirectPosition2D​(<a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/crs/CoordinateReferenceSystem.html?is-external=true" title="class or interface in org.opengis.referencing.crs" class="externalLink">CoordinateReferenceSystem</a> crs)</pre> |
| <div class="block">Constructs a position initialized to (0,0) with the specified coordinate reference system.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>crs</code> - the coordinate reference system, or <code>null</code>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="<init>(double,double)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>DirectPosition2D</h4> |
| <pre>public DirectPosition2D​(double x, |
| double y)</pre> |
| <div class="block">Constructs a 2D position from the specified coordinates. Despite their names, |
| the (<var>x</var>,<var>y</var>) coordinates don't need to be oriented toward |
| (<a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/cs/AxisDirection.html?is-external=true#EAST" title="class or interface in org.opengis.referencing.cs" class="externalLink">East</a>, <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/cs/AxisDirection.html?is-external=true#NORTH" title="class or interface in org.opengis.referencing.cs" class="externalLink">North</a>). |
| Those parameter names simply match the <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true#x" title="class or interface in java.awt.geom" class="externalLink">x</a> and <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true#y" title="class or interface in java.awt.geom" class="externalLink">y</a> fields. |
| See the <a href="#skip-navbar_top">class javadoc</a> for details.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>x</code> - the first coordinate value (not necessarily horizontal).</dd> |
| <dd><code>y</code> - the second coordinate value (not necessarily vertical).</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="<init>(org.opengis.referencing.crs.CoordinateReferenceSystem,double,double)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>DirectPosition2D</h4> |
| <pre>public DirectPosition2D​(<a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/crs/CoordinateReferenceSystem.html?is-external=true" title="class or interface in org.opengis.referencing.crs" class="externalLink">CoordinateReferenceSystem</a> crs, |
| double x, |
| double y)</pre> |
| <div class="block">Constructs a 2D position from the specified coordinates in the specified CRS. |
| Despite their names, the (<var>x</var>,<var>y</var>) coordinates don't need to be oriented |
| toward (<a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/cs/AxisDirection.html?is-external=true#EAST" title="class or interface in org.opengis.referencing.cs" class="externalLink">East</a>, <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/cs/AxisDirection.html?is-external=true#NORTH" title="class or interface in org.opengis.referencing.cs" class="externalLink">North</a>). |
| Those parameter names simply match the <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true#x" title="class or interface in java.awt.geom" class="externalLink">x</a> and <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true#y" title="class or interface in java.awt.geom" class="externalLink">y</a> fields. |
| The actual axis orientations are determined by the specified CRS. |
| See the <a href="#skip-navbar_top">class javadoc</a> for details.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>crs</code> - the coordinate reference system, or <code>null</code>.</dd> |
| <dd><code>x</code> - the first coordinate value (not necessarily horizontal).</dd> |
| <dd><code>y</code> - the second coordinate value (not necessarily vertical).</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="<init>(org.opengis.geometry.DirectPosition)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>DirectPosition2D</h4> |
| <pre>public DirectPosition2D​(<a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a> position) |
| throws <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/MismatchedDimensionException.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">MismatchedDimensionException</a></pre> |
| <div class="block">Constructs a position initialized to the same values than the specified point.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>position</code> - the position to copy.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/MismatchedDimensionException.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">MismatchedDimensionException</a></code> - if the given position is not two-dimensional.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="#setLocation(java.awt.geom.Point2D)"><code>setLocation(Point2D)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="<init>(java.lang.CharSequence)"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>DirectPosition2D</h4> |
| <pre>public DirectPosition2D​(<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> wkt) |
| 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">Constructs a position initialized to the values parsed from the given string in |
| <cite>Well Known Text</cite> (WKT) format. The given string is typically a <code>POINT</code> |
| element like below: |
| |
| <blockquote><pre>POINT(6 10)</pre></blockquote></div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>wkt</code> - the <code>POINT</code> or other kind of element to parse.</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 the given string can not be parsed.</dd> |
| <dd><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/MismatchedDimensionException.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">MismatchedDimensionException</a></code> - if the given point is not two-dimensional.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="#toString()"><code>toString()</code></a>, |
| <a href="CoordinateFormat.html" title="class in org.apache.sis.geometry"><code>CoordinateFormat</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="getDirectPosition()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getDirectPosition</h4> |
| <pre class="methodSignature">public final <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a> getDirectPosition()</pre> |
| <div class="block">Returns always <code>this</code>, the direct position for this |
| <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/coordinate/Position.html?is-external=true" title="class or interface in org.opengis.geometry.coordinate" class="externalLink">position</a>.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/coordinate/Position.html?is-external=true#getDirectPosition()" title="class or interface in org.opengis.geometry.coordinate" class="externalLink">getDirectPosition</a></code> in interface <code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/coordinate/Position.html?is-external=true" title="class or interface in org.opengis.geometry.coordinate" class="externalLink">Position</a></code></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="getDimension()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getDimension</h4> |
| <pre class="methodSignature">public final int getDimension()</pre> |
| <div class="block">The length of coordinate sequence (the number of entries). |
| This is always 2 for <code>DirectPosition2D</code> objects.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true#getDimension()" title="class or interface in org.opengis.geometry" class="externalLink">getDimension</a></code> in interface <code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the dimensionality of this position.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="getCoordinateReferenceSystem()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getCoordinateReferenceSystem</h4> |
| <pre class="methodSignature">public final <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/crs/CoordinateReferenceSystem.html?is-external=true" title="class or interface in org.opengis.referencing.crs" class="externalLink">CoordinateReferenceSystem</a> getCoordinateReferenceSystem()</pre> |
| <div class="block">Returns the coordinate reference system in which the coordinate is given. |
| May be <code>null</code> if this particular <code>DirectPosition</code> is included |
| in a larger object with such a reference to a CRS.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true#getCoordinateReferenceSystem()" title="class or interface in org.opengis.geometry" class="externalLink">getCoordinateReferenceSystem</a></code> in interface <code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the coordinate reference system, or <code>null</code>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="setCoordinateReferenceSystem(org.opengis.referencing.crs.CoordinateReferenceSystem)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setCoordinateReferenceSystem</h4> |
| <pre class="methodSignature">public void setCoordinateReferenceSystem​(<a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/crs/CoordinateReferenceSystem.html?is-external=true" title="class or interface in org.opengis.referencing.crs" class="externalLink">CoordinateReferenceSystem</a> crs)</pre> |
| <div class="block">Sets the coordinate reference system in which the coordinate is given.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>crs</code> - the new coordinate reference system, or <code>null</code>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="getCoordinate()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getCoordinate</h4> |
| <pre class="methodSignature">public final double[] getCoordinate()</pre> |
| <div class="block">Returns a sequence of numbers that hold the coordinate of this position in its reference system. |
| |
| <div class="note"><b>API note:</b> |
| This method is final for ensuring consistency with the <code>x</code> and <code>y</code> fields, which are public.</div></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true#getCoordinate()" title="class or interface in org.opengis.geometry" class="externalLink">getCoordinate</a></code> in interface <code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the coordinate.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="getOrdinate(int)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getOrdinate</h4> |
| <pre class="methodSignature">public final double getOrdinate​(int dimension) |
| throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IndexOutOfBoundsException</a></pre> |
| <div class="block">Returns the coordinate at the specified dimension. |
| |
| <div class="note"><b>API note:</b> |
| This method is final for ensuring consistency with the <code>x</code> and <code>y</code> fields, which are public.</div></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true#getOrdinate(int)" title="class or interface in org.opengis.geometry" class="externalLink">getOrdinate</a></code> in interface <code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>dimension</code> - the dimension in the range 0 to 1 inclusive.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the coordinate at the specified dimension.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IndexOutOfBoundsException</a></code> - if the specified dimension is out of bounds.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="setOrdinate(int,double)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setOrdinate</h4> |
| <pre class="methodSignature">public void setOrdinate​(int dimension, |
| double value) |
| throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IndexOutOfBoundsException</a></pre> |
| <div class="block">Sets the coordinate value along the specified dimension.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true#setOrdinate(int,double)" title="class or interface in org.opengis.geometry" class="externalLink">setOrdinate</a></code> in interface <code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>dimension</code> - the dimension for the coordinate of interest.</dd> |
| <dd><code>value</code> - the coordinate value of interest.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IndexOutOfBoundsException</a></code> - if the specified dimension is out of bounds.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="setLocation(java.awt.geom.Point2D)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setLocation</h4> |
| <pre class="methodSignature">public void setLocation​(<a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D</a> position)</pre> |
| <div class="block">Sets this coordinate to the specified point. If the specified position is also a |
| <code>DirectPosition</code> containing a non-null coordinate reference system (CRS), |
| then the CRS for this position will be set to the CRS of the given point.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#setLocation(java.awt.geom.Point2D)" title="class or interface in java.awt.geom" class="externalLink">setLocation</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>position</code> - the new position for this point.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="toString()"> |
| <!-- --> |
| </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()</pre> |
| <div class="block">Formats this position in the <cite>Well Known Text</cite> (WKT) format. |
| The output is like below: |
| |
| <blockquote><pre>POINT(x y)</pre></blockquote> |
| |
| The string returned by this method can be <a href="#%3Cinit%3E(java.lang.CharSequence)">parsed</a> |
| by the <code>DirectPosition2D</code> constructor.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true#toString()" title="class or interface in java.awt.geom" class="externalLink">toString</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.Double.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D.Double</a></code></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="hashCode()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>hashCode</h4> |
| <pre class="methodSignature">public int hashCode()</pre> |
| <div class="block">Returns a hash value for this coordinate. This method implements the |
| <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true#hashCode()" title="class or interface in org.opengis.geometry" class="externalLink"><code>DirectPosition.hashCode()</code></a> contract, not the <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#hashCode()" title="class or interface in java.awt.geom" class="externalLink"><code>Point2D.hashCode()</code></a> contract.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true#hashCode()" title="class or interface in org.opengis.geometry" class="externalLink">hashCode</a></code> in interface <code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a></code></dd> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#hashCode()" title="class or interface in java.awt.geom" class="externalLink">hashCode</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a hash code value for this position.</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 point with the specified object for equality. If the given object implements |
| the <code>DirectPosition</code> interface, then the comparison is performed as specified in the |
| <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true#equals(java.lang.Object)" title="class or interface in org.opengis.geometry" class="externalLink"><code>DirectPosition.equals(Object)</code></a> contract. Otherwise the comparison is performed as |
| specified in the <a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.awt.geom" class="externalLink"><code>Point2D.equals(Object)</code></a> contract.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true#equals(java.lang.Object)" title="class or interface in org.opengis.geometry" class="externalLink">equals</a></code> in interface <code><a href="http://www.geoapi.org/3.0/javadoc/org/opengis/geometry/DirectPosition.html?is-external=true" title="class or interface in org.opengis.geometry" class="externalLink">DirectPosition</a></code></dd> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.awt.geom" class="externalLink">equals</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>object</code> - the object to compare with this position.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><code>true</code> if the given object is equal to this position.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="clone()"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>clone</h4> |
| <pre class="methodSignature">public <a href="DirectPosition2D.html" title="class in org.apache.sis.geometry">DirectPosition2D</a> clone()</pre> |
| <div class="block">Returns a clone of this point.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true#clone()" title="class or interface in java.awt.geom" class="externalLink">clone</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/awt/geom/Point2D.html?is-external=true" title="class or interface in java.awt.geom" class="externalLink">Point2D</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a clone of this position.</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/DirectPosition2D.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><a href="#nested.class.summary">Nested</a> | </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="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> |