资源简介
学GIS的可以看看,手工添加点自动建立delaunay三角网和voronoi图

代码片段和文件信息
package delaunay;
/*
* Copyright (c) 2007 by L. Paul Chew.
*
* Permission is hereby granted without written agreement and without
* license or royalty fees to use copy modify and distribute this
* software and its documentation for any purpose subject to the following
* conditions:
*
* The above copyright notice and this permission notice shall be included
* in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED “AS IS“ WITHOUT WARRANTY OF ANY KIND EXPRESS
* OR IMPLIED INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM DAMAGES OR OTHER
* LIABILITY WHETHER IN AN ACTION OF CONTRACT TORT OR OTHERWISE ARISING
* FROM OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* DEALINGS IN THE SOFTWARE.
*/
import java.util.AbstractSet;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Iterator;
/**
* An ArrayList implementation of Set. An ArraySet is good for small sets; it
* has less overhead than a HashSet or a TreeSet.
*
* @author Paul Chew
*
* Created December 2007. For use with Voronoi/Delaunay applet.
*
*/
public class ArraySet extends AbstractSet {
private ArrayList items; // Items of the set
/**
* Create an empty set (default initial capacity is 3).
*/
public ArraySet () {
this(3);
}
/**
* Create an empty set with the specified initial capacity.
* @param initialCapacity the initial capacity
*/
public ArraySet (int initialCapacity) {
items = new ArrayList(initialCapacity);
}
/**
* Create a set containing the items of the collection. Any duplicate
* items are discarded.
* @param collection the source for the items of the small set
*/
public ArraySet (Collection extends E> collection) {
items = new ArrayList(collection.size());
for (E item: collection)
if (!items.contains(item)) items.add(item);
}
/**
* Get the item at the specified index.
* @param index where the item is located in the ListSet
* @return the item at the specified index
* @throws IndexOutOfBoundsException if the index is out of bounds
*/
public E get (int index) throws IndexOutOfBoundsException {
return items.get(index);
}
/**
* True iff any member of the collection is also in the ArraySet.
* @param collection the Collection to check
* @return true iff any member of collection appears in this ArraySet
*/
public boolean containsAny (Collection> collection) {
for (object item: collection)
if (this.contains(item)) return true;
return false;
}
@Override
public boolean add(E item) {
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 232 2008-04-14 21:45 MyVoronoi\.classpath
文件 385 2008-04-14 21:45 MyVoronoi\.project
文件 2247 2009-03-31 17:10 MyVoronoi\bin\delaunay\ArraySet.class
文件 5593 2009-03-31 17:10 MyVoronoi\bin\delaunay\DelaunayAp.class
文件 6199 2009-03-31 17:10 MyVoronoi\bin\delaunay\DelaunayPanel.class
文件 2553 2009-03-31 17:10 MyVoronoi\bin\delaunay\Graph.class
文件 8927 2009-03-31 17:10 MyVoronoi\bin\delaunay\Pnt.class
文件 1172 2009-03-31 17:10 MyVoronoi\bin\delaunay\Triangle$1.class
文件 3701 2009-03-31 17:10 MyVoronoi\bin\delaunay\Triangle.class
文件 7482 2009-03-31 17:10 MyVoronoi\bin\delaunay\Triangulation.class
文件 141 2009-04-02 14:25 MyVoronoi\bin\java.policy.ap
文件 3269 2007-12-14 14:52 MyVoronoi\src\delaunay\ArraySet.java
文件 14597 2007-12-14 14:51 MyVoronoi\src\delaunay\DelaunayAp.java
文件 3825 2007-12-14 14:44 MyVoronoi\src\delaunay\Graph.java
文件 17519 2007-12-14 14:42 MyVoronoi\src\delaunay\Pnt.java
文件 5235 2007-12-14 14:44 MyVoronoi\src\delaunay\Triangle.java
文件 11137 2007-12-14 14:44 MyVoronoi\src\delaunay\Triangulation.java
目录 0 2009-06-09 01:34 MyVoronoi\bin\delaunay
目录 0 2009-06-09 01:34 MyVoronoi\src\delaunay
目录 0 2009-06-09 01:34 MyVoronoi\bin
目录 0 2009-06-09 01:34 MyVoronoi\src
目录 0 2009-06-09 01:34 MyVoronoi
----------- --------- ---------- ----- ----
94214 22
- 上一篇:datepicker.jar
- 下一篇:纯JAVA不用数据库的,用数组对数据增删改查
相关资源
- JAVA JSP公司财务管理系统 源代码 论文
- JSP+MYSQL旅行社管理信息系统
- 推荐算法的JAVA实现
- 基于Java的酒店管理系统源码(毕业设
- java-图片识别 图片比较
- android毕业设计
- java23种设计模式+23个实例demo
- java Socket发送/接受报文
- JAVA828436
- java界面美化 提供多套皮肤直接使用
- 在线聊天系统(java代码)
- 基于Java的图书管理系统807185
- java中实现将页面数据导入Excel中
- java 企业销售管理系统
- java做的聊天系统(包括正规课程设计
- Java编写的qq聊天室
- 商店商品管理系统 JAVA写的 有界面
- JAVA开发聊天室程序
- 在linux系统下用java执行系统命令实例
- java期末考试试题两套(答案) 选择(
- JAVA3D编程示例(建模、交互)
- Java 文件加密传输
- java做的房产管理系统
- 基于jsp的bbs论坛 非常详细
- [免费]java实现有障碍物的贪吃蛇游戏
- java Servlet投票实例
- 操作系统作业 (pv,作业管理,等5个
- 基于C/S架构考试系统(Java)
- java access 仓库管理系统 源码
- 一元多项式相加 java实现
评论
共有 条评论