All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.fudaa.dodico.rubar.io.RubarSEMWriterGISAdapter Maven / Gradle / Ivy

There is a newer version: 2.7
Show newest version
/*
 * @creation     2 juil. 2008
 * @modification $Date:$
 * @license      GNU General Public License 2
 * @copyright    (c)1998-2008 CETMEF 2 bd Gambetta F-60231 Compiegne
 * @mail         [email protected]
 */
package org.fudaa.dodico.rubar.io;

import org.fudaa.ctulu.CtuluNumberFormatFortran;
import org.fudaa.ctulu.CtuluNumberFormatI;
import org.fudaa.ctulu.collection.CDoubleArrayList;
import org.fudaa.ctulu.collection.CollectionPointDataDoubleInterface;
import org.fudaa.ctulu.collection.CtuluCollectionDouble;
import org.fudaa.ctulu.gis.GISDataModel;
import org.fudaa.ctulu.gis.GISMultiPoint;
import org.fudaa.dodico.fortran.FortranDoubleReaderResultInterface;

import com.vividsolutions.jts.geom.CoordinateSequence;

/**
 * Un adapteur pour ecrire sur un fichier Rubar SEM a partir d'un modele de multipoints.
 * @author Bertrand Marchand
 * @version $Id:$
 */
public class RubarSEMWriterGISAdapter implements FortranDoubleReaderResultInterface {
  CDoubleArrayList[] values_=new CDoubleArrayList[3];
  CtuluNumberFormatFortran doubleFormater_ = new CtuluNumberFormatFortran(13,4);

  /**
   * Le mod?le ne doit contenir que des multipoints. Le reste n'est pas trait?.
   * @param _mdl
   */
  public RubarSEMWriterGISAdapter(GISDataModel _mdl) {
    initVals(_mdl);
  }
  
  private void initVals(GISDataModel _mdl) {
    int nblines=0;
    int nb=_mdl.getNumGeometries();
    for (int i=0; i




© 2015 - 2024 Weber Informatics LLC | Privacy Policy