Difference between revisions of "Zh/Documentation/DevGuide/Extensions/Description of XML Elements"
m |
m (→<code>/description/update-information</code> 元素) |
||
(33 intermediate revisions by the same user not shown) | |||
Line 11: | Line 11: | ||
==== <code>/description</code> 元素==== | ==== <code>/description</code> 元素==== | ||
− | * 父元素: | + | * 父元素: 文件根 |
* 子元素: | * 子元素: | ||
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/identifier 元素|<identifier>]]</code> |
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/version 元素|<version>]]</code> |
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/platform 元素|<platform>]]</code> |
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/registration 元素|<registration>]]</code> |
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/dependencies 元素|<dependencies>]]</code> |
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/update-information 元素|<update-information>]]</code> |
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/publisher|<publisher>]]</code> |
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/release-notes 元素|<release-notes>]]</code> |
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/display-name 元素|<display-name>]]</code> |
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/icon 元素|<icon>]]</code> |
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/extension-description 元素|<extension-description>]]</code> |
*始用于:OOo 2.0.4 | *始用于:OOo 2.0.4 | ||
<code><description></code> 是 ''description.xml'' 的根元素。 | <code><description></code> 是 ''description.xml'' 的根元素。 | ||
− | |||
{|border="1" cellpadding=4 style="border-collapse:collapse;" | {|border="1" cellpadding=4 style="border-collapse:collapse;" | ||
Line 51: | Line 50: | ||
==== <code>/description/identifier</code> 元素 ==== | ==== <code>/description/identifier</code> 元素 ==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description 元素|<description>]]</code> |
* 子元素: 无 | * 子元素: 无 | ||
*始用于:OOo 2.2 | *始用于:OOo 2.2 | ||
− | |||
{|border="1" cellpadding=4 style="border-collapse:collapse;" | {|border="1" cellpadding=4 style="border-collapse:collapse;" | ||
Line 65: | Line 63: | ||
|必需。扩展标识符。 | |必需。扩展标识符。 | ||
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
Line 74: | Line 71: | ||
==== <code>/description/version</code> 元素==== | ==== <code>/description/version</code> 元素==== | ||
− | *父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | *父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description 元素|<description>]]</code> |
*子元素: 无 | *子元素: 无 | ||
*始用于: OOo 2.1 | *始用于: OOo 2.1 | ||
− | |||
{|border="1" cellpadding=4 style="border-collapse:collapse;" | {|border="1" cellpadding=4 style="border-collapse:collapse;" | ||
Line 88: | Line 84: | ||
|必需。扩展版本的文字表现形式。 | |必需。扩展版本的文字表现形式。 | ||
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
Line 97: | Line 92: | ||
==== <code>/description/platform</code> 元素==== | ==== <code>/description/platform</code> 元素==== | ||
− | *父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | *父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description 元素|<description>]]</code> |
*子元素: 无 | *子元素: 无 | ||
*始用于: OOo 3.0 | *始用于: OOo 3.0 | ||
− | |||
{|border="1" cellpadding=4 style="border-collapse:collapse;" | {|border="1" cellpadding=4 style="border-collapse:collapse;" | ||
Line 111: | Line 105: | ||
|必需。为表示特定平台的符号。详见 [[Zh/Documentation/DevGuide/Extensions/Target Platform|目标平台]]。 | |必需。为表示特定平台的符号。详见 [[Zh/Documentation/DevGuide/Extensions/Target Platform|目标平台]]。 | ||
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
Line 120: | Line 113: | ||
==== <code>/description/registration</code> 元素 ==== | ==== <code>/description/registration</code> 元素 ==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description 元素|<description>]]</code> |
* 子元素: | * 子元素: | ||
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/registration/simple-license 元素|<simple-license>]]</code> |
* 始用于:OOo 2.0.4 | * 始用于:OOo 2.0.4 | ||
Line 134: | Line 127: | ||
==== <code>/description/registration/simple-license</code> 元素==== | ==== <code>/description/registration/simple-license</code> 元素==== | ||
− | 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/registration 元素|<registration>]]</code> |
* 子元素: | * 子元素: | ||
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/registration/simple-license/license-text 元素|<license-text>]]</code> |
* 始用于: OOo 2.0.4 | * 始用于: OOo 2.0.4 | ||
− | 这个元素包含 <code><license-text></code> | + | 这个元素包含 <code><license-text></code> 元素,验证是否所有用户接收这个授权许可对,或只是安装者接收此授权许可对,并且验证默认的 <code><license-text></code> 元素。检验 “默认" 的机制在 OOo 2.4 版本做了变更。详见 [[Zh/Documentation/DevGuide/Extensions/Localized XML Elements|本地化 XML 元素]]。 |
− | + | ||
如果 <code><simple-license></code> 元素存在的话,那么它必需包含至少一个子元素。 | 如果 <code><simple-license></code> 元素存在的话,那么它必需包含至少一个子元素。 | ||
Line 151: | Line 143: | ||
|- | |- | ||
|<code>accept-by</code> | |<code>accept-by</code> | ||
− | |<code> | + | |必需。<code>Value</code> 可以是 “user” 或 “admin”。“user” 意味着每个用户必需接受此授权许可对。也就是说,此扩展只能被安装为用户扩展而非共享扩展。如果值为 “admin”,那么扩展才可以被部署为共享扩展。在那种情况下只有安装者才必需接受授权许可对。不需要询问每个用户去接受此授权许可对。他们可以直接使用此扩展。在值为 “user” 时扩展被安装成用户扩展,那么用户都会被询问是否接受此授权许可对。 |
|- | |- | ||
|<code>default-license-id</code> | |<code>default-license-id</code> | ||
− | | | + | |必需。自 OOo 2.4 版本起,此属性被认为是'''陈旧'''属性。如果扩展需要正确地在 2.4 之前的版本上运行的话(在安装过程中显示正确的授权许可)就必需使用这个属性。如果不使用这个属性那么就应该使用 [[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/dependencies/OpenOffice.org-minimal-version 元素|OpenOffice.org-minimal-version]] 值为 '2.4' 的依赖关系。 |
− | + | ||
+ | 这个属性确定如果没有一个 <license-text> 元素的 lang 属性值可以与 {{PRODUCTNAME}} 的安装地域相匹配时使用什么 <license-text>。任何时候只有一个带 ''license-id'' 属性的 <code><license-text></code> 元素。''license-id'' 值与 ''default-license-id'' 相匹配,类型为 <code>xsd:IDREF</code>。 | ||
|- | |- | ||
|<code>suppress-on-update</code> | |<code>suppress-on-update</code> | ||
− | | | + | |可选。当没有提供此属性时此属性值为假设为 “false”。值为 “true” 时表示的是当相同扩展已经安装(相同 id 但可能不同版本)的情况下,此扩展的协议在安装过程中不会再被显示。这同样也作用于自动更新和手动安装扩展。它并不关心已安装扩展的版本。在线升级时排除授权许可对相当有用,因为不那样的话更新操作可能会被许许多多的授权许可对话框中断。 |
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
Line 168: | Line 160: | ||
==== <code>/description/registration/simple-license/license-text</code> 元素==== | ==== <code>/description/registration/simple-license/license-text</code> 元素==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | |
+ | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/registration/simple-license 元素|<simple-license>]]</code> | ||
* 子元素: 无 | * 子元素: 无 | ||
* 始用于: OOo 2.0.4 | * 始用于: OOo 2.0.4 | ||
− | + | 此元素包含以下信息:授权许可文件的位置、使用何种语言和这个元素是否是 “默认"的 <code><license-text></code>。检验 “默认" 的机制在 OOo 2.4 版本做了变更。详见[[Zh/Documentation/DevGuide/Extensions/Localized XML Elements|本地化 XML 元素]]。 | |
− | + | ||
{|border="1" cellpadding=4 style="border-collapse:collapse;" | {|border="1" cellpadding=4 style="border-collapse:collapse;" | ||
Line 182: | Line 174: | ||
|- | |- | ||
|<code>xlink:href</code> | |<code>xlink:href</code> | ||
− | |Required. | + | |Required.必需。值为该扩展授权许可文件对应的 URL。 |
|- | |- | ||
|<code>lang</code> | |<code>lang</code> | ||
− | | | + | |必需。遵循 RFC 3066 标准的语言标识。详见 [[Zh/Documentation/DevGuide/Extensions/Localized XML Elements|本地化 XML 元素]]。 |
|- | |- | ||
|<code>license-id</code> | |<code>license-id</code> | ||
− | | | + | |必需。自 OOo 2.4 版本起,此属性被认为是'''陈旧'''属性。如果扩展需要正确地在 2.4 之前的版本上运行的话(在安装过程中显示正确的授权许可)就必需使用这个属性。如果不使用这个属性那么就应该使用 [[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/dependencies/OpenOffice.org-minimal-version 元素|OpenOffice.org-minimal-version]] 值为 '2.4' 的依赖关系。 |
− | + | 一个 license-text 元素必需有这个属性并且属性值必需与 <code><simple-license></code> 元素的 default-license-id 的值相匹配。值类型为 <code>xsd:ID</code>。 | |
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
*[[Zh/Documentation/DevGuide/Extensions/Simple License|Simple License]] | *[[Zh/Documentation/DevGuide/Extensions/Simple License|Simple License]] | ||
− | *[[Zh/Documentation/DevGuide/Extensions/Example| | + | *[[Zh/Documentation/DevGuide/Extensions/Example|description.xml 示例]] |
+ | ==== <code>/description/dependencies</code> 元素==== | ||
− | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description 元素|<description>]]</code> | |
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | |
* 子元素: | * 子元素: | ||
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/dependencies/OpenOffice.org-minimal-version 元素|<OpenOffice.org-minimal-version>]]</code> |
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/dependencies/OpenOffice.org-maximal-version 元素|<OpenOffice.org-maximal-version>]]</code> |
** 其他 | ** 其他 | ||
* 始用于: OOo 2.0.4 | * 始用于: OOo 2.0.4 | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
Line 214: | Line 204: | ||
==== <code>/description/dependencies/OpenOffice.org-minimal-version</code> 元素 ==== | ==== <code>/description/dependencies/OpenOffice.org-minimal-version</code> 元素 ==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | |
+ | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/dependencies 元素|<dependencies>]]</code> | ||
* 子元素: 无 | * 子元素: 无 | ||
* 始用于: OOo 2.1 | * 始用于: OOo 2.1 | ||
− | |||
{|border="1" cellpadding=4 style="border-collapse:collapse;" | {|border="1" cellpadding=4 style="border-collapse:collapse;" | ||
Line 226: | Line 216: | ||
|- | |- | ||
|<code>xmlns:dep</code> | |<code>xmlns:dep</code> | ||
− | | | + | |此 namespace 用于依赖关系信息(继承自 <code><description></code>)根据 http://openoffice.org/extensions/description/2006 定义。 |
− | http://openoffice.org/extensions/description/2006 | + | |
|- | |- | ||
|<code>dep:name</code> | |<code>dep:name</code> | ||
− | | | + | |必需。字符串 “OpenOffice.org ''value''” (这里 ''value'' 的值为属性 '''value''' 的值)。 |
|- | |- | ||
|<code>dep:OpenOffice.org-minimal-version</code> | |<code>dep:OpenOffice.org-minimal-version</code> | ||
− | | | + | |可选。在这个元素里此属性应该永远不会被用到。 |
|- | |- | ||
− | |<code>value</code> | + | |'''<code>value</code>''' |
− | | | + | |必需。OpenOffice.org 的基本版本需求(“2.1”、“2.2”、等等),由 OpenOffice.org 2.1 开始。 |
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
*[[Zh/Documentation/DevGuide/Extensions/Dependencies|依赖关系]] | *[[Zh/Documentation/DevGuide/Extensions/Dependencies|依赖关系]] | ||
− | *[[Zh/Documentation/DevGuide/Extensions/Example| | + | *[[Zh/Documentation/DevGuide/Extensions/Example|description.xml 示例]] |
==== <code>/description/dependencies/OpenOffice.org-maximal-version</code> 元素 ==== | ==== <code>/description/dependencies/OpenOffice.org-maximal-version</code> 元素 ==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/dependencies 元素|<dependencies>]]</code> |
* 子元素: 无 | * 子元素: 无 | ||
* 始用于: OOo 3.1 | * 始用于: OOo 3.1 | ||
− | |||
{|border="1" cellpadding=4 style="border-collapse:collapse;" | {|border="1" cellpadding=4 style="border-collapse:collapse;" | ||
Line 259: | Line 246: | ||
|- | |- | ||
|<code>xmlns:dep</code> | |<code>xmlns:dep</code> | ||
− | | | + | |此 namespace 用于依赖关系信息(继承自 <code><description></code>)根据 http://openoffice.org/extensions/description/2006 定义。 |
− | http://openoffice.org/extensions/description/2006 | + | |
|- | |- | ||
|<code>dep:name</code> | |<code>dep:name</code> | ||
− | | | + | |必需。字符串 “OpenOffice.org ''value''”(这里 ''value'' 的值为属性 '''value''' 的值)。 |
|- | |- | ||
|<code>dep:OpenOffice.org-minimal-version</code> | |<code>dep:OpenOffice.org-minimal-version</code> | ||
− | | | + | |可选。在这个元素中的这个属性值总是被定义为 “2.3”。 |
|- | |- | ||
− | |<code>value</code> | + | |'''<code>value</code>''' |
− | | | + | |必需。可运行的 OpenOffice.org 的最高版本(“3.0”、“3.2”、等等)。 |
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
Line 279: | Line 264: | ||
==== <code>/description/update-information</code> 元素 ==== | ==== <code>/description/update-information</code> 元素 ==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description 元素|<description>]]</code> |
* 子元素: | * 子元素: | ||
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/update-information/src 元素|<src>]]</code> |
* 始用于: OOo 2.2 | * 始用于: OOo 2.2 | ||
− | <code><update-information></code> | + | <code><update-information></code> 必需至少有一个 <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/update-information/src 元素|<src>]]</code> 子元素。第二个、第三个或更多元素被看作备用,也可以说这些元素提供镜像的 URL。扩展管理器会尝试使用一个 URL 来获取更新信息,只有在出错的情况下才会使用另外一个 URL。例如如果的第一个 URL 引用了一个不包含任何引用信息但却是个合法的 ATOM Feed,那么扩展管理器就会假设没有更新。而其他 <code><src></code> 元素就不会在检查了。因此,每个 URL 引用的更新信息都必需一致。 |
'''也请参阅''' | '''也请参阅''' | ||
− | *[[Zh/Documentation/DevGuide/Extensions/Online Update of Extensions| | + | *[[Zh/Documentation/DevGuide/Extensions/Online Update of Extensions|扩展的在线更新]] |
*[[Zh/Documentation/DevGuide/Extensions/Example|description.xml 示例]] | *[[Zh/Documentation/DevGuide/Extensions/Example|description.xml 示例]] | ||
− | |||
==== <code>/description/update-information/src</code> 元素 ==== | ==== <code>/description/update-information/src</code> 元素 ==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/update-information 元素|<update-information>]]</code> |
* 子元素: 无 | * 子元素: 无 | ||
* 始用于: OOo 2.2 | * 始用于: OOo 2.2 | ||
− | |||
{|border="1" cellpadding=4 style="border-collapse:collapse;" | {|border="1" cellpadding=4 style="border-collapse:collapse;" | ||
Line 305: | Line 288: | ||
|- | |- | ||
|<code>xlink:href</code> | |<code>xlink:href</code> | ||
− | | | + | |必需。此值为 提供更新信息的 URL 或是一个引用更新信息的 ATOM Feed。此 URL 可以直接指向一个文件或调用代码,比如调用 servlet或cgi等等来返回 ATOM Feed 或者更新信息。 |
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
Line 316: | Line 298: | ||
==== <code>/description/publisher</code> 元素 ==== | ==== <code>/description/publisher</code> 元素 ==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description 元素|<description>]]</code> |
* 子元素: | * 子元素: | ||
− | **<code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | **<code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/publisher/name 元素|<name>]]</code> |
* 始用于: OOo 2.4 | * 始用于: OOo 2.4 | ||
− | <code><publisher></code> | + | <code><publisher></code> 必需至少有一个 <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/publisher/name 元素|<name>]]</code> 子元素。这个元素的子元素提供一个 [[Zh/Documentation/DevGuide/Extensions/Localized XML Elements|本地化 XML 元素]] 的 URL。 |
− | + | ||
'''也请参阅''' | '''也请参阅''' | ||
Line 331: | Line 312: | ||
==== <code>/description/publisher/name</code> 元素==== | ==== <code>/description/publisher/name</code> 元素==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/publisher 元素|<publisher>]]</code> |
* 子元素: Text | * 子元素: Text | ||
* 始用于: OOo 2.4 | * 始用于: OOo 2.4 | ||
− | |||
The text value of this element is the ''publisher name''. | The text value of this element is the ''publisher name''. | ||
Line 345: | Line 325: | ||
|- | |- | ||
|<code>xlink:href</code> | |<code>xlink:href</code> | ||
− | | | + | |必需。值为扩展中发行者的 Web 站点的 URL。 |
|- | |- | ||
|<code>lang</code> | |<code>lang</code> | ||
− | | | + | |必需。遵循 RFC 3066 标准的语言标识。详见 [[Zh/Documentation/DevGuide/Extensions/Localized XML Elements|本地化 XML 元素]]。 |
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
Line 358: | Line 337: | ||
==== <code>/description/release-notes</code> 元素 ==== | ==== <code>/description/release-notes</code> 元素 ==== | ||
− | * 父元素: <code>[[Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Documentation/DevGuide/Extensions/Description of XML Elements#/description 元素|<description>]]</code> |
* 子元素: | * 子元素: | ||
− | **<code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | **<code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/release-notes/src 元素|<src>]]</code> |
* 始用于: OOo 2.4 | * 始用于: OOo 2.4 | ||
− | <code><release-notes></code> | + | <code><release-notes></code> 必需至少有一个 <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/release-notes/src 元素|<src>]]</code> 子元素。此子元素提供 [[Zh/Documentation/DevGuide/Extensions/Localized XML Elements|本地化 release-notes]] 的 URLs。 |
− | + | 当前此元素和其子元素还没有被用于扩展管理器。 | |
'''也请参阅''' | '''也请参阅''' | ||
Line 372: | Line 351: | ||
==== <code>/description/release-notes/src</code> 元素==== | ==== <code>/description/release-notes/src</code> 元素==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | |
+ | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/release-notes 元素|<release-notes>]]</code> | ||
* 子元素: none | * 子元素: none | ||
* 始用于: OOo 2.4 | * 始用于: OOo 2.4 | ||
Line 385: | Line 365: | ||
|- | |- | ||
|<code>xlink:href</code> | |<code>xlink:href</code> | ||
− | | | + | |必需。值为扩展中发行注释的 URL。 |
|- | |- | ||
|<code>lang</code> | |<code>lang</code> | ||
− | | | + | |必需。遵循 RFC 3066 标准的语言标识。详见 [[Zh/Documentation/DevGuide/Extensions/Localized XML Elements|本地化 XML 元素]]。 |
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
*[[Zh/Documentation/DevGuide/Extensions/Example|description.xml 示例]] | *[[Zh/Documentation/DevGuide/Extensions/Example|description.xml 示例]] | ||
− | |||
==== <code>/description/display-name</code> 元素 ==== | ==== <code>/description/display-name</code> 元素 ==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description 元素|<description>]]</code> |
* 子元素: | * 子元素: | ||
− | **<code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | **<code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/display-name/name 元素|<name>]]</code> |
* 始用于: OOo 2.4 | * 始用于: OOo 2.4 | ||
− | <code><display-name></code> 必须至少有一个 <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | <code><display-name></code> 必须至少有一个 <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/display-name/name 元素|<name>]]</code> 子元素。这个元素的子元素提供一个 [[Zh/Documentation/DevGuide/Extensions/Localized XML Elements|本地化的显示名称]]。这个名称将会用在用户图形界面上来替换文件的名称。 |
'''也请参阅''' | '''也请参阅''' | ||
Line 412: | Line 390: | ||
==== <code>/description/display-name/name</code> 元素 ==== | ==== <code>/description/display-name/name</code> 元素 ==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/display-name 元素|<display-name>]]</code> |
* 子元素: Text | * 子元素: Text | ||
* 始用于: OOo 2.4 | * 始用于: OOo 2.4 | ||
Line 425: | Line 403: | ||
|- | |- | ||
|<code>lang</code> | |<code>lang</code> | ||
− | | | + | |必需。遵循 RFC 3066 标准的语言标识。详见 [[Zh/Documentation/DevGuide/Extensions/Localized XML Elements|本地化 XML 元素]]。 |
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
*[[Zh/Documentation/DevGuide/Extensions/Display Name|显示名称]] | *[[Zh/Documentation/DevGuide/Extensions/Display Name|显示名称]] | ||
*[[Zh/Documentation/DevGuide/Extensions/Example|description.xml 示例]] | *[[Zh/Documentation/DevGuide/Extensions/Example|description.xml 示例]] | ||
− | |||
==== <code>/description/icon</code> 元素 ==== | ==== <code>/description/icon</code> 元素 ==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description 元素|<description>]]</code> |
* 子元素: | * 子元素: | ||
− | **<code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | **<code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/icon/default 元素|<default>]]</code> |
− | **<code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | **<code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/icon/high-contrast 元素|<high-contrast>]]</code> |
* 始用于: OOo 3.0 | * 始用于: OOo 3.0 | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
Line 450: | Line 425: | ||
==== <code>/description/icon/default</code> 元素 ==== | ==== <code>/description/icon/default</code> 元素 ==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/icon 元素|<icon>]]</code> |
* 子元素: 无 | * 子元素: 无 | ||
* 始用于: OOo 3.0 | * 始用于: OOo 3.0 | ||
Line 463: | Line 438: | ||
|值为扩展中图标文件对应的 URL。 | |值为扩展中图标文件对应的 URL。 | ||
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
Line 471: | Line 445: | ||
==== <code>/description/icon/high-contrast</code> 元素==== | ==== <code>/description/icon/high-contrast</code> 元素==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/icon 元素|<icon>]]</code> |
* 子元素: 无 | * 子元素: 无 | ||
* 始用于: OOo 3.0 | * 始用于: OOo 3.0 | ||
Line 484: | Line 458: | ||
|值为扩展中图标文件对应的 URL。 | |值为扩展中图标文件对应的 URL。 | ||
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' | ||
Line 490: | Line 463: | ||
− | ==== | + | ==== <code>/description/extension-description</code> 元素==== |
− | * 父元素: <code>[[Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Documentation/DevGuide/Extensions/Description of XML Elements#/description 元素|<description>]]</code> |
* 子元素: | * 子元素: | ||
− | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | ** <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/extension-description/src 元素|<src>]]</code> |
* 始用于: OOo 3.1 | * 始用于: OOo 3.1 | ||
− | <extension-description> 必需至少有一个 [[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | <extension-description> 必需至少有一个 [[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/extension-description/src 元素|<src>]] 子元素。没个子元素引用一个本地化的说明。详见 [[Zh/Documentation/DevGuide/Extensions/Localized XML Elements|本地化 XML 元素]]。 |
− | + | ||
'''也请参阅''' | '''也请参阅''' | ||
*[[Zh/Documentation/DevGuide/Extensions/Extension Description|扩展说明]] | *[[Zh/Documentation/DevGuide/Extensions/Extension Description|扩展说明]] | ||
*[[Zh/Documentation/DevGuide/Extensions/Example|description.xml 示例]] | *[[Zh/Documentation/DevGuide/Extensions/Example|description.xml 示例]] | ||
− | |||
==== <code>/description/extension-description/src</code> 元素 ==== | ==== <code>/description/extension-description/src</code> 元素 ==== | ||
− | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements# | + | * 父元素: <code>[[Zh/Documentation/DevGuide/Extensions/Description of XML Elements#/description/extension-description 元素|<extension-description>]]</code> |
* 子元素: 无 | * 子元素: 无 | ||
* 始用于: OOo 3.1 | * 始用于: OOo 3.1 | ||
Line 523: | Line 494: | ||
|- | |- | ||
|<code>lang</code> | |<code>lang</code> | ||
− | | | + | |必需。遵循 RFC 3066 标准的语言标识。详见 [[Zh/Documentation/DevGuide/Extensions/Localized XML Elements|本地化的 XML 元素]]。 |
|} | |} | ||
− | |||
'''也请参阅''' | '''也请参阅''' |
Latest revision as of 09:19, 10 September 2008
/description
元素
- 父元素: 文件根
- 子元素:
- 始用于:OOo 2.0.4
<description>
是 description.xml 的根元素。
属性 | 说明 |
---|---|
xmlns
|
默认的元素说明和所有子元素必需根据 http://openoffice.org/extensions/description/2006 定义 |
xmlns:dep
|
依赖关系信息的 namespace 同样也必需根据 http://openoffice.org/extensions/description/2006 定义 |
xmlns:xlink
|
xlink namespace 必需根据 http://www.w3.org/1999/xlink 定义 |
其他 namespace 定义 | 如需要还可添加其他 namespaces |
/description/identifier
元素
- 父元素:
<description>
- 子元素: 无
- 始用于:OOo 2.2
属性 | 说明 |
---|---|
value
|
必需。扩展标识符。 |
也请参阅
/description/version
元素
- 父元素:
<description>
- 子元素: 无
- 始用于: OOo 2.1
属性 | 说明 |
---|---|
value
|
必需。扩展版本的文字表现形式。 |
也请参阅
/description/platform
元素
- 父元素:
<description>
- 子元素: 无
- 始用于: OOo 3.0
属性 | 说明 |
---|---|
value
|
必需。为表示特定平台的符号。详见 目标平台。 |
也请参阅
/description/registration
元素
- 父元素:
<description>
- 子元素:
- 始用于:OOo 2.0.4
registration 元素当前只包含 <simple-license>
元素。如果 <registration>
元素存在的话,那么它必需包含至少一个子元素。
也请参阅
/description/registration/simple-license
元素
父元素: <registration>
- 子元素:
- 始用于: OOo 2.0.4
这个元素包含 <license-text>
元素,验证是否所有用户接收这个授权许可对,或只是安装者接收此授权许可对,并且验证默认的 <license-text>
元素。检验 “默认" 的机制在 OOo 2.4 版本做了变更。详见 本地化 XML 元素。
如果 <simple-license>
元素存在的话,那么它必需包含至少一个子元素。
属性 | 说明 |
---|---|
accept-by
|
必需。Value 可以是 “user” 或 “admin”。“user” 意味着每个用户必需接受此授权许可对。也就是说,此扩展只能被安装为用户扩展而非共享扩展。如果值为 “admin”,那么扩展才可以被部署为共享扩展。在那种情况下只有安装者才必需接受授权许可对。不需要询问每个用户去接受此授权许可对。他们可以直接使用此扩展。在值为 “user” 时扩展被安装成用户扩展,那么用户都会被询问是否接受此授权许可对。
|
default-license-id
|
必需。自 OOo 2.4 版本起,此属性被认为是陈旧属性。如果扩展需要正确地在 2.4 之前的版本上运行的话(在安装过程中显示正确的授权许可)就必需使用这个属性。如果不使用这个属性那么就应该使用 OpenOffice.org-minimal-version 值为 '2.4' 的依赖关系。
这个属性确定如果没有一个 <license-text> 元素的 lang 属性值可以与 OpenOffice.org 的安装地域相匹配时使用什么 <license-text>。任何时候只有一个带 license-id 属性的 |
suppress-on-update
|
可选。当没有提供此属性时此属性值为假设为 “false”。值为 “true” 时表示的是当相同扩展已经安装(相同 id 但可能不同版本)的情况下,此扩展的协议在安装过程中不会再被显示。这同样也作用于自动更新和手动安装扩展。它并不关心已安装扩展的版本。在线升级时排除授权许可对相当有用,因为不那样的话更新操作可能会被许许多多的授权许可对话框中断。 |
也请参阅
/description/registration/simple-license/license-text
元素
- 父元素:
<simple-license>
- 子元素: 无
- 始用于: OOo 2.0.4
此元素包含以下信息:授权许可文件的位置、使用何种语言和这个元素是否是 “默认"的 <license-text>
。检验 “默认" 的机制在 OOo 2.4 版本做了变更。详见本地化 XML 元素。
属性 | 说明 |
---|---|
xlink:href
|
Required.必需。值为该扩展授权许可文件对应的 URL。 |
lang
|
必需。遵循 RFC 3066 标准的语言标识。详见 本地化 XML 元素。 |
license-id
|
必需。自 OOo 2.4 版本起,此属性被认为是陈旧属性。如果扩展需要正确地在 2.4 之前的版本上运行的话(在安装过程中显示正确的授权许可)就必需使用这个属性。如果不使用这个属性那么就应该使用 OpenOffice.org-minimal-version 值为 '2.4' 的依赖关系。
一个 license-text 元素必需有这个属性并且属性值必需与 |
也请参阅
/description/dependencies
元素
- 父元素:
<description>
- 子元素:
- 始用于: OOo 2.0.4
也请参阅
/description/dependencies/OpenOffice.org-minimal-version
元素
- 父元素:
<dependencies>
- 子元素: 无
- 始用于: OOo 2.1
属性 | 说明 |
---|---|
xmlns:dep
|
此 namespace 用于依赖关系信息(继承自 <description> )根据 http://openoffice.org/extensions/description/2006 定义。
|
dep:name
|
必需。字符串 “OpenOffice.org value” (这里 value 的值为属性 value 的值)。 |
dep:OpenOffice.org-minimal-version
|
可选。在这个元素里此属性应该永远不会被用到。 |
value
|
必需。OpenOffice.org 的基本版本需求(“2.1”、“2.2”、等等),由 OpenOffice.org 2.1 开始。 |
也请参阅
/description/dependencies/OpenOffice.org-maximal-version
元素
- 父元素:
<dependencies>
- 子元素: 无
- 始用于: OOo 3.1
属性 | 说明 |
---|---|
xmlns:dep
|
此 namespace 用于依赖关系信息(继承自 <description> )根据 http://openoffice.org/extensions/description/2006 定义。
|
dep:name
|
必需。字符串 “OpenOffice.org value”(这里 value 的值为属性 value 的值)。 |
dep:OpenOffice.org-minimal-version
|
可选。在这个元素中的这个属性值总是被定义为 “2.3”。 |
value
|
必需。可运行的 OpenOffice.org 的最高版本(“3.0”、“3.2”、等等)。 |
也请参阅
/description/update-information
元素
- 父元素:
<description>
- 子元素:
- 始用于: OOo 2.2
<update-information>
必需至少有一个 <src>
子元素。第二个、第三个或更多元素被看作备用,也可以说这些元素提供镜像的 URL。扩展管理器会尝试使用一个 URL 来获取更新信息,只有在出错的情况下才会使用另外一个 URL。例如如果的第一个 URL 引用了一个不包含任何引用信息但却是个合法的 ATOM Feed,那么扩展管理器就会假设没有更新。而其他 <src>
元素就不会在检查了。因此,每个 URL 引用的更新信息都必需一致。
也请参阅
/description/update-information/src
元素
- 父元素:
<update-information>
- 子元素: 无
- 始用于: OOo 2.2
属性 | 说明 |
---|---|
xlink:href
|
必需。此值为 提供更新信息的 URL 或是一个引用更新信息的 ATOM Feed。此 URL 可以直接指向一个文件或调用代码,比如调用 servlet或cgi等等来返回 ATOM Feed 或者更新信息。 |
也请参阅
/description/publisher
元素
- 父元素:
<description>
- 子元素:
- 始用于: OOo 2.4
<publisher>
必需至少有一个 <name>
子元素。这个元素的子元素提供一个 本地化 XML 元素 的 URL。
也请参阅
/description/publisher/name
元素
- 父元素:
<publisher>
- 子元素: Text
- 始用于: OOo 2.4
The text value of this element is the publisher name.
属性 | 说明 |
---|---|
xlink:href
|
必需。值为扩展中发行者的 Web 站点的 URL。 |
lang
|
必需。遵循 RFC 3066 标准的语言标识。详见 本地化 XML 元素。 |
也请参阅
/description/release-notes
元素
- 父元素:
<description>
- 子元素:
- 始用于: OOo 2.4
<release-notes>
必需至少有一个 <src>
子元素。此子元素提供 本地化 release-notes 的 URLs。
当前此元素和其子元素还没有被用于扩展管理器。
也请参阅
/description/release-notes/src
元素
- 父元素:
<release-notes>
- 子元素: none
- 始用于: OOo 2.4
The element contains a URL to the release notes.
属性 | 说明 |
---|---|
xlink:href
|
必需。值为扩展中发行注释的 URL。 |
lang
|
必需。遵循 RFC 3066 标准的语言标识。详见 本地化 XML 元素。 |
也请参阅
/description/display-name
元素
- 父元素:
<description>
- 子元素:
- 始用于: OOo 2.4
<display-name>
必须至少有一个 <name>
子元素。这个元素的子元素提供一个 本地化的显示名称。这个名称将会用在用户图形界面上来替换文件的名称。
也请参阅
/description/display-name/name
元素
- 父元素:
<display-name>
- 子元素: Text
- 始用于: OOo 2.4
这个元素的文本为扩展的显示名称 值。字符串长度必须大于零并且不能只包含空格字符。
属性 | 说明 |
---|---|
lang
|
必需。遵循 RFC 3066 标准的语言标识。详见 本地化 XML 元素。 |
也请参阅
/description/icon
元素
- 父元素:
<description>
- 子元素:
- 始用于: OOo 3.0
也请参阅
/description/icon/default
元素
- 父元素:
<icon>
- 子元素: 无
- 始用于: OOo 3.0
属性 | 说明 |
---|---|
xlink:href
|
值为扩展中图标文件对应的 URL。 |
也请参阅
/description/icon/high-contrast
元素
- 父元素:
<icon>
- 子元素: 无
- 始用于: OOo 3.0
属性 | 说明 |
---|---|
xlink:href
|
值为扩展中图标文件对应的 URL。 |
也请参阅
/description/extension-description
元素
- 父元素:
<description>
- 子元素:
- 始用于: OOo 3.1
<extension-description> 必需至少有一个 <src> 子元素。没个子元素引用一个本地化的说明。详见 本地化 XML 元素。
也请参阅
/description/extension-description/src
元素
- 父元素:
<extension-description>
- 子元素: 无
- 始用于: OOo 3.1
这个元素包含如何寻找含有说明文本的文件以及它使用何种语言的相关信息。
属性 | 说明 |
---|---|
xlink:href
|
必需。值为扩展内说明文件对应的 URL。 |
lang
|
必需。遵循 RFC 3066 标准的语言标识。详见 本地化的 XML 元素。 |
也请参阅
Content on this page is licensed under the Public Documentation License (PDL). |