Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[udig-devel] Layer with NullGeoResource

Hello,

I'm trying to programatically add a layer (from an Oracle DB). Though the code works in most circumstances, sometimes I see my layer with an OracleGeoResource (just before it gets added in AddLayersCommand.run(IProgressMonitor) ), have its georesource turned into a NullGeoResource(http://NULL).

The layer comes from an oracle view that gets created dynamically. The point is, when I run the code again, the layer gets added.

Am I missing something, like telling the Catalog to synchronize?

This is a tough one. I've tracked the problem down to LayerFactoryImpl.createLayer(IGeoResource) but I'd like to make sure I'm not missing anything before I dig further.

BTW, in LayerFactoryImpl.createLayer(IGeoResource), the line

layer.setGeoResource(preferredResource);

might yield

LayerImp.geoResource = null;

Does anyone want to have that? (Perhaps that's the reason for my problem?)

Thanks in advance,

Ugo

--
Ugo Taddei

Fraunhofer Institut Intelligente Analyse- und Informationssysteme (FhG IAIS)
http://www.iais.fraunhofer.de
Department Knowledge Discovery - IAIS.KD -
Working Group Spatial Decision Support
http://www.iais.fraunhofer.de/kd.html
phone  (+49)2241-14-2184    fax    (+49)2241-14-2072
Schloss Birlinghoven, D-53754 Sankt Augustin, Germany


Back to the top