kpilot
popmail-conduit.h
Go to the documentation of this file.00001 #ifndef _KPILOT_POPMAIL_CONDUIT_H 00002 #define _KPILOT_POPMAIL_CONDUIT_H 00003 /* popmail-conduit.h KPilot 00004 ** 00005 ** Copyright (C) 1998,1999,2000 Dan Pilone 00006 ** Copyright (C) 1999,2000 Michael Kropfberger 00007 ** 00008 ** This file is part of the popmail conduit, a conduit for KPilot that 00009 ** synchronises the Pilot's email application with the outside world, 00010 ** which currently means: 00011 ** -- sendmail or SMTP for outgoing mail 00012 ** -- POP or mbox for incoming mail 00013 */ 00014 00015 /* 00016 ** This program is free software; you can redistribute it and/or modify 00017 ** it under the terms of the GNU General Public License as published by 00018 ** the Free Software Foundation; either version 2 of the License, or 00019 ** (at your option) any later version. 00020 ** 00021 ** This program is distributed in the hope that it will be useful, 00022 ** but WITHOUT ANY WARRANTY; without even the implied warranty of 00023 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00024 ** GNU General Public License for more details. 00025 ** 00026 ** You should have received a copy of the GNU General Public License 00027 ** along with this program in a file called COPYING; if not, write to 00028 ** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 00029 ** MA 02110-1301, USA. 00030 */ 00031 00032 /* 00033 ** Bug reports and questions can be sent to kde-pim@kde.org 00034 */ 00035 00036 00037 #include "plugin.h" 00038 00039 class KSocket; 00040 00041 class PilotRecord; 00042 class PilotDatabase; 00043 00044 class PopMailConduit : public ConduitAction 00045 { 00046 public: 00047 PopMailConduit(KPilotLink *d, 00048 const char *n=0L, 00049 const QStringList &l=QStringList()); 00050 virtual ~PopMailConduit(); 00051 00052 protected: 00053 virtual bool exec(); 00054 00055 // static PilotRecord *readMessage(FILE *mailbox, 00056 // char *buffer,int bufferSize); 00057 00058 protected: 00059 void doSync(); 00060 void doTest(); 00061 00062 // Pilot -> Sendmail 00063 // 00064 // 00065 int sendPendingMail(int mode /* unused */); 00066 // int sendViaSendmail(); 00067 int sendViaKMail(); 00068 // int sendViaSMTP(); 00069 void writeMessageToFile(FILE* sendf, struct Mail& theMail); 00070 QString getKMailOutbox() const; 00071 00072 }; 00073 00074 #endif