Quantum GIS API Documentation  1.8
src/analysis/interpolation/qgsgridfilewriter.h
Go to the documentation of this file.
00001 /***************************************************************************
00002                               qgsgridfilewriter.h
00003                               --------------------
00004   begin                : March 10, 2008
00005   copyright            : (C) 2008 by Marco Hugentobler
00006   email                : marco dot hugentobler at karto dot baug dot ethz dot ch
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; either version 2 of the License, or     *
00014  *   (at your option) any later version.                                   *
00015  *                                                                         *
00016  ***************************************************************************/
00017 
00018 #ifndef QGSGRIDFILEWRITER_H
00019 #define QGSGRIDFILEWRITER_H
00020 
00021 #include "qgsrectangle.h"
00022 #include <QString>
00023 #include <QTextStream>
00024 
00025 class QgsInterpolator;
00026 
00028 //todo: extend such that writing to other file types is possible
00029 class ANALYSIS_EXPORT QgsGridFileWriter
00030 {
00031   public:
00032     QgsGridFileWriter( QgsInterpolator* i, QString outputPath, QgsRectangle extent, int nCols, int nRows, double cellSizeX, double cellSizeY );
00033     ~QgsGridFileWriter();
00034 
00039     int writeFile( bool showProgressDialog = false );
00040 
00041   private:
00042 
00043     QgsGridFileWriter(); //forbidden
00044     int writeHeader( QTextStream& outStream );
00045 
00046     QgsInterpolator* mInterpolator;
00047     QString mOutputFilePath;
00048     QgsRectangle mInterpolationExtent;
00049     int mNumColumns;
00050     int mNumRows;
00051 
00052     double mCellSizeX;
00053     double mCellSizeY;
00054 };
00055 
00056 #endif
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines