I know that Andrea's example allocates colors by itself. About the original example, I thought that attributeName was the name of the color attribute!!! :PPP My code uses the "color" attribute of the features, they are extracted by the DXF plug-in.
I studied Java at university 5 years ago... for that it is not too hard. I prefer C++, but Java is really funny. I like its don't-you-worry philosophy. :D I think that the Java approach is smart , the massive use of design patterns makes it really effective. I don't like the abnormal resource wasting... Valerio Il 05/08/2011 01:40, Michael Bedward ha scritto: > Hi Valerio, > >> After some try, I fixed your example making the following replacement: >> >> // OLD: >> >> ColorLookupFunction colourFn = new >> ColorLookupFunction(featureSource.getFeatures(), >> filterFactory.property(attributeName)); >> >> // NEW: >> >> ExpressioncolourFn = filterFactory.property(attributeName); > So it looks like you have the colours as an attribute in your feature > data - is that correct ? In that case it will be fine but the > intention of the original example, and Andrea's example, is to > allocate colours based on non-colour attributes (e.g. general numeric > data). > > If you are only just getting familiar with Java as well as GeoTools > you are doing very well ! > > Michael -- Valerio Di Gregorio Automotive and Telecommunication Division Information Engineer INTECS Informatica e Tecnologia del Software S.p.A. Via Egidio Giannessi, 5 56121 - Ospedaletto, Pisa Italy Voice: +39 050 9657 411 (operator) Voice: +39 050 9657 455 (direct) Fax: +39 050 9657 400 Skype: valeriodigregorio.intecs.it Email: [email protected] Web: http://www.intecs.it LEGAL DISCLAIMER: The contents of this email and any transmitted files are confidential and intended solely for the use of the individual or entity to whom they are addressed. We hereby exclude any warranty and any liability as to the quality or accuracy of the contents of this email and any attached transmitted files. If you are not the intended recipient, be advised that you have received this email in error and that any use, dissemination, forwarding, printing or copying of this email is strictly prohibited. If you have received this email in error please contact the sender and delete the material from any computer. ------------------------------------------------------------------------------ BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA The must-attend event for mobile developers. Connect with experts. Get tools for creating Super Apps. See the latest technologies. Sessions, hands-on labs, demos & much more. Register early & save! http://p.sf.net/sfu/rim-blackberry-1 _______________________________________________ Geotools-gt2-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users
