Re: [Geotools-devel] ContentFeatureStore for CSV tututorial

2011-05-15 Thread lee-verizon
Right - changes to ContentFeatureStore, see GEOT-3586 just submitted with patch. When that's fixed, I'll commit the CSV changes. Thanks, Lee On 5/15/2011 4:10 PM, Jody Garnett wrote: If it is a change to one of the core classes we need to make a Jira + patch. If it is just a change to CSVFea

Re: [Geotools-devel] ContentFeatureStore for CSV tututorial

2011-05-15 Thread Jody Garnett
If it is a change to one of the core classes we need to make a Jira + patch. If it is just a change to CSVFeatureWriter then you can commit directly? -- Jody Garnett On Monday, 16 May 2011 at 8:45 AM, lee-verizon wrote: > The javadoc in FeatureWriter: > > * After aquiring a feature using nex

Re: [Geotools-devel] ContentFeatureStore for CSV tututorial

2011-05-15 Thread lee-verizon
The javadoc in FeatureWriter: * After aquiring a feature using next() you may call remove() or after * modification write(). If you do not call one of these two methods before * calling hasNext(), or next() for that matter, the feature will be left * unmodified. So yeah, I think we should

Re: [Geotools-devel] ContentFeatureStore for CSV tututorial

2011-05-13 Thread Jody Garnett
I think I agree with that; my understanding is it is either write() or remove()? But really we better check the javadocs - as I have known to be wrong :-) -- Jody Garnett On Saturday, 14 May 2011 at 12:19 AM, lee-verizon wrote: > Moving on to remove... I think there really is a bug in > Con

Re: [Geotools-devel] ContentFeatureStore for CSV tututorial

2011-05-13 Thread lee-verizon
Moving on to remove... I think there really is a bug in ContentFeatureStore>removeFeatures(). The main loop looks like this: while( writer.hasNext() ) { writer.next(); writer.remove(); writer.write(); } I think that last wr

Re: [Geotools-devel] ContentFeatureStore for CSV tututorial

2011-05-12 Thread lee-verizon
I thought of another way to do it that confines the fix to CSVFeatureWriter and does not involve any changes to FilteringFeatureWriter. Much cleaner, IMO. Still need to do remove and add... Lee On 5/12/2011 8:59 AM, lee-verizon wrote: > ok, I came up with something that seems to work - in > F

Re: [Geotools-devel] ContentFeatureStore for CSV tututorial

2011-05-12 Thread lee-verizon
ok, I came up with something that seems to work - in FilteringFeatureWriter>hasNext(), it is doing this: SimpleFeature peek; while (writer.hasNext()) { peek = writer.next(); if (filter.evaluate(peek)) { next = peek; ret

Re: [Geotools-devel] ContentFeatureStore for CSV tututorial

2011-05-11 Thread lee-verizon
On 5/11/2011 7:36 PM, Jody Garnett wrote: > > On Thursday, 12 May 2011 at 10:30 AM, [email protected] wrote: > >> Sorry, I forgot to mention that I already did put in the >> FilteringFeatureWriter and it works fine. Perhaps too fine. > ? so that part works ? Yes, worked first time. It deli

Re: [Geotools-devel] ContentFeatureStore for CSV tututorial

2011-05-11 Thread Jody Garnett
On Thursday, 12 May 2011 at 10:30 AM, [email protected] wrote: Sorry, I forgot to mention that I already did put in the FilteringFeatureWriter and it works fine. Perhaps too fine. > ? so that part works ? > Or maybe it just needs more work. I like the idea of chaining together > vario

Re: [Geotools-devel] ContentFeatureStore for CSV tututorial

2011-05-11 Thread [email protected]
Sorry, I forgot to mention that I already did put in the FilteringFeatureWriter and it works fine. Perhaps too fine. Or maybe it just needs more work. I like the idea of chaining together various wrapped writers, but I just don't see how the current set of them can work. Can we chat sometime o