QGpCompatibility/CompatAutocorrReport.h
Go to the documentation of this file.
00001 /***************************************************************************
00002 **
00003 **  This file is part of QGpCompatibility.
00004 **
00005 **  This file may be distributed and/or modified under the terms of the
00006 **  GNU General Public License version 2 or 3 as published by the Free
00007 **  Software Foundation and appearing in the file LICENSE.GPL included
00008 **  in the packaging of this file.
00009 **
00010 **  This file is distributed in the hope that it will be useful, but WITHOUT
00011 **  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00012 **  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
00013 **  more details.
00014 **
00015 **  You should have received a copy of the GNU General Public License
00016 **  along with this program. If not, see <http://www.gnu.org/licenses/>.
00017 **
00018 **  See http://www.geopsy.org for more information.
00019 **
00020 **  Created : 2003-05-22
00021 **  Authors:
00022 **    Marc Wathelet
00023 **    Marc Wathelet (ULg, Liège, Belgium)
00024 **    Marc Wathelet (LGIT, Grenoble, France)
00025 **
00026 ***************************************************************************/
00027 
00028 #ifndef AUTOCORRREPORT_H
00029 #define AUTOCORRREPORT_H
00030 
00031 #include "QGpCompatibilityDLLExport.h"
00032 #include "CompatInversionReport.h"
00033 
00034 namespace QGpCompatibility {
00035 
00036 class CompatAutocorrCurves;
00037 class CompatAutocorrData;
00038 
00039 class QGPCOMPATIBILITY_EXPORT CompatAutocorrReport :  public CompatInversionReport
00040 {
00041 public:
00043   CompatAutocorrReport(bool isWrite, QString reportFile, QString naInFile=QString::null, int nModels=0);
00044   ~CompatAutocorrReport();
00046   virtual bool isA(const char * className);
00047   int  radiusCount();
00048   void addAutocorrGoal(CompatAutocorrData *ad);
00054   void modifyAutocorrGoal(CompatAutocorrData * rms);
00056   void addModel(const Seismic1DModel * model, float * naModel,
00057                 const CompatDispersion * disp,
00058                 const CompatAutocorrCurves * ac,
00059                 double cost, int modelID=-1);
00061   void addModel(const Seismic1DModel * model, float * naModel,
00062                 const CompatDispersion * disp,
00063                 const CompatEllipticity * ell,
00064                 const CompatAutocorrCurves * ac,
00065                 double cost, int modelID=-1);
00067   bool loadAutocorrOnly(int modelIndex);
00069   bool loadAutocorr(int modelIndex);
00071   bool loadAutocorr(CompatAutocorrCurves * ac, int modelIndex);
00073   CompatAutocorrData * loadAutocorrGoal();
00075   CompatAutocorrCurves *  currentAutocorr();
00076 protected:
00078   CompatAutocorrCurves * _currentAutocorr;
00080   bool initCurrentAutocorr();
00081 };
00082 
00083 } // namespace QGpCompatibility
00084 
00085 #include "CompatAutocorrCurves.h"
00086 
00087 namespace QGpCompatibility {
00088 
00089 inline CompatAutocorrCurves * CompatAutocorrReport::currentAutocorr()
00090 {
00091   TRACE;
00092   if(!_currentAutocorr) loadAutocorr(0);  
00093   return _currentAutocorr;
00094 }
00095 
00096 inline int CompatAutocorrReport::radiusCount()
00097 {
00098   TRACE;
00099   if(!_currentAutocorr) loadAutocorr(0);  
00100   return _currentAutocorr->radiusCount();
00101 }
00102 } // namespace QGpCompatibility
00103 
00104 #endif // COMPATAUTOCORRREPORT_H
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines