Module Structure: Difference between revisions
(New page: =What is a Module= =Module Configuration File= A module exists by defining its configuration files. There is one top-level node <I2CEConfiguration> under which there are two possible nod...) |
No edit summary |
||
Line 11: | Line 11: | ||
<nowiki><!ELEMENT metadata (</nowiki>[[#displayName]],[[#className]]?,[[#category]]?,[[#description]]?,[[#creator]]?,[[#email]]?,[[#link]]?,[[#version]],([[#enable]]|[#requirement]]|[[#conflict]]|[[#path]])*,[[#priority]]?<nowiki>)></nowiki> | <nowiki><!ELEMENT metadata (</nowiki>[[#displayName]],[[#className]]?,[[#category]]?,[[#description]]?,[[#creator]]?,[[#email]]?,[[#link]]?,[[#version]],([[#enable]]|[#requirement]]|[[#conflict]]|[[#path]])*,[[#priority]]?<nowiki>)></nowiki> | ||
For the most part, the orders of these tags matter due to limitations in the structure of DTDs. The exceptions is that the <enabled>, <requirement>, <conflict> and <path> tags can be listed in any order amongst themselves. | For the most part, the orders of these tags matter due to limitations in the structure of DTDs. The exceptions is that the <enabled>, <requirement>, <conflict> and <path> tags can be listed in any order amongst themselves. | ||
===displayName== | ===displayName=== | ||
This tag is requireed it is human readable name of this module which is displayed, for example, in the ''Configure Modules'' pa | This tag is requireed it is human readable name of this module which is displayed, for example, in the ''Configure Modules'' pa | ||
Example: <displayName>Popup Box</displayName> | Example: <displayName>Popup Box</displayName> | ||
===className== | ===className=== | ||
The tag is optional and it associates a class for the module. See [[#The Module Class]] for specific information about the module's class | The tag is optional and it associates a class for the module. See [[#The Module Class]] for specific information about the module's class | ||
Example: <className>I2CE_Module_JavascriptPopup</className> | Example: <className>I2CE_Module_JavascriptPopup</className> |
Revision as of 10:29, 11 March 2009
What is a Module
Module Configuration File
A module exists by defining its configuration files. There is one top-level node <I2CEConfiguration> under which there are two possible nodes:
- The #metadata tag is required.
- The <configurationGroup> tag is optional.
The <I2CEConfiguration> tag has a required attribute name whose values should be a unique short name to describe this module such as I2CE, ihris-manage or my_custom_module. The DTD which describes the format of the configuration file is located in I2CE/lib/I2CE_Configuration.DTD.
metadata
The DTD has for the <metadata> tag allows the following nodes:
<!ELEMENT metadata (#displayName,#className?,#category?,#description?,#creator?,#email?,#link?,#version,(#enable|[#requirement]]|#conflict|#path)*,#priority?)>
For the most part, the orders of these tags matter due to limitations in the structure of DTDs. The exceptions is that the <enabled>, <requirement>, <conflict> and <path> tags can be listed in any order amongst themselves.
displayName
This tag is requireed it is human readable name of this module which is displayed, for example, in the Configure Modules pa
Example: <displayName>Popup Box</displayName>
className
The tag is optional and it associates a class for the module. See #The Module Class for specific information about the module's class
Example: <className>I2CE_Module_JavascriptPopup</className>
category
This is an optional tag that is used to group similar modules together by category in the Configure Modules page.
Example: <category>Javascript Library</category>
description
This is an optional tag which gives a description of this module which is displayed in the Configure Modules page.
Example: <description>Provides a javascript popup box</description>
creator
This is an optional tag which shows the creator in the Configure Modules page.
Example: <creator>Freddy Mercury</creator>
link
This is an optional tag which gives a URL for the module in the 'Configure Modules page.
Example: <link>http://en.wikipedia.org/wiki/Freddie_Mercury</link>
version
This is a required tag which you can use to version your module.
Example: <version>1.0.0</version>
requirement
conflict
enable
path
priority
Module Paths
Configuration (Magic) Data
See Technical Overview: Configuration (Magic) Data for more background information.