michael@0: /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: #include "nsISupports.idl" michael@0: michael@0: interface nsISimpleEnumerator; michael@0: michael@0: /** michael@0: * An optional interface for accessing or removing the cookies michael@0: * that are in the cookie list michael@0: */ michael@0: michael@0: [scriptable, uuid(AAAB6710-0F2C-11d5-A53B-0010A401EB10)] michael@0: interface nsICookieManager : nsISupports michael@0: { michael@0: michael@0: /** michael@0: * Called to remove all cookies from the cookie list michael@0: */ michael@0: void removeAll(); michael@0: michael@0: /** michael@0: * Called to enumerate through each cookie in the cookie list. michael@0: * The objects enumerated over are of type nsICookie michael@0: */ michael@0: readonly attribute nsISimpleEnumerator enumerator; michael@0: michael@0: /** michael@0: * Called to remove an individual cookie from the cookie list, specified michael@0: * by host, name, and path. If the cookie cannot be found, no exception michael@0: * is thrown. Typically, the arguments to this method will be obtained michael@0: * directly from the desired nsICookie object. michael@0: * michael@0: * @param aHost The host or domain for which the cookie was set. @see michael@0: * nsICookieManager2::add for a description of acceptable host michael@0: * strings. If the target cookie is a domain cookie, a leading michael@0: * dot must be present. michael@0: * @param aName The name specified in the cookie michael@0: * @param aPath The path for which the cookie was set michael@0: * @param aBlocked Indicates if cookies from this host should be permanently blocked michael@0: * michael@0: */ michael@0: void remove(in AUTF8String aHost, michael@0: in ACString aName, michael@0: in AUTF8String aPath, michael@0: in boolean aBlocked); michael@0: };