KIO
dataprotocol.h
Go to the documentation of this file.
00001 // dataprotocol.h 00002 // ================ 00003 // 00004 // Interface of the KDE data protocol core operations 00005 // 00006 // Author: Leo Savernik 00007 // Email: l.savernik@aon.at 00008 // Copyright (C) 2002 by Leo Savernik <l.savernik@aon.at> 00009 // Created: Sam Dez 28 14:11:18 CET 2002 00010 00011 /*************************************************************************** 00012 * * 00013 * This program is free software; you can redistribute it and/or modify * 00014 * it under the terms of the GNU Lesser General Public License as * 00015 * published by the Free Software Foundation; version 2. * 00016 * * 00017 ***************************************************************************/ 00018 00019 #ifndef DATAPROTOCOL_H 00020 #define DATAPROTOCOL_H 00021 00022 // dataprotocol.* interprets the following defines 00023 // DATAKIOSLAVE: define if you want to compile this into a stand-alone 00024 // kioslave 00025 // TESTKIO: define for test-driving 00026 // Both defines are mutually exclusive. Defining none of them compiles 00027 // DataProtocol for internal usage within libkiocore. 00028 00029 /* Wondering what this is all about? Leo explained it to me: 00030 * 00031 * That's simple, you can compile it into a standalone executable that is 00032 * registered like any other kioslave. 00033 * 00034 * However, given that data-urls don't depend on any external data it seemed 00035 * overkill, therefore I added a special hack that the kio-dataslave is invoked 00036 * in-process on the client side. 00037 * 00038 * Hence, by defining DATAKIOSLAVE you can disable this special hack and compile 00039 * dataprotocol.* into a standalone kioslave. 00040 */ 00041 00042 class QByteArray; 00043 00044 class KUrl; 00045 00046 #if defined(DATAKIOSLAVE) 00047 # include <kio/slavebase.h> 00048 #elif !defined(TESTKIO) 00049 # include "kio/dataslave.h" 00050 #endif 00051 00052 namespace KIO { 00053 00058 #if defined(DATAKIOSLAVE) 00059 class DataProtocol : public KIO::SlaveBase { 00060 #elif defined(TESTKIO) 00061 class DataProtocol : public TestSlave { 00062 #else 00063 class DataProtocol : public DataSlave { 00064 #endif 00065 00066 public: 00067 #if defined(DATAKIOSLAVE) 00068 DataProtocol(const QByteArray &pool_socket, const QByteArray &app_socket); 00069 #else 00070 DataProtocol(); 00071 #endif 00072 virtual ~DataProtocol(); 00073 virtual void mimetype(const KUrl &url); 00074 virtual void get(const KUrl &url); 00075 }; 00076 00077 }/*end namespace*/ 00078 00079 #endif
This file is part of the KDE documentation.
Documentation copyright © 1996-2019 The KDE developers.
Generated on Mon Jan 21 2019 12:34:57 by doxygen 1.7.5.1 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2019 The KDE developers.
Generated on Mon Jan 21 2019 12:34:57 by doxygen 1.7.5.1 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.