sbLocalDatabaseLibrary Class Reference

#include <sbLocalDatabaseLibrary.h>

Inheritance diagram for sbLocalDatabaseLibrary:
[legend]
Collaboration diagram for sbLocalDatabaseLibrary:
[legend]

Public Member Functions

NS_DECL_ISUPPORTS_INHERITED
NS_DECL_SBILIBRARY
NS_DECL_SBILOCALDATABASELIBRARY
NS_DECL_NSICLASSINFO
NS_DECL_NSIOBSERVER
NS_DECL_SBILIBRARYSTATISTICS
NS_IMETHOD 
GetLibrary (sbILibrary **aLibrary)
 
NS_IMETHOD GetIsMutable (PRBool *aIsMutable)
 
NS_IMETHOD GetItemController (sbIMediaItemController **aMediaItemController)
 
NS_IMETHOD GetMediaCreated (PRInt64 *aMediaCreated)
 
NS_IMETHOD SetMediaCreated (PRInt64 aMediaCreated)
 
NS_IMETHOD GetMediaUpdated (PRInt64 *aMediaUpdated)
 
NS_IMETHOD SetMediaUpdated (PRInt64 aMediaUpdated)
 
NS_IMETHOD GetContentSrc (nsIURI **aContentSrc)
 
NS_IMETHOD GetContentLength (PRInt64 *aContentLength)
 
NS_IMETHOD SetContentLength (PRInt64 aContentLength)
 
NS_IMETHOD GetContentType (nsAString &aContentType)
 
NS_IMETHOD SetContentType (const nsAString &aContentType)
 
NS_IMETHOD TestIsURIAvailable (nsIObserver *aObserver)
 
NS_IMETHOD OpenInputStreamAsync (nsIStreamListener *aListener, nsISupports *aContext, nsIChannel **_retval)
 
NS_IMETHOD OpenInputStream (nsIInputStream **_retval)
 
NS_IMETHOD OpenOutputStream (nsIOutputStream **_retval)
 
NS_IMETHOD ToString (nsAString &_retval)
 
NS_IMETHOD GetName (nsAString &aName)
 
NS_IMETHOD SetName (const nsAString &aName)
 
NS_IMETHOD GetLength (PRUint32 *aLength)
 
NS_IMETHOD GetIsEmpty (PRBool *aIsEmpty)
 
NS_IMETHOD GetUserEditableContent (PRBool *aUserEditableContent)
 
NS_IMETHOD GetItemByIndex (PRUint32 aIndex, sbIMediaItem **_retval)
 
NS_IMETHOD GetListContentType (PRUint16 *_retval)
 
NS_IMETHOD EnumerateAllItems (sbIMediaListEnumerationListener *aEnumerationListener, PRUint16 aEnumerationType)
 
NS_IMETHOD EnumerateItemsByProperty (const nsAString &aPropertyID, const nsAString &aPropertyValue, sbIMediaListEnumerationListener *aEnumerationListener, PRUint16 aEnumerationType)
 
NS_IMETHOD EnumerateItemsByProperties (sbIPropertyArray *aProperties, sbIMediaListEnumerationListener *aEnumerationListener, PRUint16 aEnumerationType)
 
NS_IMETHOD GetItemsByProperty (const nsAString &aPropertyID, const nsAString &aPropertyValue, nsIArray **_retval)
 
NS_IMETHOD GetItemCountByProperty (const nsAString &aPropertyID, const nsAString &aPropertyValue, PRUint32 *_retval)
 
NS_IMETHOD GetItemsByProperties (sbIPropertyArray *aProperties, nsIArray **_retval)
 
NS_IMETHOD IndexOf (sbIMediaItem *aMediaItem, PRUint32 aStartFrom, PRUint32 *_retval)
 
NS_IMETHOD LastIndexOf (sbIMediaItem *aMediaItem, PRUint32 aStartFrom, PRUint32 *_retval)
 
NS_IMETHOD AddListener (sbIMediaListListener *aListener, PRBool aOwnsWeak, PRUint32 aFlags, sbIPropertyArray *aPropertyFilter)
 
NS_IMETHOD RemoveListener (sbIMediaListListener *aListener)
 
NS_IMETHOD RunInBatchMode (sbIMediaListBatchCallback *aCallback, nsISupports *aUserData)
 
NS_IMETHOD GetDistinctValuesForProperty (const nsAString &aPropertyID, nsIStringEnumerator **_retval)
 
NS_IMETHOD GetType (nsAString &aType)
 
NS_IMETHOD GetItemByGuid (const nsAString &aGuid, sbIMediaItem **_retval)
 
