00001 /*************************************************************************** 00002 ** 00003 ** This file is part of dinver. 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 : 2004-10-28 00021 ** Authors: 00022 ** Marc Wathelet 00023 ** Marc Wathelet (ULg, Liège, Belgium) 00024 ** Marc Wathelet (LGIT, Grenoble, France) 00025 ** 00026 ***************************************************************************/ 00027 00028 #ifndef ModelThreadInfo_H 00029 #define ModelThreadInfo_H 00030 00031 #include <QList> 00032 #include <QVector> 00033 #include <QAbstractItemModel> 00034 00035 class InversionThread; 00036 class PSViewer; 00037 00038 class ModelThreadInfo 00039 { 00040 public: 00041 inline ModelThreadInfo(const InversionThread * t, int index); 00042 00043 bool operator<(const ModelThreadInfo& o) const; 00044 const InversionThread * thread() const {return _thread;} 00045 int index() const {return _index;} 00046 private: 00047 const InversionThread * _thread; 00048 int _index; 00049 }; 00050 00051 typedef QList<InversionThread *> ThreadList; 00052 typedef QList<ModelThreadInfo> ModelThreadList; 00053 typedef QVector<PSViewer*> PSViewerVector; 00054 typedef QList<PSViewer*> PSViewerList; 00055 00056 inline ModelThreadInfo::ModelThreadInfo(const InversionThread * t, int index) 00057 { 00058 _thread=t; 00059 _index=index; 00060 } 00061 00062 #endif