27 #include "nsISupports.idl"
37 [scriptable,
uuid(7b86a6fc-a9d4-4ef9-90e3-3334e58cc3d6)]
46 readonly attribute AString
id;
53 readonly attribute AString
name;
69 [scriptable,
uuid(16814f07-373a-404a-a31b-73ca83cb3c96)]
78 in AString aFromUnitID,
81 in
long aMaxDecimals);
106 in
long aMinDecimals,
107 in
long aMaxDecimals);
readonly attribute AString name
The full name of the unit, ie. Kilobyte. This is a localized string, ie. a partial entity such as "&m...
Property unit interface This interface describes a property unit.
attribute sbIPropertyInfo propertyInfo
The sbIPropertyInfo this converter is associated with. This attribute will be set automatically by th...
readonly attribute AString nativeUnitId
The native unit for this property. This is the unit used for storage in the database, and that is implied when getting and setting the property.
readonly attribute AString shortName
The short name of the unit, ie. kB. This is a localized string, ie. a partial entity such as "&my...
AString convert(in AString aValue, in AString aFromUnitID, in AString aToUnitID, in long aMinDecimals, in long aMaxDecimals)
Convert a value to a different unit. Use -1 for aMinDecimals and aMaxDecimals if you do not wish to s...
readonly attribute AString id
The id of the unit. This string is not localized and is used in calls to sbIPropertyUnitConverter's c...
An interface used to describe a metadata property for use by the UI and other sbILibrary interfaces (...
readonly attribute AString stringBundle
The url to the string bundle used to localize partial entities.
Property unit converter interface This is an interface songbird property converter, used to convert a property value between its various units representations.
AString autoFormat(in AString aValue, in long aMinDecimals, in long aMaxDecimals)
Formats a value using the most suitable unit. Use -1 for aMinDecimals and aMaxDecimals if you do not ...
readonly attribute nsISimpleEnumerator units
The list of available units for this property.