Revision 970 trunk/libraries/libjni-gdal/src/es/gva/cit/jogr/OGRFeatureDefn.java
OGRFeatureDefn.java | ||
---|---|---|
40 | 40 |
private native String getNameNat(long cPtr); |
41 | 41 |
private native int getGeomTypeNat(long cPtr); |
42 | 42 |
private native void FreeOGRFeatureDefnNat(long cPtr); |
43 |
private native long getFieldDefnNat(long cPtr, int i); |
|
43 | 44 |
|
44 | 45 |
/** |
45 | 46 |
* Constructor |
... | ... | |
127 | 128 |
* @return Objeto que contiene el campo seleccionado |
128 | 129 |
*/ |
129 | 130 |
|
130 |
/*public OGRFieldDefn getFieldDefn(int i)throws OGRException{
|
|
131 |
public OGRFieldDefn getFieldDefn(int i)throws OGRException{ |
|
131 | 132 |
|
133 |
if(cPtr <= 0) |
|
134 |
throw new OGRException("Error en getFieldDefn(). El constructor ha fallado."); |
|
132 | 135 |
|
133 |
}*/ |
|
136 |
long id = getFieldDefnNat(cPtr,i); |
|
137 |
if(id<=0) |
|
138 |
throw new OGRException("Error en getGeomType(). No se ha podido obtener un tipo de geometria valido."); |
|
139 |
|
|
140 |
OGRFieldDefn field = new OGRFieldDefn(id); |
|
141 |
return field; |
|
142 |
} |
|
134 | 143 |
|
135 | 144 |
/** |
136 | 145 |
* Destructor |
Also available in: Unified diff