gvsig-raster / org.gvsig.raster / branches / org.gvsig.raster.2.4 / org.gvsig.raster / org.gvsig.raster.lib / org.gvsig.raster.lib.buffer / org.gvsig.raster.lib.buffer.api / src / main / java / org / gvsig / raster / lib / buffer / api / ROI.java @ 8800
History | View | Annotate | Download (2.97 KB)
1 |
/* gvSIG. Desktop Geographic Information System.
|
---|---|
2 |
*
|
3 |
* Copyright ? 2007-2016 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.raster.lib.buffer.api; |
24 |
|
25 |
import org.gvsig.fmap.geom.Geometry; |
26 |
import org.gvsig.fmap.geom.exception.CreateGeometryException; |
27 |
import org.gvsig.fmap.geom.operation.GeometryOperationException; |
28 |
import org.gvsig.fmap.geom.operation.GeometryOperationNotSupportedException; |
29 |
import org.gvsig.fmap.geom.primitive.Envelope; |
30 |
import org.gvsig.raster.lib.buffer.api.exceptions.GettingEnvelopeException; |
31 |
import org.gvsig.tools.observer.Observable; |
32 |
|
33 |
/**
|
34 |
* @author fdiaz
|
35 |
*
|
36 |
*/
|
37 |
public interface ROI extends Observable { |
38 |
|
39 |
public static final String ROI_CHANGED = "ROI Changed"; |
40 |
|
41 |
/**
|
42 |
* Checks if a point in pixel coordinates is inside of this region of
|
43 |
* interest
|
44 |
*
|
45 |
* @param cellX X cell of raster
|
46 |
* @param cellY Y cell of raster
|
47 |
* @return true whether the point is inside
|
48 |
* @throws CreateGeometryException
|
49 |
* @throws GeometryOperationException
|
50 |
* @throws GeometryOperationNotSupportedException
|
51 |
*/
|
52 |
public boolean isInside(int cellX, int cellY) throws CreateGeometryException, |
53 |
GeometryOperationNotSupportedException, GeometryOperationException; |
54 |
|
55 |
/**
|
56 |
* Checks if the geometry is inside of this region of interest
|
57 |
*
|
58 |
* @param geometry
|
59 |
* Geometry to check if it is inside roi
|
60 |
* @return true whether the point is inside
|
61 |
* @throws GeometryOperationException
|
62 |
* @throws GeometryOperationNotSupportedException
|
63 |
*/
|
64 |
public boolean isInside(Geometry geometry) throws GeometryOperationNotSupportedException, |
65 |
GeometryOperationException; |
66 |
|
67 |
/**
|
68 |
* Gets the bounding box of this ROI
|
69 |
*
|
70 |
* @return the envelope
|
71 |
* @throws GettingEnvelopeException
|
72 |
* @throws CloneNotSupportedException
|
73 |
*/
|
74 |
public Envelope getEnvelope() throws GettingEnvelopeException; |
75 |
|
76 |
/**
|
77 |
* @return the name
|
78 |
*/
|
79 |
public String getName(); |
80 |
|
81 |
/**
|
82 |
* @param name
|
83 |
*/
|
84 |
public void setName(String name); |
85 |
|
86 |
/**
|
87 |
* @return the identifier
|
88 |
*/
|
89 |
public long getID(); |
90 |
|
91 |
/**
|
92 |
* @param id
|
93 |
*/
|
94 |
public void setID(long id); |
95 |
|
96 |
} |