NS_IMETHOD Contains (sbIMediaItem *aMediaItem, PRBool *_retval)
 
NS_IMETHOD Add (sbIMediaItem *aMediaItem)
 
NS_IMETHOD AddItem (sbIMediaItem *aMediaItem, sbIMediaItem **aNewMediaItem)
 
NS_IMETHOD AddAll (sbIMediaList *aMediaList)
 
NS_IMETHOD AddSome (nsISimpleEnumerator *aMediaItems)
 
NS_IMETHOD AddMediaItems (nsISimpleEnumerator *aMediaItems, sbIAddMediaItemsListener *aListener, PRBool aAsync)
 
NS_IMETHOD Remove (sbIMediaItem *aMediaItem)
 
NS_IMETHOD RemoveByIndex (PRUint32 aIndex)
 
NS_IMETHOD RemoveSome (nsISimpleEnumerator *aMediaItems)
 
NS_IMETHOD Clear ()
 
NS_IMETHOD CreateView (sbIMediaListViewState *aState, sbIMediaListView **_retval)
 
NS_IMETHOD SetContentSrc (nsIURI *aContentSrc)
 
 sbLocalDatabaseLibrary ()
 
 ~sbLocalDatabaseLibrary ()
 
NS_IMETHOD GetDefaultSortProperty (nsAString &aProperty)
 
nsresult Init (const nsAString &aDatabaseGuid, nsIPropertyBag2 *aCreationParameters, sbILibraryFactory *aFactory, nsIURI *aDatabaseLocation=nsnull)
 
nsresult RemoveSelected (nsISimpleEnumerator *aSelection, sbLocalDatabaseMediaListView *aView)
 Bulk removes the selected items specified in aSelection from the view aView. More...
 
nsresult AddSomeAsyncInternal (nsISimpleEnumerator *aMediaItems, sbIAddMediaItemsListener *aListener)
 
nsresult GetLengthCache (sbILocalDatabaseGUIDArrayLengthCache **aLengthCache)
 
- Public Member Functions inherited from sbLocalDatabaseMediaListBase
NS_DECL_ISUPPORTS_INHERITED
NS_DECL_SBIMEDIALIST 
sbLocalDatabaseMediaListBase ()
 
virtual ~sbLocalDatabaseMediaListBase ()
 
nsresult Init (sbLocalDatabaseLibrary *aLibrary, const nsAString &aGuid, PRBool aOwnsLibrary=PR_TRUE)
 
already_AddRefed
< sbLocalDatabaseLibrary
GetNativeLibrary ()
 
sbILocalDatabaseGUIDArrayGetArray ()
 
nsresult AddListener (sbIMediaListListener *aListener, PRBool aOwnsWeak=PR_FALSE, PRUint32 aFlags=0)
 
void SetCachedListContentType (PRUint16 aContentType)
 
void BeginUpdateBatch ()
 
void EndUpdateBatch ()
 
- Public Member Functions inherited from sbLocalDatabaseMediaItem
NS_DECL_ISUPPORTS
NS_DECL_NSIREQUESTOBSERVER
NS_DECL_NSICLASSINFO
NS_DECL_SBILIBRARYRESOURCE
NS_DECL_SBILOCALDATABASEMEDIAITEM
NS_DECL_SBIMEDIAITEM 
sbLocalDatabaseMediaItem ()
 
virtual ~sbLocalDatabaseMediaItem ()
 
nsresult Init (sbLocalDatabaseLibrary *aLibrary, const nsAString &aGuid, PRBool aOwnsLibrary=PR_TRUE)
 Initializes the media item. More...
 
- Public Member Functions inherited from sbSupportsWeakReference
 sbSupportsWeakReference ()
 
- Public Member Functions inherited from sbILocalDatabaseMediaItem
void SetSuppressNotifications (in boolean aSuppress)
 
- Public Member Functions inherited from sbIMediaItem
void testIsURIAvailable (in nsIObserver aObserver)
 Test if this media item is available for playback. More...
 
nsIChannel openInputStreamAsync (in nsIStreamListener aListener, in nsISupports aContext)
 Asynchronously get an input stream to the content of the media item. More...
 
nsIInputStream openInputStream ()
 Synchronously get an input stream to the content of the media item. More...
 
nsIOutputStream openOutputStream ()
 Get an output stream to the content of the media item. More...
 
AString toString ()
 Get a string representation of the media item, useful for debugging. More...
 
- Public Member Functions inherited from sbILibraryResource
AString getProperty (in AString aID)
 Get the value of a property of this resource. More...
 
