| VRS - The Virtual Rendering System |
| version 3.3 |
00001 /****************************************************************************** 00002 * VRS - The Virtual Rendering System 00003 * Copyright (C) 2000-2005 Computer Graphics Systems Group at the 00004 * Hasso-Plattner-Institute (HPI), Potsdam, Germany. 00005 * 00006 * This library is free software; you can redistribute it and/or modify it 00007 * under the terms of the GNU Lesser General Public License as published by 00008 * the Free Software Foundation; either version 2.1 of the License, or (at 00009 * your option) any later version. This library is distributed in the hope 00010 * that it will be useful, but WITHOUT ANY WARRANTY; without even the implied 00011 * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00012 * GNU Lesser General Public License for more details. You should have received 00013 * a copy of the GNU Lesser+ General Public License along with this library; if 00014 * not, write to the FreeSoftware Foundation, Inc., 59 Temple Place, Suite 330, 00015 * Boston, MA, 02111-1307, USA. 00016 ******************************************************************************/ 00017 00018 // $Id: httpserver.h 6014 2007-08-09 07:51:16Z Konstantin_Baumann $ 00019 // 00020 // $Log$ 00021 // Revision 1.2 2005/11/23 19:50:20 klimetschek 00022 // fixed signal paramter type bug with missing VRS:: prefix 00023 // 00024 // Revision 1.1 2005/11/23 19:31:45 klimetschek 00025 // added http web server classes based on qt 00026 // 00027 00028 #ifndef VRS_QT_HTTPSERVER_HTTPSERVER_H 00029 #define VRS_QT_HTTPSERVER_HTTPSERVER_H 00030 00031 #include <vrs/qt3/httpserver/httprequestheader.h> 00032 #include <vrs/qt3/httpserver/httpresponseheader.h> 00033 #include <vrs/qt3/httpserver/httpresponse.h> 00034 00035 #include <qserversocket.h> 00036 00037 namespace VRS { 00038 00040 00077 class VRS_QT3_API HttpServer : public QServerSocket 00078 { 00079 Q_OBJECT 00080 public: 00081 HttpServer( QObject* parent=0, int port=80 ); 00082 00083 virtual void newConnection( int socket ); 00084 00085 signals: 00086 void newConnect(); 00087 void requestReceived( 00088 const VRS::HttpRequestHeader& request, 00089 VRS::HttpResponse& response 00090 ); 00091 void wroteToClient(); 00092 void endConnect(); 00093 00094 private slots: 00095 void readClient(); 00096 void discardClient(); 00097 00098 private: 00099 QString headerLines_; 00100 }; 00101 00102 } // namespace VRS 00103 00104 00105 #endif // VRS_QT_HTTPSERVER_HTTPSERVER_H