GeopsySLinkGui/SeedLinkLoader.h
Go to the documentation of this file.
00001 /***************************************************************************
00002 **
00003 **  This file is part of GeopsySLinkGui.
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 : 2007-04-30
00021 **  Authors:
00022 **    Marc Wathelet
00023 **    Marc Wathelet (LGIT, Grenoble, France)
00024 **
00025 ***************************************************************************/
00026 
00027 #ifndef SEEDLINKLOADER_H
00028 #define SEEDLINKLOADER_H
00029 
00030 #include <GeopsySLink.h>
00031 
00032 #include "ui_SeedLinkLoader.h"
00033 #include "GeopsySLinkGuiDLLExport.h"
00034 
00035 namespace GeopsySLinkGui {
00036 
00037 class GEOPSYSLINKGUI_EXPORT SeedLinkLoader : public QWidget, private Ui::SeedLinkLoader
00038 {
00039   Q_OBJECT
00040 public:
00041   SeedLinkLoader(QWidget * parent=0);
00042   ~SeedLinkLoader();
00043 
00044   void removeOptions();
00045   void removeView();
00046 
00047   void setServer(QString serverAddress, int serverPort);
00048   void selectStreams(QString selection);
00049 
00050   void setFromTime(QDateTime f) {_seedLink->setFromTime(f);}
00051   void setBufferType(SeedLinkStream::BufferType bt) {_seedLink->setBufferType(bt);}
00052   void setMaximumDuration(double d) {_seedLink->setMaximumDuration(d);}
00053 private slots:
00054   void on_selectBut_clicked();
00055   void on_connectBut_clicked();
00056   void on_startBut_clicked();
00057   void on_stopBut_clicked();
00058   void on_viewBut_clicked();
00059   void on_optionsBut_clicked();
00060   void streamInfoAvailable();
00061   void seedLinkError(GeopsySLink::SeedLink::Error e);
00062   void showContextMenu(const QPoint & pos);
00063   void monitorDataChange(Signal * sig, const TimeRange& tw);
00064 signals:
00065   void started();
00066   void stopped();
00067   void dataChanged(Signal * sig, TimeRange tw);
00068 private:
00069   void setStreamsEnabled(bool b);
00070   bool isAnySelected();
00071 
00072   SeedLink * _seedLink;
00073   QString _streamSelection;
00074 };
00075 
00076 } // namespace GeopsySLinkGui
00077 
00078 #endif // SEEDLINKLOADER_H
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines