source: extensions/net.sf.basedb.examples/trunk/META-INF/extensions.xml @ 636

Last change on this file since 636 was 636, checked in by Nicklas Nordborg, 14 years ago

References #103: Create example extensions

First checkin of example extensions.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Date Id
File size: 2.7 KB
Line 
1<?xml version="1.0" encoding="UTF-8" ?>
2<extensions xmlns="http://base.thep.lu.se/extensions.xsd">
3  <extension
4    id="net.sf.basedb.clients.web.menu.extensions.helloworld"
5    extends="net.sf.basedb.clients.web.menu.extensions"
6    >
7    <index>1</index>
8    <about>
9      <name>Hello world</name>
10      <description>
11        The very first extensions example. Adds a "Hello world"
12        menu item that displays "Hello world" in a javascript
13        popup when selected.
14      </description>
15    </about>
16    <action-factory>
17      <factory-class>
18        net.sf.basedb.clients.web.extensions.menu.FixedMenuItemFactory
19      </factory-class>
20      <parameters>
21        <title>Hello world!</title>
22        <tooltip>This is to test the extensions system</tooltip>
23        <onClick>alert('Hello world!')</onClick>
24        <icon>/images/info.gif</icon>
25      </parameters>
26    </action-factory>
27  </extension>
28 
29  <extension
30    id="net.sf.basedb.clients.web.menu.extensions.helloworldfactory"
31    extends="net.sf.basedb.clients.web.menu.extensions"
32    >
33    <index>2</index>
34    <about>
35      <name>Hello factory world</name>
36      <description>
37        A "Hello world" variant with a custom action factory.
38        Everything is hard-coded into the factory.
39      </description>
40    </about>
41    <action-factory>
42      <factory-class>
43        net.sf.basedb.examples.extensions.HelloWorldFactory
44      </factory-class>
45    </action-factory>
46  </extension>
47 
48  <extension
49    id="net.sf.basedb.clients.web.menu.extensions.hellouser"
50    extends="net.sf.basedb.clients.web.menu.extensions"
51    >
52    <index>3</index>
53    <about>
54      <name>Greetings user</name>
55      <description>
56        A "Hello world" variant with a custom action factory
57        that displays "Greetings {name of user}" instead. We also
58        make the icon configurable.
59      </description>
60    </about>
61    <action-factory>
62      <factory-class>
63        net.sf.basedb.examples.extensions.HelloUserFactory
64      </factory-class>
65      <parameters>
66        <prefix>Greetings</prefix>
67        <icon>/images/take_ownership.png</icon>
68      </parameters>
69    </action-factory>
70  </extension>
71
72  <extension
73    id="net.sf.basedb.clients.web.menu.extensions.hellojspworld"
74    extends="net.sf.basedb.clients.web.menu.extensions"
75    >
76    <index>4</index>
77    <about>
78      <name>Hello JSP world</name>
79      <description>
80        This example uses a custom JSP page to display the
81        "Hello world" message instead of a javascript popup.
82      </description>
83    </about>
84    <action-factory>
85      <factory-class>
86        net.sf.basedb.clients.web.extensions.menu.FixedMenuItemFactory
87      </factory-class>
88      <parameters>
89        <title>Hello JSP world!</title>
90        <tooltip>Opens a JSP page with the message</tooltip>
91        <onClick>Main.openPopup('$HOME$/hello_world.jsp?ID=' + getSessionId(), 'HelloJspWorld', 400, 300)</onClick>
92        <icon>~/images/world.png</icon>
93      </parameters>
94    </action-factory>
95  </extension>
96
97</extensions>
Note: See TracBrowser for help on using the repository browser.