aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/async/imap/MCIMAPCheckAccountOperation.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/async/imap/MCIMAPCheckAccountOperation.cpp')
-rw-r--r--src/async/imap/MCIMAPCheckAccountOperation.cpp23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/async/imap/MCIMAPCheckAccountOperation.cpp b/src/async/imap/MCIMAPCheckAccountOperation.cpp
new file mode 100644
index 00000000..5baa89a9
--- /dev/null
+++ b/src/async/imap/MCIMAPCheckAccountOperation.cpp
@@ -0,0 +1,23 @@
+//
+// MCIMAPCheckAccountOperation.cc
+// mailcore2
+//
+// Created by DINH Viêt Hoà on 1/12/13.
+// Copyright (c) 2013 MailCore. All rights reserved.
+//
+
+#include "MCIMAPCheckAccountOperation.h"
+
+#include "MCIMAPAsyncConnection.h"
+#include "MCIMAPSession.h"
+
+using namespace mailcore;
+
+void IMAPCheckAccountOperation::main()
+{
+ ErrorCode error;
+ session()->session()->connectIfNeeded(&error);
+ if (error == ErrorNone)
+ session()->session()->login(&error);
+ setError(error);
+}