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

📄 esritextpoint.java

📁 OpenMap是一个基于JavaBeansTM的开发工具包。利用OpenMap你就能够快速构建用于访问legacy数据库的应用程序与applets。OpenMap提供了允许用户查看和操作地理空间信息的
💻 JAVA
字号:
// **********************************************************************// // <copyright>// //  BBN Technologies//  10 Moulton Street//  Cambridge, MA 02138//  (617) 873-8000// //  Copyright (C) BBNT Solutions LLC. All rights reserved.// // </copyright>// **********************************************************************// // $Source: /cvs/distapps/openmap/src/openmap/com/bbn/openmap/dataAccess/shape/EsriTextPoint.java,v $// $RCSfile: EsriTextPoint.java,v $// $Revision: 1.1.4.2 $// $Date: 2006/08/24 20:56:31 $// $Author: dietrick $// // **********************************************************************package com.bbn.openmap.dataAccess.shape;import com.bbn.openmap.omGraphics.DrawingAttributes;import com.bbn.openmap.omGraphics.OMGraphicConstants;import com.bbn.openmap.omGraphics.OMText;/** * An extension to OMPoint that typecasts a specific Esri graphic * type. Used to ensure that all OMGraphics added to a EsriGraphicList * is of the same type. *  * @author Doug Van Auken */public class EsriTextPoint extends OMText  implements Cloneable, EsriGraphic,        OMGraphicConstants {    protected int type = SHAPE_TYPE_POINT;        public EsriTextPoint(float lat, float lon, String stuff, int justification) {        super(lat, lon, stuff, justification);    }    /**     * The lat/lon extent of the EsriGraphic, assumed to contain miny,     * minx, maxy maxx in order of the array.     */    public void setExtents(float[] extents) {    // we know what it is.    }    /**     * The lat/lon extent of the EsriGraphic, returned as miny, minx,     * maxy maxx in order of the array.     */    public float[] getExtents() {        float[] ex = new float[4];        ex[0] = getLat();        ex[1] = getLon();        ex[2] = getLat();        ex[3] = getLon();        return ex;    }        public void setType(int t) {        type = t;    }        public int getType() {        return type;    }        public static EsriTextPoint convert(OMText omtext) {        if (omtext.getRenderType() == RENDERTYPE_LATLON) {            EsriTextPoint etp = new EsriTextPoint(omtext.getLat(), omtext.getLon(), omtext.getData(), omtext.getJustify());            etp.setAttributes(omtext.getAttributes());            DrawingAttributes attributes = new DrawingAttributes();            attributes.setFrom(omtext);            attributes.setTo(etp);            return etp;        } else {            return null;        }    }    public EsriGraphic shallowCopy() {        return shallowCopyPoint();    }    public EsriTextPoint shallowCopyPoint() {        return (EsriTextPoint) super.clone();    }}

⌨️ 快捷键说明

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