void setProperty (in AString aID, in AString aValue)
 Set the value of a property on this resource. More...
 
sbIPropertyArray getProperties ([optional] in sbIPropertyArray aPropertyIDs)
 Get properties from this resource in a property array. More...
 
void setProperties (in sbIPropertyArray aProperties)
 Sets the properties and values in the supplied property array to this resource. This works as if you called setProperty on each property in the array. More...
 
boolean equals (in sbILibraryResource aOtherLibraryResource)
 Tests the equality of two library resources. More...
 
- Public Member Functions inherited from sbLocalDatabaseMediaListListener
 sbLocalDatabaseMediaListListener ()
 
virtual ~sbLocalDatabaseMediaListListener ()
 
- Public Member Functions inherited from sbIMediaList
sbIMediaItem getItemByGuid (in AString aGuid)
 Get a media item in the list by guid. More...
 
sbIMediaItem getItemByIndex (in unsigned long aIndex)
 Get a media item in the list by index. More...
 
unsigned short getListContentType ()
 Get the content type of the media list. More...
 
void enumerateAllItems (in sbIMediaListEnumerationListener aEnumerationListener, [optional] in unsigned short aEnumerationType)
 Enumerate all items in the list. More...
 
void enumerateItemsByProperty (in AString aPropertyID, in AString aPropertyValue, in sbIMediaListEnumerationListener aEnumerationListener, [optional] in unsigned short aEnumerationType)
 Enumerate the media items in the list that match a given property ID and value. More...
 
void enumerateItemsByProperties (in sbIPropertyArray aProperties, in sbIMediaListEnumerationListener aEnumerationListener, [optional] in unsigned short aEnumerationType)
 Enumerate the media items that match a list of property IDs and values. More...
 
nsIArray getItemsByProperty (in AString aPropertyID, in AString aPropertyValue)
 
PRUint32 getItemCountByProperty (in AString aPropertyID, in AString aPropertyValue)
 
nsIArray getItemsByProperties (in sbIPropertyArray aProperties)
 
unsigned long indexOf (in sbIMediaItem aMediaItem, [optional] in unsigned long aStartFrom)
 Get the first index of a media item in the list. More...
 
unsigned long lastIndexOf (in sbIMediaItem aMediaItem, in unsigned long aStartFrom)
 Get the last index of a media item int he list. More...
 
boolean contains (in sbIMediaItem aMediaItem)
 Check if the list contains a media item. More...
 
void add (in sbIMediaItem aMediaItem)
 Add a media item to this list. More...
 
sbIMediaItem addItem (in sbIMediaItem aMediaItem)
 addItem a media item to this list More...
 
void addAll (in sbIMediaList aMediaList)
 Add the contents of a media list to this list. More...
 
void addSome (in nsISimpleEnumerator aMediaItems)
 Adds media items suppled by the provided enumerator NOTE: This method is now deprecated. More...
 
void addMediaItems (in nsISimpleEnumerator aMediaItems, in sbIAddMediaItemsListener aListener, in boolean aAsync)
 Adds media items suppled by the provided enumerator. More...
 
void remove (in sbIMediaItem aMediaItem)
 Remove the first occurrence of the given media item from the list. More...
 
void removeByIndex (in unsigned long aIndex)
 Remove a media item from the list by index. More...
 
void removeSome (in nsISimpleEnumerator aMediaItems)
 Removed media items suppled by the provided enumerator. More...
 
void clear ()
 Clear the list. More...
 
void addListener (in sbIMediaListListener aListener, [optional] in boolean aOwnsWeak, [optional] in unsigned long aFlags, [optional] in sbIPropertyArray aPropertyFilter)
 Add a listener to this media list. More...
 
void removeListener (in sbIMediaListListener aListener)
 Remove a listener from this media list. More...
 
sbIMediaListView createView ([optional] in sbIMediaListViewState aState)
 Create a new, raw view for this list. This is generally not the function that you want to use for making views as it will create a completely raw view, for example lacking any filterConstraint. Please consider using sbLibraryUtils.createStandardMediaListView and proceed carefully if you use this method instead. More...
 
void runInBatchMode (in sbIMediaListBatchCallback aCallback, [optional] in nsISupports aUserData)
 Runs the given callback with the given user data in batch mode. More...
 
nsIStringEnumerator getDistinctValuesForProperty (in AString aPropertyID)
 
- Public Member Functions inherited from sbILibrary
boolean containsItemWithSameIdentity (in sbIMediaItem aMediaItem)
 Checks if another mediaitem with the same identity as aMediaItem is already present in the library. This function can be called on the parent library of aMediaItem and it will only return true if a mediaitem other than the param aMediaItem has the same identity as aMediaItem. More...
 
