Statistics
| Revision:

gvsig-raster / org.gvsig.raster.gdal / tags / pre-remove-jgdal / org.gvsig.raster.gdal / org.gvsig.raster.gdal.io / src / main / java / org / gvsig / jogr / OGRFeature.java @ 3497

History | View | Annotate | Download (10.3 KB)

1
/**********************************************************************
2
 * $Id: OGRFeature.java 7765 2006-10-03 07:05:18Z nacho $
3
 *
4
 * Name:     OGRFeature.java
5
 * Project:  JGDAL. Interface java to gdal (Frank Warmerdam).
6
 * Purpose:   
7
 * Author:   Nacho Brodin, brodin_ign@gva.es
8
 *
9
 **********************************************************************/
10
/*Copyright (C) 2004  Nacho Brodin <brodin_ign@gva.es>
11

12
 This program is free software; you can redistribute it and/or
13
 modify it under the terms of the GNU General Public License
14
 as published by the Free Software Foundation; either version 2
15
 of the License, or (at your option) any later version.
16

17
 This program is distributed in the hope that it will be useful,
18
 but WITHOUT ANY WARRANTY; without even the implied warranty of
19
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
20
 GNU General Public License for more details.
21

22
 You should have received a copy of the GNU General Public License
23
 along with this program; if not, write to the Free Software
24
 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
25
 */
26

    
27
package org.gvsig.jogr;
28

    
29
import org.gdal.ogr.Feature;
30

    
31

    
32
/** 
33
 * 
34
 * @author Nacho Brodin <brodin_ign@gva.es>.<BR> Equipo de desarrollo gvSIG.<BR> http://www.gvsig.gva.es
35
 * @version 0.0
36
 * @link http://www.gvsig.gva.es
37
 */
