code: public void write(Collection<? extends E> elements) throws IOException {
  		final Progression progressBar = getTaskProgression();
  		Progression subTask = null;
  
  		if (progressBar != null) {
  			progressBar.setProperties(0, 0, (elements.size() + 1) * 100, false);
  		}
  
  		if (this.fileBounds == null) {
  			this.fileBounds = getFileBounds();
  		}
  
  		if (this.fileBounds != null) {
  			writeHeader(this.fileBounds, this.elementType, elements);
  
  			if (progressBar != null) {
  				progressBar.setValue(100);
  				subTask = progressBar.subTask(elements.size() * 100);
  				subTask.setProperties(0, 0, elements.size(), false);
  			}
  
  			for (final E element : elements) {
  
  				writeElement(this.recordIndex, element, this.elementType);
  
  				if (subTask != null) {
  					subTask.setValue(this.recordIndex + 1);
  				}
  
  				++this.recordIndex;
  
  			}
  		} else {
  			throw new BoundsNotFoundException();
  		}
  
  		if (progressBar != null) {
  			progressBar.end();
  		}
  	}
docs: Write the Shape file and its associated files.
  
  @param elements are the elements to write down
  @throws IOException in case of error.