Revision 20626 trunk/libraries/libFMap_dataFile/src/org/gvsig/data/datastores/vectorial/file/shp/SHPStore.java

View differences:

SHPStore.java
231 231
		return DATASTORE_NAME;
232 232
	}
233 233

  
234
	public void open() throws OpenException {
235
		this.observable.notifyObservers(this,
236
				new FeatureStoreNotification(this,FeatureStoreNotification.BEFORE_OPEN)
237
		);
238
		super.open();
234
	protected void doOpen() throws OpenException {
235
		super.doOpen();
239 236
//		 create a new header.
240 237
		ShapeFileHeader2 myHeader = new ShapeFileHeader2();
241 238

  
......
278 275
////			throw new FileNotFoundDriverException(getName(),e,strFichDbf);
279 276
//		}
280 277
//		numReg = m_FichDbf.getRecordCount();
281
		this.observable.notifyObservers(this,
282
				new FeatureStoreNotification(this,FeatureStoreNotification.AFTER_OPEN)
283
		);
284 278

  
285 279
	}
286 280

  
287
	public void close() throws CloseException {
288
		this.observable.notifyObservers(this,
289
                new FeatureStoreNotification(this,FeatureStoreNotification.BEFORE_CLOSE)
290
            );
291
		super.close();
281
	protected void doClose() throws CloseException {
282
		super.doClose();
292 283
		CloseException ret = null;
293 284

  
294 285
		try {
......
299 290
		} finally {
300 291
			try {
301 292
				fin.close();
293
				finShx.close();
302 294
			} catch (IOException e1) {
303 295
				ret = new CloseException(getName(),e1);
304 296
			}
......
309 301
//		}
310 302
		bb = null;
311 303
		bbShx = null;
312
        this.observable.notifyObservers(this,
313
                new FeatureStoreNotification(this,FeatureStoreNotification.AFTER_CLOSE)
314
            );
315 304

  
316 305
	}
317 306

  
318
	public void dispose() {
319
		this.observable.notifyObservers(this,
320
                new FeatureStoreNotification(this,FeatureStoreNotification.BEFORE_DISPOSE)
321
            );
322
		super.dispose();
323
        this.observable.notifyObservers(this,
324
                new FeatureStoreNotification(this,FeatureStoreNotification.AFTER_DISPOSE)
325
            );
307
	protected void doDispose() throws CloseException {
308
		super.doDispose();
326 309
	}
327 310

  
328 311
	public boolean isEditable() {
......
369 352
//		writer.init(this);
370 353
		return writer;
371 354
	}
372
	protected long getFeatureCount(){
355
	protected long getFeatureCount() throws ReadException{
373 356
		return dbf.getRecordCount();
374 357
	}
375 358

  

Also available in: Unified diff