Bumping gaia.json for 8 gaia revision(s) a=gaia-bump
[gecko.git] / xpcom / ds / nsIEnumerator.idl
blob7569fb8a39d817c1a34eb2c963a6e265701d80e4
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 #include "nsISupports.idl"
8 %{C++
9 #define NS_ENUMERATOR_FALSE 1
12 * DO NOT USE THIS INTERFACE. IT IS HORRIBLY BROKEN, USES NS_COMFALSE
13 * AND IS BASICALLY IMPOSSIBLE TO USE CORRECTLY THROUGH PROXIES OR
14 * XPCONNECT. IF YOU SEE NEW USES OF THIS INTERFACE IN CODE YOU ARE
15 * REVIEWING, YOU SHOULD INSIST ON nsISimpleEnumerator.
17 * DON'T MAKE ME COME OVER THERE.
19 [scriptable, uuid(ad385286-cbc4-11d2-8cca-0060b0fc14a3)]
20 interface nsIEnumerator : nsISupports {
21 /** First will reset the list. will return NS_FAILED if no items
23 void first();
25 /** Next will advance the list. will return failed if already at end
27 void next();
29 /** CurrentItem will return the CurrentItem item it will fail if the
30 * list is empty
32 nsISupports currentItem();
34 /** return if the collection is at the end. that is the beginning following
35 * a call to Prev and it is the end of the list following a call to next
37 void isDone();
40 [uuid(75f158a0-cadd-11d2-8cca-0060b0fc14a3)]
41 interface nsIBidirectionalEnumerator : nsIEnumerator {
43 /** Last will reset the list to the end. will return NS_FAILED if no items
45 void last();
47 /** Prev will decrement the list. will return failed if already at beginning
49 void prev();