import "sbIAlbumArtService.idl";
Public Member Functions | |
nsIArray | getFetcherList (in unsigned long type) |
boolean | imageIsValidAlbumArt (in AUTF8String aMimeType,[const, array, size_is(aDataLen)] in octet aData, in unsigned long aDataLen) |
Determine whether the image specified by aData and aDataLen of type specified by aMimeType is a valid album art image. Return true if so. | |
nsIFileURL | cacheImage (in AUTF8String aMimeType,[const, array, size_is(aDataLen)] in octet aData, in unsigned long aDataLen) |
Write the album art image specified by aData and aDataLen of type specified by aMimeType to a cache file and return the cache file URL. | |
void | cacheTemporaryData (in AString aKey, in nsISupports aData) |
Add arbitrary data to a temporary cache. | |
nsISupports | retrieveTemporaryData (in AString aKey) |
Get data previously placed into the temporary cache. |
"@songbirdnest.com/Songbird/album-art-service;1"
Definition at line 51 of file sbIAlbumArtService.idl.
nsIArray sbIAlbumArtService::getFetcherList | ( | in unsigned long | type | ) |
Return a list of album art fetcher contract ID's as an array of nsIVariant ACStrings. Use type to specify if local, remote, or all fetchers.
type | sbIAlbumArtFetcherSet.TYPE_LOCAL, etc. |
boolean sbIAlbumArtService::imageIsValidAlbumArt | ( | in AUTF8String | aMimeType, | |
[const, array, size_is(aDataLen)] in octet | aData, | |||
in unsigned long | aDataLen | |||
) |
Determine whether the image specified by aData and aDataLen of type specified by aMimeType is a valid album art image. Return true if so.
aMimeType | MIME type of image data. | |
aData | Album art image data. | |
aDataLen | Length in bytes of image data. |
nsIFileURL sbIAlbumArtService::cacheImage | ( | in AUTF8String | aMimeType, | |
[const, array, size_is(aDataLen)] in octet | aData, | |||
in unsigned long | aDataLen | |||
) |
Write the album art image specified by aData and aDataLen of type specified by aMimeType to a cache file and return the cache file URL.
aMimeType | MIME type of image data. | |
aData | Album art image data. | |
aDataLen | Length in bytes of image data. |
void sbIAlbumArtService::cacheTemporaryData | ( | in AString | aKey, | |
in nsISupports | aData | |||
) |
Add arbitrary data to a temporary cache.
Used by art fetchers to cache intermediate results for a short period of time. Allows fetchers to avoid additional work without keeping their own static cache.
Note: The contents of this cache is flushed periodically
aKey | Hash key | |
aData | Arbitrary data to store. |
nsISupports sbIAlbumArtService::retrieveTemporaryData | ( | in AString | aKey | ) |
Get data previously placed into the temporary cache.
aKey | Hash key |
NS_ERROR_NOT_AVAILABLE | if the key is not found |