sbDefaultBaseDeviceInfoRegistrar Class Reference

#include <sbDefaultBaseDeviceInfoRegistrar.h>

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

Public Member Functions

NS_DECL_SBIDEVICEINFOREGISTRAR sbDefaultBaseDeviceInfoRegistrar ()
 
- Public Member Functions inherited from sbIDeviceInfoRegistrar
void addCapabilities (in sbIDevice aDevice, in sbIDeviceCapabilities aDeviceCapabilities)
 Allows a third party to augment the device capabilities. More...
 
AString getDefaultName (in sbIDevice aDevice)
 Return the default name for the device. More...
 
AString getDeviceFolder (in sbIDevice aDevice, in unsigned long aContentType)
 Return the device folder URL for the device and content type specified by aDevice and aContentType. More...
 
nsIArray getImportRules (in sbIDevice aDevice)
 Return a list of "rules" to apply to files imported from aDevice. Each rule is itself an nsIArray of two nsISupportsStrings: a path and an "import type" of files residing (recursively) within that path. The import type is a symbolic value that determines how to set the media item properties when importing items of that type from aDevice. More...
 
unsigned long getMountTimeout (in sbIDevice aDevice)
 Return the mount timeout value in seconds for the device specified by aDevice. More...
 
AString getExcludedFolders (in sbIDevice aDevice)
 Return the excluded folder list as a comma separate string. More...
 
boolean getDoesDeviceSupportReformat (in sbIDevice aDevice)
 Returns true if the device supports reformat. More...
 
boolean getOnlyMountMediaFolders (in sbIDevice aDevice)
 Return true if only the media folders should be mounted rather than the entire storage volume. More...
 
nsIArray getStorageDeviceInfoList (in sbIDevice aDevice)
 Return the storage device info list as an nsIArray of nsIPropertyBag elements. More...
 
AString getDeviceIcon (in sbIDevice aDevice)
 Return the device icon file URL for the device specified by aDevice. More...
 
boolean interestedInDevice (in sbIDevice aDevice)
 Determines if the registrar is interested in this device. More...
 

Protected Member Functions

nsresult GetDeviceXMLInfo (sbIDevice *aDevice, sbDeviceXMLInfo **aDeviceXMLInfo)
 
nsresult GetDeviceXMLInfo (const nsACString &aDeviceXMLInfoSpec, sbIDevice *aDevice)
 
virtual nsresult GetDeviceXMLInfoSpec (nsACString &aDeviceXMLInfoSpec)
 
virtual nsresult GetDeviceXMLInfoExtensions (nsACString &aDeviceXMLInfoExtensions)
 
virtual nsresult GetDefaultDeviceXMLInfoSpec (nsACString &aDeviceXMLInfoSpec)
 
virtual ~sbDefaultBaseDeviceInfoRegistrar ()
 

Protected Attributes

sbIDevicemDevice
 
nsAutoPtr< sbDeviceXMLInfomDeviceXMLInfo
 
PRBool mDeviceXMLInfoPresent
 

Additional Inherited Members

- Public Attributes inherited from sbIDeviceInfoRegistrar
const PRUint32 NONE = 0
 
const PRUint32 DEFAULT = 1
 
const PRUint32 GENERIC = 2
 
const PRUint32 DEVICE_SPECIFIC = 3
 
readonly attribute PRUint32 type
 

Detailed Description

This is a base class for implementing a default info registrar for a device.

Definition at line 45 of file sbDefaultBaseDeviceInfoRegistrar.h.

Constructor & Destructor Documentation

sbDefaultBaseDeviceInfoRegistrar::sbDefaultBaseDeviceInfoRegistrar ( )

Definition at line 67 of file sbDefaultBaseDeviceInfoRegistrar.cpp.

sbDefaultBaseDeviceInfoRegistrar::~sbDefaultBaseDeviceInfoRegistrar ( )
protectedvirtual

Definition at line 78 of file sbDefaultBaseDeviceInfoRegistrar.cpp.

Member Function Documentation

nsresult sbDefaultBaseDeviceInfoRegistrar::GetDefaultDeviceXMLInfoSpec ( nsACString &  aDeviceXMLInfoSpec)
protectedvirtual

Return in aDeviceXMLInfoSpec the URI spec for the default device XML info document. If no matching device info is found in the main device XML info document, the device info in the default document is used. Typically, the default device XML info document matches all devices.

Parameters
aDeviceXMLInfoSpecDefault device XML info document URI spec.

Definition at line 511 of file sbDefaultBaseDeviceInfoRegistrar.cpp.

nsresult sbDefaultBaseDeviceInfoRegistrar::GetDeviceXMLInfo ( sbIDevice aDevice,
sbDeviceXMLInfo **  aDeviceXMLInfo 
)
protected

Return in aDeviceXMLInfo the device XML info for the device specified by aDevice. If no device XML info is available, return null in aDeviceXMLInfo.

Parameters
aDeviceDevice for which to get info.
aDeviceXMLInfoReturned device XML info.

Definition at line 419 of file sbDefaultBaseDeviceInfoRegistrar.cpp.

nsresult sbDefaultBaseDeviceInfoRegistrar::GetDeviceXMLInfo ( const nsACString &  aDeviceXMLInfoSpec,
sbIDevice aDevice 
)
protected

Read the device XML info document with the URI spec specified by aDeviceXMLInfoSpec for the device specified by aDevice.

Parameters
aDeviceXMLInfoSpecDevice XML info document URI spec.
aDeviceDevice for which to get info.

Definition at line 469 of file sbDefaultBaseDeviceInfoRegistrar.cpp.

nsresult sbDefaultBaseDeviceInfoRegistrar::GetDeviceXMLInfoExtensions ( nsACString &  aDeviceXMLInfoExtensions)
protectedvirtual

Return in aDeviceXMLInfoExtensions a space-delimited list of file extensions (without dots) to scan for when searching a directory for device XML info files. Directories are not scanned if this string is empty

Parameters
aDeviceXMLInfoExtensionsReturns a space-delimited list of extensions

Definition at line 503 of file sbDefaultBaseDeviceInfoRegistrar.cpp.

nsresult sbDefaultBaseDeviceInfoRegistrar::GetDeviceXMLInfoSpec ( nsACString &  aDeviceXMLInfoSpec)
protectedvirtual

Return in aDeviceXMLInfoSpec the URI spec for the device XML info document.

Parameters
aDeviceXMLInfoSpecDevice XML info document URI spec.

Definition at line 495 of file sbDefaultBaseDeviceInfoRegistrar.cpp.

Member Data Documentation

sbIDevice* sbDefaultBaseDeviceInfoRegistrar::mDevice
protected

Definition at line 61 of file sbDefaultBaseDeviceInfoRegistrar.h.

nsAutoPtr<sbDeviceXMLInfo> sbDefaultBaseDeviceInfoRegistrar::mDeviceXMLInfo
protected

Definition at line 62 of file sbDefaultBaseDeviceInfoRegistrar.h.

PRBool sbDefaultBaseDeviceInfoRegistrar::mDeviceXMLInfoPresent
protected

Definition at line 63 of file sbDefaultBaseDeviceInfoRegistrar.h.


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