Ready for review

Finish the XAR format documentation conversion

Last modified by Eleni Cojocariu on 2026/08/20 12:22

Finishes the conversion of XAR Format Specifications (revision 60.3) into the two pages that carried a "WIP for migration" banner, and checks every element against the platform sources at 18.7.0-SNAPSHOT (XarModel, XarDocumentModel, XarAttachmentModel, XarClassModel, XarObjectModel, XarObjectPropertyModel, XarPackage, ExportAction and XWikiDocumentLocaleEventGenerator).

Format for Document XML was the page still marked incomplete, and it is the bulk of this change:

  • The 22 element descriptions that were blank are filled in (defaultLanguage, translation, creator, creationDate, parent, syntaxId, hidden, minorEdit, originalMetadataAuthor, contentAuthor, and the class and object metadata), plus the elements the table never listed at all: title, comment, content, renderedcontent, validationScript, customClass, defaultTemplate and version.
  • The propN row was wrong. A child of class is not a numbered propN element with a fixed set of sub-elements: it is named after the property, and its sub-elements are the fields of that property type, which is why the Date property in the example has dateFormat and emptyIsToday where the String one has size. classType names the Java class of the type.
  • The revision row was wrong too. It described revision as "an alias to the content", which is what contentAlias is. revisions holds one revision per version of the attachment, and contentAlias replaces content in a revision that shares its bytes with another one, which is the deduplication format 1.4 introduced.
  • The object section gained the two elements that carry the data: the class copy of the XClass definition, and property, whose type attribute (format 1.7, XWiki 18.2.0) is what keeps a value readable when its XClass is gone. Both are visible in the example and were documented nowhere.
  • The format-version history is restored as a table of the version attribute's values. It was on the legacy page as a changelog and had been dropped, yet it is the only thing that tells a reader what an archive exported from an older instance can contain. The web, name and language rows now say which format version deprecated them rather than just "Deprecated".
  • The example is a real export, of a Page defining an XClass with two properties, holding one XObject of it and carrying one attachment. It replaces a 500-line example that was mostly two verbatim copies of the XWiki.XWikiComments XClass definition, and it is 20K characters shorter. A second, shorter block shows the attachment element of a Page exported with its history, so revisions and contentAlias have something to point at.
  • Typos fixed: synatxId, mimtype, "it's 1.0.", the trailing colons inside the disabled: style monospace spans, and "the same properties than the attachment".

XAR Format Specifications:

  • The three-column table was structurally broken: its rowspan values did not match the number of rows (8 for 7, 3 for 4) and the defaultAction and file rows carried an extra empty leading cell, so the grouping column did not line up with its rows. It is now two plain tables under "Package Information" and "Files", which also disposes of the "XML Elemet" heading typo and of the stray hash marks in the "Files" grouping cell.
  • The related field pointed at documentation.xs.admin.exports.export-xar-format.format-specifications, which does not exist (the space is export-content-xar-format), so the only related link on the page was red. Replaced by Customize a XAR File, XAR Export as a Backup Method and Imports.
  • The example is a real package.xml, in the element order XarPackage actually writes (version before backupPack, extensionId last) and with the translation entries an export produces. The previous one had extensionId in the middle and mixed a terminal Page reference into a list of WebHome ones.
  • Details added from the sources: preserveVersion is set when either "Backup package" or "With history" is selected (ExportAction sets it to backup || history); an unnamed export is called backup when it covers the whole wiki and export otherwise; the type attribute is written only for entries that have a type, which in practice means the archive is an Extension.

Both pages get the Technical ID xwiki:org.xwiki.platform:xwiki-platform-xar, which was empty, so the Extension badge resolves to the XAR Module.

Export Content in XAR format is in this change request for its links, which the migration has to repoint:

  • The "export" link in the very first sentence pointed at documentation.xs.admin., an incomplete reference that rendered red. It now points at Exports.
  • "XAR format" pointed at the legacy Extensions-wiki page this conversion empties. It now points at XAR Format Specifications.
  • "exporting directly from viewing a Page" pointed at the administrator Exports hub rather than at Export a Page, which is the Page it describes.
  • The "Description*" typo in the "More options" list, and the unprefixed Technical ID.

Dropped deliberately, and worth a reviewer's eye:

  • The legacy example's type="home" attribute. There is no home XAR entry type: the components are default, configuration, customizable and demo.
  • The legacy "Changelog 1.1 / XWiki 10.3" section of the package.xml half. That descriptor has no version attribute, so nothing in a file can be read against it, and 10.3 is long out of support.
  • The WIP warning banners on both pages, and the "the table is incomplete" todo, since nothing is left to convert.

Not in this change request: the child page was renamed from format-document-xml to document-xml before it was opened, because a page name may not repeat its parent's path. That was a move with link update, not a content change, and its one backlink (the legacy page) was repointed by the refactoring job. The legacy Extensions-wiki page itself is handled separately, since a change request cannot span two wikis.

Left alone: the result step of Export Content in XAR format still shows no screenshot, and its sibling Customizations for XAR Export Using URL Parameters documents the export parameter as license where ExportAction reads licence, omits description, and has three table rows with a trailing empty cell. Both are worth their own change.

All changes

Summary

Details