nsIArray getItemsWithSameIdentity (in sbIMediaItem aMediaItem)
 Find mediaitems in the library that have the same identity as aMediaItem. Returns an empty array if none are found. This function can be called on the parent library of aMediaItem and it will only return a mediaitem other than the param aMediaItem. More...
 
nsIChannel resolve (in nsIURI aUri)
 Resolves a songbird schemed URL to a channel. Throws an exception if the item referenced in the URL is not found. More...
 
sbIMediaItem createMediaItem (in nsIURI aContentUri, [optional] in sbIPropertyArray aProperties, [optional] in boolean aAllowDuplicates)
 Creates a new media item aContentUri The URI pointing to the content of the new media item. Use sbILibraryUtils.getContentURI or getFileContentURI to produce library content URI's. More...
 
boolean createMediaItemIfNotExist (in nsIURI aContentUri, [optional] in sbIPropertyArray aProperties, [optional] out sbIMediaItem aResultItem)
 Create a new media item, disallowing duplicates, and return if it did. More...
 
sbIMediaList createMediaList (in AString aType, [optional] in sbIPropertyArray aProperties)
 Creates a new media list. More...
 
sbIMediaList copyMediaList (in AString aType, in sbIMediaList aSource, in boolean aDontCopyContent)
 Creates a new media list. More...
 
sbIMediaItem getMediaItem (in AString aGuid)
 Get a media item. More...
 
sbIMediaItem getDuplicate (in sbIMediaItem aMediaItem)
 Search for and return a duplicate of the media item specified by aMediaItem. More...
 
void clearItems ()
 Clear all media items (excluding medialists) from the library. More...
 
void clearItemsByType (in AString aContentType)
 Clear items of a certain CONTENT_TYPE (see sbStandardProperties.h). More...
 
void registerMediaListFactory (in sbIMediaListFactory aFactory)
 Register a new media list type at run time. More...
 
void optimize ([optional] in boolean aAnalyzeOnly)
 Called when the library should remove unsupported media list types, unknown property types, temporary items, or otherwise optimize its performance or size. More...
 
void flush ()
 Called when the library should save any cached data to disk. More...
 
nsIArray batchCreateMediaItems (in nsIArray aURIArray, [optional] in nsIArray aPropertyArrayArray, [optional] in boolean aAllowDuplicates)
 Create many media items from a list of URIs, and notify their addition. More...
 
nsIArray batchCreateMediaItemsIfNotExist (in nsIArray aURIArray, [optional] in nsIArray aPropertyArrayArray, [optional] out nsIArray aResultItemArray)
 Create many media items from a list of URIs, disallowing duplicates, and return which items were created. More...
 
void batchCreateMediaItemsAsync (in sbIBatchCreateMediaItemsListener aListener, in nsIArray aURIArray, [optional] in nsIArray aPropertyArrayArray, [optional] in boolean aAllowDuplicates)
 Asychronously create many media items from a list of URIs. More...
 
- Public Member Functions inherited from sbILocalDatabaseLibrary
void addCopyListener (in sbILocalDatabaseLibraryCopyListener aCopyListener)
 Add a copy listener to this library. More...
 
void removeCopyListener (in sbILocalDatabaseLibraryCopyListener aCopyListener)
 Remove a copy listener from this library. More...
 
ACString getContractIdForGuid (in AString aGuid)
 
unsigned long getMediaItemIdForGuid (in AString aGuid)
 
void NotifyListenersItemUpdated (in sbIMediaItem aItem, in sbIPropertyArray aProperties)
 
void notifyCopyListenersItemCopied (in sbIMediaItem aSourceItem, in sbIMediaItem aDestinationItem)
 
sbIDatabaseQuery createQuery ()
 
void forceBeginUpdateBatch ()
 
void forceEndUpdateBatch ()
 
- Public Member Functions inherited from sbILibraryStatistics
nsIArray collectDistinctValues (in AString aProperty, in PRUint32 aCollectionMethod, in AString aOtherProperty, in boolean aAscending, in PRUint32 aMaxResults)
 

Static Public Member Functions

static void GetNowString (nsAString &_retval)
 Make a string of the current time in milliseconds. More...
 

Friends

class sbLibraryInsertingEnumerationListener
 
class sbLibraryRemovingEnumerationListener
 
class sbLocalDatabasePropertyCache
 
class sbBatchCreateTimerCallback
 
class sbBatchCreateHelper
 

