/* * GeoTools - The Open Source Java GIS Toolkit * http://geotools.org * * (C) 2004-2008, Open Source Geospatial Foundation (OSGeo) * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; * version 2.1 of the License. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. */ package org.geotools.data.store; import java.io.IOException; import java.util.Iterator; import java.util.NoSuchElementException; import org.geotools.data.FeatureWriter; import org.opengis.feature.simple.SimpleFeature; import org.opengis.feature.simple.SimpleFeatureType; /** * An iterator wrapper for a FeatureWriter - for use with * an AbstractFeatureCollection. *
* There is no reason modify this class, subclasses that wish * to work with a custom iterator need just that - a custom iterator. *
*
* The use of this class against a SimpleFeatureSource not backed by * a Transaction may *really* cut into performance. Consider if * you will the overhead involved in writing out each feature into * a temporary file (when the user may not even modify anything). *
* @author jgarnett * @since 2.1.RC0 * @source $URL$ */ final class FeatureWriterIterator implements Iterator