Page properties
Content
... ... @@ -1,46 +1,51 @@
1 -A "**X**Wiki **Ar**chive" (XAR) file is a ZIP file with extension "##.xar##" containing an (optional) "##package.xml##" descriptor file and in which each Page (including the Page's [[history>>documentation.xs.user.base.page.view.view-history.history-tab.WebHome]], [[XObjects>>documentation.xs.dev.data-model.x-objects.WebHome]], [[attachments>>Documentation.UserGuide.Features.Attachments]], [[XClasses>>documentation.xs.dev.data-model.x-classes.WebHome]], etc.) is in a XML file. This is the current format of the "##package.xml##" file:
1 +A "**X**Wiki **Ar**chive" (XAR) file is a ZIP archive with the "##.xar##" extension. It holds one XML file per exported Page, whose [[elements are documented separately>>doc:documentation.xs.admin.exports.export-content-xar-format.format-specifications.document-xml.WebHome]], plus a "##package.xml##" descriptor at the root of the archive that names the package and lists its entries.
2 2  
3 -{{code language="xml"}}
3 +The descriptor below is the one produced by [[exporting content in XAR format>>doc:documentation.xs.admin.exports.export-content-xar-format.WebHome]]:
4 4  
5 +{{code language="xml"}}
6 +<?xml version='1.0' encoding='UTF-8'?>
5 5  <package>
6 6   <infos>
7 - <name>Package Name</name>
8 - <description>A description of the package</description>
9 - <licence>Some License 2.0</licence>
10 - <author>XWiki.User</author>
11 - <extensionId>extension-id</extensionId>
9 + <name>OfficeLocations</name>
10 + <description>The offices of our company</description>
11 + <licence>LGPL 2.1</licence>
12 + <author>XWiki.Admin</author>
12 12   <version>1.0</version>
13 13   <backupPack>false</backupPack>
14 - <preserveVersion>true</preserveVersion>
15 + <preserveVersion>false</preserveVersion>
15 15   </infos>
16 16   <files>
17 17   <file defaultAction="0" language="">News.WebHome</file>
18 - <file defaultAction="0" language="">News.Announcements.WebHome</file>
19 - <file defaultAction="0" language="">News.Updates.WebHome</file>
20 - <file defaultAction="0" language="">Welcome.WebHome</file>
19 + <file defaultAction="0" language="fr">News.WebHome</file>
21 21   <file defaultAction="0" language="">Welcome.AboutOurCompany.WebHome</file>
22 - <file language="fr" defaultAction="0">Welcome.TranslatedPage</file>
21 + <file defaultAction="0" language="fr">Welcome.AboutOurCompany.WebHome</file>
22 + <file defaultAction="0" language="">Welcome.AboutOurCompany.OfficeLocations.WebHome</file>
23 23   </files>
24 24  </package>
25 -
26 26  {{/code}}
27 27  
28 -|=Package information and files|=XML Elemet|=Description
29 -|(% rowspan="8" %)Information (##infos##)
30 -|##name##|The name representing what's contained in the XAR.
31 -|##description##|More detailed description of the content of the XAR.
32 -|##licence##|This can be set to specify under which license this XAR content is published.
33 -|##author##|The wiki [[author>>documentation.xs.user.base.page.authors.WebHome]] of this XAR. When the XAR is going to be [[imported>>documentation.xs.admin.imports.WebHome]], if the "import as backup pack" option is selected, the author mentioned in this field will be preserved (the Pages will have this author as their last author).
34 -|##extensionId## (optional)|If set, then this marks the XAR as containing an Extension. Thus when you [[import the extension>>documentation.xs.admin.imports.extensions.WebHome]], the [[Extension Manager>>extensions:Extension.Extension Manager Application||anchor="HInstall"]] will be able to match it with its Extension database and perform versioning verifications.
35 -|##preserveVersion##(optional)|If set to true, then the [[history>>documentation.xs.user.base.page.view.view-history.history-tab.WebHome]] is preserved (the history for each Page is part of its XML).
36 -|##backupPack##|If true, it means that the XAR is a backup pack. It's up to the import to decide whether to import it as a backup pack or not but this provides the information that it is a backup pack.
37 -|(% rowspan="3" %)Files (##files)##
38 -|##language##|The [[language of the Page>>documentation.xs.user.base.page.view.set-language.languages.WebHome]]. The default Page content should use an empty string.
39 -|##type##|The type of the Page, it's possible to set any type since extensions can contribute new types. [[Standard Types>>extensions:Extension.Extension Module.Extensions.XAR.WebHome||anchor="HStandardtypes"]].
40 -| |##defaultAction##|This attribute is deprecated, it is part of an older import mechanism and is no longer recommended for new packages. When it is applied (which is not very often), ##defaultAction## defines the default behavior to use when importing a Page:(((
41 -* ##-1## (undefined): The exact behavior depends on the component that processes the package.
42 -* ##0## (overwrite): The document in the database is overwritten by the one from the package. This is the default value used by the Maven XAR plugin when generating XAR files.
43 -* ##1## (skip): The Page is not imported.
44 -* ##2## (merge): The importer attempts to merge the packaged Page with the existing one in the database.
27 +== Package Information ==
28 +
29 +|=Element|=Description
30 +|##name##|The name of the package, taken from the "File name" export setting. A whole-wiki export left unnamed uses ##backup##, a partial one ##export##.
31 +|##description##|The package description, displayed when [[importing the package>>doc:documentation.xs.admin.imports.WebHome]].
32 +|##licence##|The license the packaged content is published under, for example ##LGPL 2.1##. The element uses the British spelling, and so does the export URL parameter.
33 +|##author##|The wiki [[author>>doc:documentation.xs.user.base.page.authors.WebHome]] of the package. When the package is imported as a backup pack, this author is kept as the last author of the imported Pages.
34 +|##version##|The version of the package, which is what tracks the changes made to its content.
35 +|##backupPack##|##true## when the export was made as a backup package. The import decides whether to honor it, so the choice can still be changed at import time.
36 +|##preserveVersion##|##true## when the [[history>>doc:documentation.xs.user.base.page.view.view-history.history-tab.WebHome]] of each Page is part of its XML. An export sets it when either "Backup package" or "With history" is selected.
37 +|##extensionId##|Written only when the XAR is an Extension. The [[Extension Manager>>doc:extensions:Extension.Extension Manager Application||anchor="HInstall"]] then matches the archive against its Extension database and runs the version checks when [[installing it>>doc:documentation.xs.admin.imports.extensions.WebHome]].
38 +
39 +== Files ==
40 +
41 +The ##files## element holds one ##file## entry per exported Page, and one further entry per [[translation>>doc:documentation.xs.user.base.page.view.translate.translations.WebHome]]. The value of the element is the Page [[reference>>doc:documentation.xs.user.base.page.linking-references.WebHome||anchor="HPageReferences"]] relative to the wiki, as in ##Welcome.AboutOurCompany.OfficeLocations.WebHome##.
42 +
43 +|=Attribute|=Description
44 +|##language##|The [[language>>doc:documentation.xs.user.base.page.view.set-language.languages.WebHome]] of the Page, empty for the default one. A translation is listed under the same reference with its own locale.
45 +|##type##|The entry type, which decides whether the Page may be edited or deleted and how it behaves when the Extension shipping it is upgraded. It is written only when the entry has a type, which in practice means the archive is an Extension. Extensions can contribute new types to the four [[standard ones>>doc:extensions:Extension.Extension Module.Extensions.XAR.WebHome||anchor="HStandardtypes"]].
46 +|##defaultAction##|Deprecated, and part of an older import mechanism: the action to apply to the Page when the archive is imported. Both the export and the Maven XAR plugin write ##0##.(((
47 +* ##-1## (undefined): the behavior depends on the component reading the archive.
48 +* ##0## (overwrite): the Page in the database is replaced by the one from the archive.
49 +* ##1## (skip): the Page is not imported.
50 +* ##2## (merge): the importer merges the packaged Page with the one in the database.
45 45  )))
46 -| |The ##file## element (e.g., "##News.Announcements.WebHome##") |The file element is the [[Page reference>>documentation.xs.user.base.page.linking-references.WebHome||anchor="HPageReferences"]].
DocApp.Code.DocumentationClass[0]
FAQ
... ... @@ -1,3 +1,11 @@
1 -== How are the package information defined? ==
1 +== How is the package information filled in? ==
2 2  
3 -When [[exporting content in XAR format>>documentation.xs.admin.exports.export-content-xar-format.WebHome]], there are some configuration settings allowing to set the name of the package, a description, etc. In addition, there are some [[customizations done using some URL parameters>>documentation.xs.admin.exports.export-content-xar-format.xar-customization-url.WebHome]].
3 +The name, description, author, license and version come from the settings of the [[XAR export>>documentation.xs.admin.exports.export-content-xar-format.WebHome]], and can also be set with [[URL parameters>>documentation.xs.admin.exports.export-content-xar-format.xar-customization-url.WebHome]].
4 +
5 +== Is the "package.xml" file required? ==
6 +
7 +No. An import reads every XML entry of the archive and takes each Page's reference from the entry itself, so an archive with no descriptor still imports; what it loses is the package information and the per-entry attributes.
8 +
9 +== Can a XAR file be changed by hand? ==
10 +
11 +Yes, it is an ordinary ZIP archive, so it can be unpacked, edited and repacked. See [[Customize a XAR File>>documentation.xs.admin.imports.customize-xar-file.WebHome]].
Related
... ... @@ -1,1 +1,3 @@
1 -* [[XAR Extensions>>documentation.xs.admin.exports.export-xar-format.format-specifications.WebHome]].
1 +* [[Customize a XAR File>>documentation.xs.admin.imports.customize-xar-file.WebHome]].
2 +* [[XAR Export as a Backup Method>>documentation.xs.admin.backup.xar-export.WebHome]].
3 +* [[Imports>>documentation.xs.admin.imports.WebHome]].
DocApp.Code.DocumentationExtensionClass[0]
Technical Identifier
... ... @@ -1,0 +1,1 @@
1 +xwiki:org.xwiki.platform:xwiki-platform-xar

