Revision 24791 branches/v2_0_0_prep/libraries/libFMap_dalfile/src/org/gvsig/fmap/dal/store/shp/utils/SHPFile.java
SHPFile.java | ||
---|---|---|
118 | 118 |
|
119 | 119 |
public void open() throws DataException { |
120 | 120 |
try { |
121 |
fin = new FileInputStream(this.params.getSHPFileObject());
|
|
121 |
fin = new FileInputStream(this.params.getSHPFile()); |
|
122 | 122 |
} catch (java.io.FileNotFoundException e) { |
123 |
throw new FileNotFoundException(this.params.getSHPFile()); |
|
123 |
throw new FileNotFoundException(this.params.getSHPFileName());
|
|
124 | 124 |
} |
125 | 125 |
|
126 | 126 |
|
... | ... | |
134 | 134 |
try { |
135 | 135 |
bb = new BigByteBuffer2(channel, FileChannel.MapMode.READ_ONLY); |
136 | 136 |
} catch (IOException e) { |
137 |
throw new ReadException(this.params.getSHPFile(), e); |
|
137 |
throw new ReadException(this.params.getSHPFileName(), e);
|
|
138 | 138 |
|
139 | 139 |
} |
140 | 140 |
try { |
141 |
finShx = new FileInputStream(this.params.getSHXFileObject());
|
|
141 |
finShx = new FileInputStream(this.params.getSHXFile()); |
|
142 | 142 |
} catch (java.io.FileNotFoundException e) { |
143 |
throw new FileNotFoundException(this.params.getSHXFile()); |
|
143 |
throw new FileNotFoundException(this.params.getSHXFileName());
|
|
144 | 144 |
} |
145 | 145 |
|
146 | 146 |
|
... | ... | |
156 | 156 |
bbShx = new BigByteBuffer2(channelShx, |
157 | 157 |
FileChannel.MapMode.READ_ONLY); |
158 | 158 |
} catch (IOException e) { |
159 |
throw new ReadException(this.params.getSHXFile(), e); |
|
159 |
throw new ReadException(this.params.getSHXFileName(), e);
|
|
160 | 160 |
|
161 | 161 |
} |
162 | 162 |
bbShx.order(ByteOrder.BIG_ENDIAN); |
... | ... | |
202 | 202 |
} |
203 | 203 |
|
204 | 204 |
//TODO: SRS |
205 |
File prjFile = SHP.getPrjFile(this.params.getSHPFileObject());
|
|
205 |
File prjFile = SHP.getPrjFile(this.params.getSHPFile()); |
|
206 | 206 |
if (prjFile.exists()) { |
207 | 207 |
BufferedReader input=null; |
208 | 208 |
try { |
... | ... | |
235 | 235 |
} |
236 | 236 |
|
237 | 237 |
public boolean isEditable(){ |
238 |
return this.params.getSHPFileObject().canWrite()
|
|
239 |
&& this.params.getSHXFileObject().canWrite();
|
|
238 |
return this.params.getSHPFile().canWrite() |
|
239 |
&& this.params.getSHXFile().canWrite(); |
|
240 | 240 |
} |
241 | 241 |
|
242 | 242 |
public int getGeometryType() throws ReadException { |
Also available in: Unified diff