Wiki Custom Properties API
Provides a scripting API to access and manage generic custom properties in the wiki descriptor |
Type | JAR |
Category | |
Developed by | |
Active Installs | 0 |
Rating | |
License | GNU Lesser General Public License 2.1 |
Table of contents
Description
The main purpose of this extension is to provide a simplified solution to add some properties to wiki descriptor. It implements a generic WikiPropertyGroup that may persist its properties into an object of XClass XWiki.XWikiExtendedServerClass stored into the same document than the default descriptor. To have your properties persisted, you need to define those properties into this new XClass.
Script Service: $services.wiki.customproperties
This script services allow easy management of the properties from velocity. To be able to change or persist properties, you need to have admin access on the wiki your are editing. The API provides the following features:
Get the value of <propertyName> custom property from the cached descriptor of the current wiki:
Get the value of <propertyName> custom property from the cached descriptor of the <wikiId> wiki:
Set the value of the <propertyName> property in the cached descriptor of the current wiki and save it into the database.
Set the value of the <propertyName> property in the cached descriptor of the <wikiId> wiki and save it into the database.
Set the value of <propertyName> custom property in the cached descriptor of the current wiki:
Set the value of <propertyName> custom property in the cached descriptor of the <wikiId> wiki:
Save into the database the custom property values currently stored in the cached descriptor of the current wiki:
Save into the database the custom property values currently stored in the cached descriptor of the <wikiId> wiki:
For more details, you can consult the javadoc.
Java API
For details about the Java API, you can consult the javadoc of the WikiCustomPropertiesManager class.
Prerequisites & Installation Instructions
We recommend using the Extension Manager to install this extension (Make sure that the text "Installable with the Extension Manager" is displayed at the top right location on this page to know if this extension can be installed with the Extension Manager).
You can also use the manual method which involves dropping the JAR file and all its dependencies into the WEB-INF/lib folder and restarting XWiki.
Dependencies
Dependencies for this extension (org.xwiki.contrib:api-wiki-customproperties 1.0):
- org.xwiki.commons:xwiki-commons-component-api 5.3
- org.xwiki.platform:xwiki-platform-wiki-api 5.3
- org.xwiki.platform:xwiki-platform-wiki-default 5.3
- org.xwiki.platform:xwiki-platform-oldcore 5.3
- org.xwiki.platform:xwiki-platform-security-api 5.3
- org.xwiki.commons:xwiki-commons-script 5.3