Songbird / Development / Songbird Add-Ons API Documentation

components/library/localdatabase/public/sbILocalDatabaseSmartMediaList.idl

Go to the documentation of this file.
00001 /*
00002 //
00003 // BEGIN SONGBIRD GPL
00004 //
00005 // This file is part of the Songbird web player.
00006 //
00007 // Copyright(c) 2005-2008 POTI, Inc.
00008 // http://songbirdnest.com
00009 //
00010 // This file may be licensed under the terms of of the
00011 // GNU General Public License Version 2 (the "GPL").
00012 //
00013 // Software distributed under the License is distributed
00014 // on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either
00015 // express or implied. See the GPL for the specific language
00016 // governing rights and limitations.
00017 //
00018 // You should have received a copy of the GPL along with this
00019 // program. If not, go to http://www.gnu.org/licenses/gpl.html
00020 // or write to the Free Software Foundation, Inc.,
00021 // 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
00022 //
00023 // END SONGBIRD GPL
00024 //
00025 */
00026 
00033 #include "nsISupports.idl"
00034 #include "sbIMediaList.idl"
00035 
00036 interface sbIPropertyOperator;
00037 interface sbILocalDatabaseSmartMediaList;
00038 
00043 [scriptable, uuid(39b60b98-1b65-4e6e-866c-25b88127f8ad)]
00044 interface sbILocalDatabaseSmartMediaListCondition : nsISupports
00045 {
00049   readonly attribute AString propertyID;
00050 
00055   readonly attribute sbIPropertyOperator operator;
00056 
00061   readonly attribute AString leftValue;
00062 
00069   readonly attribute AString rightValue;
00070 
00078   readonly attribute AString displayUnit;
00079 };
00080 
00081 [scriptable, function, uuid(4b3f9a5b-44d5-4384-8f4d-6f953013f877)]
00082 interface sbILocalDatabaseSmartMediaListListener : nsISupports
00083 {
00084   void onRebuild(in sbILocalDatabaseSmartMediaList aSmartMediaList);
00085 };
00086 
00087 
00097 [scriptable, uuid(908211a1-2466-4642-bab9-75b228ff1532)]
00098 interface sbILocalDatabaseSmartMediaList : sbIMediaList
00099 {
00100   const unsigned long MATCH_TYPE_ANY  = 0;
00101   const unsigned long MATCH_TYPE_ALL  = 1;
00102   const unsigned long MATCH_TYPE_NONE = 2;
00103 
00104   const unsigned long LIMIT_TYPE_NONE  = 0;
00105   const unsigned long LIMIT_TYPE_ITEMS = 1;
00106   const unsigned long LIMIT_TYPE_USECS = 2;
00107   const unsigned long LIMIT_TYPE_BYTES = 3;
00108 
00109   const unsigned long NOTEXISTS_ASZERO = 0;
00110   const unsigned long NOTEXISTS_ASNULL = 1;
00111 
00115   attribute unsigned long matchType;
00116 
00120   readonly attribute unsigned long conditionCount;
00121 
00125   attribute unsigned long limitType;
00126 
00130   attribute unsigned long long limit;
00131 
00135   attribute AString selectPropertyID;
00136 
00141   attribute boolean selectDirection;
00142 
00146   attribute boolean randomSelection;
00147 
00152   attribute boolean autoUpdate;
00153   
00163    attribute unsigned long notExistsMode;
00164 
00168   sbILocalDatabaseSmartMediaListCondition
00169     appendCondition(in AString aPropertyID,
00170                     in sbIPropertyOperator aOperator,
00171                     in AString aLeftValue,
00172                     in AString aRightValue,
00173                     in AString aDisplayUnit);
00174 
00178   void removeConditionAt(in unsigned long aConditionIndex);
00179 
00184   sbILocalDatabaseSmartMediaListCondition
00185     getConditionAt(in unsigned long aConditionIndex);
00186 
00190   void clearConditions();
00191 
00196   void rebuild();
00197   
00198   void addSmartMediaListListener(in sbILocalDatabaseSmartMediaListListener aListener);
00199   void removeSmartMediaListListener(in sbILocalDatabaseSmartMediaListListener aListener);
00200   
00205   attribute AString sourceLibraryGuid;
00206 };

Generated on Tue Mar 10 14:28:55 2009 for Songbird by  doxygen 1.5.2