Statistics
| Revision:

gvsig-raster / org.gvsig.raster.cache / trunk / org.gvsig.raster.cache / org.gvsig.raster.cache.lib.api / src / main / java / org / gvsig / raster / cache / buffer / BufferParam.java @ 999

History | View | Annotate | Download (3.28 KB)

1
package org.gvsig.raster.cache.buffer;
2

    
3
import java.awt.geom.Rectangle2D;
4

    
5
import org.gvsig.raster.cache.buffer.BufferDataSource;
6

    
7
/**
8
 * Buffer parameters. This class contains generic parameters. 
9
 * Basic information to fill: x, y, w, h, datatype and bandcount. If
10
 * the buffer is RasterReadOnlyBuffer is necessary a IBufferDataSource too.
11
 * 02/11/2008
12
 * @author Nacho Brodin nachobrodin@gmail.com
13
 */
14
public interface BufferParam {
15
        /**
16
         * Get a interest area
17
         * @return Rectangle2D
18
         */
19
        public Rectangle2D getAreaOfInterest();
20
        
21
        /**
22
         * Set a interest area
23
         * @param selection
24
         */
25
        public void setAreaOfInterest(Rectangle2D selection);
26
        
27
        /**
28
         * Get the file reference
29
         * @return
30
         */
31
        public String getReference();
32
        
33
        /**
34
         * Set the file reference
35
         * @param ref
36
         */
37
        public void setReference(String ref);
38
        
39
        /**
40
         * Set the data source
41
         * @param dataSource
42
         */
43
        public void setDataSource(BufferDataSource dataSource);
44

    
45
        /**
46
         * Get the data source
47
         * @return
48
         */
49
        public BufferDataSource getDataSource();
50
        
51
        /**
52
         * Returns the width in pixels
53
         * @return Width in pixels of this raster
54
         */
55
        public int getWidth();
56

    
57
        /**
58
         * Sets the width in pixels
59
         * @param  width
60
         *         Width in pixels of this raster
61
         */
62
        public void setWidth(int width);
63

    
64
        /**
65
         * Returns the height in pixels
66
         * @return Height in pixels of this raster
67
         */
68
        public int getHeight();
69

    
70
        /**
71
         * Sets the height in pixels
72
         * @param  height
73
         *         Height in pixels of this raster 
74
         */
75
        public void setHeight(int height);
76

    
77
        /**
78
         * Returns the X upper left coordinate
79
         * @return X upper left coordinate in pixels
80
         */
81
        public int getX();
82

    
83
        /**
84
         * Sets the X upper left coordinate
85
         * @params  x
86
         *          X upper left coordinate in pixels
87
         */
88
        public void setX(int x);
89

    
90
        /**
91
         * Returns the Y upper left coordinate
92
         * @return Y upper left coordinate in pixels
93
         */
94
        public int getY();
95

    
96
        /**
97
         * Sets the Y upper left coordinate
98
         * @params  y
99
         *          Y upper left coordinate in pixels
100
         */
101
        public void setY(int y);
102

    
103
        /**
104
         * Gets the data type
105
         * @return
106
         */
107
        public int getDataType();
108

    
109
        /**
110
         * Sets the data type
111
         * @param dataType
112
         */
113
        public void setDataType(int dataType);
114

    
115
        /**
116
         * Gets number of bands
117
         * @return
118
         */
119
        public int getBandCount();
120

    
121
        /**
122
         * Sets number of bands
123
         * @param bandCount
124
         */
125
        public void setBandCount(int bandCount);
126
        
127
        /**
128
         * Adds one to the band counter
129
         */
130
        public void bandPlusPlus();
131
        
132
        /**
133
         * Substracts one to the band counter
134
         */
135
        public void bandLessLess();
136
        
137
         /**
138
     * Gets no data value
139
     * @return double
140
     */
141
         public double getNoDataValue();
142
         
143
         /**
144
          * Sets no data value
145
          * @return double
146
          */
147
         public void setNoDataValue(double noDataValue);
148
        
149
        /**
150
         * Gets the size of the data type in bytes
151
         * @return Size of the data type that is used
152
         */
153
        public int getDataSize();
154
    
155
    /**
156
         * Gets the buffer size
157
         * @return buffer size
158
         */
159
        public long sizeof();
160
        
161
        /**
162
         * Sets the type of access defined as constant in Buffer interface
163
         */
164
        public void setAccessType(int accessType);
165
        
166
        /**
167
         * Gets the type of access defined as constant in Buffer interface
168
         */
169
        public int getAccessType();
170
        
171
        /**
172
         * Sets the band list
173
         * @param file
174
         */
175
        public void setBandList(int[] bands);
176

    
177
        /**
178
         * Gets the band list
179
         * @return
180
         */
181
        public int[] getBandList();
182
}