38

    
39
public class OGRFeature extends Feature{
40
        
41
//        private native void FreeOGRFeatureNat(long cPtr);
42
//        private native void dumpReadableNat(long cPtr, String file);
43
//        private native long getDefnRefNat(long cPtr);
44
//        private native int setGeometryDirectlyNat( long cPtr, OGRGeometry geom );//Excepciones
45
//        private native int setGeometryNat( long cPtr, OGRGeometry geom );//Excepciones
46
//        private native long getGeometryRefNat(long cPtr);
47
//        private native long stealGeometryNat(long cPtr);
48
//        private native long cloneFeatureNat(long cPtr);//*
49
//        private native int equalNat( long cPtr, OGRFeature poFeature );
50
//        private native long getFieldDefnRefNat(long cPtr, int iField );
51
//        private native int getFieldIndexNat( long cPtr, String  pszName);
52
//        private native int isFieldSetNat( long cPtr, int iField );
53
//        private native void unsetFieldNat( long cPtr, int iField );
54
//        private native long getRawFieldRefNat( long cPtr, int i );
55
//        private native int getFieldAsIntegerNat( long cPtr, int i );
56
//        private native double getFieldAsDoubleNat( long cPtr, int i );
57
//        private native String getFieldAsStringNat( long cPtr, int i );
58
//        private native int getFieldAsIntegerListNat( long cPtr, int i, int pnCount );
59
//        private native double  getFieldAsDoubleListNat( long cPtr, int i, int pnCount );
60
//        private native String[] getFieldAsStringListNat( long cPtr, int i );
61
//        private native int getFieldAsIntegerNat( long cPtr, String pszFName );
62
//        private native double getFieldAsDoubleNat( long cPtr, String pszFName );
63
//        private native String getFieldAsStringNat( long cPtr, String pszFName );
64
//        private native int getFieldAsIntegerListNat( long cPtr, String pszFName, int pnCount );
65
//        private native double getFieldAsDoubleListNat( long cPtr, String pszFName, int pnCount );
66
//        private native String[] getFieldAsStringListNat( long cPtr, String pszFName );
67
//        private native void setFieldNat( long cPtr, int i, int nValue );
68
//        private native void setFieldNat( long cPtr, int i, double dfValue );
69
//        private native void setFieldNat( long cPtr, int i, String pszValue );
70
//        private native void setFieldNat( long cPtr, int i, int nCount, int panValues );
71
//        private native void setFieldNat( long cPtr, int i, int nCount, double padfValues );
72
//        private native void setFieldNat( long cPtr, int i, String[] papszValues );
73
//        private native void setFieldNat( long cPtr, int i, OGRField puValue );
74
//        private native void setFieldNat( long cPtr, String pszFName, int nValue );
75
//        private native void setFieldNat( long cPtr, String pszFName, double dfValue );
76
//        private native void setFieldNat( long cPtr, String pszFName, String pszValue);
77
//        private native void setFieldNat( long cPtr, String pszFName, int nCount, int panValues );
78
//        private native void setFieldNat( long cPtr, String pszFName, int nCount, double padfValues );
79
//        private native void setFieldNat( long cPtr, String pszFName, String[] papszValues );                    
80
//        private native void setFieldNat( long cPtr, String pszFName, OGRField puValue );
81
//        private native long getFIDNat(long cPtr);
82
//        private native int setFIDNat( long cPtr, long nFID );//Excepciones
83
//        private native int setFromNat( long cPtr, OGRFeature feature, int b);//Excepciones
84
//        private native int remapFieldsNat( long cPtr, OGRFeatureDefn poNewDefn, int panRemapSource );//Excepciones
85
//        private native String getStyleStringNat(long cPtr);
86
//        private native void setStyleStringNat(long cPtr, String style);
87
//        private native void setStyleTableNat(long cPtr, OGRStyleTable poStyleTable);
88
//        private native static OGRFeature createFeatureNat( long cPtr, OGRFeatureDefn feature );
89
//        private native static void destroyFeatureNat( long cPtr, OGRFeature feature );
90
        
91
        static int h=0;
92
        
93
        /**
94
         * Constructor
95
         * @param cPtr        direcci?n de memoria al objeto OGRFeature de C. 
96
         */
97
        
98
        public OGRFeature(long cPtr){
99
                super(cPtr, true);
100
        }
101
        
102
        /**
103
         * 
104
         */
105
        
106
        public void dumpReadable(String file)throws OGRException{
107
                h++;
108
//                if(cPtr == 0)
109
//                        throw new OGRException("Error en dumpReadable(). El constructor ha fallado."+h);
110
                this.DumpReadable();
111
                
112
        }
113
        
114
        /**
115
         * Destructor 
116
         */
117
        
118
        protected void finalize() throws OGRFailureException{
119
//                if(cPtr == 0)
120
//                        throw new OGRFailureException("Fallo al acceder al dato.");
121
//                
122
//                FreeOGRFeatureNat(cPtr);
123
                this.delete();
124
        }
125
        
126
        
127
        /**
128
         * 
129
         */
130
        
131
        public OGRFeatureDefn getDefnRef()throws OGRException{
132
                return null;
133
        }
134
        
135
        /**
136
         * 
137
         */
138
        
139
        public void setGeometryDirectly( OGRGeometry geom )throws OGRException{//Excepciones
140
                
141
        }
142
        
143
        /**
144
         * 
145
         */
146
        
147
        public void setGeometry( OGRGeometry geom )throws OGRException{//Excepciones
148
                
149
        }
150
        
151
        /**
152
         * 
153
         */
154
        
155
        public OGRGeometry getGeometryRef()throws OGRException{
156
                return null;
157
        }
158
        
159
        /**
160
         * 
161
         */
162
        
163
        public OGRGeometry stealGeometry()throws OGRException{
164
                return null;
165
        }
166
        
167
        /**
168
         * 
169
         */
170
        
171
        public OGRFeature cloneFeature()throws OGRException{
172
                return null;
173
        }
174
        
175
        /**
176
         * 
177
         */
178
        
179
        public int equal( OGRFeature poFeature )throws OGRException{
180
                return 0;
181
        }
182
        
183
        /**
184
         * 
185
         */
186
        
187
        public int getFieldCount()throws OGRException{
188
                return 0;
189
        }
190
        
191
        /**
192
         * 
193
         */
194
        
195
        public OGRFieldDefn getFieldDefnRef( int iField )throws OGRException{
196
                return null;
197
        }
198
        
199
        /**
200
         * 
201
         */
202
        
203
        public int getFieldIndex( String  pszName)throws OGRException{
204
                return 0;
205
        }
206
        
207
        /**
208
         * 
209
         */
210
        
211
        public int isFieldSet( int iField )throws OGRException{
212
                return 0;
213
        }
214
        
215
        /**
216
         * 
217
         */
218
        
219
        public void unsetField( int iField )throws OGRException{
220
                
221
        }
222
        
223
        /**
224
         * 
225
         */
226
        
227
        public OGRField getRawFieldRef( int i )throws OGRException{
228
                return null;
229
        }
230
        
231
        /**
232
         * 
233
         */
234
        
235
        public int getFieldAsInteger( int i )throws OGRException{
236
                return 0;
237
        }
238
        
239
        /**
240
         * 
241
         */
242
        
243
        public double getFieldAsDouble( int i )throws OGRException{
244
                return 0;
245
        }
246
        
247
        /**
248
         * 
249
         */
250
        
251
        public String getFieldAsString( int i )throws OGRException{
252
                return null;
253
        }
254
        
255
        /**
256
         * 
257
         */
258
        
259
        public int getFieldAsIntegerList( int i, int pnCount )throws OGRException{
260
                return 0;
261
        }
262
        
263
        /**
264
         * 
265
         */
266
        
267
        public double  getFieldAsDoubleList( int i, int pnCount )throws OGRException{
268
                return 0;
269
        }
270
        
271
        /**
272
         * 
273
         */
274
        
275
        public String[] getFieldAsStringList( int i )throws OGRException{
276
                return null;
277
        }
278
        
279
        /**
280
         * 
281
         */
282
        
283
        public int getFieldAsInteger( String pszFName )throws OGRException{
284
                return 0;
285
        }
286
        
287
        /**
288
         * 
289
         */
290
        
291
        public double getFieldAsDouble( String pszFName )throws OGRException{
292
                return 0;
293
        }
294
        
295
        /**
296
         * 
297
         */
298
        
299
        public String getFieldAsString( String pszFName )throws OGRException{
300
                return null;
301
        }
302
        
303
        /**
304
         * 
305
         */
306
        
307
        public int getFieldAsIntegerList( String pszFName, int pnCount )throws OGRException{
308
                return 0;
309
        }
310
        
311
        /**
312
         * 
313
         */
314
        
315
        public double getFieldAsDoubleList( String pszFName, int pnCount )throws OGRException{
316
                return 0;
317
        }
318
        
319
        /**
320
         * 
321
         */
322
        
323
        public String[] getFieldAsStringList( String pszFName )throws OGRException{
324
                return null;
325
        }
326
        
327
        /**
328
         * 
329
         */
330
        
331
        public void setField( int i, int nValue )throws OGRException{
332
                
333
        }
334
        
335
        /**
336
         * 
337
         */
338
        
339
        public void setField( int i, double dfValue )throws OGRException{
340
                
341
        }
342
        
343
        /**
344
         * 
345
         */
346
        
347
        public void setField( int i, String pszValue )throws OGRException{
348
                
349
        }
350
        
351
        /**
352
         * 
353
         */
354
        
355
        public void setField( int i, int nCount, int panValues )throws OGRException{
356
                
357
        }
358
        
359
        /**
360
         * 
361
         */
362
        
363
        public void setField( int i, int nCount, double padfValues )throws OGRException{
364
                
365
        }
366
        
367
        /**
368
         * 
369
         */
370
        
371
        public void setField( int i, String[] papszValues )throws OGRException{
372
                
373
        }
374
        
375
        /**
376
         * 
377
         */
378
        
379
        public void setField( int i, OGRField puValue )throws OGRException{
380
                
381
        }
382
        
383
        /**
384
         * 
385
         */
386
        
387
        public void setField( String pszFName, int nValue )throws OGRException{
388
                
389
        }
390
        
391
        /**
392
         * 
393
         */
394
        
395
        public void setField( String pszFName, double dfValue )throws OGRException{
396
                
397
        }
398
        
399
        /**
400
         * 
401
         */
402
        
403
        public void setField( String pszFName, String pszValue)throws OGRException{
404
                
405
        }
406
        
407
        /**
408
         * 
409
         */
410
        
411
        public void setField( String pszFName, int nCount, int panValues )throws OGRException{
412
                
413
        }
414
        
415
        /**
416
         * 
417
         */
418
        
419
        public void setField( String pszFName, int nCount, double padfValues )throws OGRException{
420
                
421
        }
422
        
423
        /**
424
         * 
425
         */
426
        
427
        public void setField( String pszFName, String[] papszValues )throws OGRException{
428
                
429
        }
430
        
431
        /**
432
         * 
433
         */
434
        
435
        public void setField( String pszFName, OGRField puValue )throws OGRException{
436
                
437
        }
438
        
439
        /**
440
         * 
441
         */
442
        
443
        public long getFID()throws OGRException{
444
                return 0;
445
        }
446
        
447
        /**
448
         * 
449
         */
450
        
451
        public void setFID( long nFID )throws OGRException{//Excepciones
452
                
453
        }
454
        
455
        /**
456
         * 
457
         */
458
        
459
        public void setFrom( OGRFeature feature, int b)throws OGRException{//Excepciones
460
                
461
        }
462
        
463
        /**
464
         * 
465
         */
466
        
467
        public void remapFields( OGRFeatureDefn poNewDefn, int panRemapSource )throws OGRException{//Excepciones
468
                
469
        }
470
        
471
        /**
472
         * 
473
         */
474
        
475
        public String getStyleString()throws OGRException{
476
                return null;
477
        }
478
        
479
        /**
480
         * 
481
         */
482
        
483
        public void setStyleString(String style)throws OGRException{
484
                
485
        }
486
        
487
        /**
488
         * 
489
         */
490
        
491
        public void setStyleTable(OGRStyleTable poStyleTable)throws OGRException{
492
                
493
        }
494
        
495
        /**
496
         * 
497
         */
498
        
499
        public static OGRFeature  createFeature( OGRFeatureDefn feature )throws OGRException{
500
                return null;
501
        }
502
        
503
        /**
504
         * 
505
         */
506
        
507
        public static void destroyFeature( OGRFeature feature )throws OGRException{
508
                
509
        }
510
        
511
        
512
}