XClass Application

Last modified by Michael Hamann on 2024/07/05 14:34

building_editHelper pages for creating and listing Class/Template/Sheets
TypeXAR
CategoryApplication
Developed by

XWiki Development Team

Rating
1 Votes
LicenseGNU Lesser General Public License 2.1
Bundled With

XWiki Standard

Description

Use this application when you wish to get direction for creating XWiki Classes, Sheets and Templates page.

At the moment this application has no entry point in XWiki's UI and you need to navigate to the XWiki.XWikiClasses page directly (for example by modifying the URL directly: e.g. http://<server>/xwiki/bin/view/XWiki/XWikiClasses). All the pages from this application are hidden by default and you won't get them in search results by default; you'll need to modify your user's profile to list hidden pages to see them in listings.

To learn how to use this application, there's a tutorial showing it in action for creating a FAQ application.

Data Types

This application provides a page (XWiki.XWikiClasses) where you can see the list of existing data types (classes) and you can create a new data type. On this page you will also find links to some templates and sheets that are useful when creating a new class.

XWiki 

dataTypes.png

XWiki 13.10+

dataTypes-LD.png

Default Class Sheet

This application also provides a default sheet (XWiki.ClassSheet) that can be applied on any class and which displays:

  • the list of class properties, with their pretty name, name and type
  • the list of existing class entries (pages that have an object of that type)
  • the available class sheets
  • the class template

This page allows you to perform the following actions:

  • create a new class entry
  • create a sheet for the class and bind it to the class
  • create a template for the class and add the required object
  • XWiki 11.8+ create a template provider (only after the template was created)

XWiki 

classSheet.png

XWiki 13.10+

classSheet-LD.png

Default Object Sheet

This application also provides a default sheet (XWiki.ObjectSheet) that can be copied and modified to display the objects (instances) of a given class (data type). The default object sheet iterates over all the properties of specified class, displaying:

  • the translated property pretty name
  • the translated property hint
  • the property value (from the displayed object, in view mode) or the form field to edit the property value (in edit mode)

It uses the Vertical Form layout and, starting with XWiki 12.4RC1, it supports in-place editing.

If you copy the code of the default object sheet then make sure you update the name of the class (data type) used in the code. This is done automatically for you if you create your object sheet using the button displayed by the default class sheet mentioned above.

Get Connected