[Geoserver-devel] Should I change the source code of Geoserver or Geotool?

I need to change the Geoserver source code to offset GIS data. The offset function should between getting data from source (database or others) and publishing maps.
The reason that I cannot use SLD is that my boss does not want to use it. He gave me a jar file which can create random data for offseting data. I should use this jar file to get random data and offset correct GIS data.

My question is as follows:

1, should I change the Geotool’s source or Geoserver code?

2010/11/1 lv <lv.123@anonymised.com>:

I need to change the Geoserver source code to offset GIS data. The offset
function should between getting data from source (database or others) and
publishing maps.
The reason that I cannot use SLD is that my boss does not want to use it. He
gave me a jar file which can create random data for offseting data. I should
use this jar file to get random data and offset correct GIS data.

My question is as follows:

1, should I change the Geotool's source or Geoserver code?

You can create a filter function that applies the transformation you need
straight from your jar.
Look at a similar filter function in geotools and create your own, e.g.
FilterFunction_buffer (from the geotools main module)
and make sure you register it in the spi file of your custom jar:
src/main/resources/META-INF/services/org.opengis.filter.expression.Function

and then use the function you created in the sld to transform on the fly
your geometry.

If that does not suit you you'll have to hack directly the StreamingRenderer
or the ShapefileRenderer... which is going to be painful... or hack at
the data source level, where the data is read.

Cheers
Andrea

-----------------------------------------------------
Ing. Andrea Aime
Senior Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy

phone: +39 0584962313
fax: +39 0584962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

-----------------------------------------------------