summaryrefslogtreecommitdiffstats
path: root/comm/mail/components/migration/src/nsProfileMigratorBase.h
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 17:32:43 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 17:32:43 +0000
commit6bf0a5cb5034a7e684dcc3500e841785237ce2dd (patch)
treea68f146d7fa01f0134297619fbe7e33db084e0aa /comm/mail/components/migration/src/nsProfileMigratorBase.h
parentInitial commit. (diff)
downloadthunderbird-6bf0a5cb5034a7e684dcc3500e841785237ce2dd.tar.xz
thunderbird-6bf0a5cb5034a7e684dcc3500e841785237ce2dd.zip
Adding upstream version 1:115.7.0.upstream/1%115.7.0upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'comm/mail/components/migration/src/nsProfileMigratorBase.h')
-rw-r--r--comm/mail/components/migration/src/nsProfileMigratorBase.h40
1 files changed, 40 insertions, 0 deletions
diff --git a/comm/mail/components/migration/src/nsProfileMigratorBase.h b/comm/mail/components/migration/src/nsProfileMigratorBase.h
new file mode 100644
index 0000000000..6ca0d7fcb4
--- /dev/null
+++ b/comm/mail/components/migration/src/nsProfileMigratorBase.h
@@ -0,0 +1,40 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
+#ifndef profilemigratorbase___h___
+#define profilemigratorbase___h___
+
+#include "nsIFile.h"
+#include "nsIObserverService.h"
+#include "nsITimer.h"
+#include "nsIImportGeneric.h"
+#include "nsIImportModule.h"
+#include "nsIMsgAccount.h"
+
+class nsProfileMigratorBase {
+ public:
+ nsProfileMigratorBase();
+ virtual ~nsProfileMigratorBase();
+ virtual nsresult ContinueImport() = 0;
+
+ protected:
+ nsresult ImportSettings(nsIImportModule* aImportModule);
+ nsresult ImportAddressBook(nsIImportModule* aImportModule);
+ nsresult ImportMailData(nsIImportModule* aImportModule);
+ nsresult ImportFilters(nsIImportModule* aImportModule);
+ nsresult FinishCopyingAddressBookData();
+ nsresult FinishCopyingMailFolders();
+
+ nsCOMPtr<nsIObserverService> mObserverService;
+ nsCOMPtr<nsITimer> mFileIOTimer;
+ nsCOMPtr<nsIImportGeneric> mGenericImporter;
+ nsCOMPtr<nsIImportModule> mImportModule;
+ nsCOMPtr<nsIMsgAccount>
+ mLocalFolderAccount; // needed for nsIImportSettings::Import
+ bool mProcessingMailFolders; // we are either asynchronously parsing address
+ // books or mail folders
+};
+
+#endif