root / branches / v2_0_0_prep / libraries / libFMap_dal / src / org / gvsig / fmap / dal / feature / EditableFeature.java @ 38608
History | View | Annotate | Download (6.89 KB)
1 | 24496 | jmvivo | package org.gvsig.fmap.dal.feature; |
---|---|---|---|
2 | 23754 | jjdelcerro | |
3 | import java.util.Date; |
||
4 | |||
5 | import org.gvsig.fmap.geom.Geometry; |
||
6 | 37297 | jpiera | import org.gvsig.timesupport.Instant; |
7 | import org.gvsig.timesupport.Interval; |
||
8 | 23754 | jjdelcerro | |
9 | 24537 | jiyarza | /**
|
10 | 24657 | jjdelcerro | * This interface represents a Feature in editable state. To edit a Feature
|
11 | 24537 | jiyarza | * you have to obtain its instance of EditableFeature and then perform editing
|
12 | 25481 | jiyarza | * operations on it. Once you have completed the editing you can save the changes
|
13 | 24537 | jiyarza | * to the original Feature. This is the only way to edit a Feature.
|
14 | */
|
||
15 | 23754 | jjdelcerro | public interface EditableFeature extends Feature { |
16 | |||
17 | 24537 | jiyarza | /**
|
18 | * Sets the value of an attribute given its name
|
||
19 | 24657 | jjdelcerro | * @param name
|
20 | 24537 | jiyarza | * attribute's name
|
21 | * @param value
|
||
22 | * value to set
|
||
23 | */
|
||
24 | 23754 | jjdelcerro | public void set(String name, Object value); |
25 | 24657 | jjdelcerro | |
26 | 24537 | jiyarza | /**
|
27 | * Sets the value of an attribute given its index
|
||
28 | 24657 | jjdelcerro | * @param index
|
29 | 24537 | jiyarza | * attribute's index
|
30 | * @param value
|
||
31 | * value to set
|
||
32 | 24657 | jjdelcerro | */
|
33 | 23754 | jjdelcerro | public void set(int index, Object value); |
34 | |||
35 | 24537 | jiyarza | /**
|
36 | * Sets the value of an attribute of type integer, given its name
|
||
37 | 24657 | jjdelcerro | * @param name
|
38 | 24537 | jiyarza | * attribute's name
|
39 | * @param value
|
||
40 | * value to set
|
||
41 | */
|
||
42 | 23754 | jjdelcerro | public void setInt(String name, int value); |
43 | 24657 | jjdelcerro | |
44 | 24537 | jiyarza | /**
|
45 | * Sets the value of an attribute of type integer, given its index
|
||
46 | 24657 | jjdelcerro | * @param index
|
47 | 24537 | jiyarza | * attribute's index
|
48 | * @param value
|
||
49 | * value to set
|
||
50 | 24657 | jjdelcerro | */
|
51 | 23754 | jjdelcerro | public void setInt(int index, int value); |
52 | |||
53 | 24537 | jiyarza | /**
|
54 | * Sets the value of an attribute of type boolean, given its name
|
||
55 | 24657 | jjdelcerro | * @param name
|
56 | 24537 | jiyarza | * attribute's name
|
57 | * @param value
|
||
58 | * value to set
|
||
59 | */
|
||
60 | 23754 | jjdelcerro | public void setBoolean(String name, boolean value); |
61 | 24657 | jjdelcerro | |
62 | 24537 | jiyarza | /**
|
63 | * Sets the value of an attribute of type boolean, given its index
|
||
64 | 24657 | jjdelcerro | * @param index
|
65 | 24537 | jiyarza | * attribute's index
|
66 | * @param value
|
||
67 | * value to set
|
||
68 | 24657 | jjdelcerro | */
|
69 | 23754 | jjdelcerro | public void setBoolean(int index, boolean value); |
70 | |||
71 | 24537 | jiyarza | /**
|
72 | * Sets the value of an attribute of type long, given its name
|
||
73 | 24657 | jjdelcerro | * @param name
|
74 | 24537 | jiyarza | * attribute's name
|
75 | * @param value
|
||
76 | * value to set
|
||
77 | 24657 | jjdelcerro | */
|
78 | 23754 | jjdelcerro | public void setLong(String name, long value); |
79 | 24657 | jjdelcerro | |
80 | 24537 | jiyarza | /**
|
81 | * Sets the value of an attribute of type long, given its index
|
||
82 | 24657 | jjdelcerro | * @param index
|
83 | 24537 | jiyarza | * attribute's index
|
84 | * @param value
|
||
85 | * value to set
|
||
86 | 24657 | jjdelcerro | */
|
87 | 23754 | jjdelcerro | public void setLong(int index, long value); |
88 | 23772 | jjdelcerro | |
89 | 24537 | jiyarza | /**
|
90 | * Sets the value of an attribute of type float, given its name
|
||
91 | 24657 | jjdelcerro | * @param name
|
92 | 24537 | jiyarza | * attribute's name
|
93 | * @param value
|
||
94 | * value to set
|
||
95 | 24657 | jjdelcerro | */
|
96 | 23754 | jjdelcerro | public void setFloat(String name, float value); |
97 | 24657 | jjdelcerro | |
98 | 24537 | jiyarza | /**
|
99 | * Sets the value of an attribute of type float, given its index
|
||
100 | 24657 | jjdelcerro | * @param index
|
101 | 24537 | jiyarza | * attribute's index
|
102 | * @param value
|
||
103 | * value to set
|
||
104 | 24657 | jjdelcerro | */
|
105 | 23754 | jjdelcerro | public void setFloat(int index, float value); |
106 | |||
107 | 24537 | jiyarza | /**
|
108 | * Sets the value of an attribute of type double, given its name
|
||
109 | 24657 | jjdelcerro | * @param name
|
110 | 24537 | jiyarza | * attribute's name
|
111 | * @param value
|
||
112 | * value to set
|
||
113 | 24657 | jjdelcerro | */
|
114 | 23754 | jjdelcerro | public void setDouble(String name, double value); |
115 | 24657 | jjdelcerro | |
116 | 24537 | jiyarza | /**
|
117 | * Sets the value of an attribute of type double, given its index
|
||
118 | 24657 | jjdelcerro | * @param index
|
119 | 24537 | jiyarza | * attribute's index
|
120 | * @param value
|
||
121 | * value to set
|
||
122 | 24657 | jjdelcerro | */
|
123 | 23754 | jjdelcerro | public void setDouble(int index, double value); |
124 | |||
125 | 24537 | jiyarza | /**
|
126 | * Sets the value of an attribute of type date, given its name
|
||
127 | 24657 | jjdelcerro | * @param name
|
128 | 24537 | jiyarza | * attribute's name
|
129 | * @param value
|
||
130 | * value to set
|
||
131 | 24657 | jjdelcerro | */
|
132 | 23754 | jjdelcerro | public void setDate(String name, Date value); |
133 | 24537 | jiyarza | |
134 | /**
|
||
135 | * Sets the value of an attribute of type date, given its index
|
||
136 | 24657 | jjdelcerro | * @param index
|
137 | 24537 | jiyarza | * attribute's index
|
138 | * @param value
|
||
139 | * value to set
|
||
140 | 24657 | jjdelcerro | */
|
141 | 23754 | jjdelcerro | public void setDate(int index, Date value); |
142 | |||
143 | 24537 | jiyarza | /**
|
144 | * Sets the value of an attribute of type string, given its name
|
||
145 | 24657 | jjdelcerro | * @param name
|
146 | 24537 | jiyarza | * attribute's name
|
147 | * @param value
|
||
148 | * value to set
|
||
149 | 24657 | jjdelcerro | */
|
150 | 23754 | jjdelcerro | public void setString(String name, String value); |
151 | 24537 | jiyarza | |
152 | /**
|
||
153 | * Sets the value of an attribute of type string, given its index
|
||
154 | 24657 | jjdelcerro | * @param index
|
155 | 24537 | jiyarza | * attribute's index
|
156 | * @param value
|
||
157 | * value to set
|
||
158 | 24657 | jjdelcerro | */
|
159 | 23754 | jjdelcerro | public void setString(int index, String value); |
160 | |||
161 | 24537 | jiyarza | /**
|
162 | * Sets the value of an attribute of type byte, given its name
|
||
163 | 24657 | jjdelcerro | * @param name
|
164 | 24537 | jiyarza | * attribute's name
|
165 | * @param value
|
||
166 | * value to set
|
||
167 | 24657 | jjdelcerro | */
|
168 | 23754 | jjdelcerro | public void setByte(String name, byte value); |
169 | 24657 | jjdelcerro | |
170 | 24537 | jiyarza | /**
|
171 | * Sets the value of an attribute of type byte, given its index
|
||
172 | 24657 | jjdelcerro | * @param index
|
173 | 24537 | jiyarza | * attribute's index
|
174 | * @param value
|
||
175 | * value to set
|
||
176 | 24657 | jjdelcerro | */
|
177 | 23754 | jjdelcerro | public void setByte(int index, byte value); |
178 | |||
179 | 24537 | jiyarza | /**
|
180 | * Sets the value of an attribute of type geometry, given its name
|
||
181 | 24657 | jjdelcerro | * @param name
|
182 | 24537 | jiyarza | * attribute's name
|
183 | * @param value
|
||
184 | * value to set
|
||
185 | 24657 | jjdelcerro | */
|
186 | 23754 | jjdelcerro | public void setGeometry(String name, Geometry value); |
187 | 24657 | jjdelcerro | |
188 | 24537 | jiyarza | /**
|
189 | * Sets the value of an attribute of type geometry, given its index
|
||
190 | 24657 | jjdelcerro | * @param index
|
191 | 24537 | jiyarza | * attribute's index
|
192 | * @param value
|
||
193 | * value to set
|
||
194 | 24657 | jjdelcerro | */
|
195 | 23754 | jjdelcerro | public void setGeometry(int index, Geometry value); |
196 | |||
197 | 24537 | jiyarza | /**
|
198 | * Sets the value of an attribute of type array, given its name
|
||
199 | 24657 | jjdelcerro | * @param name
|
200 | 24537 | jiyarza | * attribute's name
|
201 | * @param value
|
||
202 | * value to set
|
||
203 | 24657 | jjdelcerro | */
|
204 | 23754 | jjdelcerro | public void setArray(String name, Object[] value); |
205 | 24657 | jjdelcerro | |
206 | 24537 | jiyarza | /**
|
207 | * Sets the value of an attribute of type array, given its index
|
||
208 | 24657 | jjdelcerro | * @param index
|
209 | 24537 | jiyarza | * attribute's index
|
210 | * @param value
|
||
211 | * value to set
|
||
212 | 24657 | jjdelcerro | */
|
213 | 23754 | jjdelcerro | public void setArray(int index, Object[] value); |
214 | 23772 | jjdelcerro | |
215 | 24537 | jiyarza | /**
|
216 | * Sets the value of an attribute of type feature, given its name
|
||
217 | 24657 | jjdelcerro | * @param name
|
218 | 24537 | jiyarza | * attribute's name
|
219 | * @param value
|
||
220 | * value to set
|
||
221 | 24657 | jjdelcerro | */
|
222 | 23754 | jjdelcerro | public void setFeature(String name, Feature value); |
223 | 24657 | jjdelcerro | |
224 | 24537 | jiyarza | /**
|
225 | * Sets the value of an attribute of type feature, given its index
|
||
226 | 24657 | jjdelcerro | * @param index
|
227 | 24537 | jiyarza | * attribute's index
|
228 | * @param value
|
||
229 | * value to set
|
||
230 | 24657 | jjdelcerro | */
|
231 | 23754 | jjdelcerro | public void setFeature(int index, Feature value); |
232 | 23772 | jjdelcerro | |
233 | 24537 | jiyarza | /**
|
234 | * Returns the Feature from which this EditableFeature was created
|
||
235 | 24657 | jjdelcerro | *
|
236 | 24537 | jiyarza | * @return Feature from which this EditableFeature was created
|
237 | */
|
||
238 | 24657 | jjdelcerro | public Feature getSource();
|
239 | 23772 | jjdelcerro | |
240 | 24537 | jiyarza | /**
|
241 | * Returns a non editable copy of the Feature.
|
||
242 | 24657 | jjdelcerro | *
|
243 | 24537 | jiyarza | * @return non editable copy of the Feature.
|
244 | */
|
||
245 | 23754 | jjdelcerro | public Feature getNotEditableCopy();
|
246 | |||
247 | 24537 | jiyarza | /**
|
248 | * Sets de value of the default geometry attribute.
|
||
249 | 24657 | jjdelcerro | *
|
250 | 24537 | jiyarza | * @param value geometry to set.
|
251 | */
|
||
252 | 23772 | jjdelcerro | public void setDefaultGeometry(Geometry value); |
253 | 25407 | jiyarza | |
254 | /**
|
||
255 | * Copies the values of all attributes from the source feature to this feature
|
||
256 | *
|
||
257 | * @param source
|
||
258 | * source feature from which the values will be copied.
|
||
259 | */
|
||
260 | public void copyFrom(Feature source); |
||
261 | 37297 | jpiera | |
262 | /**
|
||
263 | * Sets the value of an attribute of type instant, given its name
|
||
264 | * @param name
|
||
265 | * attribute's name
|
||
266 | * @param value
|
||
267 | * value to set
|
||
268 | */
|
||
269 | public void setInstant(String name, Instant value); |
||
270 | 23772 | jjdelcerro | |
271 | 37297 | jpiera | /**
|
272 | * Sets the value of an attribute of type instant, given its index
|
||
273 | * @param index
|
||
274 | * attribute's index
|
||
275 | * @param value
|
||
276 | * value to set
|
||
277 | */
|
||
278 | public void setInstant(int index, Instant value); |
||
279 | |||
280 | /**
|
||
281 | * Sets the value of an attribute of type interval, given its name
|
||
282 | * @param name
|
||
283 | * attribute's name
|
||
284 | * @param value
|
||
285 | * value to set
|
||
286 | */
|
||
287 | public void setInterval(String name, Interval value); |
||
288 | |||
289 | /**
|
||
290 | * Sets the value of an attribute of type interval, given its index
|
||
291 | * @param index
|
||
292 | * attribute's index
|
||
293 | * @param value
|
||
294 | * value to set
|
||
295 | */
|
||
296 | public void setInterval(int index, Interval value); |
||
297 | 23754 | jjdelcerro | } |