Thanks Jesse. Unfortunately selecting it didn't make a difference.  
I assume that you mean selecting it in the Layers view? Manually re- 
rendering the map doesn't work either.
I did find this in the console output every time I apply the filter:
26/04/2006 09:52:52 org.geotools.xml.XMLSAXHandler endElement
WARNING: java.lang.NullPointerException
26/04/2006 09:52:52 org.geotools.xml.XMLSAXHandler endElement
WARNING: Line 9 Col 23
26/04/2006 09:52:52 org.geotools.xml.XMLSAXHandler endElement
WARNING: java.lang.NullPointerException
26/04/2006 09:52:52 org.geotools.xml.XMLSAXHandler endElement
WARNING: Line 9 Col 23
Any idea where I can debug this? The layer is a WFS layer. Hang on  
a sec... that is actually a service exception being thrown from  
GeoServer as a result of this request:
3698536497 [FINE]  
org.vfny.geoserver.util.requests.readers.KvpRequestReader - clean  
request is  
SERVICE=WFS&VERSION=1.0.0&REQUEST=GetFeature&FILTER=<Filter  
xmlns="http://www.opengis.net/ogc" xmlns:gml="http:// 
www.opengis.net/ 
gml"><And><PropertyIsEqualTo><PropertyName>roadeventid</PropertyName>
<Literal>1</Literal>
</PropertyIsEqualTo>
<And><BBOX><PropertyName>the_geom</PropertyName>
<gml:Box><gml:coordinates decimal="." cs="," ts="  
">171.84467232281352,-42.68326658192282  
174.92959292258212,-40.78287574213683</gml:coordinates>
</gml:Box>
</BBOX>
<Or><Or><Or><Or><Or><Or><PropertyIsEqualTo><Function  
name="geometryType"><PropertyName>the_geom</PropertyName>
</Function>
<Literal>Point</Literal>
</PropertyIsEqualTo>
<PropertyIsEqualTo><Function  
name="geometryType"><PropertyName>the_geom</PropertyName>
</Function>
<Literal>MultiPoint</Literal>
</PropertyIsEqualTo>
</Or>
<PropertyIsEqualTo><Function  
name="geometryType"><PropertyName>the_geom</PropertyName>
</Function>
<Literal>LineString</Literal>
</PropertyIsEqualTo>
</Or>
<PropertyIsEqualTo><Function  
name="geometryType"><PropertyName>the_geom</PropertyName>
</Function>
<Literal>LinearRing</Literal>
</PropertyIsEqualTo>
</Or>
<PropertyIsEqualTo><Function  
name="geometryType"><PropertyName>the_geom</PropertyName>
</Function>
<Literal>MultiLineString</Literal>
</PropertyIsEqualTo>
</Or>
<PropertyIsEqualTo><Function  
name="geometryType"><PropertyName>the_geom</PropertyName>
</Function>
<Literal>Polygon</Literal>
</PropertyIsEqualTo>
</Or>
<PropertyIsEqualTo><Function  
name="geometryType"><PropertyName>the_geom</PropertyName>
</Function>
<Literal>MultiPolygon</Literal>
</PropertyIsEqualTo>
</Or>
</And>
</And>
</Filter>
&TYPENAME=topp:roadevent_pnt
Which causes:
3698536516 [INFO] org.vfny.geoserver.servlets.AbstractService - Had  
an undefined error: null
3698536516 [FINE] org.vfny.geoserver.ServiceException -  
java.lang.NullPointerException
3698536517 [WARNING] org.vfny.geoserver.ServiceException -  
encountered error: java.lang.NullPointerException
StackTrace: java.lang.NullPointerException
3698536518 [FINE] org.vfny.geoserver.ServiceException - return wfs  
exception is <?xml version="1.0" ?>
<ServiceExceptionReport
  version="1.2.0"
  xmlns="http://www.opengis.net/ogc"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://www.opengis.net/ogc https:// 
0800.transit.govt.nz:8443/geoserver/schemas//wfs/1.0.0/OGC- 
exception.xsd">
  <ServiceException>
     java.lang.NullPointerException
  </ServiceException>
</ServiceExceptionReport>
There is no stack trace of where the error occurred.
Why is a request being sent back to GeoServer just to highlight a  
feature on the map? Has this always been the way? And if so, what  
changed? It's the same version of GeoServer (1.3.0) that we've been  
using for a while.
Thanks,
Mark
Jesse Eichar wrote:
Is they layer you are selecting on the selected layer?  If it is  
not  it may not be shown.  This might also be a bug.  Could you  
make sure  that the layer is the selected layer and if it is not  
highlight then  add a bug report.
Does the highlight appear if you manually re-render the map?
Jesse
On 25-Apr-06, at 2:32 AM, Mark Presling wrote:
Hi all,
Something else has changed since my last source update to  
revision  19235 (20/04/06). I used to use LayerImpl.setFilter()  
to highlight  a feature on the map using a FID filter. Now this  
doesn't seem to  work correctly. It just doesn't do anything at  
all and I can't seem  to track down why.
Has anyone changed something to do with the selection stuff?  
Should  I be doing this a new way?
FYI, here is the code I am using to do this:
       IMap map = ApplicationGIS.getActiveMap();
       LayerImpl eventLayer = (LayerImpl) getLayerByName  
(LAYER_ROADEVENT, map); //My own method
              FilterFactory filterFactory = new FilterFactoryImpl();
       CompareFilter filter = null;
       try {
           FeatureSource featureSource = (FeatureSource)   
eventLayer.getResource(
                   FeatureSource.class, null);
           filter = filterFactory.createCompareFilter  
(CompareFilter.COMPARE_EQUALS);
           FeatureType featureType = featureSource.getFeatures  
().getSchema();
           filter.addLeftValue  
(filterFactory.createAttributeExpression(featureType,  
"roadeventid"));
           filter.addRightValue  
(filterFactory.createLiteralExpression(id));
           eventLayer.setFilter(filter);
       } catch (Exception e) {
           e.printStackTrace();
       }
Thanks,
Mark
--
This message has been scanned for viruses and dangerous
content by MailScanner, and is believed to be clean.
<mark.vcf>
_______________________________________________
User-friendly Desktop Internet GIS (uDig)
http://udig.refractions.net
http://lists.refractions.net/mailman/listinfo/udig-devel
_______________________________________________
User-friendly Desktop Internet GIS (uDig)
http://udig.refractions.net
http://lists.refractions.net/mailman/listinfo/udig-devel
--
This message has been scanned for viruses and dangerous
content by MailScanner, and is believed to be clean.
<mark.vcf>
_______________________________________________
User-friendly Desktop Internet GIS (uDig)
http://udig.refractions.net
http://lists.refractions.net/mailman/listinfo/udig-devel