gvsig-raster / org.gvsig.raster / trunk / org.gvsig.raster / org.gvsig.raster.lib / org.gvsig.raster.lib.impl / src / main / java / org / gvsig / raster / impl / datastruct / GeoPointList.java @ 723
History | View | Annotate | Download (1.97 KB)
1 |
/* gvSIG. Geographic Information System of the Valencian Government
|
---|---|
2 |
*
|
3 |
* Copyright (C) 2007-2008 Infrastructures and Transports Department
|
4 |
* of the Valencian Government (CIT)
|
5 |
*
|
6 |
* This program is free software; you can redistribute it and/or
|
7 |
* modify it under the terms of the GNU General Public License
|
8 |
* as published by the Free Software Foundation; either version 2
|
9 |
* of the License, or (at your option) any later version.
|
10 |
*
|
11 |
* This program is distributed in the hope that it will be useful,
|
12 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14 |
* GNU General Public License for more details.
|
15 |
*
|
16 |
* You should have received a copy of the GNU General Public License
|
17 |
* along with this program; if not, write to the Free Software
|
18 |
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
19 |
* MA 02110-1301, USA.
|
20 |
*
|
21 |
*/
|
22 |
package org.gvsig.raster.impl.datastruct; |
23 |
|
24 |
import java.util.ArrayList; |
25 |
/**
|
26 |
* La clase GeoPointList es un contenedor de GeoPoints.
|
27 |
*
|
28 |
* Internamente se guardan en un ArrayList. As? que el interfaz que se ofrece
|
29 |
* hacia afuera es el de un ArrayList, con la excepcion de que en vez de tratar
|
30 |
* con Objects, se trata con GeoPoints.
|
31 |
*
|
32 |
* @version 17/07/2008
|
33 |
* @author BorSanZa - Borja S?nchez Zamorano (borja.sanchez@iver.es)
|
34 |
*/
|
35 |
public class GeoPointList { |
36 |
|
37 |
private ArrayList<GeoPoint> list = null; |
38 |
|
39 |
/**
|
40 |
* Construye una lista vac?a de GeoPoints
|
41 |
*/
|
42 |
public GeoPointList() {
|
43 |
list = new ArrayList<GeoPoint>(); |
44 |
} |
45 |
|
46 |
/**
|
47 |
* @param arg0
|
48 |
* @return
|
49 |
* @see java.util.ArrayList#add(java.lang.Object)
|
50 |
*/
|
51 |
public boolean add(GeoPoint arg0) { |
52 |
return list.add(arg0);
|
53 |
} |
54 |
|
55 |
/**
|
56 |
* @param index
|
57 |
* @return
|
58 |
* @see java.util.ArrayList#get(int)
|
59 |
*/
|
60 |
public GeoPoint get(int index) { |
61 |
return (GeoPoint) list.get(index);
|
62 |
} |
63 |
|
64 |
/**
|
65 |
* @return
|
66 |
* @see java.util.ArrayList#size()
|
67 |
*/
|
68 |
public int size() { |
69 |
return list.size();
|
70 |
} |
71 |
} |