KCDDB

asyncsmtpsubmit.cpp
1 /*
2  SPDX-FileCopyrightText: 2003 Richard Lärkäng <[email protected]>
3 
4  SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6 
7 #include "asyncsmtpsubmit.h"
8 #include "logging.h"
9 
10 #include "cdinfo.h"
11 
12 #include <KIO/Job>
13 
14 namespace KCDDB
15 {
16  AsyncSMTPSubmit::AsyncSMTPSubmit(const QString& hostname, uint port,
17  const QString& username, const QString& from, const QString& to )
18  : SMTPSubmit( hostname, port, username, from, to )
19  {
20 
21  }
22 
23  AsyncSMTPSubmit::~AsyncSMTPSubmit()
24  {
25 
26  }
27 
28  Result AsyncSMTPSubmit::runJob(KIO::Job* job)
29  {
30  connect( job, &KJob::result,
31  this, &AsyncSMTPSubmit::slotDone );
32 
33  return Success;
34  }
35 
36  void AsyncSMTPSubmit::slotDone( KJob* job )
37  {
38  qCDebug(LIBKCDDB) ;
39  if ( job->error()==0 )
40  Q_EMIT finished( Success );
41  else
42  Q_EMIT finished( UnknownError );
43  }
44 }
45 
void result(KJob *job)
int error() const
This file is part of the KDE documentation.
Documentation copyright © 1996-2021 The KDE developers.
Generated on Sun Dec 5 2021 23:10:08 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.