1999-01-27 05:59:12 +03:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
|
1999-01-23 05:48:58 +03:00
|
|
|
*
|
|
|
|
* The contents of this file are subject to the Netscape Public License
|
|
|
|
* Version 1.0 (the "NPL"); you may not use this file except in
|
|
|
|
* compliance with the NPL. You may obtain a copy of the NPL at
|
|
|
|
* http://www.mozilla.org/NPL/
|
|
|
|
*
|
|
|
|
* Software distributed under the NPL is distributed on an "AS IS" basis,
|
|
|
|
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
|
|
|
|
* for the specific language governing rights and limitations under the
|
|
|
|
* NPL.
|
|
|
|
*
|
|
|
|
* The Initial Developer of this code under the NPL is Netscape
|
|
|
|
* Communications Corporation. Portions created by Netscape are
|
|
|
|
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
|
|
|
|
* Reserved.
|
|
|
|
*/
|
1999-01-27 05:59:12 +03:00
|
|
|
|
1999-01-23 05:48:58 +03:00
|
|
|
#include "nsISupports.idl"
|
|
|
|
#include "nsISupportsArray.idl"
|
1999-01-27 05:59:12 +03:00
|
|
|
#include "nsIRDFNode.idl"
|
|
|
|
|
|
|
|
enum FolderType {
|
|
|
|
FOLDER_MAIL,
|
|
|
|
FOLDER_IMAPMAIL,
|
|
|
|
FOLDER_NEWSGROUP,
|
|
|
|
FOLDER_CONTAINERONLY,
|
|
|
|
FOLDER_CATEGORYCONTAINER,
|
|
|
|
FOLDER_IMAPSERVERCONTAINER,
|
|
|
|
FOLDER_UNKNOWN
|
|
|
|
};
|
1999-01-23 05:48:58 +03:00
|
|
|
|
|
|
|
[uuid(85e39ff0-b248-11d2-b7ef-00805f05ffa5)]
|
1999-01-27 05:59:12 +03:00
|
|
|
interface nsIMsgFolder : nsIRDFResource {
|
1999-01-23 05:48:58 +03:00
|
|
|
|
1999-01-27 05:59:12 +03:00
|
|
|
readonly attribute FolderType type;
|
|
|
|
readonly attribute string prettyName;
|
|
|
|
readonly attribute string name;
|
|
|
|
void SetName(in string name);
|
|
|
|
readonly attribute string prettiestName;
|
|
|
|
|
|
|
|
string GetNameFromPathName(in string pathName);
|
|
|
|
boolean HasSubFolders();
|
|
|
|
long GetNumSubFolders() ;
|
|
|
|
long GetNumSubFoldersToDisplay();
|
|
|
|
nsIMsgFolder GetSubFolder(in long which) ;
|
|
|
|
nsISupportsArray GetSubFolders();
|
|
|
|
void AddSubFolder(in nsIMsgFolder folder);
|
|
|
|
void RemoveSubFolder (in nsIMsgFolder folder);
|
|
|
|
|
|
|
|
readonly attribute boolean deleteIsMoveToTrash;
|
|
|
|
readonly attribute boolean showDeletedMessages;
|
1999-01-26 02:38:09 +03:00
|
|
|
|
1999-01-27 05:59:12 +03:00
|
|
|
void OnCloseFolder ();
|
|
|
|
void Delete ();
|
|
|
|
|
|
|
|
void PropagateDelete(inout nsIMsgFolder folder, in boolean deleteStorage);
|
|
|
|
void RecursiveDelete(in boolean deleteStorage);
|
|
|
|
|
|
|
|
void CreateSubfolder(in string leafNameFromUser, out nsIMsgFolder outFolder, out long outPos);
|
|
|
|
|
|
|
|
void Rename(in string name);
|
|
|
|
void Adopt(in nsIMsgFolder srcFolder, out long outPos);
|
|
|
|
|
|
|
|
boolean ContainsChildNamed(in string name);
|
|
|
|
nsIMsgFolder FindChildNamed(in string name);
|
|
|
|
nsIMsgFolder FindParentOf(in nsIMsgFolder childFolder);
|
|
|
|
boolean IsParentOf(in nsIMsgFolder folder, in boolean deep);
|
|
|
|
|
|
|
|
string GenerateUniqueSubfolderName(in string prefix, in nsIMsgFolder otherFolder);
|
|
|
|
|
|
|
|
attribute long depth;
|
|
|
|
|
|
|
|
void UpdateSummaryTotals();
|
|
|
|
void SummaryChanged();
|
|
|
|
long GetNumUnread(in boolean deep);
|
|
|
|
long GetTotalMessages(in boolean deep);
|
|
|
|
|
|
|
|
readonly attribute long expungedBytesCount;
|
|
|
|
readonly attribute boolean deletable;
|
|
|
|
readonly attribute boolean canCreateChildren;
|
|
|
|
readonly attribute boolean canBeRenamed;
|
|
|
|
readonly attribute boolean requiresCleanup;
|
|
|
|
|
|
|
|
void ClearRequiresCleanup();
|
|
|
|
|
|
|
|
readonly attribute boolean knowsSearchNntpExtension;
|
|
|
|
readonly attribute boolean allowsPosting;
|
|
|
|
|
|
|
|
readonly attribute string relativePathName;
|
|
|
|
readonly attribute long sizeOnDisk;
|
|
|
|
|
|
|
|
void RememberPassword(in string password);
|
|
|
|
string GetRememberedPassword();
|
|
|
|
boolean UserNeedsToAuthenticateForFolder(in boolean displayOnly);
|
|
|
|
string GetUserName();
|
|
|
|
string GetHostName();
|
|
|
|
|
1999-01-26 02:38:09 +03:00
|
|
|
void AddSubfolderIfUnique(in nsIMsgFolder newSubfolder);
|
|
|
|
void ReplaceSubfolder(in nsIMsgFolder oldFolder,
|
|
|
|
in nsIMsgFolder newFolder);
|
|
|
|
|
|
|
|
void SetFlag(in long flag);
|
|
|
|
void ClearFlag(in long flag);
|
|
|
|
boolean GetFlag(in long flag);
|
1999-01-28 04:23:40 +03:00
|
|
|
|
|
|
|
void ToggleFlag (in long flag);
|
|
|
|
void OnFlagChange (in long flag);
|
|
|
|
long GetFlags();
|
|
|
|
|
|
|
|
void GetFoldersWithFlag(in long flags, out nsIMsgFolder result,
|
|
|
|
in long resultsize, out long numFolders);
|
|
|
|
|
|
|
|
void GetExpansionArray(in nsISupportsArray expansionArray);
|
|
|
|
|
1999-01-23 05:48:58 +03:00
|
|
|
};
|
|
|
|
|
|
|
|
|