⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 referencedcanvas.html

📁 Geotools是一个开源的Java GIS工具包,可利用它来开发符合标准的地理信息系统。Geotools提供了OGC(Open Geospatial Consortium)规范的一个实现来作为他们的
💻 HTML
📖 第 1 页 / 共 5 页
字号:
 implementation invokes <code><A HREF="../../../../org/geotools/display/canvas/ReferencedGraphic.html#getTypicalCellDimension(org.opengis.spatialschema.geometry.DirectPosition)"><CODE>getTypicalCellDimension</CODE></A>(position)</code> for each graphic and returns the finest resolution.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>position</CODE> - A position where to evaluate the typical cell size, or  for         a default one.<DT><B>Returns:</B><DD>A typical cell dimension in terms of objective CRS, or  is no graphic         provide such information.</DL></DD></DL><HR><A NAME="getScale()"><!-- --></A><H3>getScale</H3><PRE>public double <B>getScale</B>()</PRE><DL><DD>Returns the scale factor, or <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Double.html#NaN" title="class or interface in java.lang"><CODE>NaN</CODE></A> if the scale is unknow. The scale factor is usually smaller than 1. For example for a 1:1000 scale, the scale factor will be 0.001. This scale factor takes in account the physical size of the rendering device (e.g. the screen size) if such information is available. Note that this scale can't be more accurate than the <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/GraphicsConfiguration.html#getNormalizingTransform()" title="class or interface in java.awt">information supplied by the underlying system</A>. <p>  do not computes the scale by itself. This information is available only if subclasses invoke <A HREF="../../../../org/geotools/display/canvas/ReferencedCanvas.html#setScale(double)"><CODE>setScale(double)</CODE></A>.<P><DD><DL><DT><B>Returns:</B><DD>The rendering scale factor as a number between 0 and 1, or <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Double.html#NaN" title="class or interface in java.lang"><CODE>Double.NaN</CODE></A>.</DL></DD></DL><HR><A NAME="setScale(double)"><!-- --></A><H3>setScale</H3><PRE>protected void <B>setScale</B>(double&nbsp;scaleFactor)</PRE><DL><DD>Set the scale factor to the specified value. Subclasses should invoke this method everytime the scale changed. This method is usually (but not always) invoked together with <A HREF="../../../../org/geotools/display/canvas/BufferedCanvas2D.html#zoomChanged(java.awt.geom.AffineTransform)"><CODE>BufferedCanvas2D.zoomChanged(java.awt.geom.AffineTransform)</CODE></A>. Note that some zoom changes do not imply a scale change. For example the zoom change may be just a translation or a rotation. <p> This method fires a {@value} property change event for every listeners registered in this canvas, as well as every listeners registered in each <A HREF="../../../../org/geotools/display/canvas/AbstractGraphic.html" title="class in org.geotools.display.canvas">graphic</A> contained in this canvas.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>scaleFactor</CODE> - The new scale factor.</DL></DD></DL><HR><A NAME="add(org.opengis.go.display.primitive.Graphic)"><!-- --></A><H3>add</H3><PRE>public Graphic <B>add</B>(Graphic&nbsp;graphic)</PRE><DL><DD>Adds the given  to this . This implementation respect the <var>z</var>-order retrieved by calling <CODE>Graphic.getZOrderHint()</CODE>. When two added s have the same <var>z</var>-order, the most recently added will be on top. <p> If no CRS were explicitly set to this canvas (either at construction time or through a call to <A HREF="../../../../org/geotools/display/canvas/ReferencedCanvas.html#setObjectiveCRS(org.opengis.referencing.crs.CoordinateReferenceSystem)"><CODE>setObjectiveCRS</CODE></A>), then this method will set the canvas objective CRS to the CRS of the first graphic added. <p> This method fires {@value} and {@value} property change events.<P><DD><DL><DT><B>Specified by:</B><DD><CODE>add</CODE> in interface <CODE>Canvas</CODE><DT><B>Overrides:</B><DD><CODE><A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#add(org.opengis.go.display.primitive.Graphic)">add</A></CODE> in class <CODE><A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html" title="class in org.geotools.display.canvas">AbstractCanvas</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>graphic</CODE> - Graphic to add to this canvas. This method call will be ignored if          has already been added to this canvas.<DT><B>Returns:</B><DD>The graphic added. This is usually the supplied graphic, but may also be a         new one if this method cloned the graphic.<DT><B>See Also:</B><DD><A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#remove(org.opengis.go.display.primitive.Graphic)"><CODE>AbstractCanvas.remove(org.opengis.go.display.primitive.Graphic)</CODE></A>, <A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#removeAll()"><CODE>AbstractCanvas.removeAll()</CODE></A>, <A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#getGraphics()"><CODE>AbstractCanvas.getGraphics()</CODE></A></DL></DD></DL><HR><A NAME="remove(org.opengis.go.display.primitive.Graphic)"><!-- --></A><H3>remove</H3><PRE>public void <B>remove</B>(Graphic&nbsp;graphic)</PRE><DL><DD>Removes the given  from this . Note that if the graphic is going to be added back to the same canvas later, then it is more efficient to invoke <CODE>Graphic.setVisible(boolean)</CODE> instead. <p> This method fires a {@value} property change event.<P><DD><DL><DT><B>Specified by:</B><DD><CODE>remove</CODE> in interface <CODE>Canvas</CODE><DT><B>Overrides:</B><DD><CODE><A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#remove(org.opengis.go.display.primitive.Graphic)">remove</A></CODE> in class <CODE><A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html" title="class in org.geotools.display.canvas">AbstractCanvas</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>graphic</CODE> - The graphic to remove. This method call will be ignored if          has already been removed from this canvas.<DT><B>See Also:</B><DD><A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#add(org.opengis.go.display.primitive.Graphic)"><CODE>AbstractCanvas.add(org.opengis.go.display.primitive.Graphic)</CODE></A>, <A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#removeAll()"><CODE>AbstractCanvas.removeAll()</CODE></A>, <A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#getGraphics()"><CODE>AbstractCanvas.getGraphics()</CODE></A></DL></DD></DL><HR><A NAME="removeAll()"><!-- --></A><H3>removeAll</H3><PRE>public void <B>removeAll</B>()</PRE><DL><DD>Remove all graphics from this canvas. <p> This method fires a {@value} property change event.<P><DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#removeAll()">removeAll</A></CODE> in class <CODE><A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html" title="class in org.geotools.display.canvas">AbstractCanvas</A></CODE></DL></DD><DD><DL><DT><B>See Also:</B><DD><A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#add(org.opengis.go.display.primitive.Graphic)"><CODE>AbstractCanvas.add(org.opengis.go.display.primitive.Graphic)</CODE></A>, <A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#remove(org.opengis.go.display.primitive.Graphic)"><CODE>AbstractCanvas.remove(org.opengis.go.display.primitive.Graphic)</CODE></A>, <A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#getGraphics()"><CODE>AbstractCanvas.getGraphics()</CODE></A></DL></DD></DL><HR><A NAME="graphicPropertyChanged(org.geotools.display.canvas.AbstractGraphic, java.beans.PropertyChangeEvent)"><!-- --></A><H3>graphicPropertyChanged</H3><PRE>protected void <B>graphicPropertyChanged</B>(<A HREF="../../../../org/geotools/display/canvas/AbstractGraphic.html" title="class in org.geotools.display.canvas">AbstractGraphic</A>&nbsp;graphic,                                      <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/beans/PropertyChangeEvent.html" title="class or interface in java.beans">PropertyChangeEvent</A>&nbsp;event)</PRE><DL><DD>Invoked automatically when a graphic registered in this canvas changed. Subclasses can override this method if they need to react to some graphic change events, but should always invoke .<P><DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html#graphicPropertyChanged(org.geotools.display.canvas.AbstractGraphic, java.beans.PropertyChangeEvent)">graphicPropertyChanged</A></CODE> in class <CODE><A HREF="../../../../org/geotools/display/canvas/AbstractCanvas.html" title="class in org.geotools.display.canvas">AbstractCanvas</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>graphic</CODE> - The graphic that changed.<DD><CODE>event</CODE> - The property change event.</DL></DD></DL><HR><A NAME="getTopGraphicAt(org.opengis.spatialschema.geometry.DirectPosition)"><!-- --></A><H3>getTopGraphicAt</H3><PRE>public Graphic <B>getTopGraphicAt</B>(DirectPosition&nbsp;directPosition)</PRE><DL><DD>Returns the top-most  that occupies given direct position. The top-most  will have the highest <var>z</var>-order.<P><DD><DL></DL></DD></DL><HR><A NAME="getGraphicsAt(org.opengis.spatialschema.geometry.DirectPosition)"><!-- --></A><H3>getGraphicsAt</H3><PRE>public Graphic[] <B>getGraphicsAt</B>(DirectPosition&nbsp;directPosition)</PRE><DL><DD>Returns the s that occupy the given direct position.<P><DD><DL></DL></DD></DL><HR><A NAME="getGraphicsIn(org.opengis.spatialschema.geometry.Envelope)"><!-- --></A><H3>getGraphicsIn</H3><PRE>public Graphic[] <B>getGraphicsIn</B>(Envelope&nbsp;bounds)</PRE><DL><DD>Returns the s that occupy the given envelope.<P><DD><DL></DL></DD></DL><HR><A NAME="isVisible(org.opengis.spatialschema.geometry.DirectPosition)"><!-- --></A><H3>isVisible</H3><PRE>public boolean <B>isVisible</B>(DirectPosition&nbsp;coordinate)</PRE><DL><DD>Returns  if the given coordinate is visible on this . The default implementation checks if the coordinate is inside the canvas envelope. Subclasses should override this method if a more accurate check is possible.<P><DD><DL></DL></DD></DL><HR><A NAME="format(org.geotools.display.event.ReferencedEvent, java.lang.StringBuffer)"><!-- --></A><H3>format</H3><PRE>public boolean <B>format</B>(<A HREF="../../../../org/geotools/display/event/ReferencedEvent.html" title="interface in org.geotools.display.event">ReferencedEvent</A>&nbsp;event,                      <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/StringBuffer.html" title="class or interface in java.lang">StringBuffer</A>&nbsp;toAppendTo)</PRE><DL><DD>Formats a value for a given event. The meaning of "value" depends on the underlying graphics. For example in the particular case of a Digital Elevation Model (DEM), it

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -