sbIURIImportService.idl
Go to the documentation of this file.
1 /*
2 //
3 // BEGIN SONGBIRD GPL
4 //
5 // This file is part of the Songbird web player.
6 //
7 // Copyright(c) 2005-2008 POTI, Inc.
8 // http://songbirdnest.com
9 //
10 // This file may be licensed under the terms of of the
11 // GNU General Public License Version 2 (the "GPL").
12 //
13 // Software distributed under the License is distributed
14 // on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either
15 // express or implied. See the GPL for the specific language
16 // governing rights and limitations.
17 //
18 // You should have received a copy of the GPL along with this
19 // program. If not, go to http://www.gnu.org/licenses/gpl.html
20 // or write to the Free Software Foundation, Inc.,
21 // 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
22 //
23 // END SONGBIRD GPL
24 //
25 */
26 
27 #include "nsISupports.idl"
28 
29 interface nsIMutableArray;
30 interface nsIDOMWindow;
31 interface sbIMediaList;
32 interface sbIMediaItem;
33 
34 
35 //
36 // @brief Callback listener interface for an import job.
37 //
38 [scriptable, uuid(7E0C19F8-64D4-418D-B7A6-B89EE92B7721)]
40 {
41  //
42  // @brief Callback method when the import of URIs is complete.
43  // @param aTargetMediaList The target media list.
44  // @param aTotalImportCount The number of items that where imported
45  // @param aTotalDupeCount The number of duplicates found
46  // @param aTotalUnsupportedCount The number of unsupported items found
47  // @param aTotalInserted The number of media items that where inserted into
48  // the target media list.
49  // @param aOtherDrops Other items that were not imported.
50  //
51  void onImportComplete(in sbIMediaList aTargetMediaList,
52  in unsigned long aTotalImportCount,
53  in unsigned long aTotalDupeCount,
54  in unsigned long aTotalUnsupportedCount,
55  in unsigned long aTotalInserted,
56  in unsigned long aOtherDrops);
57 
58  //
59  // @brief Callback method when the first media item has been inserted.
60  // @param aTargetMediaList The target media list of the import
61  // @param aTargetMediaItem The first inserted media item.
62  //
63  void onFirstMediaItem(in sbIMediaList aTargetMediaList,
64  in sbIMediaItem aTargetMediaItem);
65 };
66 
67 //------------------------------------------------------------------------------
68 
69 //
70 // @brief Import service to help assist with inputing several URIs into a
71 // associated medialist. For callback information about the status
72 // of the import, see |sbIRUIImportListener|.
73 //
74 [scriptable, uuid(F9BC0B02-C078-47A3-91C3-3F00EA0CF8A1)]
76 {
77  //
78  // @brief Start a import of a URI array.
79  // @param aURIArray The array of URIs to import into the medialist.
80  // @param aDOMWindow The parent window to show progress off of.
81  // @param aTargetMediaList The media list to insert the media items created
82  // from the URI array into.
83  // @param aTargetPosition The position to insert media items into at. This
84  // value can be -1 if the position does not matter.
85  // @param aImportListener The callback listener that implements
86  // |sbIURIImportListener|.
87  //
88  void importURIArray(in nsIMutableArray aURIArray,
89  in nsIDOMWindow aDOMWindow,
90  in sbIMediaList aTargetMediaList,
91  in long aTargetPosition,
92  in sbIRUIImportListener aImportListener);
93 };
94 
var D
var uuid
A brief description of the contents of this interface.
void onImportComplete(in sbIMediaList aTargetMediaList, in unsigned long aTotalImportCount, in unsigned long aTotalDupeCount, in unsigned long aTotalUnsupportedCount, in unsigned long aTotalInserted, in unsigned long aOtherDrops)
const nsIDOMWindow
void onFirstMediaItem(in sbIMediaList aTargetMediaList, in sbIMediaItem aTargetMediaItem)
void importURIArray(in nsIMutableArray aURIArray, in nsIDOMWindow aDOMWindow, in sbIMediaList aTargetMediaList, in long aTargetPosition, in sbIRUIImportListener aImportListener)
Interface that defines a single item of media in the system.
#define C3