Additional Inherited Members

- Public Attributes inherited from sbILocalDatabaseMediaItem
readonly attribute unsigned long mediaItemId
 
attribute
sbILocalDatabaseResourcePropertyBag 
propertyBag
 
- Public Attributes inherited from sbIMediaItem
readonly attribute sbILibrary library
 The library that this media item is contained in. More...
 
readonly attribute boolean isMutable
 Can the media item be changed? More...
 
readonly attribute
sbIMediaItemController 
itemController
 An interface to the media item controller (if any) that determines this item's availability for playback. More...
 
attribute long long mediaCreated
 Creation time of the media item as a unix timestamp. More...
 
attribute long long mediaUpdated
 Last modification time of the media item as a unix timestamp. More...
 
attribute nsIURI contentSrc
 A nsIURI that resolves to the content of the media item. More...
 
attribute long long contentLength
 Size (in bytes) of the content of the media item. More...
 
attribute AString contentType
 Content type of the content of the media item, typically a mime type (should this be renamed?) More...
 
- Public Attributes inherited from sbILibraryResource
readonly attribute AString guid
 The guid of this resource. More...
 
readonly attribute long long created
 The creation time of this resource as a unix timestamp. More...
 
readonly attribute long long updated
 The last update time of this resource as a unix timestamp. More...
 
readonly attribute
nsIStringEnumerator 
propertyIDs
 Returns a string enumerator of the IDs of all the properties set on this resource. More...
 
readonly attribute boolean userEditable
 True if users should be allowed to modify the resource. More...
 
- Public Attributes inherited from sbIMediaList
const unsigned short ENUMERATIONTYPE_SNAPSHOT = 0
 This flag means that the list being enumerated is a copy that may become out of date. More...
 
const unsigned short ENUMERATIONTYPE_LOCKING = 1
 This flag means that the list is protected from changes by other threads during the enumeration. More...
 
const unsigned short CONTENTTYPE_NONE = 0
 These flags specify the contentType of the media list. More...
 
const unsigned short CONTENTTYPE_AUDIO = 1
 
const unsigned short CONTENTTYPE_VIDEO = 2
 
const unsigned short CONTENTTYPE_MIX = 3
 
attribute AString name
 The name of the media list. More...
 
readonly attribute AString type
 The type of media list (eg "simple") More...
 
readonly attribute unsigned long length
 Returns the length of the list. More...
 
readonly attribute boolean isEmpty
 Is the list empty? More...
 
readonly attribute boolean userEditableContent
 True if the user should be allowed to edit the content of this media list. More...
 
const unsigned long LISTENER_FLAGS_ITEMADDED = 1 << 0
 
const unsigned long LISTENER_FLAGS_BEFOREITEMREMOVED = 1 << 1
 
const unsigned long LISTENER_FLAGS_AFTERITEMREMOVED = 1 << 2
 
const unsigned long LISTENER_FLAGS_ITEMUPDATED = 1 << 3
 
const unsigned long LISTENER_FLAGS_BEFORELISTCLEARED = 1 << 4
 
const unsigned long LISTENER_FLAGS_LISTCLEARED = 1 << 5
 
const unsigned long LISTENER_FLAGS_BATCHBEGIN = 1 << 6
 
const unsigned long LISTENER_FLAGS_BATCHEND = 1 << 7
 
const unsigned long LISTENER_FLAGS_ITEMMOVED = 1 << 8
 
const unsigned long LISTENER_FLAGS_ALL = 0xffffffff
 
- Public Attributes inherited from sbILibrary
readonly attribute sbIDevice device
 Reference to the device that this library is stored on. More...
 
readonly attribute boolean supportsForeignMediaItems
 Declares if this library will host foreign media items. More...
 
readonly attribute nsIPropertyBag2 creationParameters
 Holds the parameters with which this library was created. More...
 
readonly attribute
sbILibraryFactory 
factory
 Holds the factory that created this library. More...
 
readonly attribute
nsIStringEnumerator 
mediaListTypes
 A list of available media list types. More...
 
- Public Attributes inherited from sbILocalDatabaseLibrary
readonly attribute AString databaseGuid
 
readonly attribute nsIURI databaseLocation
 Returns the folder in which the database is stored. More...
 
readonly attribute
sbILocalDatabasePropertyCache 
propertyCache
 
readonly attribute
sbLocalDatabaseLibrary 
nativeLibrary
 
- Public Attributes inherited from sbILibraryStatistics
const PRUint32 COLLECT_SUM = 0
 
