nsIUpdateItem 编辑
toolkit/mozapps/extensions/public/nsIExtensionManager.idl
Scriptable Describes an item managed by the extension system, providing metadata describing the item. 1.0 66 Introduced Gecko 1.8 Obsolete Gecko 2.0 Inherits from: nsISupports
Last changed in Gecko 2.0 (Firefox 4 / Thunderbird 3.3 / SeaMonkey 2.1) This interface is obsolete; instead of using the Extension Manager, you should use the Addon Manager.Method overview
void init(in AString id, in AString version, in AString installLocationKey, in AString minAppVersion, in AString maxAppVersion, in AString name, in AString downloadURL, in AString xpiHash, in AString iconURL, in AString updateURL, in AString updateKey, in long type, in AString targetAppID); |
Attributes
Attribute | Type | Description |
iconURL | AString | The URL of the icon that can be shown for this item. Read only. |
id | AString | The GUID of the item. Read only. |
installLocationKey | AString | The name of the Install Location where this item is installed. Read only. |
maxAppVersion | AString | The maximum version of the application that this item works with, in FVF format. Read only. |
minAppVersion | AString | The minimum version of the application that this item works with, in FVF format. Read only. |
name | AString | The name of this item. Read only. |
objectSource | AString | Returns a JS Object source representing an nsIUpdateItem . Read only. |
targetAppID | AString | The target application id of toolkit@mozilla.org in their install manifest for compatibility with all apps using a specific release of the toolkit. Read only. |
type | long | The type of this item. Read only. |
updateKey | AString | The public key to verify updates for this item. This must be the public part of the key that was used to sign update manifests for this add-on. Read only. |
updateRDF | AString | The URL of the update RDF file for this item. Read only. |
version | AString | The Version of the item, in FVF format. Read only. |
xpiHash | AString | The string Hash for the XPI file. Can be null and if supplied must be in the format of "type :hash" (see the types in nsICryptoHash and nsIXPInstallManager.initManagerWithHashes() . Read only. |
xpiURL | AString | The URL of the XPI where this item can be downloaded. Read only. |
Constants
Item type constants
Constants representing types of update checks. Constants that callers can use to indicate the reason for an add-on update check. Internal code uses other constants in nsExtensionManager.js.in.
Constant | Gecko version | Description | ||||
1.8 | 1.8.1 | 1.9 | 1.9.1 | 1.9.2 | ||
TYPE_APP | 0x01 | |||||
TYPE_EXTENSION | 0x02 | |||||
TYPE_THEME | 0x04 | |||||
TYPE_LOCALE | 0x08 | |||||
TYPE_MULTI_XPI | 0x20 | |||||
TYPE_ADDON | TYPE_EXTENSION + TYPE_THEME + TYPE_LOCALE + TYPE_PLUGIN | TYPE_EXTENSION + TYPE_THEME + TYPE_LOCALE | ||||
TYPE_ANY | TYPE_APP + TYPE_ADDON | 0xff | ||||
TYPE_PLUGIN | 0x10 |
Methods
init()
Initializes the object.
void init( in AString id, in AString version, in AString installLocationKey, in AString minAppVersion, in AString maxAppVersion, in AString name, in AString downloadURL, in AString xpiHash, in AString iconURL, in AString updateURL, in AString updateKey, in long type, in AString targetAppID );
Parameters
id
- The item's GUID.
version
- The item's version.
installLocationKey
- The name of the install location at which the item is installed.
minAppVersion
- The minimum application version with which the item is compatible.
maxAppVersion
- The maximum application version with which the item is compatible.
name
- The item's name
downloadURL
- The URL from which the item is to be downloaded.
xpiHash
- The string hash for the XPI file.
iconURL
- The URL of the icon that can be shown for the item.
updateURL
- The URL of the update RDF for the item.
updateKey
- The public key to use to verify updates for the item.
type
- The type of item; see Item type constants.
targetAppID
- The application ID of the target application.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论