Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [udig-devel] filtering contents of rendered layers

Hmmm. I think you found a little bug with my logic. I need the datastore in order to create the view and I do that through the service. I could change it to access the datastore using the FeatureSource instead... That would be a good idea.

But unless you want to make that change you might consider changing your service to return a Datastore... Unless you can't for some reason, in which case you'll want to use create a custom style for this functionality.

Jesse


On Oct 30, 2007, at 1:58 PM, Vince Darley wrote:

At 20:49 30/10/2007, Vince Darley wrote:
At 20:08 30/10/2007, Jesse Eichar wrote:
Put a break point in ShowViewInterceptor and verify that the filter
is being picked up correctly.

Hmm, no it's not. The 'properties' member of LayerImpl is empty. Why would that be?

Sorry to correct myself, but sometimes it does seem to be picked up correctly. Not sure of the difference, but it does seem to be there just before rendering. But, what seems to happen then:

                    IService service = (IService) parent;
DataStore ds=service.resolve(DataStore.class, ProgressManager.instance().get());
                    if( ds==null )
                        return resource;
                    FeatureSource view;
                    if( prop instanceof Filter )
...

is that 'ds' is null, since our service is just following the documentation of IService.resolve() which doesn't mention any need to support returning a DataStore.

Is that going to be the issue? (since the code immediately after the 'return' above is where the Filter seems to be applied to get a view).

Vince.
_______________________________________________
User-friendly Desktop Internet GIS (uDig)
http://udig.refractions.net
http://lists.refractions.net/mailman/listinfo/udig-devel



Back to the top