- Protected Member Functions inherited from sbLocalDatabaseMediaListBase
nsresult MakeStandardQuery (sbIDatabaseQuery **_retval)
 
nsresult GetFilteredPropertiesForNewItem (sbIPropertyArray *aProperties, sbIPropertyArray **_retval)
 
nsresult GetOriginProperties (sbIMediaItem *aSourceItem, sbIMutablePropertyArray *aProperties)
 
void SetArray (sbILocalDatabaseGUIDArray *aArray)
 
- Protected Member Functions inherited from sbSupportsWeakReference
 ~sbSupportsWeakReference ()
 
void ClearWeakReferences ()
 
PRBool HasWeakReferences () const
 
- Protected Member Functions inherited from sbLocalDatabaseMediaListListener
nsresult Init ()
 
nsresult AddListener (sbLocalDatabaseMediaListBase *aList, sbIMediaListListener *aListener, PRBool aOwnsWeak=PR_FALSE, PRUint32 aFlags=sbIMediaList::LISTENER_FLAGS_ALL, sbIPropertyArray *aPropertyFilter=nsnull)
 
nsresult RemoveListener (sbLocalDatabaseMediaListBase *aList, sbIMediaListListener *aListener)
 
PRUint32 ListenerCount ()
 
void NotifyListenersItemAdded (sbIMediaList *aList, sbIMediaItem *aItem, PRUint32 aIndex)
 Notifies all listeners that an item has been added to the list. More...
 
void NotifyListenersBeforeItemRemoved (sbIMediaList *aList, sbIMediaItem *aItem, PRUint32 aIndex)
 Notifies all listeners that an item is about to be removed from the list. More...
 
void NotifyListenersAfterItemRemoved (sbIMediaList *aList, sbIMediaItem *aItem, PRUint32 aIndex)
 Notifies all listeners that an item has been removed from the list. More...
 
void NotifyListenersItemUpdated (sbIMediaList *aList, sbIMediaItem *aItem, sbIPropertyArray *aProperties)
 Notifies all listeners that an item has been updated. More...
 
void NotifyListenersItemMoved (sbIMediaList *aList, PRUint32 aFromIndex, PRUint32 aToIndex)
 Notifies all listeners that an item has been moved. More...
 
void NotifyListenersBeforeListCleared (sbIMediaList *aList, PRBool aExcludeLists)
 Notifies all listeners before the list has been cleared. More...
 
void NotifyListenersListCleared (sbIMediaList *aList, PRBool aExcludeLists)
 Notifies all listeners that the list has been cleared. More...
 
void NotifyListenersBatchBegin (sbIMediaList *aList)
 Notifies all listeners that multiple items are about to be changed. More...
 
void NotifyListenersBatchEnd (sbIMediaList *aList)
 Notifies all listeners that multiple items have been changed. More...
 
- Protected Attributes inherited from sbLocalDatabaseMediaListBase
PRMonitor * mFullArrayMonitor
 
PRUint16 mListContentType
 
PRBool mLockedEnumerationActive
 
nsTHashtable< nsStringHashKey > mFilteredProperties
 
- Protected Attributes inherited from sbLocalDatabaseMediaItem
PRUint32 mMediaItemId
 
PRBool mOwnsLibrary
 
sbLocalDatabaseLibrarymLibrary
 
nsString mGuid
 
PRBool mSuppressNotifications
 
nsCOMPtr< sbIMediaItemControllermItemController
 
PRBool mItemControllerFetched
 

Detailed Description

Definition at line 144 of file sbLocalDatabaseLibrary.h.

Constructor & Destructor Documentation

sbLocalDatabaseLibrary::sbLocalDatabaseLibrary ( )

Definition at line 540 of file sbLocalDatabaseLibrary.cpp.

sbLocalDatabaseLibrary::~sbLocalDatabaseLibrary ( )

Definition at line 553 of file sbLocalDatabaseLibrary.cpp.

Member Function Documentation

NS_IMETHODIMP sbLocalDatabaseLibrary::Add ( sbIMediaItem aMediaItem)

See sbIMediaList

Definition at line 4211 of file sbLocalDatabaseLibrary.cpp.

Here is the call graph for this function:

NS_IMETHODIMP sbLocalDatabaseLibrary::AddAll ( sbIMediaList aMediaList)

See sbIMediaList

Definition at line 4272 of file sbLocalDatabaseLibrary.cpp.

NS_IMETHODIMP sbLocalDatabaseLibrary::AddItem ( sbIMediaItem aMediaItem,
sbIMediaItem **  aNewMediaItem 
)

Definition at line 4217 of file sbLocalDatabaseLibrary.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

