svn-gvsig-desktop / trunk / org.gvsig.desktop / org.gvsig.desktop.compat.cdc / org.gvsig.fmap.geometry / org.gvsig.fmap.geometry.jts / src / main / java / org / gvsig / fmap / geom / jts / primitive / surface / AbstractSurface.java @ 46506
History | View | Annotate | Download (2.58 KB)
1 |
/* gvSIG. Desktop Geographic Information System.
|
---|---|
2 |
*
|
3 |
* Copyright ? 2007-2015 gvSIG Association
|
4 |
*
|
5 |
* This program is free software; you can redistribute it and/or
|
6 |
* modify it under the terms of the GNU General Public License
|
7 |
* as published by the Free Software Foundation; either version 2
|
8 |
* of the License, or (at your option) any later version.
|
9 |
*
|
10 |
* This program is distributed in the hope that it will be useful,
|
11 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
12 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
13 |
* GNU General Public License for more details.
|
14 |
*
|
15 |
* You should have received a copy of the GNU General Public License
|
16 |
* along with this program; if not, write to the Free Software
|
17 |
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
18 |
* MA 02110-1301, USA.
|
19 |
*
|
20 |
* For any additional information, do not hesitate to contact us
|
21 |
* at info AT gvsig.com, or visit our website www.gvsig.com.
|
22 |
*/
|
23 |
package org.gvsig.fmap.geom.jts.primitive.surface; |
24 |
|
25 |
import org.gvsig.fmap.geom.Geometry; |
26 |
import org.gvsig.fmap.geom.jts.primitive.AbstractPrimitive; |
27 |
import org.gvsig.fmap.geom.jts.primitive.surface.split.SurfaceSplitOperation; |
28 |
import org.gvsig.fmap.geom.primitive.Point; |
29 |
import org.gvsig.fmap.geom.primitive.Surface; |
30 |
import org.gvsig.fmap.geom.primitive.SurfaceAppearance; |
31 |
|
32 |
|
33 |
/**
|
34 |
* @author fdiaz
|
35 |
*
|
36 |
*/
|
37 |
public abstract class AbstractSurface extends AbstractPrimitive implements Surface { |
38 |
|
39 |
/**
|
40 |
*
|
41 |
*/
|
42 |
private static final long serialVersionUID = 452141349577139850L; |
43 |
|
44 |
/**
|
45 |
*
|
46 |
* @param type
|
47 |
* @param subtype
|
48 |
*/
|
49 |
protected AbstractSurface(int type, int subtype) { |
50 |
super(type, subtype);
|
51 |
} |
52 |
|
53 |
|
54 |
/* (non-Javadoc)
|
55 |
* @see org.gvsig.fmap.geom.primitive.Surface#setSurfaceAppearance(org.gvsig.fmap.geom.primitive.SurfaceAppearance)
|
56 |
*/
|
57 |
@Override
|
58 |
public void setSurfaceAppearance(SurfaceAppearance app) { |
59 |
// TODO Auto-generated method stub
|
60 |
|
61 |
} |
62 |
|
63 |
/* (non-Javadoc)
|
64 |
* @see org.gvsig.fmap.geom.primitive.Surface#getSurfaceAppearance()
|
65 |
*/
|
66 |
@Override
|
67 |
public SurfaceAppearance getSurfaceAppearance() {
|
68 |
// TODO Auto-generated method stub
|
69 |
return null; |
70 |
} |
71 |
|
72 |
@Override
|
73 |
public Geometry split(Geometry splitter) {
|
74 |
SurfaceSplitOperation op = new SurfaceSplitOperation();
|
75 |
return op.split(this, splitter); |
76 |
} |
77 |
|
78 |
|
79 |
@Override
|
80 |
public boolean isEmpty() { |
81 |
return this.getNumVertices()<1; |
82 |
} |
83 |
|
84 |
@Override
|
85 |
public int size() { |
86 |
return this.getNumVertices(); |
87 |
} |
88 |
|
89 |
@Override
|
90 |
public Point get(int position) { |
91 |
return this.getVertex(position); |
92 |
} |
93 |
|
94 |
} |