Summary

Details

Page properties
Content
... ... @@ -1,47 +1,42 @@
1 -{{warning}}
2 -WIP: the table is incomplete. Please consult the [[XAR Format Specifications>>doc:extensions:Extension.XAR Module Specifications]] in the meantime.
3 -{{/warning}}
1 +You can read the XML of a Page by [[exporting it>>doc:documentation.xs.admin.exports.export-content-xar-format.WebHome]] and opening the archive with any tool that extracts ZIP files, or without exporting at all by adding the [[##xpage=xml## parameter>>Documentation.DevGuide.Architecture.URL Architecture.Standard URL Format||anchor="HParameter:xpage"]] to the URL of the Page.
4 4  
5 -You can view the XML of a Page by [[exporting it>>documentation.xs.admin.exports.export-content-xar-format.WebHome]], compressing the result into a ZIP file, and then opening it with any tool that supports archive extraction. Inside the archive, you will find the [[##package.xml## descriptor file>>documentation.xs.admin.exports.export-content-xar-format.format-specifications.WebHome]] as well as the XML files for each Page exported. You can also view the XML by using the [[##xpage=xml## parameter when on wiki Page URL>>Documentation.DevGuide.Architecture.URL Architecture.Standard URL Format||anchor="HParameter:xpage"]].
3 +Inside the archive the files follow the [[Page hierarchy>>doc:documentation.xs.user.base.page.nested-pages.relations.WebHome]], as in ##Welcome/AboutOurCompany/OfficeLocations/WebHome.xml##. That layout is a convenience only: a parser ignores the path and reads the reference from the file itself. The file below is the export of a Page that defines an XClass with two properties, holds one XObject of it and carries one attachment:
6 6  
7 -Document files are usually organized in directories that mirror the [[Page hierarchy>>documentation.xs.user.base.page.nested-pages.relations.WebHome]] (for example, ##News##/##Announcements##.xml), but this structure is not technically required. Parsers (i.e., the components that read and interpret the XML files) ignore the file path and rely only on the information defined inside the document itself.
8 -
9 -Example of a XML file:
10 -
11 11  {{code language="xml"}}
12 12  <?xml version='1.1' encoding='UTF-8'?>
13 -<xwikidoc version="1.6" reference="Welcome.AboutOurCompany.History.WebHome" locale="">
14 - <web>Welcome.AboutOurCompany.History</web>
7 +<xwikidoc version="1.7" reference="Welcome.AboutOurCompany.OfficeLocations.WebHome" locale="">
8 + <web>Welcome.AboutOurCompany.OfficeLocations</web>
15 15   <name>WebHome</name>
16 16   <language/>
17 17   <defaultLanguage>en</defaultLanguage>
18 18   <translation>0</translation>
19 19   <creator>XWiki.Admin</creator>
20 - <creationDate>1773427257000</creationDate>
21 - <parent>Main.WebHome</parent>
14 + <creationDate>1787220145000</creationDate>
22 22   <author>XWiki.Admin</author>
23 23   <originalMetadataAuthor>XWiki.Admin</originalMetadataAuthor>
24 24   <contentAuthor>XWiki.Admin</contentAuthor>
25 - <date>1776264797000</date>
26 - <contentUpdateDate>1776264676000</contentUpdateDate>
27 - <version>9.1</version>
28 - <title>History</title>
18 + <date>1787220179000</date>
19 + <contentUpdateDate>1787220145000</contentUpdateDate>
20 + <version>4.1</version>
21 + <title>Office Locations</title>
29 29   <comment/>
30 30   <minorEdit>false</minorEdit>
31 31   <syntaxId>xwiki/2.1</syntaxId>
32 32   <hidden>false</hidden>
33 - <content>This is some fictional text.</content>
26 + <content>Our company runs offices in Paris and Bucharest.</content>
34 34   <attachment>
35 - <filename>history-office.jpg</filename>
28 + <filename>paris-office.png</filename>
29 + <mimetype>image/png</mimetype>
30 + <charset>UTF-8</charset>
36 36   <author>XWiki.Admin</author>
37 - <date>1773427257000</date>
32 + <date>1787220166000</date>
38 38   <version>1.1</version>
39 39   <comment/>
40 - <content>/</content>
41 - <filesize>13098</filesize>
35 + <content>iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAAKUlEQVR42mNkYPhfz0AEYCJG0X9K</content>
36 + <filesize>100</filesize>
42 42   </attachment>
43 43   <class>
44 - <name>Welcome.AboutOurCompany.History.WebHome</name>
39 + <name>Welcome.AboutOurCompany.OfficeLocations.WebHome</name>
45 45   <customClass/>
46 46   <customMapping/>
47 47   <defaultViewSheet/>
... ... @@ -49,29 +49,35 @@
49 49   <defaultWeb/>
50 50   <nameField/>
51 51   <validationScript/>
52 - <ExampleProperty>
53 - <customDisplay/>
54 - <defaultValue/>
47 + <city>
55 55   <disabled>0</disabled>
56 - <displayFormType>select</displayFormType>
57 - <displayType/>
58 - <hint>This is the hint of the example property</hint>
59 - <name>ExampleProperty</name>
49 + <name>city</name>
60 60   <number>1</number>
61 - <prettyName>ExampleProperty</prettyName>
51 + <prettyName>city</prettyName>
52 + <size>30</size>
62 62   <unmodifiable>0</unmodifiable>
63 - <validationMessage/>
64 - <validationRegExp/>
65 - <classType>com.xpn.xwiki.objects.classes.BooleanClass</classType>
66 - </ExampleProperty>
54 + <classType>com.xpn.xwiki.objects.classes.StringClass</classType>
55 + </city>
56 + <opened>
57 + <dateFormat>dd/MM/yyyy HH:mm:ss</dateFormat>
58 + <disabled>0</disabled>
59 + <emptyIsToday>1</emptyIsToday>
60 + <name>opened</name>
61 + <number>2</number>
62 + <picker>1</picker>
63 + <prettyName>opened</prettyName>
64 + <size>20</size>
65 + <unmodifiable>0</unmodifiable>
66 + <classType>com.xpn.xwiki.objects.classes.DateClass</classType>
67 + </opened>
67 67   </class>
68 68   <object>
69 - <name>Welcome.AboutOurCompany.History.WebHome</name>
70 + <name>Welcome.AboutOurCompany.OfficeLocations.WebHome</name>
70 70   <number>0</number>
71 - <className>XWiki.Like.LikeConfigurationClass</className>
72 - <guid>a9980df3-dd1a-4edf-adb5-34b893b21c47</guid>
72 + <className>Welcome.AboutOurCompany.OfficeLocations.WebHome</className>
73 + <guid>51757e7c-00f0-4205-a574-f68457d007ef</guid>
73 73   <class>
74 - <name>XWiki.Like.LikeConfigurationClass</name>
75 + <name>Welcome.AboutOurCompany.OfficeLocations.WebHome</name>
75 75   <customClass/>
76 76   <customMapping/>
77 77   <defaultViewSheet/>
... ... @@ -79,492 +79,161 @@
79 79   <defaultWeb/>
80 80   <nameField/>
81 81   <validationScript/>
82 - <alwaysDisplayButton>
83 - <customDisplay/>
84 - <defaultValue/>
83 + <city>
85 85   <disabled>0</disabled>
86 - <displayFormType>checkbox</displayFormType>
87 - <displayType/>
88 - <hint/>
89 - <name>alwaysDisplayButton</name>
90 - <number>2</number>
91 - <prettyName>alwaysDisplayButton</prettyName>
92 - <unmodifiable>0</unmodifiable>
93 - <validationMessage/>
94 - <validationRegExp/>
95 - <classType>com.xpn.xwiki.objects.classes.BooleanClass</classType>
96 - </alwaysDisplayButton>
97 - <cacheCapacity>
98 - <customDisplay/>
99 - <disabled>0</disabled>
100 - <hint/>
101 - <name>cacheCapacity</name>
102 - <number>3</number>
103 - <numberType>integer</numberType>
104 - <prettyName>cacheCapacity</prettyName>
105 - <size>30</size>
106 - <unmodifiable>0</unmodifiable>
107 - <validationMessage/>
108 - <validationRegExp/>
109 - <classType>com.xpn.xwiki.objects.classes.NumberClass</classType>
110 - </cacheCapacity>
111 - <enabled>
112 - <customDisplay/>
113 - <defaultValue/>
114 - <disabled>0</disabled>
115 - <displayFormType>checkbox</displayFormType>
116 - <displayType/>
117 - <hint/>
118 - <name>enabled</name>
85 + <name>city</name>
119 119   <number>1</number>
120 - <prettyName>enabled</prettyName>
121 - <unmodifiable>0</unmodifiable>
122 - <validationMessage/>
123 - <validationRegExp/>
124 - <classType>com.xpn.xwiki.objects.classes.BooleanClass</classType>
125 - </enabled>
126 - </class>
127 - <property>
128 - <alwaysDisplayButton>1</alwaysDisplayButton>
129 - </property>
130 - <property>
131 - <cacheCapacity>500</cacheCapacity>
132 - </property>
133 - <property>
134 - <enabled>1</enabled>
135 - </property>
136 - </object>
137 - <object>
138 - <name>Welcome.AboutOurCompany.History.WebHome</name>
139 - <number>0</number>
140 - <className>XWiki.XWikiComments</className>
141 - <guid>322c7339-e99c-496e-a453-2b8643508913</guid>
142 - <class>
143 - <name>XWiki.XWikiComments</name>
144 - <customClass/>
145 - <customMapping/>
146 - <defaultViewSheet/>
147 - <defaultEditSheet/>
148 - <defaultWeb/>
149 - <nameField/>
150 - <validationScript/>
151 - <author>
152 - <cache>0</cache>
153 - <disabled>0</disabled>
154 - <displayType>input</displayType>
155 - <multiSelect>0</multiSelect>
156 - <name>author</name>
157 - <number>1</number>
158 - <picker>1</picker>
159 - <prettyName>Author</prettyName>
160 - <relationalStorage>0</relationalStorage>
161 - <separator> </separator>
87 + <prettyName>city</prettyName>
162 162   <size>30</size>
163 163   <unmodifiable>0</unmodifiable>
164 - <classType>com.xpn.xwiki.objects.classes.UsersClass</classType>
165 - </author>
166 - <comment>
167 - <disabled>0</disabled>
168 - <editor/>
169 - <name>comment</name>
170 - <number>5</number>
171 - <prettyName>Comment</prettyName>
172 - <restricted>1</restricted>
173 - <rows>5</rows>
174 - <size>40</size>
175 - <unmodifiable>0</unmodifiable>
176 - <classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType>
177 - </comment>
178 - <date>
179 - <dateFormat>dd/MM/yyyy HH:mm:ss</dateFormat>
180 - <disabled>0</disabled>
181 - <emptyIsToday>1</emptyIsToday>
182 - <name>date</name>
183 - <number>2</number>
184 - <picker>1</picker>
185 - <prettyName>Date</prettyName>
186 - <size>20</size>
187 - <unmodifiable>0</unmodifiable>
188 - <classType>com.xpn.xwiki.objects.classes.DateClass</classType>
189 - </date>
190 - <highlight>
191 - <disabled>0</disabled>
192 - <name>highlight</name>
193 - <number>3</number>
194 - <prettyName>Highlighted Text</prettyName>
195 - <restricted>0</restricted>
196 - <rows>2</rows>
197 - <size>40</size>
198 - <unmodifiable>0</unmodifiable>
199 - <classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType>
200 - </highlight>
201 - <originalSelection>
202 - <contenttype>PureText</contenttype>
203 - <disabled>0</disabled>
204 - <editor>PureText</editor>
205 - <name>originalSelection</name>
206 - <number>6</number>
207 - <prettyName>Original Selection</prettyName>
208 - <restricted>0</restricted>
209 - <rows>5</rows>
210 - <size>40</size>
211 - <unmodifiable>0</unmodifiable>
212 - <classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType>
213 - </originalSelection>
214 - <replyto>
215 - <disabled>0</disabled>
216 - <name>replyto</name>
217 - <number>4</number>
218 - <numberType>integer</numberType>
219 - <prettyName>Reply To</prettyName>
220 - <size>5</size>
221 - <unmodifiable>0</unmodifiable>
222 - <classType>com.xpn.xwiki.objects.classes.NumberClass</classType>
223 - </replyto>
224 - <selection>
225 - <contenttype>PureText</contenttype>
226 - <disabled>0</disabled>
227 - <editor>PureText</editor>
228 - <name>selection</name>
229 - <number>3</number>
230 - <prettyName>Selection</prettyName>
231 - <restricted>0</restricted>
232 - <rows>5</rows>
233 - <size>40</size>
234 - <unmodifiable>0</unmodifiable>
235 - <classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType>
236 - </selection>
237 - <selectionLeftContext>
238 - <contenttype>PureText</contenttype>
239 - <disabled>0</disabled>
240 - <editor>PureText</editor>
241 - <name>selectionLeftContext</name>
242 - <number>4</number>
243 - <prettyName>Selection Left Context</prettyName>
244 - <restricted>0</restricted>
245 - <rows>5</rows>
246 - <size>40</size>
247 - <unmodifiable>0</unmodifiable>
248 - <classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType>
249 - </selectionLeftContext>
250 - <selectionRightContext>
251 - <contenttype>PureText</contenttype>
252 - <disabled>0</disabled>
253 - <editor>PureText</editor>
254 - <name>selectionRightContext</name>
255 - <number>5</number>
256 - <prettyName>Selection Right Context</prettyName>
257 - <restricted>0</restricted>
258 - <rows>5</rows>
259 - <size>40</size>
260 - <unmodifiable>0</unmodifiable>
261 - <classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType>
262 - </selectionRightContext>
263 - <state>
264 - <disabled>0</disabled>
265 - <name>state</name>
266 - <number>8</number>
267 - <prettyName>State</prettyName>
268 - <size>30</size>
269 - <unmodifiable>0</unmodifiable>
270 270   <classType>com.xpn.xwiki.objects.classes.StringClass</classType>
271 - </state>
272 - <target>
273 - <cache>0</cache>
274 - <classname/>
275 - <disabled>0</disabled>
276 - <displayType>input</displayType>
277 - <freeText>discouraged</freeText>
278 - <multiSelect>0</multiSelect>
279 - <name>target</name>
280 - <number>7</number>
281 - <picker>1</picker>
282 - <prettyName>Target</prettyName>
283 - <relationalStorage>0</relationalStorage>
284 - <separator> </separator>
285 - <size>30</size>
286 - <sql/>
287 - <unmodifiable>0</unmodifiable>
288 - <classType>com.xpn.xwiki.objects.classes.PageClass</classType>
289 - </target>
290 - </class>
291 - <property>
292 - <author>XWiki.AnaSmith</author>
293 - </property>
294 - <property>
295 - <comment>This article was posted also on the platform.</comment>
296 - </property>
297 - <property>
298 - <date>2025-12-29 16:22:41.147</date>
299 - </property>
300 - <property>
301 - <highlight></highlight>
302 - </property>
303 - <property>
304 - <originalSelection></originalSelection>
305 - </property>
306 - <property>
307 - <replyto/>
308 - </property>
309 - <property>
310 - <selection></selection>
311 - </property>
312 - <property>
313 - <selectionLeftContext></selectionLeftContext>
314 - </property>
315 - <property>
316 - <selectionRightContext></selectionRightContext>
317 - </property>
318 - <property>
319 - <state></state>
320 - </property>
321 - <property>
322 - <target></target>
323 - </property>
324 - </object>
325 - <object>
326 - <name>Welcome.AboutOurCompany.History.WebHome</name>
327 - <number>1</number>
328 - <className>XWiki.XWikiComments</className>
329 - <guid>0693a30a-f35b-447b-95ce-bc90b6ab062a</guid>
330 - <class>
331 - <name>XWiki.XWikiComments</name>
332 - <customClass/>
333 - <customMapping/>
334 - <defaultViewSheet/>
335 - <defaultEditSheet/>
336 - <defaultWeb/>
337 - <nameField/>
338 - <validationScript/>
339 - <author>
340 - <cache>0</cache>
341 - <disabled>0</disabled>
342 - <displayType>input</displayType>
343 - <multiSelect>0</multiSelect>
344 - <name>author</name>
345 - <number>1</number>
346 - <picker>1</picker>
347 - <prettyName>Author</prettyName>
348 - <relationalStorage>0</relationalStorage>
349 - <separator> </separator>
350 - <size>30</size>
351 - <unmodifiable>0</unmodifiable>
352 - <classType>com.xpn.xwiki.objects.classes.UsersClass</classType>
353 - </author>
354 - <comment>
355 - <disabled>0</disabled>
356 - <editor/>
357 - <name>comment</name>
358 - <number>5</number>
359 - <prettyName>Comment</prettyName>
360 - <restricted>1</restricted>
361 - <rows>5</rows>
362 - <size>40</size>
363 - <unmodifiable>0</unmodifiable>
364 - <classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType>
365 - </comment>
366 - <date>
91 + </city>
92 + <opened>
367 367   <dateFormat>dd/MM/yyyy HH:mm:ss</dateFormat>
368 368   <disabled>0</disabled>
369 369   <emptyIsToday>1</emptyIsToday>
370 - <name>date</name>
96 + <name>opened</name>
371 371   <number>2</number>
372 372   <picker>1</picker>
373 - <prettyName>Date</prettyName>
99 + <prettyName>opened</prettyName>
374 374   <size>20</size>
375 375   <unmodifiable>0</unmodifiable>
376 376   <classType>com.xpn.xwiki.objects.classes.DateClass</classType>
377 - </date>
378 - <highlight>
379 - <disabled>0</disabled>
380 - <name>highlight</name>
381 - <number>3</number>
382 - <prettyName>Highlighted Text</prettyName>
383 - <restricted>0</restricted>
384 - <rows>2</rows>
385 - <size>40</size>
386 - <unmodifiable>0</unmodifiable>
387 - <classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType>
388 - </highlight>
389 - <originalSelection>
390 - <contenttype>PureText</contenttype>
391 - <disabled>0</disabled>
392 - <editor>PureText</editor>
393 - <name>originalSelection</name>
394 - <number>6</number>
395 - <prettyName>Original Selection</prettyName>
396 - <restricted>0</restricted>
397 - <rows>5</rows>
398 - <size>40</size>
399 - <unmodifiable>0</unmodifiable>
400 - <classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType>
401 - </originalSelection>
402 - <replyto>
403 - <disabled>0</disabled>
404 - <name>replyto</name>
405 - <number>4</number>
406 - <numberType>integer</numberType>
407 - <prettyName>Reply To</prettyName>
408 - <size>5</size>
409 - <unmodifiable>0</unmodifiable>
410 - <classType>com.xpn.xwiki.objects.classes.NumberClass</classType>
411 - </replyto>
412 - <selection>
413 - <contenttype>PureText</contenttype>
414 - <disabled>0</disabled>
415 - <editor>PureText</editor>
416 - <name>selection</name>
417 - <number>3</number>
418 - <prettyName>Selection</prettyName>
419 - <restricted>0</restricted>
420 - <rows>5</rows>
421 - <size>40</size>
422 - <unmodifiable>0</unmodifiable>
423 - <classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType>
424 - </selection>
425 - <selectionLeftContext>
426 - <contenttype>PureText</contenttype>
427 - <disabled>0</disabled>
428 - <editor>PureText</editor>
429 - <name>selectionLeftContext</name>
430 - <number>4</number>
431 - <prettyName>Selection Left Context</prettyName>
432 - <restricted>0</restricted>
433 - <rows>5</rows>
434 - <size>40</size>
435 - <unmodifiable>0</unmodifiable>
436 - <classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType>
437 - </selectionLeftContext>
438 - <selectionRightContext>
439 - <contenttype>PureText</contenttype>
440 - <disabled>0</disabled>
441 - <editor>PureText</editor>
442 - <name>selectionRightContext</name>
443 - <number>5</number>
444 - <prettyName>Selection Right Context</prettyName>
445 - <restricted>0</restricted>
446 - <rows>5</rows>
447 - <size>40</size>
448 - <unmodifiable>0</unmodifiable>
449 - <classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType>
450 - </selectionRightContext>
451 - <state>
452 - <disabled>0</disabled>
453 - <name>state</name>
454 - <number>8</number>
455 - <prettyName>State</prettyName>
456 - <size>30</size>
457 - <unmodifiable>0</unmodifiable>
458 - <classType>com.xpn.xwiki.objects.classes.StringClass</classType>
459 - </state>
460 - <target>
461 - <cache>0</cache>
462 - <classname/>
463 - <disabled>0</disabled>
464 - <displayType>input</displayType>
465 - <freeText>discouraged</freeText>
466 - <multiSelect>0</multiSelect>
467 - <name>target</name>
468 - <number>7</number>
469 - <picker>1</picker>
470 - <prettyName>Target</prettyName>
471 - <relationalStorage>0</relationalStorage>
472 - <separator> </separator>
473 - <size>30</size>
474 - <sql/>
475 - <unmodifiable>0</unmodifiable>
476 - <classType>com.xpn.xwiki.objects.classes.PageClass</classType>
477 - </target>
103 + </opened>
478 478   </class>
479 - <property>
480 - <author>XWiki.AlexJohnson</author>
105 + <property type="String">
106 + <city>Paris</city>
481 481   </property>
482 - <property>
483 - <comment>Great article!</comment>
108 + <property type="Date">
109 + <opened>2019-04-15 00:00:00.0</opened>
484 484   </property>
485 - <property>
486 - <date>2025-12-29 16:28:40.426</date>
487 - </property>
488 - <property>
489 - <highlight></highlight>
490 - </property>
491 - <property>
492 - <originalSelection></originalSelection>
493 - </property>
494 - <property>
495 - <replyto/>
496 - </property>
497 - <property>
498 - <selection></selection>
499 - </property>
500 - <property>
501 - <selectionLeftContext></selectionLeftContext>
502 - </property>
503 - <property>
504 - <selectionRightContext></selectionRightContext>
505 - </property>
506 - <property>
507 - <state></state>
508 - </property>
509 - <property>
510 - <target></target>
511 - </property>
512 512   </object>
513 513  </xwikidoc>
514 514  {{/code}}
515 515  
516 -|=Document elements|=Sub-elements|=Description
517 -|(% rowspan="20" %)##xwikidoc## (the root of the XML element)|##version##|The version of the XML format, if not specified then it's ##1.0.##
518 -|##reference##|The [[reference>>documentation.xs.user.base.page.linking-references.WebHome||anchor="HPageReferences"]] of the Page.
519 -|##defaultLanguage## |
520 -|##translation## |
521 -|##creator##|
522 -|##creationDate##|
523 -|##parent##|
524 -|##synatxId##|
525 -|##hidden##|
526 -|##minorEdit##|
527 -|##originalMetadataAuthor##|
528 -|##contentAuthor## |
529 -|##locale## |The locale (as defined in [[Java Locale specifications>>http://docs.oracle.com/javase/7/docs/api/java/util/Locale.html]]) of the document
530 -|##web##|Deprecated, property containing the unique space of the document.
531 -|##name## |Deprecated, the name of the document.
532 -|##language## |Deprecated, the locale (as defined in [[Java Locale specifications>>http://docs.oracle.com/javase/7/docs/api/java/util/Locale.html]]) of the document.
533 -|##date##|The last modification date of the document (format: epoch date and time UTC)
534 -|##contentUpdateDate##|The last modification date of the document content (format: epoch date and time UTC)
535 -|##versions##|A serialized version of the ##com.xpn.xwiki.doc.rcs.XWikiRCSArchive## Java object
536 -|##enforceRequiredRights##|Whether [[required rights>>extensions:Extension.Security Module||anchor="HRequiredRights"]] shall be enforced. Only present when the value is ##true## for increased backwards-compatibility.
537 -|(% rowspan="12" %)##attachment##|##filename##|The name of the file.
538 -|##author##|The author of the attachment.
539 -|##date##|[[Epoch date and time>>||anchor="HHowarepagedates28creationdate2Clasteditdate29storedinXARfiles3F"]] UTC.
540 -|##version##|The [[version of the attachment>>Documentation.AdminGuide.Attachments||anchor="HVersions"]].
541 -|##comment##|The comment associated to the version of the attachment.
542 -|##content##|The binary content serialized in base64.
543 -|##filesize##|The size of the attachment in bytes.
544 -|##mimtype##|The MIME type of the attachment (as expressed by the [[RFC 6838>>https://tools.ietf.org/html/rfc6838]]).
545 -|##charset##|The charset of the attachment (as expressed in the HTTP Content-Type).
546 -|##versions##|Deprecated in favor of ##revisions.##
547 -|##revisions##|The revisions of the attachment, it contains the same properties than the attachment plus "contentAlias".
548 -|##revision##|An alias to the content of the indicated version of the attachment revision. Empty string for current attachment.
549 -|(% rowspan="16" %)##class##|##name##|
550 -|##customClass##|
551 -|##customMapping##|
552 -|##defaultViewSheet##|
553 -|##defaultEditSheet##|
554 -|##defaultWeb##|
555 -|##nameField##|
556 -|##validationScript##|
557 -|(% rowspan="8" %)##propN##, where N is the number of the property|##disabled:##
558 -|##name:##
559 -|##number:##
560 -|##numberType:##
561 -|##prettyName:##
562 -|##size:##
563 -|##unmodifiable:##
564 -|##classType:##
565 -|(% rowspan="4" %)##object##|##name##|
566 -|##number##|
567 -|##className##|
568 -|##guid##|
115 +== Format Versions ==
569 569  
570 -\\
117 +The ##version## attribute of the root element names the version of the format, which changes whenever the set of elements does. Reading it tells you what an older archive can and cannot contain:
118 +
119 +|=Format|=Written since|=Change
120 +|##1.7##|XWiki 18.2.0|The ##type## attribute on an XObject property, which keeps the value readable when its XClass is gone.
121 +|##1.6##|XWiki 16.10.0|The ##enforceRequiredRights## element.
122 +|##1.5##|XWiki 14.0|The ##originalMetadataAuthor## element.
123 +|##1.4##|XWiki 12.0|The ##revisions## element for attachment history, which allows streaming and deduplication, in place of the JRCS ##versions## element.
124 +|##1.3##|XWiki 9.0|XML 1.1 instead of XML 1.0.
125 +|##1.2##|XWiki 7.2|Nested spaces: the ##reference## and ##locale## attributes, which deprecate the ##web##, ##name## and ##language## elements.
126 +|##1.1##|XWiki 6.2|The ##version## attribute itself, plus a change of element order and indentation.
127 +
128 +An archive with no ##version## attribute is in format ##1.0##.
129 +
130 +== Root Element ==
131 +
132 +|=Attribute of ##xwikidoc##|=Description
133 +|##version##|The version of the format the file follows.
134 +|##reference##|The full [[reference>>doc:documentation.xs.user.base.page.linking-references.WebHome||anchor="HPageReferences"]] of the Page.
135 +|##locale##|The locale of the Page, as defined by the [[Java locale specifications>>https://docs.oracle.com/en/java/javase/21/docs/api/java.base/java/util/Locale.html]], and empty for the default locale.
136 +
137 +== Document Elements ==
138 +
139 +|=Element|=Description
140 +|##web##|Deprecated in favor of the ##reference## attribute: the space of the Page. Ignored when ##reference## is set.
141 +|##name##|Deprecated in favor of the ##reference## attribute: the name of the Page. Ignored when ##reference## is set.
142 +|##language##|Deprecated in favor of the ##locale## attribute: the locale of the Page.
143 +|##defaultLanguage##|The locale the Page's own content is written in, the one its translations translate.
144 +|##translation##|##1## when the file holds a translation of the Page, ##0## when it holds the Page itself.
145 +|##creator##|The user who created the Page.
146 +|##creationDate##|When the Page was created.
147 +|##parent##|The parent of the Page in the legacy parent and child relationship, written only when one is set. It has nothing to do with where the Page sits in the [[Page hierarchy>>doc:documentation.xs.user.base.page.nested-pages.relations.WebHome]].
148 +|##author##|The user who holds the responsibility, in terms of rights, for everything in the Page except its content.
149 +|##originalMetadataAuthor##|The user who triggered the save without holding that responsibility, which is what happens when saving needs no edit right, as when a comment is added.
150 +|##contentAuthor##|The last user who changed the content of the Page. This is the author whose rights are checked when the content runs a script.
151 +|##date##|When the Page was last modified.
152 +|##contentUpdateDate##|When the content of the Page was last modified.
153 +|##version##|The [[version>>doc:documentation.xs.user.base.page.view.view-history.major-minor-versions.WebHome]] of the Page.
154 +|##title##|The title of the Page.
155 +|##comment##|The comment attached to the last version of the Page.
156 +|##minorEdit##|##true## when the last change was a [[minor version>>doc:documentation.xs.user.base.page.view.view-history.major-minor-versions.WebHome]].
157 +|##syntaxId##|The identifier of the syntax the content is written in, for example ##xwiki/2.1##.
158 +|##hidden##|Whether the Page is hidden.
159 +|##content##|The content of the Page, in the syntax named by ##syntaxId##.
160 +|##renderedcontent##|The content rendered as HTML. Present only when the export was asked for it, which the standard XAR export does not do.
161 +|##versions##|The history of the Page, as a serialized ##com.xpn.xwiki.doc.rcs.XWikiRCSArchive## Java object. Present only when the Page was exported with its history.
162 +|##enforceRequiredRights##|##true## when the [[required rights>>doc:extensions:Extension.Security.RequiredRights.WebHome]] of the Page are enforced. Written only in that case, so that archives stay importable into instances older than the flag.
163 +|##validationScript##|The script executed when the Page is validated on save, written only when one is set.
164 +|##customClass##|The Java class used in place of the standard one to represent the Page in scripts, written only when one is set.
165 +|##defaultTemplate##|A legacy element naming a template Page, kept for backward compatibility and written only when it is set.
166 +|##attachment##, ##class##, ##object##|One ##attachment## per attached file, one ##class## when the Page defines an [[XClass>>doc:documentation.xs.dev.data-model.x-classes.WebHome]], and one ##object## per [[XObject>>doc:documentation.xs.dev.data-model.x-objects.WebHome]] the Page holds. Their own elements are described below.
167 +
168 +== Attachments ==
169 +
170 +An ##attachment## element carries the current file, and the [[versions>>Documentation.AdminGuide.Attachments||anchor="HVersions"]] that came before it when the Page was exported with its history:
171 +
172 +{{code language="xml"}}
173 + <attachment>
174 + <filename>paris-office.png</filename>
175 + <mimetype>image/png</mimetype>
176 + <charset>UTF-8</charset>
177 + <author>XWiki.Admin</author>
178 + <date>1787220223000</date>
179 + <version>1.2</version>
180 + <comment/>
181 + <content>iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAAJ0lEQVR42mP8z8DAwMjAwMDIwMDA</content>
182 + <filesize>95</filesize>
183 + <revisions>
184 + <revision>
185 + <author>XWiki.Admin</author>
186 + <date>1787220166000</date>
187 + <version>1.1</version>
188 + <comment/>
189 + <content>iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAAKUlEQVR42mNkYPhfz0AEYCJG0X9K</content>
190 + <filesize>100</filesize>
191 + </revision>
192 + <revision>
193 + <author>XWiki.Admin</author>
194 + <date>1787220223000</date>
195 + <version>1.2</version>
196 + <comment/>
197 + <contentAlias/>
198 + <filesize>95</filesize>
199 + </revision>
200 + </revisions>
201 + </attachment>
202 +{{/code}}
203 +
204 +|=Element|=Description
205 +|##filename##|The name of the file.
206 +|##mimetype##|The MIME type of the file, as expressed by [[RFC 6838>>https://www.rfc-editor.org/rfc/rfc6838.html]].
207 +|##charset##|The charset of the file, as expressed in the HTTP ##Content-Type## header.
208 +|##author##|The user who uploaded this version of the file.
209 +|##date##|When this version was uploaded.
210 +|##version##|The version of the attachment.
211 +|##comment##|The comment attached to this version.
212 +|##content##|The binary content, serialized in base64.
213 +|##filesize##|The size of the content in bytes.
214 +|##revisions##|One ##revision## element per version of the attachment, each carrying the same elements as the attachment itself.
215 +|##contentAlias##|Written inside a ##revision## instead of ##content## when that revision shares its content with another one, and empty when the content is the one of the current attachment. This is what keeps a repeatedly saved attachment from being serialized several times.
216 +|##versions##|Deprecated in favor of ##revisions##: the history of the attachment as a JRCS archive dump.
217 +
218 +== XClass Definition ==
219 +
220 +The ##class## element is present when the Page defines an [[XClass>>doc:documentation.xs.dev.data-model.x-classes.WebHome]]. Its fixed elements come first, and every element after them is one property of the XClass.
221 +
222 +|=Element|=Description
223 +|##name##|The reference of the Page the XClass is attached to, which is also the name of the XClass.
224 +|##customClass##|The Java class used in place of the standard one to represent the XObjects of this XClass.
225 +|##customMapping##|The Hibernate mapping storing the XObjects of this XClass in their own database table instead of the generic object tables.
226 +|##validationScript##|The script executed to validate an XObject of this XClass before it is saved.
227 +|##defaultViewSheet##, ##defaultEditSheet##, ##defaultWeb##, ##nameField##|Legacy elements, kept for backward compatibility and left empty by the XClasses XWiki ships.
228 +|One element per property, named after it|The definition of that [[property>>doc:documentation.xs.dev.data-model.x-properties.WebHome]]. ##classType## names the Java class implementing its type, and the other elements are the fields of that type, so they differ from one property to the next: the ##Date## property above has ##dateFormat## and ##emptyIsToday##, the ##String## property has ##size##.
229 +
230 +== XObjects ==
231 +
232 +There is one ##object## element per [[XObject>>doc:documentation.xs.dev.data-model.x-objects.WebHome]] the Page holds.
233 +
234 +|=Element|=Description
235 +|##name##|The reference of the Page the XObject belongs to.
236 +|##number##|The index of the XObject among the ones of the same XClass on that Page, starting at ##0##.
237 +|##className##|The reference of the XClass the XObject is an instance of.
238 +|##guid##|The unique identifier of the XObject.
239 +|##class##|A copy of the XClass definition as it was when the archive was written, with the same elements as the ##class## element above. It is what makes an XObject readable even when the Page defining its XClass is not in the archive.
240 +|##property##|One per property value. Its single child element is named after the property and holds the value. Its ##type## attribute names the property type, which is what allows the value to be read when the XClass is missing altogether.
DocApp.Code.DocumentationClass[0]
FAQ
... ... @@ -1,7 +1,11 @@
1 -== How are page dates (creation date, last edit date) stored in XAR files? ==
1 +== How are Page dates stored in the XML? ==
2 2  
3 -All dates are stored as numeric timestamps, representing the number of milliseconds elapsed since January 1, 1970, 00:00:00 (GMT). For example, the value 1700000000000 corresponds to November 14, 2023, 22:13:20 (GMT).
3 +Every date is the number of milliseconds elapsed since January 1, 1970, 00:00:00 (GMT). The value ##1700000000000##, for instance, is November 14, 2023, 22:13:20 (GMT).
4 4  
5 -== How is the translation of a Page conveyed in the XML format? ==
5 +== How is a translation of a Page represented? ==
6 6  
7 -The [[translation>>documentation.xs.user.base.page.view.translate.translations.WebHome]] of a Page has a separate XML Page, as it's treated in the wiki as a separate Page.
7 +Each [[translation>>documentation.xs.user.base.page.view.translate.translations.WebHome]] has its own XML file, named after the Page plus its locale, as in ##WebHome.fr.xml##, because the wiki stores it as a separate Page.
8 +
9 +== How can I tell from the XML whether a Page is terminal? ==
10 +
11 +The ##name## element is ##WebHome## for a non-terminal Page and the name of the Page itself for a [[terminal>>documentation.xs.user.base.page.nested-pages.relations.WebHome]] one, and the last segment of the ##reference## attribute says the same.
Related
... ... @@ -1,0 +1,3 @@
1 +* [[XAR Export as a Backup Method>>documentation.xs.admin.backup.xar-export.WebHome]].
2 +* [[XWiki Classes>>documentation.xs.dev.data-model.x-classes.WebHome]].
3 +* [[XWiki Objects>>documentation.xs.dev.data-model.x-objects.WebHome]].
DocApp.Code.DocumentationExtensionClass[0]
Technical Identifier
... ... @@ -1,0 +1,1 @@
1 +xwiki:org.xwiki.platform:xwiki-platform-xar

Summary

Details

Page properties
Content
... ... @@ -1,4 +1,4 @@
1 -To [[export>>documentation.xs.admin.]] content in [[##XAR## format>>extensions:Extension.XAR Module Specifications]]:
1 +To [[export>>doc:documentation.xs.admin.exports.WebHome]] content in [[##XAR## format>>doc:documentation.xs.admin.exports.export-content-xar-format.format-specifications.WebHome]]:
2 2  
3 3  1. [[Administer your wiki>>xwiki:documentation.xs.admin.base.content-organization.administer-wiki.WebHome]].
4 4  1. Select "Content", and then select "Export" from the dropdown.(((
... ... @@ -10,7 +10,7 @@
10 10  )))
11 11  * If the Page/s you want to export include extension Pages, it is useful to use the "Select from" dropdown described in the [[Export modal>>documentation.xs.user.exports.export-page.modal.WebHome]] Page.
12 12  )))
13 -1. Configure the following settings as needed. These additional settings for exporting ##XARs## are not available when [[exporting directly from viewing a Page>>documentation.xs.admin.exports.WebHome]].(((
13 +1. Configure the following settings as needed. These additional settings for exporting ##XARs## are not available when [[exporting directly from viewing a Page>>doc:documentation.xs.user.exports.export-page.WebHome]].(((
14 14  {{image reference="additional-settings-export-xar.png" size="large" alt="Additional export settings for XARs"/}}
15 15  
16 16  * "With history": You can include the [[Page history>>documentation.xs.user.base.page.view.view-history.history-tab.WebHome]] in the export. If not checked, only the [[latest version>>documentation.xs.user.base.page.view.view-history.major-minor-versions.WebHome]] of a Page is exported.
... ... @@ -21,7 +21,7 @@
21 21  1. Configure "More options" for exporting ##XARs##:(((
22 22  {{image reference="options-export-xar.png" size="large" alt="More options to configure exporting XARs"/}}
23 23  
24 -* "Description*: The package description that will be displayed when [[importing the package>>documentation.xs.admin.imports.WebHome]].
24 +* "Description": The package description that will be displayed when [[importing the package>>documentation.xs.admin.imports.WebHome]].
25 25  * "Author": The [[author>>documentation.xs.user.base.page.authors.WebHome]] displayed when importing.
26 26  * "License": This refers to the content license applied to the package, which defines the terms under which the content can be used, modified, and distributed. Examples of licenses include LGPL, GPLv2, etc.
27 27  * "Version": This refers to the version of the package, which is stored in the package descriptor. It indicates the specific version of the package and helps track updates or changes made to it.
DocApp.Code.DocumentationExtensionClass[0]
Technical Identifier
... ... @@ -1,1 +1,1 @@
1 -org.xwiki.platform:xwiki-platform-administration-ui
1 +xwiki:org.xwiki.platform:xwiki-platform-administration-ui

Approvers

Approvers have not been explicitly defined for this Change Request. Approvers will be based entirely on approval rights.
This Change Request is ready for review.
No conflicts to show.
The change request cannot be published without valid approval or if at least one review request for changes.

Get Connected