NS_IMETHOD sbLocalDatabaseLibrary::AddListener ( sbIMediaListListener aListener,
PRBool  aOwnsWeak,
PRUint32  aFlags,
sbIPropertyArray aPropertyFilter 
)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHODIMP sbLocalDatabaseLibrary::AddMediaItems ( nsISimpleEnumerator aMediaItems,
sbIAddMediaItemsListener aListener,
PRBool  aAsync 
)

See sbIMediaList

Definition at line 4297 of file sbLocalDatabaseLibrary.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

NS_IMETHODIMP sbLocalDatabaseLibrary::AddSome ( nsISimpleEnumerator aMediaItems)

Definition at line 4289 of file sbLocalDatabaseLibrary.cpp.

Here is the call graph for this function:

nsresult sbLocalDatabaseLibrary::AddSomeAsyncInternal ( nsISimpleEnumerator aMediaItems,
sbIAddMediaItemsListener aListener 
)

Definition at line 4366 of file sbLocalDatabaseLibrary.cpp.

NS_IMETHODIMP sbLocalDatabaseLibrary::Clear ( void  )

See sbIMediaList

Definition at line 4520 of file sbLocalDatabaseLibrary.cpp.

NS_IMETHODIMP sbLocalDatabaseLibrary::Contains ( sbIMediaItem aMediaItem,
PRBool *  _retval 
)

See sbIMediaList

Definition at line 4186 of file sbLocalDatabaseLibrary.cpp.

NS_IMETHODIMP sbLocalDatabaseLibrary::CreateView ( sbIMediaListViewState aState,
sbIMediaListView **  _retval 
)

See sbIMediaList

Definition at line 4529 of file sbLocalDatabaseLibrary.cpp.

NS_IMETHOD sbLocalDatabaseLibrary::EnumerateAllItems ( sbIMediaListEnumerationListener aEnumerationListener,
PRUint16  aEnumerationType 
)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::EnumerateItemsByProperties ( sbIPropertyArray aProperties,
sbIMediaListEnumerationListener aEnumerationListener,
PRUint16  aEnumerationType 
)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::EnumerateItemsByProperty ( const nsAString &  aPropertyID,
const nsAString &  aPropertyValue,
sbIMediaListEnumerationListener aEnumerationListener,
PRUint16  aEnumerationType 
)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetContentLength ( PRInt64 *  aContentLength)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetContentSrc ( nsIURI **  aContentSrc)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetContentType ( nsAString &  aContentType)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHODIMP sbLocalDatabaseLibrary::GetDefaultSortProperty ( nsAString &  aProperty)
virtual

See

Implements sbLocalDatabaseMediaListBase.

Definition at line 4554 of file sbLocalDatabaseLibrary.cpp.

NS_IMETHOD sbLocalDatabaseLibrary::GetDistinctValuesForProperty ( const nsAString &  aPropertyID,
nsIStringEnumerator **  _retval 
)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetIsEmpty ( PRBool *  aIsEmpty)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetIsMutable ( PRBool *  aIsMutable)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHODIMP sbLocalDatabaseLibrary::GetItemByGuid ( const nsAString &  aGuid,
sbIMediaItem **  _retval 
)

See sbIMediaList

Definition at line 4167 of file sbLocalDatabaseLibrary.cpp.

NS_IMETHOD sbLocalDatabaseLibrary::GetItemByIndex ( PRUint32  aIndex,
sbIMediaItem **  _retval 
)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetItemController ( sbIMediaItemController **  aMediaItemController)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetItemCountByProperty ( const nsAString &  aPropertyID,
const nsAString &  aPropertyValue,
PRUint32 *  _retval 
)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetItemsByProperties ( sbIPropertyArray aProperties,
nsIArray **  _retval 
)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetItemsByProperty ( const nsAString &  aPropertyID,
const nsAString &  aPropertyValue,
nsIArray **  _retval 
)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetLength ( PRUint32 *  aLength)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

Here is the caller graph for this function:

nsresult sbLocalDatabaseLibrary::GetLengthCache ( sbILocalDatabaseGUIDArrayLengthCache **  aLengthCache)

Definition at line 1993 of file sbLocalDatabaseLibrary.cpp.

Here is the caller graph for this function:

NS_DECL_ISUPPORTS_INHERITED NS_DECL_SBILIBRARY NS_DECL_SBILOCALDATABASELIBRARY NS_DECL_NSICLASSINFO NS_DECL_NSIOBSERVER NS_DECL_SBILIBRARYSTATISTICS NS_IMETHOD sbLocalDatabaseLibrary::GetLibrary ( sbILibrary **  aLibrary)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetListContentType ( PRUint16 *  _retval)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetMediaCreated ( PRInt64 *  aMediaCreated)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetMediaUpdated ( PRInt64 *  aMediaUpdated)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::GetName ( nsAString &  aName)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

void sbLocalDatabaseLibrary::GetNowString ( nsAString &  _retval)
static

Make a string of the current time in milliseconds.

Definition at line 809 of file sbLocalDatabaseLibrary.cpp.

NS_IMETHODIMP sbLocalDatabaseLibrary::GetType ( nsAString &  aType)

See sbIMediaList

Definition at line 4157 of file sbLocalDatabaseLibrary.cpp.

NS_IMETHOD sbLocalDatabaseLibrary::GetUserEditableContent ( PRBool *  aUserEditableContent)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::IndexOf ( sbIMediaItem aMediaItem,
PRUint32  aStartFrom,
PRUint32 *  _retval 
)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

nsresult sbLocalDatabaseLibrary::Init ( const nsAString &  aDatabaseGuid,
nsIPropertyBag2 *  aCreationParameters,
sbILibraryFactory aFactory,
nsIURI *  aDatabaseLocation = nsnull 
)

Definition at line 562 of file sbLocalDatabaseLibrary.cpp.

Here is the call graph for this function:

NS_IMETHOD sbLocalDatabaseLibrary::LastIndexOf ( sbIMediaItem aMediaItem,
PRUint32  aStartFrom,
PRUint32 *  _retval 
)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::OpenInputStream ( nsIInputStream **  _retval)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::OpenInputStreamAsync ( nsIStreamListener *  aListener,
nsISupports aContext,
nsIChannel **  _retval 
)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::OpenOutputStream ( nsIOutputStream **  _retval)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHODIMP sbLocalDatabaseLibrary::Remove ( sbIMediaItem aMediaItem)

See sbIMediaList

Definition at line 4429 of file sbLocalDatabaseLibrary.cpp.

Here is the caller graph for this function:

NS_IMETHODIMP sbLocalDatabaseLibrary::RemoveByIndex ( PRUint32  aIndex)

See sbIMediaList

Definition at line 4456 of file sbLocalDatabaseLibrary.cpp.

Here is the call graph for this function:

NS_IMETHOD sbLocalDatabaseLibrary::RemoveListener ( sbIMediaListListener aListener)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

nsresult sbLocalDatabaseLibrary::RemoveSelected ( nsISimpleEnumerator aSelection,
sbLocalDatabaseMediaListView aView 
)

Bulk removes the selected items specified in aSelection from the view aView.

Definition at line 3895 of file sbLocalDatabaseLibrary.cpp.

Here is the call graph for this function:

NS_IMETHODIMP sbLocalDatabaseLibrary::RemoveSome ( nsISimpleEnumerator aMediaItems)

See sbIMediaList

Definition at line 4480 of file sbLocalDatabaseLibrary.cpp.

NS_IMETHOD sbLocalDatabaseLibrary::RunInBatchMode ( sbIMediaListBatchCallback aCallback,
nsISupports aUserData 
)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::SetContentLength ( PRInt64  aContentLength)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHODIMP sbLocalDatabaseLibrary::SetContentSrc ( nsIURI *  aContentSrc)

See sbIMediaItem

Definition at line 4147 of file sbLocalDatabaseLibrary.cpp.

NS_IMETHOD sbLocalDatabaseLibrary::SetContentType ( const nsAString &  aContentType)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::SetMediaCreated ( PRInt64  aMediaCreated)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::SetMediaUpdated ( PRInt64  aMediaUpdated)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::SetName ( const nsAString &  aName)
inline

Definition at line 231 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::TestIsURIAvailable ( nsIObserver aObserver)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

NS_IMETHOD sbLocalDatabaseLibrary::ToString ( nsAString &  _retval)
inline

Definition at line 230 of file sbLocalDatabaseLibrary.h.

Friends And Related Function Documentation

friend class sbBatchCreateHelper
friend

Definition at line 154 of file sbLocalDatabaseLibrary.h.

friend class sbBatchCreateTimerCallback
friend

Definition at line 153 of file sbLocalDatabaseLibrary.h.

Definition at line 150 of file sbLocalDatabaseLibrary.h.

Definition at line 151 of file sbLocalDatabaseLibrary.h.

friend class sbLocalDatabasePropertyCache
friend

Definition at line 152 of file sbLocalDatabaseLibrary.h.


The documentation for this class was generated from the following files: